diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2014-07-12 06:01:38 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2014-07-21 21:32:07 -0400 |
commit | 150cee9cfd749b1a9f4e995d63761891d46c56de (patch) | |
tree | 1dc2b7c63a4846e6d819b0c7b5d8c4c603b0bdfb | |
parent | 8f8e7e14637a07d8bde6e4b0dc385b72d1a674fb (diff) |
drm: bochs: fix warnings
Regular nightly randconfig build testing discovered these warnings:
drivers/gpu/drm/bochs/bochs_drv.c:100:12: warning: 'bochs_pm_suspend' defined but not used [-Wunused-function]
drivers/gpu/drm/bochs/bochs_drv.c:117:12: warning: 'bochs_pm_resume' defined but not used [-Wunused-function]
Fix these by adding the same condition that SET_SYSTEM_SLEEP_PM_OPS()
uses.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Dave Airlie <airlied@redhat.com>
-rw-r--r-- | drivers/gpu/drm/bochs/bochs_drv.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/bochs/bochs_drv.c b/drivers/gpu/drm/bochs/bochs_drv.c index 9c13df29fd20..f5e0ead974a6 100644 --- a/drivers/gpu/drm/bochs/bochs_drv.c +++ b/drivers/gpu/drm/bochs/bochs_drv.c | |||
@@ -97,6 +97,7 @@ static struct drm_driver bochs_driver = { | |||
97 | /* ---------------------------------------------------------------------- */ | 97 | /* ---------------------------------------------------------------------- */ |
98 | /* pm interface */ | 98 | /* pm interface */ |
99 | 99 | ||
100 | #ifdef CONFIG_PM_SLEEP | ||
100 | static int bochs_pm_suspend(struct device *dev) | 101 | static int bochs_pm_suspend(struct device *dev) |
101 | { | 102 | { |
102 | struct pci_dev *pdev = to_pci_dev(dev); | 103 | struct pci_dev *pdev = to_pci_dev(dev); |
@@ -131,6 +132,7 @@ static int bochs_pm_resume(struct device *dev) | |||
131 | drm_kms_helper_poll_enable(drm_dev); | 132 | drm_kms_helper_poll_enable(drm_dev); |
132 | return 0; | 133 | return 0; |
133 | } | 134 | } |
135 | #endif | ||
134 | 136 | ||
135 | static const struct dev_pm_ops bochs_pm_ops = { | 137 | static const struct dev_pm_ops bochs_pm_ops = { |
136 | SET_SYSTEM_SLEEP_PM_OPS(bochs_pm_suspend, | 138 | SET_SYSTEM_SLEEP_PM_OPS(bochs_pm_suspend, |