Skip to content

Commit

Permalink
ACPI / EC: disable GPE before removing GPE handler
Browse files Browse the repository at this point in the history
Adjust the order of disabling the EC GPE and removing its handler to
avoid unhandled events.

Signed-off-by: Lan Tianyu <tianyu.lan@intel.com>
[rjw: Changelog]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Lan Tianyu authored and Rafael J. Wysocki committed Dec 19, 2013
1 parent 8eaa29f commit 42b946b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/acpi/ec.c
Original file line number Diff line number Diff line change
Expand Up @@ -779,9 +779,9 @@ static int ec_install_handlers(struct acpi_ec *ec)
pr_err("Fail in evaluating the _REG object"
" of EC device. Broken bios is suspected.\n");
} else {
acpi_disable_gpe(NULL, ec->gpe);
acpi_remove_gpe_handler(NULL, ec->gpe,
&acpi_ec_gpe_handler);
acpi_disable_gpe(NULL, ec->gpe);
return -ENODEV;
}
}
Expand Down

0 comments on commit 42b946b

Please sign in to comment.