summaryrefslogtreecommitdiffstats
path: root/drivers/platform/x86/asus-wmi.h
diff options
context:
space:
mode:
authorOleksij Rempel <linux@rempel-privat.de>2017-04-28 16:19:49 +0200
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>2017-04-28 21:52:24 +0300
commite9b615186805e2c18a0ac76aca62c1543ecfdbb8 (patch)
tree00ec5f244ee853f85c8dd5ebfea974b7e9b1f980 /drivers/platform/x86/asus-wmi.h
parenta8fe342856e5bce71a43201eb2870bd059483d2f (diff)
downloadlinux-e9b615186805e2c18a0ac76aca62c1543ecfdbb8.tar.gz
linux-e9b615186805e2c18a0ac76aca62c1543ecfdbb8.tar.bz2
linux-e9b615186805e2c18a0ac76aca62c1543ecfdbb8.zip
platform/x86: asus-wmi: try to set als by default
some laptops, for example ASUS UX330UAK, have brocken als_get function but working als_set funktion. In this case, ALS will stay turned off. Method (WMNB, 3, Serialized) { ... If (Local0 == 0x53545344) { ... If (IIA0 == 0x00050001) { If (!ALSP) { Return (0x02) } Local0 = (GALS & 0x10) <<<---- bug, should be: (GALS () & 0x10) If (Local0) { Return (0x00050001) } Else { Return (0x00050000) } } ..... If (Local0 == 0x53564544) { ... If (IIA0 == 0x00050001) { Return (ALSC (IIA1)) } ...... Method (GALS, 0, NotSerialized) { Local0 = Zero Local0 |= 0x20 If (ALAE) { Local0 |= 0x10 } Local1 = 0x0A Local1 <<= 0x08 Local0 |= Local1 Return (Local0) } Since it works without problems on Windows I assume ASUS WMI driver for Win never trying to get ALS state, and instead it is setting it by default to ON. This patch will do the same. Turn ALS on by default. Signed-off-by: Oleksij Rempel <linux@rempel-privat.de> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Diffstat (limited to 'drivers/platform/x86/asus-wmi.h')
-rw-r--r--drivers/platform/x86/asus-wmi.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/platform/x86/asus-wmi.h b/drivers/platform/x86/asus-wmi.h
index c9589d9342bb..6c1311f4b04d 100644
--- a/drivers/platform/x86/asus-wmi.h
+++ b/drivers/platform/x86/asus-wmi.h
@@ -44,6 +44,7 @@ struct quirk_entry {
bool store_backlight_power;
bool wmi_backlight_power;
bool wmi_backlight_native;
+ bool wmi_force_als_set;
int wapf;
/*
* For machines with AMD graphic chips, it will send out WMI event