vserver 1.9.5.x5
[linux-2.6.git] / arch / sparc64 / kernel / time.c
index b50e16d..5c341ec 100644 (file)
@@ -46,8 +46,8 @@
 #include <asm/sections.h>
 #include <asm/cpudata.h>
 
-spinlock_t mostek_lock = SPIN_LOCK_UNLOCKED;
-spinlock_t rtc_lock = SPIN_LOCK_UNLOCKED;
+DEFINE_SPINLOCK(mostek_lock);
+DEFINE_SPINLOCK(rtc_lock);
 unsigned long mstk48t02_regs = 0UL;
 #ifdef CONFIG_PCI
 unsigned long ds1287_regs = 0UL;
@@ -64,7 +64,16 @@ static unsigned long mstk48t59_regs = 0UL;
 
 static int set_rtc_mmss(unsigned long);
 
-struct sparc64_tick_ops *tick_ops;
+static __init unsigned long dummy_get_tick(void)
+{
+       return 0;
+}
+
+static __initdata struct sparc64_tick_ops dummy_tick_ops = {
+       .get_tick       = dummy_get_tick,
+};
+
+struct sparc64_tick_ops *tick_ops = &dummy_tick_ops;
 
 #define TICK_PRIV_BIT  (1UL << 63)
 
@@ -462,6 +471,7 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id, struct pt_regs * regs)
        do {
 #ifndef CONFIG_SMP
                profile_tick(CPU_PROFILING, regs);
+               update_process_times(user_mode(regs));
 #endif
                do_timer(regs);
 
@@ -1036,6 +1046,7 @@ static struct notifier_block sparc64_cpufreq_notifier_block = {
 static struct time_interpolator sparc64_cpu_interpolator = {
        .source         =       TIME_SOURCE_CPU,
        .shift          =       16,
+       .mask           =       0xffffffffffffffffLL
 };
 
 /* The quotient formula is taken from the IA64 port. */