Messages in this thread Patch in this message | | | Date | Sat, 11 Oct 2008 22:39:02 +0400 | From | Alexey Starikovskiy <> | Subject | Re: acpi-test tree on eeepc: EC error message on second resume |
| |
Alan Jenkins wrote: > I think I found the problem. The "input buffer empty" wait depends on > "interrupt mode" to work properly, and we don't immediately enable the > interrupt on resume. The wait should have a polling fallback anyway, to > be consistent with the other transaction waits. > > Alan Yep, I think something like attached patch may help:
Thanks, Alex. ACPI: EC: Check for IBF=0 once again after timeout
From: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de> --- drivers/acpi/ec.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/acpi/ec.c b/drivers/acpi/ec.c index 69f5f78..f2902c1 100644 --- a/drivers/acpi/ec.c +++ b/drivers/acpi/ec.c @@ -318,7 +318,8 @@ static int acpi_ec_transaction(struct acpi_ec *ec, struct transaction *t, } } if (!wait_event_timeout(ec->wait, ec_check_ibf0(ec), - msecs_to_jiffies(ACPI_EC_DELAY))) { + msecs_to_jiffies(ACPI_EC_DELAY)) && + !ec_check_ibf0(ec)) { pr_err(PREFIX "input buffer is not empty, " "aborting transaction\n"); status = -ETIME; | |