diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2012-08-09 23:00:02 +0200 |
---|---|---|
committer | Rafael J. Wysocki <rjw@sisk.pl> | 2012-08-10 13:35:32 +0200 |
commit | 9069240480e24a2d6ce23404c9ad6cabf59b7258 (patch) | |
tree | 6dc30815db7ff040a91844f57848f7a0a1770d2b /drivers/acpi/fan.c | |
parent | 300d3739e873d50d4c6e3656f89007a217fb1d29 (diff) | |
download | linux-9069240480e24a2d6ce23404c9ad6cabf59b7258.tar.gz linux-9069240480e24a2d6ce23404c9ad6cabf59b7258.tar.bz2 linux-9069240480e24a2d6ce23404c9ad6cabf59b7258.zip |
ACPI / PM: Fix unused function warnings for CONFIG_PM_SLEEP
According to compiler warnings, several suspend/resume functions
in ACPI drivers are not used for CONFIG_PM_SLEEP unset, so add
#ifdefs to prevent them from being built in that case.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Diffstat (limited to 'drivers/acpi/fan.c')
-rw-r--r-- | drivers/acpi/fan.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c index 669d9ee80d16..bc36a476f1ab 100644 --- a/drivers/acpi/fan.c +++ b/drivers/acpi/fan.c @@ -53,8 +53,10 @@ static const struct acpi_device_id fan_device_ids[] = { }; MODULE_DEVICE_TABLE(acpi, fan_device_ids); +#ifdef CONFIG_PM_SLEEP static int acpi_fan_suspend(struct device *dev); static int acpi_fan_resume(struct device *dev); +#endif static SIMPLE_DEV_PM_OPS(acpi_fan_pm, acpi_fan_suspend, acpi_fan_resume); static struct acpi_driver acpi_fan_driver = { @@ -184,6 +186,7 @@ static int acpi_fan_remove(struct acpi_device *device, int type) return 0; } +#ifdef CONFIG_PM_SLEEP static int acpi_fan_suspend(struct device *dev) { if (!dev) @@ -207,6 +210,7 @@ static int acpi_fan_resume(struct device *dev) return result; } +#endif static int __init acpi_fan_init(void) { |