From: Benjamin Tissoires <benjamin.tissoi...@redhat.com> In the general case, the resources are properly released by devm without needing to do anything. However, when unplugging the wireless receiver, the kernel segfaults from time to time while calling devres_release_all().
I think in that case the resources attempt to access hid_get_drvdata(hdev) which has been set to null while leaving wacom_remove(). Signed-off-by: Benjamin Tissoires <benjamin.tissoi...@redhat.com> Acked-by: Jason Gerecke <jason.gere...@wacom.com> Signed-off-by: Jiri Kosina <jkos...@suse.cz> [jason.gere...@wacom.com: Imported into input-wacom repository (5b779fc)] Signed-off-by: Jason Gerecke <jason.gere...@wacom.com> [aaron.sko...@wacom.com: Backported from input-wacom repository (4c399ab)] Signed-off-by: Aaron Armstrong Skomra <aaron.sko...@wacom.com> --- 3.17/wacom_sys.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/3.17/wacom_sys.c b/3.17/wacom_sys.c index 5c4773a..89cc6a4 100644 --- a/3.17/wacom_sys.c +++ b/3.17/wacom_sys.c @@ -2353,6 +2353,8 @@ static void wacom_remove(struct hid_device *hdev) #endif wacom_remove_shared_data(wacom); + wacom_release_resources(wacom); + hid_set_drvdata(hdev, NULL); } -- 2.7.4 ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel