aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/watchdog/at32ap700x_wdt.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/watchdog/at32ap700x_wdt.c')
-rw-r--r--drivers/watchdog/at32ap700x_wdt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/watchdog/at32ap700x_wdt.c b/drivers/watchdog/at32ap700x_wdt.c
index e8ae638e5804..037847923dcb 100644
--- a/drivers/watchdog/at32ap700x_wdt.c
+++ b/drivers/watchdog/at32ap700x_wdt.c
@@ -326,7 +326,7 @@ static int __init at32_wdt_probe(struct platform_device *pdev)
326 return -ENOMEM; 326 return -ENOMEM;
327 } 327 }
328 328
329 wdt->regs = ioremap(regs->start, regs->end - regs->start + 1); 329 wdt->regs = ioremap(regs->start, resource_size(regs));
330 if (!wdt->regs) { 330 if (!wdt->regs) {
331 ret = -ENOMEM; 331 ret = -ENOMEM;
332 dev_dbg(&pdev->dev, "could not map I/O memory\n"); 332 dev_dbg(&pdev->dev, "could not map I/O memory\n");