mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] mfd: sec: Only build suspend() and resume if they will be used
@ 2014-01-26 23:51 Mark Brown
  0 siblings, 0 replies; only message in thread
From: Mark Brown @ 2014-01-26 23:51 UTC (permalink / raw)
  To: Sangbeom Kim, Samuel Ortiz, Lee Jones
  Cc: linux-kernel, linaro-kernel, Mark Brown

From: Mark Brown <broonie@linaro.org>

Not doing so causes warnings as the functions are static but end up not
being referenced, the macros aren't smart enough to generate fake
references.

Signed-off-by: Mark Brown <broonie@linaro.org>
---
 drivers/mfd/sec-core.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
index a139798b8065..456ce491b733 100644
--- a/drivers/mfd/sec-core.c
+++ b/drivers/mfd/sec-core.c
@@ -315,6 +315,7 @@ static int sec_pmic_remove(struct i2c_client *i2c)
 	return 0;
 }
 
+#ifdef CONFIG_PM_SLEEP
 static int sec_pmic_suspend(struct device *dev)
 {
 	struct i2c_client *i2c = container_of(dev, struct i2c_client, dev);
@@ -349,6 +350,7 @@ static int sec_pmic_resume(struct device *dev)
 
 	return 0;
 }
+#endif
 
 static SIMPLE_DEV_PM_OPS(sec_pmic_pm_ops, sec_pmic_suspend, sec_pmic_resume);
 
-- 
1.8.5.3


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-01-26 23:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-26 23:51 [PATCH] mfd: sec: Only build suspend() and resume if they will be used Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®