xref: /linux/include/linux/device-id/acpi.h (revision d2c9a99135da931377240942d44f3dea104cedb8)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef LINUX_DEVICE_ID_ACPI_H
3 #define LINUX_DEVICE_ID_ACPI_H
4 
5 #ifdef __KERNEL__
6 #include <linux/types.h>
7 typedef unsigned long kernel_ulong_t;
8 #endif
9 
10 #define ACPI_ID_LEN	16
11 
12 struct acpi_device_id {
13 	__u8 id[ACPI_ID_LEN];
14 	kernel_ulong_t driver_data;
15 	__u32 cls;
16 	__u32 cls_msk;
17 };
18 
19 /**
20  * ACPI_DEVICE_CLASS - macro used to describe an ACPI device with
21  * the PCI-defined class-code information
22  *
23  * @_cls : the class, subclass, prog-if triple for this device
24  * @_msk : the class mask for this device
25  *
26  * This macro is used to create a struct acpi_device_id that matches a
27  * specific PCI class. The .id and .driver_data fields will be left
28  * initialized with the default value.
29  */
30 #define ACPI_DEVICE_CLASS(_cls, _msk)	.cls = (_cls), .cls_msk = (_msk),
31 
32 #endif /* ifndef LINUX_DEVICE_ID_ACPI_H */
33