提交 c1c454b8 编写于 作者: K K. Y. Srinivasan 提交者: Jiri Kosina

HID: hyperv: Properly disconnect the input device

When we unload the mouse driver, properly disconnect the input device.
Signed-off-by: NK. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: NHaiyang Zhang <haiyangz@microsoft.com>
Reported-by: NFuzhou Chen <fuzhouch@microsoft.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: NJiri Kosina <jkosina@suse.cz>
上级 ba18311d
...@@ -548,6 +548,7 @@ static int mousevsc_remove(struct hv_device *dev) ...@@ -548,6 +548,7 @@ static int mousevsc_remove(struct hv_device *dev)
struct mousevsc_dev *input_dev = hv_get_drvdata(dev); struct mousevsc_dev *input_dev = hv_get_drvdata(dev);
vmbus_close(dev->channel); vmbus_close(dev->channel);
hid_hw_stop(input_dev->hid_device);
hid_destroy_device(input_dev->hid_device); hid_destroy_device(input_dev->hid_device);
mousevsc_free_device(input_dev); mousevsc_free_device(input_dev);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册