Skip to contentSkip to conversation

mailbox: tegra-hsp: mark suspend function as __maybe_unused

PATCH In review Arnd Bergmann 2 participants 2 messages Mar 4, 2019 – Mar 5, 2019

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

PATCH 1/1 mailbox: tegra-hsp: mark suspend function as __maybe_unused

We get a warning about this being unused when CONFIG_PM is disabled:

drivers/mailbox/tegra-hsp.c:782:12: error: 'tegra_hsp_resume' defined but not used [-Werror=unused-function]

Fixes 9a63f0f40599 ("mailbox: tegra-hsp: Add suspend/resume support")
---
 drivers/mailbox/tegra-hsp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mailbox/tegra-hsp.c +1 -1
index e443f6a2ec4b..11fc9fd6a94a 100644
@@ -779,7 +779,7 @@ static int tegra_hsp_probe(struct platform_device *pdev)
 	return 0;
 }
 
-static int tegra_hsp_resume(struct device *dev)
+static int __maybe_unused tegra_hsp_resume(struct device *dev)
 {
 	struct tegra_hsp *hsp = dev_get_drvdata(dev);
 	unsigned int i;
Signature · 1 line
2.20.0
Acked-by on v1 1/1
#1 lore raw
Quoted 9 lines · Arnd Bergmann

We get a warning about this being unused when CONFIG_PM is disabled:

drivers/mailbox/tegra-hsp.c:782:12: error: 'tegra_hsp_resume' defined but not used [-Werror=unused-function]

Fixes 9a63f0f40599 ("mailbox: tegra-hsp: Add suspend/resume support")
---
 drivers/mailbox/tegra-hsp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)