]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
HID: asus: support backlight on USB keyboards
authorCarlo Caione <carlo@endlessm.com>
Thu, 6 Apr 2017 10:18:17 +0000 (12:18 +0200)
committerJiri Kosina <jkosina@suse.cz>
Wed, 12 Apr 2017 20:30:29 +0000 (22:30 +0200)
commitaf22a610bc38508d5ea760507d31be6b6983dfa8
tree98aea4d9d982ce18522e0dfc6ac37dec4507689e
parent802b24b475e459e985681d6e0815ae6cb52e5560
HID: asus: support backlight on USB keyboards

The latest USB keyboards shipped on several ASUS laptop models
(including ROG laptop models such as GL702VMK) have the keyboards
backlight controlled by the keyboard firmware.

The firmware implements at least 3 different commands:
- Init command (to use when the system starts)
- Configuration command (to get keyboard status/information)
- Backlight level control (to change the level of the keyboard light)

With this patch we create the usual 'asus::kbd_backlight' led class
entry to control the keyboard backlight.

[jkosina@suse.cz: remove pointless cancel_work_sync() call while
 handling an error in asus_kbd_register_leds(), as spotted by
 Benjamin]

Signed-off-by: Carlo Caione <carlo@endlessm.com>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/Kconfig
drivers/hid/hid-asus.c