diff options
Diffstat (limited to 'arch/mips/dec/time.c')
-rw-r--r-- | arch/mips/dec/time.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/arch/mips/dec/time.c b/arch/mips/dec/time.c index e2973a432b92..820e5331205f 100644 --- a/arch/mips/dec/time.c +++ b/arch/mips/dec/time.c | |||
@@ -35,7 +35,7 @@ | |||
35 | #include <asm/dec/ioasic_addrs.h> | 35 | #include <asm/dec/ioasic_addrs.h> |
36 | #include <asm/dec/machtype.h> | 36 | #include <asm/dec/machtype.h> |
37 | 37 | ||
38 | static unsigned long dec_rtc_get_time(void) | 38 | unsigned long read_persistent_clock(void) |
39 | { | 39 | { |
40 | unsigned int year, mon, day, hour, min, sec, real_year; | 40 | unsigned int year, mon, day, hour, min, sec, real_year; |
41 | unsigned long flags; | 41 | unsigned long flags; |
@@ -74,13 +74,13 @@ static unsigned long dec_rtc_get_time(void) | |||
74 | } | 74 | } |
75 | 75 | ||
76 | /* | 76 | /* |
77 | * In order to set the CMOS clock precisely, dec_rtc_set_mmss has to | 77 | * In order to set the CMOS clock precisely, rtc_mips_set_mmss has to |
78 | * be called 500 ms after the second nowtime has started, because when | 78 | * be called 500 ms after the second nowtime has started, because when |
79 | * nowtime is written into the registers of the CMOS clock, it will | 79 | * nowtime is written into the registers of the CMOS clock, it will |
80 | * jump to the next second precisely 500 ms later. Check the Dallas | 80 | * jump to the next second precisely 500 ms later. Check the Dallas |
81 | * DS1287 data sheet for details. | 81 | * DS1287 data sheet for details. |
82 | */ | 82 | */ |
83 | static int dec_rtc_set_mmss(unsigned long nowtime) | 83 | int rtc_mips_set_mmss(unsigned long nowtime) |
84 | { | 84 | { |
85 | int retval = 0; | 85 | int retval = 0; |
86 | int real_seconds, real_minutes, cmos_minutes; | 86 | int real_seconds, real_minutes, cmos_minutes; |
@@ -139,7 +139,6 @@ static int dec_rtc_set_mmss(unsigned long nowtime) | |||
139 | return retval; | 139 | return retval; |
140 | } | 140 | } |
141 | 141 | ||
142 | |||
143 | static int dec_timer_state(void) | 142 | static int dec_timer_state(void) |
144 | { | 143 | { |
145 | return (CMOS_READ(RTC_REG_C) & RTC_PF) != 0; | 144 | return (CMOS_READ(RTC_REG_C) & RTC_PF) != 0; |
@@ -160,11 +159,8 @@ static cycle_t dec_ioasic_hpt_read(void) | |||
160 | } | 159 | } |
161 | 160 | ||
162 | 161 | ||
163 | void __init dec_time_init(void) | 162 | void __init plat_time_init(void) |
164 | { | 163 | { |
165 | rtc_mips_get_time = dec_rtc_get_time; | ||
166 | rtc_mips_set_mmss = dec_rtc_set_mmss; | ||
167 | |||
168 | mips_timer_state = dec_timer_state; | 164 | mips_timer_state = dec_timer_state; |
169 | mips_timer_ack = dec_timer_ack; | 165 | mips_timer_ack = dec_timer_ack; |
170 | 166 | ||