Staging: hv: mousevsc: Free allocated memory in free_input_device()
Free all allocated memory in free_input_device(). Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
61c4fb47cf
commit
ea8646b92f
|
@ -199,6 +199,8 @@ static struct mousevsc_dev *alloc_input_device(struct hv_device *device)
|
|||
static void free_input_device(struct mousevsc_dev *device)
|
||||
{
|
||||
WARN_ON(atomic_read(&device->ref_count) != 0);
|
||||
kfree(device->hid_desc);
|
||||
kfree(device->report_desc);
|
||||
kfree(device);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue