aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/platform/x86/hp-wmi.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/platform/x86/hp-wmi.c b/drivers/platform/x86/hp-wmi.c
index d111c8687f9b..6e142c3b5e97 100644
--- a/drivers/platform/x86/hp-wmi.c
+++ b/drivers/platform/x86/hp-wmi.c
@@ -53,6 +53,7 @@ MODULE_ALIAS("wmi:5FB7F034-2C63-45e9-BE91-3D44E2C707E4");
53#define HPWMI_ALS_QUERY 0x3 53#define HPWMI_ALS_QUERY 0x3
54#define HPWMI_HARDWARE_QUERY 0x4 54#define HPWMI_HARDWARE_QUERY 0x4
55#define HPWMI_WIRELESS_QUERY 0x5 55#define HPWMI_WIRELESS_QUERY 0x5
56#define HPWMI_BIOS_QUERY 0x9
56#define HPWMI_HOTKEY_QUERY 0xc 57#define HPWMI_HOTKEY_QUERY 0xc
57#define HPWMI_WIRELESS2_QUERY 0x1b 58#define HPWMI_WIRELESS2_QUERY 0x1b
58 59
@@ -291,6 +292,19 @@ static int hp_wmi_tablet_state(void)
291 return (state & 0x4) ? 1 : 0; 292 return (state & 0x4) ? 1 : 0;
292} 293}
293 294
295static int hp_wmi_enable_hotkeys(void)
296{
297 int ret;
298 int query = 0x6e;
299
300 ret = hp_wmi_perform_query(HPWMI_BIOS_QUERY, 1, &query, sizeof(query),
301 0);
302
303 if (ret)
304 return -EINVAL;
305 return 0;
306}
307
294static int hp_wmi_set_block(void *data, bool blocked) 308static int hp_wmi_set_block(void *data, bool blocked)
295{ 309{
296 enum hp_wmi_radio r = (enum hp_wmi_radio) data; 310 enum hp_wmi_radio r = (enum hp_wmi_radio) data;
@@ -948,6 +962,8 @@ static int __init hp_wmi_init(void)
948 err = hp_wmi_input_setup(); 962 err = hp_wmi_input_setup();
949 if (err) 963 if (err)
950 return err; 964 return err;
965
966 hp_wmi_enable_hotkeys();
951 } 967 }
952 968
953 if (bios_capable) { 969 if (bios_capable) {