platform/x86: dell-laptop: Add keyboard backlight timeout AC settings
When changing keyboard backlight state on new Dell laptops, firmware
expects a new timeout AC value filled in Set New State SMBIOS call.
Without it any change of keyboard backlight state on new Dell laptops
fails. And user can see following error message in dmesg:
dell_laptop: Setting old previous keyboard state failed
leds dell::kbd_backlight: Setting an LED's brightness failed (-6)
This patch adds support for retrieving current timeout AC values and also
updating them. Current timeout value in sysfs is displayed based on current
AC status, like current display brightness value.
Detection if Dell laptop supports or not new timeout AC settings is done by
checking existence of Keyboard Backlight with AC SMBIOS token (0x0451).
Signed-off-by: Pali Rohár <pali.rohar@gmail.com>
Acked-by: Mario Limonciello <mario.limonciello@dell.com>
Tested-by: Arcadiy Ivanov <arcadiy@ivanov.biz>
[andy: fixed merge conflict with defined constants]
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>