diff options
author | Henrique de Moraes Holschuh <hmh@hmh.eng.br> | 2009-09-12 15:22:17 -0300 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2009-09-19 00:54:04 -0400 |
commit | 230d8cf25ac32c7d2fdb4dda861ec5d954000ffb (patch) | |
tree | 9a5669e8574cea3a5fc715c93681caa0f0eaf1fe /drivers/platform/x86/thinkpad_acpi.c | |
parent | 20c9aa46f644b3ddb161a819d1b0c2b07097c4ee (diff) | |
download | kernel_samsung_smdk4412-230d8cf25ac32c7d2fdb4dda861ec5d954000ffb.zip kernel_samsung_smdk4412-230d8cf25ac32c7d2fdb4dda861ec5d954000ffb.tar.gz kernel_samsung_smdk4412-230d8cf25ac32c7d2fdb4dda861ec5d954000ffb.tar.bz2 |
thinkpad-acpi: don't poll by default any of the reserved hotkeys
Init hotkey_source_mask late, so that we can make use of
hotkey_reserved_mask to avoid polling any of the reserved
hotkeys by default.
Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/platform/x86/thinkpad_acpi.c')
-rw-r--r-- | drivers/platform/x86/thinkpad_acpi.c | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c index dd779e5..9c3bb0c 100644 --- a/drivers/platform/x86/thinkpad_acpi.c +++ b/drivers/platform/x86/thinkpad_acpi.c @@ -3062,19 +3062,6 @@ static int __init hotkey_init(struct ibm_init_struct *iibm) goto err_exit; } -#ifdef CONFIG_THINKPAD_ACPI_HOTKEY_POLL - if (tp_features.hotkey_mask) { - hotkey_source_mask = TPACPI_HKEY_NVRAM_GOOD_MASK - & ~hotkey_all_mask; - } else { - hotkey_source_mask = TPACPI_HKEY_NVRAM_GOOD_MASK; - } - - vdbg_printk(TPACPI_DBG_INIT | TPACPI_DBG_HKEY, - "hotkey source mask 0x%08x, polling freq %u\n", - hotkey_source_mask, hotkey_poll_freq); -#endif - #ifdef CONFIG_THINKPAD_ACPI_DEBUGFACILITIES if (dbg_wlswemul) { tp_features.hotkey_wlsw = 1; @@ -3186,6 +3173,21 @@ static int __init hotkey_init(struct ibm_init_struct *iibm) | (1 << TP_ACPI_HOTKEYSCAN_FNEND); } +#ifdef CONFIG_THINKPAD_ACPI_HOTKEY_POLL + if (tp_features.hotkey_mask) { + hotkey_source_mask = TPACPI_HKEY_NVRAM_GOOD_MASK + & ~hotkey_all_mask + & ~hotkey_reserved_mask; + } else { + hotkey_source_mask = TPACPI_HKEY_NVRAM_GOOD_MASK + & ~hotkey_reserved_mask; + } + + vdbg_printk(TPACPI_DBG_INIT | TPACPI_DBG_HKEY, + "hotkey source mask 0x%08x, polling freq %u\n", + hotkey_source_mask, hotkey_poll_freq); +#endif + dbg_printk(TPACPI_DBG_INIT | TPACPI_DBG_HKEY, "enabling firmware HKEY event interface...\n"); res = hotkey_status_set(true); |