GNOME Bugzilla – Bug 734455
Support for Wacom LEDs in 3.17+ kernels
Last modified: 2014-08-12 21:59:58 UTC
In kernel v3.17, the wacom.ko and hid-wacom.ko drivers will receive a deep cleaning. To easier future inclusion of new Wacom tablets, these two drivers have been merged and now rely on the hid subsystem. The counterpart of it is that the LEDs path that we used to find under the usb node are not here anymore, but under the hid node. g-s-d needs to be updated to match this new behaviour to continue to be able to send properly the LED commands to the devices. (I'll open a second bug for OLED because Bluetooth devices will require a little bit more work)
Created attachment 282846 [details] [review] 0001-wacom-check-for-the-new-HID-unified-kernel-ABI-when-.patch Quick and dirty patch for g-s-d master. Please refrain to commit or fix the bug by an other mean until the patch series hits Linus' tree. The pull request should be out shortly (patches are in https://git.kernel.org/cgit/linux/kernel/git/dtor/input.git/log/?h=for-linus), but until it is not in the master tree, anything can happen.
Review of attachment 282846 [details] [review]: Rest looks fine. ::: plugins/wacom/gsd-wacom-led-helper.c @@ +90,3 @@ + g_free (status); + g_object_unref (parent); + if(access (filename, F_OK) != -1 ) { use g_file_test() instead.
Review of attachment 282846 [details] [review]: ::: plugins/wacom/gsd-wacom-led-helper.c @@ +94,3 @@ + return filename; + } + g_free (filename); in #734458, you complained about a "g_clear_pointer (&filename, g_free);" instead. Shall I use it here too?
Created attachment 283138 [details] [review] 0001-wacom-check-for-the-new-HID-unified-kernel-ABI-when-.patch V2 V2 of the patch, without the use of "g_clear_pointer".
Review of attachment 283138 [details] [review]: Rest looks good. ::: plugins/wacom/gsd-wacom-led-helper.c @@ +94,3 @@ + return filename; + } + g_free (filename); g_clear_pointer() would be nice here as well, to avoid leaving the filename pointer dangling.
Created attachment 283207 [details] [review] wacom: check for the new HID unified kernel ABI when setting LEDs In kernel v3.17 and later, the Wacom LED sysfs attribute is located under the HID node, not the USB one. This new path is now common between USB and Bluetooth, so no special handling is required for Bluetooth now. Check for its availability first, and then fall back on the old path.
Attachment 283207 [details] pushed as 1c6627f - wacom: check for the new HID unified kernel ABI when setting LEDs