Rafael J. Wysocki 0516e42c7b ACPI: EC: Reference count query handlers under lock
[ Upstream commit 3df663a147fe077a6ee8444ec626738946e65547 ]

There is a race condition in acpi_ec_get_query_handler()
theoretically allowing query handlers to go away before refernce
counting them.

In order to avoid it, call kref_get() on query handlers under
ec->mutex.

Also simplify the code a bit while at it.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-10-01 20:40:05 +02:00
..
2020-04-02 17:20:26 +02:00
2016-04-27 23:42:57 +02:00
2016-11-11 23:23:02 +01:00
2016-01-04 22:10:30 +01:00
2016-10-10 02:20:43 +02:00
2016-10-03 20:11:49 -07:00
2019-12-21 10:42:05 +01:00
2020-06-30 15:38:44 -04:00
2016-07-19 12:32:39 -07:00