mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-12 05:24:12 +08:00
asus-wmi: fix keyboard backlight detection
Signed-off-by: Corentin Chary <corentin.chary@gmail.com> Signed-off-by: Matthew Garrett <mjg@redhat.com>
This commit is contained in:
parent
8fe8c25ef9
commit
af965e9732
@ -395,8 +395,9 @@ static int kbd_led_read(struct asus_wmi *asus, int *level, int *env)
|
||||
retval = asus_wmi_get_devstate_bits(asus, ASUS_WMI_DEVID_KBD_BACKLIGHT,
|
||||
0xFFFF);
|
||||
|
||||
/* Unknown status is considered as off */
|
||||
if (retval == 0x8000)
|
||||
retval = -ENODEV;
|
||||
retval = 0;
|
||||
|
||||
if (retval >= 0) {
|
||||
if (level)
|
||||
|
Loading…
Reference in New Issue
Block a user