Skip to contentSkip to conversation

i2c: i2c-designware: Fix compilation warning

PATCH In review EUNBONG SONG 2 participants 2 messages May 20, 2013 – May 21, 2013

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 i2c: i2c-designware: Fix compilation warning

Fix the following compilation warning when CONFIG_PM_RUNTIME is not enabled:

drivers/i2c/busses/i2c-designware-pcidrv.c:188: warning: 'i2c_dw_pci_runtime_idle' defined but not used

---
 drivers/i2c/busses/i2c-designware-pcidrv.c |    2 ++
 1 file changed, 2 insertions(+)
drivers/i2c/busses/i2c-designware-pcidrv.c +2 -0
index f6ed06c..2b5d3a6 100644
@@ -185,6 +185,7 @@ static int i2c_dw_pci_resume(struct device *dev)
 	return 0;
 }
 
+#ifdef CONFIG_PM_RUNTIME
 static int i2c_dw_pci_runtime_idle(struct device *dev)
 {
 	int err = pm_schedule_suspend(dev, 500);
@@ -194,6 +195,7 @@ static int i2c_dw_pci_runtime_idle(struct device *dev)
 		return 0;
 	return -EBUSY;
 }
+#endif
 
 static const struct dev_pm_ops i2c_dw_pm_ops = {
 	.resume         = i2c_dw_pci_resume,
Signature · 1 line
1.7.10.4