[patch 46/46] ACPI: EC: Dont do transaction from GPE handler inpoll mode.

From: Greg KH
Date: Mon Nov 17 2008 - 02:37:45 EST


2.6.27-stable review patch. If anyone has any objections, please let us know.

------------------

From: Alexey Starikovskiy <astarikovskiy@xxxxxxx>

commit 8517934ef6aaa28d6e055b98df65b31cedbd1372 upstream.

Referencies: http://bugzilla.kernel.org/show_bug.cgi?id=12004

Signed-off-by: Alexey Starikovskiy <astarikovskiy@xxxxxxx>
Signed-off-by: Len Brown <len.brown@xxxxxxxxx>
Cc: Rafael J. Wysocki <rjw@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxx>

---
drivers/acpi/ec.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)

--- a/drivers/acpi/ec.c
+++ b/drivers/acpi/ec.c
@@ -581,9 +581,12 @@ static u32 acpi_ec_gpe_handler(void *dat
pr_debug(PREFIX "~~~> interrupt\n");
status = acpi_ec_read_status(ec);

- gpe_transaction(ec, status);
- if (ec_transaction_done(ec) && (status & ACPI_EC_FLAG_IBF) == 0)
- wake_up(&ec->wait);
+ if (test_bit(EC_FLAGS_GPE_MODE, &ec->flags)) {
+ gpe_transaction(ec, status);
+ if (ec_transaction_done(ec) &&
+ (status & ACPI_EC_FLAG_IBF) == 0)
+ wake_up(&ec->wait);
+ }

ec_check_sci(ec, status);
if (!test_bit(EC_FLAGS_GPE_MODE, &ec->flags) &&

--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/