patch-2.4.20 linux-2.4.20/kernel/time.c

Next file: linux-2.4.20/kernel/timer.c
Previous file: linux-2.4.20/kernel/softirq.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.19/kernel/time.c linux-2.4.20/kernel/time.c
@@ -80,8 +80,10 @@
 	if (get_user(value, tptr))
 		return -EFAULT;
 	write_lock_irq(&xtime_lock);
+	vxtime_lock();
 	xtime.tv_sec = value;
 	xtime.tv_usec = 0;
+	vxtime_unlock();
 	time_adjust = 0;	/* stop active adjtime() */
 	time_status |= STA_UNSYNC;
 	time_maxerror = NTP_PHASE_LIMIT;
@@ -126,7 +128,9 @@
 inline static void warp_clock(void)
 {
 	write_lock_irq(&xtime_lock);
+	vxtime_lock();
 	xtime.tv_sec += sys_tz.tz_minuteswest * 60;
+	vxtime_unlock();
 	write_unlock_irq(&xtime_lock);
 }
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)