aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/acpi/scan.c5
-rw-r--r--include/acpi/acpi_bus.h3
2 files changed, 3 insertions, 5 deletions
diff --git a/drivers/acpi/scan.c b/drivers/acpi/scan.c
index 1f75ba6afae6..5b42948ea97f 100644
--- a/drivers/acpi/scan.c
+++ b/drivers/acpi/scan.c
@@ -222,11 +222,6 @@ acpi_eject_store(struct acpi_device *device, const char *buf, size_t count)
222/* -------------------------------------------------------------------------- 222/* --------------------------------------------------------------------------
223 ACPI Bus operations 223 ACPI Bus operations
224 -------------------------------------------------------------------------- */ 224 -------------------------------------------------------------------------- */
225static inline struct acpi_device * to_acpi_device(struct device * dev)
226{
227 return container_of(dev, struct acpi_device, dev);
228}
229
230static int root_suspend(struct acpi_device * acpi_dev, pm_message_t state) 225static int root_suspend(struct acpi_device * acpi_dev, pm_message_t state)
231{ 226{
232 struct acpi_device * dev, * next; 227 struct acpi_device * dev, * next;
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h
index fdd10953b2b6..a09538eb61e7 100644
--- a/include/acpi/acpi_bus.h
+++ b/include/acpi/acpi_bus.h
@@ -136,6 +136,7 @@ struct acpi_driver {
136 atomic_t references; 136 atomic_t references;
137 char *ids; /* Supported Hardware IDs */ 137 char *ids; /* Supported Hardware IDs */
138 struct acpi_device_ops ops; 138 struct acpi_device_ops ops;
139 struct device_driver drv;
139}; 140};
140 141
141/* 142/*
@@ -301,6 +302,8 @@ struct acpi_device {
301}; 302};
302 303
303#define acpi_driver_data(d) ((d)->driver_data) 304#define acpi_driver_data(d) ((d)->driver_data)
305#define to_acpi_device(d) container_of(d, struct acpi_device, dev)
306#define to_acpi_driver(d) container_of(d, struct acpi_driver, drv)
304 307
305/* 308/*
306 * Events 309 * Events