Commit 8d808959 authored by Wolfram Sang's avatar Wolfram Sang Committed by Brian Norris

mtd: elm: compile suspend/resume only with PM_SLEEP

Fixes:
drivers/mtd/devices/elm.c:480:12: warning: 'elm_suspend' defined but not used [-Wunused-function]
drivers/mtd/devices/elm.c:488:12: warning: 'elm_resume' defined but not used [-Wunused-function]
Signed-off-by: default avatarWolfram Sang <wsa@sang-engineering.com>
Acked-by: default avatarPekon Gupta <pekon@ti.com>
Signed-off-by: default avatarBrian Norris <computersforpeace@gmail.com>
parent 3579ad41
...@@ -418,6 +418,7 @@ static int elm_remove(struct platform_device *pdev) ...@@ -418,6 +418,7 @@ static int elm_remove(struct platform_device *pdev)
return 0; return 0;
} }
#ifdef CONFIG_PM_SLEEP
/** /**
* elm_context_save * elm_context_save
* saves ELM configurations to preserve them across Hardware powered-down * saves ELM configurations to preserve them across Hardware powered-down
...@@ -509,6 +510,7 @@ static int elm_resume(struct device *dev) ...@@ -509,6 +510,7 @@ static int elm_resume(struct device *dev)
elm_context_restore(info); elm_context_restore(info);
return 0; return 0;
} }
#endif
static SIMPLE_DEV_PM_OPS(elm_pm_ops, elm_suspend, elm_resume); static SIMPLE_DEV_PM_OPS(elm_pm_ops, elm_suspend, elm_resume);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment