diff options
author | David Gibson <david@gibson.dropbear.id.au> | 2007-09-19 01:46:28 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-09-19 14:24:17 -0400 |
commit | 2e3e31c05798786c131bf257f64848d4a9a894ab (patch) | |
tree | 152aa226a482c76c8e5dafeaf6f2c9f88bb90cd8 /drivers | |
parent | efc63c4fb0f95865907472d1c6bc0cfea9ee156b (diff) |
rtc-ds1742.c should use resource_size_t for base address
Currently the rtc driver, rtc-ds1742.c uses an unsigned long to store the
base mmio address of the NVRAM/RTC. This breaks on systems like PowerPC
440, which is a 32-bit core with 36-bit physical addresses: IO on the
system, including the RTC, is typically above the 4GB point, and cannot fit
into an unsigned long.
This patch fixes the problem by replacing the unsigned long with a
resource_size_t. Tested on Ebony (PPC440) (with additional patches to
instantiate the ds1742 platform device appropriately).
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Acked-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/rtc/rtc-ds1742.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-ds1742.c b/drivers/rtc/rtc-ds1742.c index b2e5481ba3b6..67291b0f8283 100644 --- a/drivers/rtc/rtc-ds1742.c +++ b/drivers/rtc/rtc-ds1742.c | |||
@@ -55,7 +55,7 @@ struct rtc_plat_data { | |||
55 | void __iomem *ioaddr_rtc; | 55 | void __iomem *ioaddr_rtc; |
56 | size_t size_nvram; | 56 | size_t size_nvram; |
57 | size_t size; | 57 | size_t size; |
58 | unsigned long baseaddr; | 58 | resource_size_t baseaddr; |
59 | unsigned long last_jiffies; | 59 | unsigned long last_jiffies; |
60 | }; | 60 | }; |
61 | 61 | ||