aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pnp
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pnp')
-rw-r--r--drivers/pnp/pnpacpi/core.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/pnp/pnpacpi/core.c b/drivers/pnp/pnpacpi/core.c
index 6a2a3c2f4d5e..616fc72190bf 100644
--- a/drivers/pnp/pnpacpi/core.c
+++ b/drivers/pnp/pnpacpi/core.c
@@ -127,6 +127,7 @@ static int pnpacpi_disable_resources(struct pnp_dev *dev)
127 return ACPI_FAILURE(status) ? -ENODEV : 0; 127 return ACPI_FAILURE(status) ? -ENODEV : 0;
128} 128}
129 129
130#ifdef CONFIG_ACPI_SLEEP
130static int pnpacpi_suspend(struct pnp_dev *dev, pm_message_t state) 131static int pnpacpi_suspend(struct pnp_dev *dev, pm_message_t state)
131{ 132{
132 return acpi_bus_set_power((acpi_handle) dev->data, 133 return acpi_bus_set_power((acpi_handle) dev->data,
@@ -140,14 +141,17 @@ static int pnpacpi_resume(struct pnp_dev *dev)
140{ 141{
141 return acpi_bus_set_power((acpi_handle) dev->data, ACPI_STATE_D0); 142 return acpi_bus_set_power((acpi_handle) dev->data, ACPI_STATE_D0);
142} 143}
144#endif
143 145
144static struct pnp_protocol pnpacpi_protocol = { 146static struct pnp_protocol pnpacpi_protocol = {
145 .name = "Plug and Play ACPI", 147 .name = "Plug and Play ACPI",
146 .get = pnpacpi_get_resources, 148 .get = pnpacpi_get_resources,
147 .set = pnpacpi_set_resources, 149 .set = pnpacpi_set_resources,
148 .disable = pnpacpi_disable_resources, 150 .disable = pnpacpi_disable_resources,
151#ifdef CONFIG_ACPI_SLEEP
149 .suspend = pnpacpi_suspend, 152 .suspend = pnpacpi_suspend,
150 .resume = pnpacpi_resume, 153 .resume = pnpacpi_resume,
154#endif
151}; 155};
152 156
153static int __init pnpacpi_add_device(struct acpi_device *device) 157static int __init pnpacpi_add_device(struct acpi_device *device)