diff options
Diffstat (limited to 'drivers/watchdog/max63xx_wdt.c')
-rw-r--r-- | drivers/watchdog/max63xx_wdt.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/watchdog/max63xx_wdt.c b/drivers/watchdog/max63xx_wdt.c index 773c661723ca..cc9d328086ed 100644 --- a/drivers/watchdog/max63xx_wdt.c +++ b/drivers/watchdog/max63xx_wdt.c | |||
@@ -14,6 +14,7 @@ | |||
14 | * another interface, some abstraction will have to be introduced. | 14 | * another interface, some abstraction will have to be introduced. |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #include <linux/err.h> | ||
17 | #include <linux/module.h> | 18 | #include <linux/module.h> |
18 | #include <linux/moduleparam.h> | 19 | #include <linux/moduleparam.h> |
19 | #include <linux/types.h> | 20 | #include <linux/types.h> |
@@ -198,9 +199,9 @@ static int max63xx_wdt_probe(struct platform_device *pdev) | |||
198 | heartbeat = current_timeout->twd; | 199 | heartbeat = current_timeout->twd; |
199 | 200 | ||
200 | wdt_mem = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 201 | wdt_mem = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
201 | wdt_base = devm_request_and_ioremap(&pdev->dev, wdt_mem); | 202 | wdt_base = devm_ioremap_resource(&pdev->dev, wdt_mem); |
202 | if (!wdt_base) | 203 | if (IS_ERR(wdt_base)) |
203 | return -ENOMEM; | 204 | return PTR_ERR(wdt_base); |
204 | 205 | ||
205 | max63xx_wdt_dev.timeout = heartbeat; | 206 | max63xx_wdt_dev.timeout = heartbeat; |
206 | watchdog_set_nowayout(&max63xx_wdt_dev, nowayout); | 207 | watchdog_set_nowayout(&max63xx_wdt_dev, nowayout); |