diff options
author | Henrique de Moraes Holschuh <hmh@hmh.eng.br> | 2008-01-08 13:02:39 -0200 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2008-02-01 22:26:06 -0500 |
commit | b2c985e7eba858a1765db6d56bdd4df775f53633 (patch) | |
tree | 938b712a2ae312a1876a04ff830c1411f7eeab4a /drivers/misc/thinkpad_acpi.h | |
parent | 0f089147e620e083f58a0e641f701bd4244b455b (diff) |
ACPI: thinkpad-acpi: refactor hotkey_get and hotkey_set (v2)
Refactor and organize the code a bit for the NVRAM polling support:
1. Split hotkey_get/set into hotkey_status_get/set and hotkey_mask_get/set;
2. Cache the status of hot key mask for later driver use;
3. Make sure the cache of hot key mask is refreshed when needed;
4. log a printk notice when the firmware doesn't set the hot key
mask to exactly what we asked it to;
5. Add proper locking to the data structures.
Only (4) should be user-noticeable, but there is a chance (5) fixes
some unknown/unreported race conditions.
Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/misc/thinkpad_acpi.h')
-rw-r--r-- | drivers/misc/thinkpad_acpi.h | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/misc/thinkpad_acpi.h b/drivers/misc/thinkpad_acpi.h index 8fba2bbe345e..3b0313443138 100644 --- a/drivers/misc/thinkpad_acpi.h +++ b/drivers/misc/thinkpad_acpi.h @@ -461,8 +461,6 @@ static struct mutex hotkey_mutex; static int hotkey_init(struct ibm_init_struct *iibm); static void hotkey_exit(void); -static int hotkey_get(int *status, u32 *mask); -static int hotkey_set(int status, u32 mask); static void hotkey_notify(struct ibm_struct *ibm, u32 event); static int hotkey_read(char *p); static int hotkey_write(char *buf); |