diff options
author | Armin Wolf <W_Armin@gmx.de> | 2023-04-25 01:29:38 +0300 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2023-05-09 12:54:42 +0300 |
commit | e8f8b448c168d7f2f93c9586cf789dee5d61182d (patch) | |
tree | d3854fd01c020a2b55e1be6fc6fae1d4ed766829 /Documentation/driver-api/wmi.rst | |
parent | d54bd4bc7b9ae9505f53440894b8c239c521f3da (diff) | |
download | linux-e8f8b448c168d7f2f93c9586cf789dee5d61182d.tar.xz |
platform/x86: wmi: Add documentation
Add documentation for the WMI subsystem. The documentation describes
both the ACPI WMI interface and the driver API for interacting with
the WMI driver core. The information regarding the ACPI interface
was retrieved from the Ubuntu kernel references and the Windows driver
samples available on GitHub. The documentation is supposed to help
driver developers writing WMI drivers, as many modern machines designed
to run Windows provide an ACPI WMI interface.
Signed-off-by: Armin Wolf <W_Armin@gmx.de>
Tested-by: Randy Dunlap <rdunlap@infradead.org>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Link: https://lore.kernel.org/r/20230424222939.208137-4-W_Armin@gmx.de
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to 'Documentation/driver-api/wmi.rst')
-rw-r--r-- | Documentation/driver-api/wmi.rst | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Documentation/driver-api/wmi.rst b/Documentation/driver-api/wmi.rst new file mode 100644 index 000000000000..6ca58c8249e5 --- /dev/null +++ b/Documentation/driver-api/wmi.rst @@ -0,0 +1,21 @@ +.. SPDX-License-Identifier: GPL-2.0-or-later + +============== +WMI Driver API +============== + +The WMI driver core supports a more modern bus-based interface for interacting +with WMI devices, and an older GUID-based interface. The latter interface is +considered to be deprecated, so new WMI drivers should generally avoid it since +it has some issues with multiple WMI devices and events sharing the same GUIDs +and/or notification IDs. The modern bus-based interface instead maps each +WMI device to a :c:type:`struct wmi_device <wmi_device>`, so it supports +WMI devices sharing GUIDs and/or notification IDs. Drivers can then register +a :c:type:`struct wmi_driver <wmi_driver>`, which will be bound to compatible +WMI devices by the driver core. + +.. kernel-doc:: include/linux/wmi.h + :internal: + +.. kernel-doc:: drivers/platform/x86/wmi.c + :export: |