Skip to content

Commit

Permalink
WATCHDOG: fix build PM warnings
Browse files Browse the repository at this point in the history
drivers/watchdog/sp805_wdt.c:288:12: warning: 'sp805_wdt_suspend' defined but not used
drivers/watchdog/sp805_wdt.c:298:12: warning: 'sp805_wdt_resume' defined but not used

This is caused by the wrong config symbol being used for these functions.
Rather than fixing that, mark the functions with __maybe_unused

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King committed Nov 8, 2012
1 parent 3d70f8c commit 60d6dd5
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions drivers/watchdog/sp805_wdt.c
Original file line number Diff line number Diff line change
Expand Up @@ -284,8 +284,7 @@ static int __devexit sp805_wdt_remove(struct amba_device *adev)
return 0;
}

#ifdef CONFIG_PM
static int sp805_wdt_suspend(struct device *dev)
static int __maybe_unused sp805_wdt_suspend(struct device *dev)
{
struct sp805_wdt *wdt = dev_get_drvdata(dev);

Expand All @@ -295,7 +294,7 @@ static int sp805_wdt_suspend(struct device *dev)
return 0;
}

static int sp805_wdt_resume(struct device *dev)
static int __maybe_unused sp805_wdt_resume(struct device *dev)
{
struct sp805_wdt *wdt = dev_get_drvdata(dev);

Expand All @@ -304,7 +303,6 @@ static int sp805_wdt_resume(struct device *dev)

return 0;
}
#endif /* CONFIG_PM */

static SIMPLE_DEV_PM_OPS(sp805_wdt_dev_pm_ops, sp805_wdt_suspend,
sp805_wdt_resume);
Expand Down

0 comments on commit 60d6dd5

Please sign in to comment.