1 From 3e5ce914bd17335ca74a7c7b06a776c6be6ca434 Mon Sep 17 00:00:00 2001
2 From: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
3 Date: Sun, 23 Sep 2007 11:39:05 -0300
4 Subject: [PATCH 10/23] ACPI: thinkpad-acpi: fix regression on HKEY LID event handling
6 We were letting ThinkPad-specific LID events through to userspace again,
7 instead of dropping them. Fix it. We don't want to give userspace the
8 option of not using generic LID handling.
10 Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
11 Signed-off-by: Len Brown <len.brown@intel.com>
13 drivers/misc/thinkpad_acpi.c | 9 +++++++--
14 1 files changed, 7 insertions(+), 2 deletions(-)
16 diff --git a/drivers/misc/thinkpad_acpi.c b/drivers/misc/thinkpad_acpi.c
17 index 3efe81b..0a33c6e 100644
18 --- a/drivers/misc/thinkpad_acpi.c
19 +++ b/drivers/misc/thinkpad_acpi.c
20 @@ -1197,6 +1197,7 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
22 unsigned int keycode, scancode;
27 printk(IBM_ERR "unknown HKEY notification event %d\n", event);
28 @@ -1219,6 +1220,7 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
36 @@ -1244,6 +1246,8 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
37 "unknown LID-related HKEY event: 0x%04x\n",
45 @@ -1263,11 +1267,12 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
49 - if (send_acpi_ev || hotkey_report_mode < 2)
50 + if (!ignore_acpi_ev && (send_acpi_ev || hotkey_report_mode < 2)) {
51 acpi_bus_generate_proc_event(ibm->acpi->device, event, hkey);
56 + if (!ignore_acpi_ev && send_acpi_ev) {
57 acpi_bus_generate_netlink_event(ibm->acpi->device->pnp.device_class,
58 ibm->acpi->device->dev.bus_id,