mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 22:02:02 +00:00
ACPI: EC: Fix oops when removing custom query handlers
When removing custom query handlers, the handler might still be used inside the EC query workqueue, causing a kernel oops if the module holding the callback function was already unloaded. Fix this by flushing the EC query workqueue when removing custom query handlers. Tested on a Acer Travelmate 4002WLMi Signed-off-by: Armin Wolf <W_Armin@gmx.de> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
parent
28f7b85895
commit
e5b492c6bb
1 changed files with 1 additions and 0 deletions
|
@ -1133,6 +1133,7 @@ static void acpi_ec_remove_query_handlers(struct acpi_ec *ec,
|
|||
void acpi_ec_remove_query_handler(struct acpi_ec *ec, u8 query_bit)
|
||||
{
|
||||
acpi_ec_remove_query_handlers(ec, false, query_bit);
|
||||
flush_workqueue(ec_query_wq);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(acpi_ec_remove_query_handler);
|
||||
|
||||
|
|
Loading…
Reference in a new issue