@@ -216,7 +216,7 @@ static int imx_sc_wdt_probe(struct platform_device *pdev)
return devm_watchdog_register_device(dev, wdog);
}
-static int __maybe_unused imx_sc_wdt_suspend(struct device *dev)
+static int imx_sc_wdt_suspend(struct device *dev)
{
struct imx_sc_wdt_device *imx_sc_wdd = dev_get_drvdata(dev);
@@ -226,7 +226,7 @@ static int __maybe_unused imx_sc_wdt_suspend(struct device *dev)
return 0;
}
-static int __maybe_unused imx_sc_wdt_resume(struct device *dev)
+static int imx_sc_wdt_resume(struct device *dev)
{
struct imx_sc_wdt_device *imx_sc_wdd = dev_get_drvdata(dev);
@@ -236,8 +236,8 @@ static int __maybe_unused imx_sc_wdt_resume(struct device *dev)
return 0;
}
-static SIMPLE_DEV_PM_OPS(imx_sc_wdt_pm_ops,
- imx_sc_wdt_suspend, imx_sc_wdt_resume);
+static DEFINE_SIMPLE_DEV_PM_OPS(imx_sc_wdt_pm_ops, imx_sc_wdt_suspend,
+ imx_sc_wdt_resume);
static const struct of_device_id imx_sc_wdt_dt_ids[] = {
{ .compatible = "fsl,imx-sc-wdt", },
@@ -250,7 +250,7 @@ static struct platform_driver imx_sc_wdt_driver = {
.driver = {
.name = "imx-sc-wdt",
.of_match_table = imx_sc_wdt_dt_ids,
- .pm = &imx_sc_wdt_pm_ops,
+ .pm = pm_sleep_ptr(&imx_sc_wdt_pm_ops),
},
};
module_platform_driver(imx_sc_wdt_driver);