From a91912f8e4e92807d2cbf02d9687d421c1188f99 Mon Sep 17 00:00:00 2001 From: Yoichi Yuasa Date: Tue, 15 Dec 2009 16:46:15 -0800 Subject: [PATCH] rtc-vr41xx: use resource_size() Signed-off-by: Yoichi Yuasa Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/rtc/rtc-vr41xx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/rtc/rtc-vr41xx.c b/drivers/rtc/rtc-vr41xx.c index fadddac1e5a..c3244244e8c 100644 --- a/drivers/rtc/rtc-vr41xx.c +++ b/drivers/rtc/rtc-vr41xx.c @@ -327,7 +327,7 @@ static int __devinit rtc_probe(struct platform_device *pdev) if (!res) return -EBUSY; - rtc1_base = ioremap(res->start, res->end - res->start + 1); + rtc1_base = ioremap(res->start, resource_size(res)); if (!rtc1_base) return -EBUSY; @@ -337,7 +337,7 @@ static int __devinit rtc_probe(struct platform_device *pdev) 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) { retval = -EBUSY; goto err_rtc1_iounmap; -- 2.20.1