diff options
author | Mathias Krause <minipli@googlemail.com> | 2014-07-16 13:43:06 -0400 |
---|---|---|
committer | Matthew Garrett <matthew.garrett@nebula.com> | 2014-08-16 04:23:51 -0400 |
commit | 80f65558bdd14c0a113cd085582d578a3a3a1976 (patch) | |
tree | a6fa8a6d21aaeda6b3731461f003c22a37ac7e08 /drivers/platform | |
parent | 87e448493297b32631ef7db3bd5bcf723e9600b2 (diff) |
acer-wmi: Hide acer_{suspend,resume} for !CONFIG_PM_SLEEP
Encapsulate acer_suspend() and acer_resume with #ifdef CONFIG_PM_SLEEP
to get rid of the following warnings:
../acer-wmi.c:2046:12: warning: ‘acer_suspend’ defined but not used [-Wunused-function]
../acer-wmi.c:2068:12: warning: ‘acer_resume’ defined but not used [-Wunused-function]
Signed-off-by: Mathias Krause <minipli@googlemail.com>
Cc: "Lee, Chun-Yi" <jlee@suse.com>
Signed-off-by: Matthew Garrett <matthew.garrett@nebula.com>
Diffstat (limited to 'drivers/platform')
-rw-r--r-- | drivers/platform/x86/acer-wmi.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/platform/x86/acer-wmi.c b/drivers/platform/x86/acer-wmi.c index 48aae3ae82a1..0eecf9245d8c 100644 --- a/drivers/platform/x86/acer-wmi.c +++ b/drivers/platform/x86/acer-wmi.c | |||
@@ -2043,6 +2043,7 @@ static int acer_platform_remove(struct platform_device *device) | |||
2043 | return 0; | 2043 | return 0; |
2044 | } | 2044 | } |
2045 | 2045 | ||
2046 | #ifdef CONFIG_PM_SLEEP | ||
2046 | static int acer_suspend(struct device *dev) | 2047 | static int acer_suspend(struct device *dev) |
2047 | { | 2048 | { |
2048 | u32 value; | 2049 | u32 value; |
@@ -2083,6 +2084,10 @@ static int acer_resume(struct device *dev) | |||
2083 | 2084 | ||
2084 | return 0; | 2085 | return 0; |
2085 | } | 2086 | } |
2087 | #else | ||
2088 | #define acer_suspend NULL | ||
2089 | #define acer_resume NULL | ||
2090 | #endif | ||
2086 | 2091 | ||
2087 | static SIMPLE_DEV_PM_OPS(acer_pm, acer_suspend, acer_resume); | 2092 | static SIMPLE_DEV_PM_OPS(acer_pm, acer_suspend, acer_resume); |
2088 | 2093 | ||