From d4e1a692e9e85f9cbee090ea8d6158b133d32157 Mon Sep 17 00:00:00 2001 From: Toshi Kani Date: Mon, 4 Mar 2013 21:30:41 +0000 Subject: ACPI: Remove acpi_device dependency in acpi_device_set_id() This patch updates the internal operations of acpi_device_set_id() to setup acpi_device_pnp without using acpi_device. There is no functional change to acpi_device_set_id() in this patch. acpi_pnp_type is added to acpi_device_pnp, so that PNPID type is self-contained within acpi_device_pnp. acpi_add_id(), acpi_bay_match(), acpi_dock_match(), acpi_ibm_smbus_match() and acpi_is_video_device() are changed to take acpi_handle as an argument, instead of acpi_device. Signed-off-by: Toshi Kani Signed-off-by: Rafael J. Wysocki --- include/acpi/acpi_bus.h | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'include/acpi') diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h index 533ef039c5e0..3cb3da8ac9d9 100644 --- a/include/acpi/acpi_bus.h +++ b/include/acpi/acpi_bus.h @@ -161,7 +161,6 @@ struct acpi_device_status { struct acpi_device_flags { u32 dynamic_status:1; - u32 bus_address:1; u32 removable:1; u32 ejectable:1; u32 suprise_removal_ok:1; @@ -169,7 +168,7 @@ struct acpi_device_flags { u32 performance_manageable:1; u32 eject_pending:1; u32 match_driver:1; - u32 reserved:23; + u32 reserved:24; }; /* File System */ @@ -192,10 +191,17 @@ struct acpi_hardware_id { char *id; }; +struct acpi_pnp_type { + u32 hardware_id:1; + u32 bus_address:1; + u32 reserved:30; +}; + struct acpi_device_pnp { - acpi_bus_id bus_id; /* Object name */ + acpi_bus_id bus_id; /* Object name */ + struct acpi_pnp_type type; /* ID type */ acpi_bus_address bus_address; /* _ADR */ - char *unique_id; /* _UID */ + char *unique_id; /* _UID */ struct list_head ids; /* _HID and _CIDs */ acpi_device_name device_name; /* Driver-determined */ acpi_device_class device_class; /* " */ -- cgit v1.2.3