Commit a91912f8 authored by Yoichi Yuasa's avatar Yoichi Yuasa Committed by Linus Torvalds

rtc-vr41xx: use resource_size()

Signed-off-by: default avatarYoichi Yuasa <yuasa@linux-mips.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 43d15bcd
...@@ -327,7 +327,7 @@ static int __devinit rtc_probe(struct platform_device *pdev) ...@@ -327,7 +327,7 @@ static int __devinit rtc_probe(struct platform_device *pdev)
if (!res) if (!res)
return -EBUSY; return -EBUSY;
rtc1_base = ioremap(res->start, res->end - res->start + 1); rtc1_base = ioremap(res->start, resource_size(res));
if (!rtc1_base) if (!rtc1_base)
return -EBUSY; return -EBUSY;
...@@ -337,7 +337,7 @@ static int __devinit rtc_probe(struct platform_device *pdev) ...@@ -337,7 +337,7 @@ static int __devinit rtc_probe(struct platform_device *pdev)
goto err_rtc1_iounmap; goto err_rtc1_iounmap;
} }
rtc2_base = ioremap(res->start, res->end - res->start + 1); rtc2_base = ioremap(res->start, resource_size(res));
if (!rtc2_base) { if (!rtc2_base) {
retval = -EBUSY; retval = -EBUSY;
goto err_rtc1_iounmap; goto err_rtc1_iounmap;
......
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