X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=arch%2Falpha%2Fkernel%2Ftime.c;h=75480cab0893c391619e681bdc1ee6dd6adbf7ed;hb=2b9a69861c39ae4c232385def833816acc07a0a4;hp=d7053eb4ffcfd93623d58aabda82d30cf9118dee;hpb=71fa0a849b384f066dea6a2351c722c19846f4ac;p=linux-2.6-omap-h63xx.git diff --git a/arch/alpha/kernel/time.c b/arch/alpha/kernel/time.c index d7053eb4ffc..75480cab089 100644 --- a/arch/alpha/kernel/time.c +++ b/arch/alpha/kernel/time.c @@ -90,17 +90,6 @@ static inline __u32 rpcc(void) return result; } -/* - * Scheduler clock - returns current time in nanosec units. - * - * Copied from ARM code for expediency... ;-} - */ -unsigned long long sched_clock(void) -{ - return (unsigned long long)jiffies * (1000000000 / HZ); -} - - /* * timer_interrupt() needs to keep up the real-time clock, * as well as call the "do_timer()" routine every clocktick @@ -130,13 +119,8 @@ irqreturn_t timer_interrupt(int irq, void *dev) state.partial_tick = delta & ((1UL << FIX_SHIFT) - 1); nticks = delta >> FIX_SHIFT; - while (nticks > 0) { - do_timer(1); -#ifndef CONFIG_SMP - update_process_times(user_mode(get_irq_regs())); -#endif - nticks--; - } + if (nticks) + do_timer(nticks); /* * If we have an externally synchronized Linux clock, then update @@ -152,10 +136,16 @@ irqreturn_t timer_interrupt(int irq, void *dev) } write_sequnlock(&xtime_lock); + +#ifndef CONFIG_SMP + while (nticks--) + update_process_times(user_mode(get_irq_regs())); +#endif + return IRQ_HANDLED; } -void +void __init common_init_rtc(void) { unsigned char x;