diff options
Diffstat (limited to 'arch/mips/kernel/time.c')
-rw-r--r-- | arch/mips/kernel/time.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/arch/mips/kernel/time.c b/arch/mips/kernel/time.c index 51273b7297a7..5e51a2d8f3f0 100644 --- a/arch/mips/kernel/time.c +++ b/arch/mips/kernel/time.c | |||
@@ -65,9 +65,9 @@ static int null_rtc_set_time(unsigned long sec) | |||
65 | return 0; | 65 | return 0; |
66 | } | 66 | } |
67 | 67 | ||
68 | unsigned long (*rtc_get_time)(void) = null_rtc_get_time; | 68 | unsigned long (*rtc_mips_get_time)(void) = null_rtc_get_time; |
69 | int (*rtc_set_time)(unsigned long) = null_rtc_set_time; | 69 | int (*rtc_mips_set_time)(unsigned long) = null_rtc_set_time; |
70 | int (*rtc_set_mmss)(unsigned long); | 70 | int (*rtc_mips_set_mmss)(unsigned long); |
71 | 71 | ||
72 | 72 | ||
73 | /* usecs per counter cycle, shifted to left by 32 bits */ | 73 | /* usecs per counter cycle, shifted to left by 32 bits */ |
@@ -440,14 +440,14 @@ irqreturn_t timer_interrupt(int irq, void *dev_id, struct pt_regs *regs) | |||
440 | 440 | ||
441 | /* | 441 | /* |
442 | * If we have an externally synchronized Linux clock, then update | 442 | * If we have an externally synchronized Linux clock, then update |
443 | * CMOS clock accordingly every ~11 minutes. rtc_set_time() has to be | 443 | * CMOS clock accordingly every ~11 minutes. rtc_mips_set_time() has to be |
444 | * called as close as possible to 500 ms before the new second starts. | 444 | * called as close as possible to 500 ms before the new second starts. |
445 | */ | 445 | */ |
446 | if (ntp_synced() && | 446 | if (ntp_synced() && |
447 | xtime.tv_sec > last_rtc_update + 660 && | 447 | xtime.tv_sec > last_rtc_update + 660 && |
448 | (xtime.tv_nsec / 1000) >= 500000 - ((unsigned) TICK_SIZE) / 2 && | 448 | (xtime.tv_nsec / 1000) >= 500000 - ((unsigned) TICK_SIZE) / 2 && |
449 | (xtime.tv_nsec / 1000) <= 500000 + ((unsigned) TICK_SIZE) / 2) { | 449 | (xtime.tv_nsec / 1000) <= 500000 + ((unsigned) TICK_SIZE) / 2) { |
450 | if (rtc_set_mmss(xtime.tv_sec) == 0) { | 450 | if (rtc_mips_set_mmss(xtime.tv_sec) == 0) { |
451 | last_rtc_update = xtime.tv_sec; | 451 | last_rtc_update = xtime.tv_sec; |
452 | } else { | 452 | } else { |
453 | /* do it again in 60 s */ | 453 | /* do it again in 60 s */ |
@@ -565,7 +565,7 @@ asmlinkage void ll_local_timer_interrupt(int irq, struct pt_regs *regs) | |||
565 | * b) (optional) calibrate and set the mips_hpt_frequency | 565 | * b) (optional) calibrate and set the mips_hpt_frequency |
566 | * (only needed if you intended to use fixed_rate_gettimeoffset | 566 | * (only needed if you intended to use fixed_rate_gettimeoffset |
567 | * or use cpu counter as timer interrupt source) | 567 | * or use cpu counter as timer interrupt source) |
568 | * 2) setup xtime based on rtc_get_time(). | 568 | * 2) setup xtime based on rtc_mips_get_time(). |
569 | * 3) choose a appropriate gettimeoffset routine. | 569 | * 3) choose a appropriate gettimeoffset routine. |
570 | * 4) calculate a couple of cached variables for later usage | 570 | * 4) calculate a couple of cached variables for later usage |
571 | * 5) board_timer_setup() - | 571 | * 5) board_timer_setup() - |
@@ -633,10 +633,10 @@ void __init time_init(void) | |||
633 | if (board_time_init) | 633 | if (board_time_init) |
634 | board_time_init(); | 634 | board_time_init(); |
635 | 635 | ||
636 | if (!rtc_set_mmss) | 636 | if (!rtc_mips_set_mmss) |
637 | rtc_set_mmss = rtc_set_time; | 637 | rtc_mips_set_mmss = rtc_mips_set_time; |
638 | 638 | ||
639 | xtime.tv_sec = rtc_get_time(); | 639 | xtime.tv_sec = rtc_mips_get_time(); |
640 | xtime.tv_nsec = 0; | 640 | xtime.tv_nsec = 0; |
641 | 641 | ||
642 | set_normalized_timespec(&wall_to_monotonic, | 642 | set_normalized_timespec(&wall_to_monotonic, |
@@ -772,8 +772,8 @@ void to_tm(unsigned long tim, struct rtc_time *tm) | |||
772 | 772 | ||
773 | EXPORT_SYMBOL(rtc_lock); | 773 | EXPORT_SYMBOL(rtc_lock); |
774 | EXPORT_SYMBOL(to_tm); | 774 | EXPORT_SYMBOL(to_tm); |
775 | EXPORT_SYMBOL(rtc_set_time); | 775 | EXPORT_SYMBOL(rtc_mips_set_time); |
776 | EXPORT_SYMBOL(rtc_get_time); | 776 | EXPORT_SYMBOL(rtc_mips_get_time); |
777 | 777 | ||
778 | unsigned long long sched_clock(void) | 778 | unsigned long long sched_clock(void) |
779 | { | 779 | { |