Armin Wolf | e8f8b44 | 2023-04-25 00:29:38 +0200 | [diff] [blame] | 1 | .. SPDX-License-Identifier: GPL-2.0-or-later |
| 2 | |
| 3 | ============== |
| 4 | WMI Driver API |
| 5 | ============== |
| 6 | |
| 7 | The WMI driver core supports a more modern bus-based interface for interacting |
| 8 | with WMI devices, and an older GUID-based interface. The latter interface is |
| 9 | considered to be deprecated, so new WMI drivers should generally avoid it since |
| 10 | it has some issues with multiple WMI devices and events sharing the same GUIDs |
| 11 | and/or notification IDs. The modern bus-based interface instead maps each |
| 12 | WMI device to a :c:type:`struct wmi_device <wmi_device>`, so it supports |
| 13 | WMI devices sharing GUIDs and/or notification IDs. Drivers can then register |
| 14 | a :c:type:`struct wmi_driver <wmi_driver>`, which will be bound to compatible |
| 15 | WMI devices by the driver core. |
| 16 | |
| 17 | .. kernel-doc:: include/linux/wmi.h |
| 18 | :internal: |
| 19 | |
| 20 | .. kernel-doc:: drivers/platform/x86/wmi.c |
| 21 | :export: |