diff options
author | Jeff Garzik <jgarzik@pobox.com> | 2005-11-18 11:44:17 -0500 |
---|---|---|
committer | Jeff Garzik <jgarzik@pobox.com> | 2005-11-18 11:44:17 -0500 |
commit | f333b3f111e9db76109e304df8ee777ace7fbf86 (patch) | |
tree | ce9a74a7327020c48c80d278e1db5f12552f0fb0 /arch/powerpc/platforms/maple/time.c | |
parent | f4256e301d9800b1e0276404cb01b3ac85b51067 (diff) | |
parent | 79bfb0a98fdc73ed6a18469cef245cbf50a1d8bb (diff) |
Merge branch 'upstream'
Diffstat (limited to 'arch/powerpc/platforms/maple/time.c')
-rw-r--r-- | arch/powerpc/platforms/maple/time.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/maple/time.c b/arch/powerpc/platforms/maple/time.c index 40fc07a8e606..15846cc938ac 100644 --- a/arch/powerpc/platforms/maple/time.c +++ b/arch/powerpc/platforms/maple/time.c | |||
@@ -158,6 +158,11 @@ int maple_set_rtc_time(struct rtc_time *tm) | |||
158 | return 0; | 158 | return 0; |
159 | } | 159 | } |
160 | 160 | ||
161 | static struct resource rtc_iores = { | ||
162 | .name = "rtc", | ||
163 | .flags = IORESOURCE_BUSY, | ||
164 | }; | ||
165 | |||
161 | unsigned long __init maple_get_boot_time(void) | 166 | unsigned long __init maple_get_boot_time(void) |
162 | { | 167 | { |
163 | struct rtc_time tm; | 168 | struct rtc_time tm; |
@@ -172,7 +177,11 @@ unsigned long __init maple_get_boot_time(void) | |||
172 | printk(KERN_INFO "Maple: No device node for RTC, assuming " | 177 | printk(KERN_INFO "Maple: No device node for RTC, assuming " |
173 | "legacy address (0x%x)\n", maple_rtc_addr); | 178 | "legacy address (0x%x)\n", maple_rtc_addr); |
174 | } | 179 | } |
175 | 180 | ||
181 | rtc_iores.start = maple_rtc_addr; | ||
182 | rtc_iores.end = maple_rtc_addr + 7; | ||
183 | request_resource(&ioport_resource, &rtc_iores); | ||
184 | |||
176 | maple_get_rtc_time(&tm); | 185 | maple_get_rtc_time(&tm); |
177 | return mktime(tm.tm_year+1900, tm.tm_mon+1, tm.tm_mday, | 186 | return mktime(tm.tm_year+1900, tm.tm_mon+1, tm.tm_mday, |
178 | tm.tm_hour, tm.tm_min, tm.tm_sec); | 187 | tm.tm_hour, tm.tm_min, tm.tm_sec); |