diff mbox series

[02/14] irqchip: st: use __maybe_unused to hide st_irq_syscfg_resume

Message ID 1456934350-1389172-3-git-send-email-arnd@arndb.de
State New
Headers show
Series None | expand

Commit Message

Arnd Bergmann March 2, 2016, 3:58 p.m. UTC
the st irqchip driver uses SIMPLE_DEV_PM_OPS to conditionally
set its power management functions, but we get a warning
about st_irq_syscfg_resume being unused when CONFIG_PM is not
set:

drivers/irqchip/irq-st.c:183:12: error: 'st_irq_syscfg_resume' defined but not used [-Werror=unused-function]

This adds a __maybe_unused annotation so the compiler knows
it can silently drop it instead of warning.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>

---
 drivers/irqchip/irq-st.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

-- 
2.7.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
diff mbox series

Patch

diff --git a/drivers/irqchip/irq-st.c b/drivers/irqchip/irq-st.c
index 9af48a85c16f..5e0e250db0be 100644
--- a/drivers/irqchip/irq-st.c
+++ b/drivers/irqchip/irq-st.c
@@ -180,7 +180,7 @@  static int st_irq_syscfg_probe(struct platform_device *pdev)
 	return st_irq_syscfg_enable(pdev);
 }
 
-static int st_irq_syscfg_resume(struct device *dev)
+static int __maybe_unused st_irq_syscfg_resume(struct device *dev)
 {
 	struct st_irq_syscfg *ddata = dev_get_drvdata(dev);