After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 734455 - Support for Wacom LEDs in 3.17+ kernels
Support for Wacom LEDs in 3.17+ kernels
Status: RESOLVED FIXED
Product: gnome-settings-daemon
Classification: Core
Component: wacom
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Carlos Garnacho
gnome-settings-daemon-maint
Depends on:
Blocks:
 
 
Reported: 2014-08-07 21:05 UTC by Benjamin Tissoires
Modified: 2014-08-12 21:59 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
0001-wacom-check-for-the-new-HID-unified-kernel-ABI-when-.patch (1.58 KB, patch)
2014-08-07 21:19 UTC, Benjamin Tissoires
reviewed Details | Review
0001-wacom-check-for-the-new-HID-unified-kernel-ABI-when-.patch V2 (1.59 KB, patch)
2014-08-11 20:40 UTC, Benjamin Tissoires
accepted-commit_now Details | Review
wacom: check for the new HID unified kernel ABI when setting LEDs (1.61 KB, patch)
2014-08-12 14:59 UTC, Benjamin Tissoires
committed Details | Review

Description Benjamin Tissoires 2014-08-07 21:05:40 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)
Comment 1 Benjamin Tissoires 2014-08-07 21:19:42 UTC
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.
Comment 2 Bastien Nocera 2014-08-08 09:38:59 UTC
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.
Comment 3 Benjamin Tissoires 2014-08-11 20:38:00 UTC
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?
Comment 4 Benjamin Tissoires 2014-08-11 20:40:05 UTC
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".
Comment 5 Bastien Nocera 2014-08-12 10:54:48 UTC
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.
Comment 6 Benjamin Tissoires 2014-08-12 14:59:28 UTC
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.
Comment 7 Bastien Nocera 2014-08-12 21:59:54 UTC
Attachment 283207 [details] pushed as 1c6627f - wacom: check for the new HID unified kernel ABI when setting LEDs