]> git.ipfire.org Git - thirdparty/linux.git/commit
platform/x86: lg-laptop: Convert ACPI driver to a platform one
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 12 Mar 2026 11:14:47 +0000 (12:14 +0100)
committerIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
Tue, 17 Mar 2026 17:20:46 +0000 (19:20 +0200)
commit2d9cb20610f75ca48c1cac064aede90196787507
treea0bde6d11a43dc01c49ff7bf316e3f6e2dd1eeb6
parentc12fe0b2c12195e0d1c56e0f670a6bd792b0567e
platform/x86: lg-laptop: Convert ACPI driver to a platform one

In all cases in which a struct acpi_driver is used for binding a driver
to an ACPI device object, a corresponding platform device is created by
the ACPI core and that device is regarded as a proper representation of
underlying hardware.  Accordingly, a struct platform_driver should be
used by driver code to bind to that device.  There are multiple reasons
why drivers should not bind directly to ACPI device objects [1].

Overall, it is better to bind drivers to platform devices than to their
ACPI companions, so convert the LG Gram ACPI features and hotkeys driver
from an ACPI driver to a platform one.

While this is not expected to alter functionality, it changes sysfs
layout and so it will be visible to user space.

Link: https://lore.kernel.org/all/2396510.ElGaqSPkdT@rafael.j.wysocki/
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Link: https://patch.msgid.link/1868365.VLH7GnMWUR@rafael.j.wysocki
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
drivers/platform/x86/lg-laptop.c