summaryrefslogtreecommitdiff
path: root/include/acpi/acpi_bus.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/acpi/acpi_bus.h')
-rw-r--r--include/acpi/acpi_bus.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h
index 9fe5f63..e748dbf 100644
--- a/include/acpi/acpi_bus.h
+++ b/include/acpi/acpi_bus.h
@@ -169,7 +169,9 @@ struct acpi_device_flags {
u32 ejectable:1;
u32 power_manageable:1;
u32 match_driver:1;
- u32 reserved:27;
+ u32 initialized:1;
+ u32 visited:1;
+ u32 reserved:25;
};
/* File System */
@@ -386,6 +388,11 @@ int acpi_match_device_ids(struct acpi_device *device,
int acpi_create_dir(struct acpi_device *);
void acpi_remove_dir(struct acpi_device *);
+static inline bool acpi_device_enumerated(struct acpi_device *adev)
+{
+ return adev && adev->flags.initialized && adev->flags.visited;
+}
+
typedef void (*acpi_hp_callback)(void *data, u32 src);
acpi_status acpi_hotplug_execute(acpi_hp_callback func, void *data, u32 src);