From: Carlo Caione Date: Tue, 30 May 2017 20:39:46 +0000 (+0200) Subject: HID: asus: Stop underlying hardware on remove X-Git-Tag: v4.14-rc1~814^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=715e944f8a7a1059db5d61ebf197e6f348d747e2;p=platform%2Fkernel%2Flinux-rpi.git HID: asus: Stop underlying hardware on remove We are missing a call to hid_hw_stop() on the remove hook. Among other things this is causing an Oops when (re-)starting GNOME / upowerd / ... after the module has been already rmmod-ed. Signed-off-by: Carlo Caione Reviewed-by: Benjamin Tissoires Signed-off-by: Jiri Kosina --- diff --git a/drivers/hid/hid-asus.c b/drivers/hid/hid-asus.c index 101ab2e..a6268f2 100644 --- a/drivers/hid/hid-asus.c +++ b/drivers/hid/hid-asus.c @@ -537,6 +537,8 @@ static void asus_remove(struct hid_device *hdev) drvdata->kbd_backlight->removed = true; cancel_work_sync(&drvdata->kbd_backlight->work); } + + hid_hw_stop(hdev); } static __u8 *asus_report_fixup(struct hid_device *hdev, __u8 *rdesc,