]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ACPI: battery: create alarm sysfs attribute atomically
authorThomas Weißschuh <linux@weissschuh.net>
Sun, 9 Jun 2024 07:27:16 +0000 (09:27 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Aug 2024 13:34:07 +0000 (15:34 +0200)
commit7953227c3c0e26bd4a5d59643d5b3de166f2871b
tree4b6e0fe13c242dabce9475ab883b67061e6cea03
parent417a820de0255cb2e2219a878a0144a65081e2e2
ACPI: battery: create alarm sysfs attribute atomically

[ Upstream commit a231eed10ed5a290129fda36ad7bcc263c53ff7d ]

Let the power supply core register the attribute.
This ensures that the attribute is created before the device is
announced to userspace, avoid a race condition.

Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/acpi/battery.c