rm9k_wdt.c: use resource_size()
From: H Hartley Sweeten
Date: Fri Dec 04 2009 - 12:48:37 EST
Use resource_size().
Signed-off-by: H Hartley Sweeten <hsweeten@xxxxxxxxxxxxxxxxxxx>
Cc: Wim Van Sebroeck <wim@xxxxxxxxx>
Cc: Henrique de Moraes Holschuh <hmh@xxxxxxxxxx>
Cc: Ming Lei <tom.leiming@xxxxxxxxx>
---
diff --git a/drivers/watchdog/rm9k_wdt.c b/drivers/watchdog/rm9k_wdt.c
index bb66958..198f748 100644
--- a/drivers/watchdog/rm9k_wdt.c
+++ b/drivers/watchdog/rm9k_wdt.c
@@ -360,7 +360,7 @@ static int __devinit wdt_gpi_probe(struct platform_device *pdv)
if (unlikely(!rr || !ri || !rc))
return -ENXIO;
- wd_regs = ioremap_nocache(rr->start, rr->end + 1 - rr->start);
+ wd_regs = ioremap_nocache(rr->start, resource_size(rr));
if (unlikely(!wd_regs))
return -ENOMEM;
wd_irq = ri->start;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/