diff options
author | Bjorn Helgaas <bjorn.helgaas@hp.com> | 2009-09-21 13:35:19 -0600 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2009-09-25 15:09:31 -0400 |
commit | 7f47fa6c2ff15f5e59cdbb350f86faef6829294a (patch) | |
tree | 02167bcbc5e6fd4eee044798ef142ff604d8eab1 /include | |
parent | b1fbfb2ae8f2f0e04219218da6f52f7313466899 (diff) | |
download | op-kernel-dev-7f47fa6c2ff15f5e59cdbb350f86faef6829294a.zip op-kernel-dev-7f47fa6c2ff15f5e59cdbb350f86faef6829294a.tar.gz |
ACPI: maintain a single list of _HID and _CID IDs
There's no need to treat _HID and _CID differently. Keeping them in
a single list makes code that uses the IDs a little simpler because it
can just traverse the list rather than checking "do we have a HID?",
"do we have any CIDs?"
Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Reviewed-by: Alex Chiang <achiang@hp.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/acpi/acpi_bus.h | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h index 670f7f3..c2c4346 100644 --- a/include/acpi/acpi_bus.h +++ b/include/acpi/acpi_bus.h @@ -171,19 +171,23 @@ typedef unsigned long acpi_bus_address; typedef char acpi_device_name[40]; typedef char acpi_device_class[20]; +struct acpi_hardware_id { + struct list_head list; + char *id; +}; + struct acpi_device_pnp { acpi_bus_id bus_id; /* Object name */ acpi_bus_address bus_address; /* _ADR */ - char *hardware_id; /* _HID */ - struct acpica_device_id_list *cid_list; /* _CIDs */ char *unique_id; /* _UID */ + struct list_head ids; /* _HID and _CIDs */ acpi_device_name device_name; /* Driver-determined */ acpi_device_class device_class; /* " */ }; #define acpi_device_bid(d) ((d)->pnp.bus_id) #define acpi_device_adr(d) ((d)->pnp.bus_address) -#define acpi_device_hid(d) ((d)->pnp.hardware_id) +char *acpi_device_hid(struct acpi_device *device); #define acpi_device_uid(d) ((d)->pnp.unique_id) #define acpi_device_name(d) ((d)->pnp.device_name) #define acpi_device_class(d) ((d)->pnp.device_class) |