[kernel] r19313 - in dists/sid/linux/debian: . patches patches/features/all/rt

Ben Hutchings benh at alioth.debian.org
Tue Aug 7 05:50:19 UTC 2012


Author: benh
Date: Tue Aug  7 05:50:17 2012
New Revision: 19313

Log:
[rt] Update to 3.2.26-rt39

This is a bit of a kluge, as Steven Rostedt is no longer providing
rebased tags in git.  There is one updated (23) and one new patch
(282) from 3.2.24-rt38-rebase, and the version bump patch that follows
the trivial merge of 3.2.26 and 3.2.24-rt38 (283).

The combined diff for this patch series appears to be the same (modulo
line numbers shifted by Debian patches) as that between 3.2.26 and
3.2.26-rt39.

Added:
   dists/sid/linux/debian/patches/features/all/rt/0282-time-rt-Fix-up-leap-second-backport-for-RT-changes.patch
   dists/sid/linux/debian/patches/features/all/rt/0283-Linux-3.2.24-rt38-REBASE.patch
   dists/sid/linux/debian/patches/features/all/rt/0284-Linux-3.2.26-rt39.patch
Deleted:
   dists/sid/linux/debian/patches/features/all/rt/0282-Linux-3.2.23-rt37-REBASE.patch
Modified:
   dists/sid/linux/debian/changelog
   dists/sid/linux/debian/patches/features/all/rt/0023-timekeeping-Split-xtime_lock.patch
   dists/sid/linux/debian/patches/features/all/rt/series
   dists/sid/linux/debian/patches/series-rt

Modified: dists/sid/linux/debian/changelog
==============================================================================
--- dists/sid/linux/debian/changelog	Tue Aug  7 05:41:22 2012	(r19312)
+++ dists/sid/linux/debian/changelog	Tue Aug  7 05:50:17 2012	(r19313)
@@ -62,6 +62,8 @@
     - Change the audit message type from AUDIT_AVC (1400) to
       AUDIT_ANON_LINK (1702)
   * lirc_sir: make device registration work (Closes: #680762)
+  * [rt] Update to 3.2.26-rt39:
+    - time/rt: Fix up leap-second backport for RT changes
 
  -- Ben Hutchings <ben at decadent.org.uk>  Tue, 24 Jul 2012 02:20:37 +0100
 

Modified: dists/sid/linux/debian/patches/features/all/rt/0023-timekeeping-Split-xtime_lock.patch
==============================================================================
--- dists/sid/linux/debian/patches/features/all/rt/0023-timekeeping-Split-xtime_lock.patch	Tue Aug  7 05:41:22 2012	(r19312)
+++ dists/sid/linux/debian/patches/features/all/rt/0023-timekeeping-Split-xtime_lock.patch	Tue Aug  7 05:50:17 2012	(r19313)
@@ -1,7 +1,7 @@
-From a0b5d92787bc37be58a70439b4399f0014840c3b Mon Sep 17 00:00:00 2001
+From 6279b0161cf978d1c6c12a7991cc27676ad1fbc2 Mon Sep 17 00:00:00 2001
 From: Thomas Gleixner <tglx at linutronix.de>
 Date: Thu, 1 Mar 2012 15:14:06 +0100
-Subject: [PATCH 023/282] timekeeping: Split xtime_lock
+Subject: [PATCH 023/283] timekeeping: Split xtime_lock
 
 xtime_lock is going to be split apart in mainline, so we can shorten
 the seqcount protected regions and avoid updating seqcount in some
@@ -9,19 +9,17 @@
 whole mess with raw seqlocks for RT.
 
 Signed-off-by: Thomas Gleixner <tglx at linutronix.de>
-[bwh: Forward-ported to 3.2.24: adjust context; drop changes to
- ntp_leap_second() function removed by commit
- 6b43ae8a619d17c4935c3320d2ef9e92bdeed05d ('ntp: Fix leap-second hrtimer
- livelock')]
 ---
  kernel/time/jiffies.c       |    4 +-
- kernel/time/ntp.c           |   24 ++++++++----
+ kernel/time/ntp.c           |   23 ++++++++---
  kernel/time/tick-common.c   |   10 +++--
  kernel/time/tick-internal.h |    3 +-
  kernel/time/tick-sched.c    |   16 +++++---
  kernel/time/timekeeping.c   |   90 +++++++++++++++++++++++++------------------
- 6 files changed, 88 insertions(+), 59 deletions(-)
+ 6 files changed, 89 insertions(+), 57 deletions(-)
 
+diff --git a/kernel/time/jiffies.c b/kernel/time/jiffies.c
+index a470154..21940eb 100644
 --- a/kernel/time/jiffies.c
 +++ b/kernel/time/jiffies.c
 @@ -74,9 +74,9 @@ u64 get_jiffies_64(void)
@@ -36,9 +34,30 @@
  	return ret;
  }
  EXPORT_SYMBOL(get_jiffies_64);
+diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c
+index f1eb182..09079b7 100644
 --- a/kernel/time/ntp.c
 +++ b/kernel/time/ntp.c
-@@ -623,7 +623,8 @@ int do_adjtimex(struct timex *txc)
+@@ -362,6 +362,9 @@ int second_overflow(unsigned long secs)
+ 	int leap = 0;
+ 	s64 delta;
+ 
++	raw_spin_lock(&xtime_lock);
++	write_seqcount_begin(&xtime_seq);
++
+ 	/*
+ 	 * Leap second processing. If in leap-insert state at the end of the
+ 	 * day, the system clock is set back one second; if in leap-delete
+@@ -402,6 +405,8 @@ int second_overflow(unsigned long secs)
+ 		break;
+ 	}
+ 
++	write_seqcount_end(&xtime_seq);
++	raw_spin_unlock(&xtime_lock);
+ 
+ 	/* Bump the maxerror field */
+ 	time_maxerror += MAXFREQ / NSEC_PER_USEC;
+@@ -623,7 +628,8 @@ int do_adjtimex(struct timex *txc)
  
  	getnstimeofday(&ts);
  
@@ -48,7 +67,7 @@
  
  	if (txc->modes & ADJ_ADJTIME) {
  		long save_adjust = time_adjust;
-@@ -665,7 +666,8 @@ int do_adjtimex(struct timex *txc)
+@@ -665,7 +671,8 @@ int do_adjtimex(struct timex *txc)
  	/* fill PPS status fields */
  	pps_fill_timex(txc);
  
@@ -58,7 +77,7 @@
  
  	txc->time.tv_sec = ts.tv_sec;
  	txc->time.tv_usec = ts.tv_nsec;
-@@ -863,7 +865,8 @@ void hardpps(const struct timespec *phas
+@@ -863,7 +870,8 @@ void hardpps(const struct timespec *phase_ts, const struct timespec *raw_ts)
  
  	pts_norm = pps_normalize_ts(*phase_ts);
  
@@ -68,7 +87,7 @@
  
  	/* clear the error bits, they will be set again if needed */
  	time_status &= ~(STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR);
-@@ -876,7 +879,8 @@ void hardpps(const struct timespec *phas
+@@ -876,7 +884,8 @@ void hardpps(const struct timespec *phase_ts, const struct timespec *raw_ts)
  	 * just start the frequency interval */
  	if (unlikely(pps_fbase.tv_sec == 0)) {
  		pps_fbase = *raw_ts;
@@ -78,7 +97,7 @@
  		return;
  	}
  
-@@ -891,7 +895,8 @@ void hardpps(const struct timespec *phas
+@@ -891,7 +900,8 @@ void hardpps(const struct timespec *phase_ts, const struct timespec *raw_ts)
  		time_status |= STA_PPSJITTER;
  		/* restart the frequency calibration interval */
  		pps_fbase = *raw_ts;
@@ -88,7 +107,7 @@
  		pr_err("hardpps: PPSJITTER: bad pulse\n");
  		return;
  	}
-@@ -908,7 +913,8 @@ void hardpps(const struct timespec *phas
+@@ -908,7 +918,8 @@ void hardpps(const struct timespec *phase_ts, const struct timespec *raw_ts)
  
  	hardpps_update_phase(pts_norm.nsec);
  
@@ -98,6 +117,8 @@
  }
  EXPORT_SYMBOL(hardpps);
  
+diff --git a/kernel/time/tick-common.c b/kernel/time/tick-common.c
+index da6c9ec..39de540 100644
 --- a/kernel/time/tick-common.c
 +++ b/kernel/time/tick-common.c
 @@ -63,13 +63,15 @@ int tick_is_oneshot_available(void)
@@ -118,7 +139,7 @@
  	}
  
  	update_process_times(user_mode(get_irq_regs()));
-@@ -130,9 +132,9 @@ void tick_setup_periodic(struct clock_ev
+@@ -130,9 +132,9 @@ void tick_setup_periodic(struct clock_event_device *dev, int broadcast)
  		ktime_t next;
  
  		do {
@@ -130,18 +151,22 @@
  
  		clockevents_set_mode(dev, CLOCK_EVT_MODE_ONESHOT);
  
+diff --git a/kernel/time/tick-internal.h b/kernel/time/tick-internal.h
+index 4e265b9..c91100d 100644
 --- a/kernel/time/tick-internal.h
 +++ b/kernel/time/tick-internal.h
-@@ -141,4 +141,5 @@ static inline int tick_device_is_functio
+@@ -141,4 +141,5 @@ static inline int tick_device_is_functional(struct clock_event_device *dev)
  #endif
  
  extern void do_timer(unsigned long ticks);
 -extern seqlock_t xtime_lock;
 +extern raw_spinlock_t xtime_lock;
 +extern seqcount_t xtime_seq;
+diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c
+index 9955ebd..f8d1e36 100644
 --- a/kernel/time/tick-sched.c
 +++ b/kernel/time/tick-sched.c
-@@ -56,7 +56,8 @@ static void tick_do_update_jiffies64(kti
+@@ -56,7 +56,8 @@ static void tick_do_update_jiffies64(ktime_t now)
  		return;
  
  	/* Reevalute with xtime_lock held */
@@ -151,7 +176,7 @@
  
  	delta = ktime_sub(now, last_jiffies_update);
  	if (delta.tv64 >= tick_period.tv64) {
-@@ -79,7 +80,8 @@ static void tick_do_update_jiffies64(kti
+@@ -79,7 +80,8 @@ static void tick_do_update_jiffies64(ktime_t now)
  		/* Keep the tick_next_period variable up to date */
  		tick_next_period = ktime_add(last_jiffies_update, tick_period);
  	}
@@ -161,7 +186,7 @@
  }
  
  /*
-@@ -89,12 +91,14 @@ static ktime_t tick_init_jiffy_update(vo
+@@ -89,12 +91,14 @@ static ktime_t tick_init_jiffy_update(void)
  {
  	ktime_t period;
  
@@ -178,7 +203,7 @@
  	return period;
  }
  
-@@ -345,11 +349,11 @@ void tick_nohz_stop_sched_tick(int inidl
+@@ -345,11 +349,11 @@ void tick_nohz_stop_sched_tick(int inidle)
  	ts->idle_calls++;
  	/* Read jiffies and the time when jiffies were updated last */
  	do {
@@ -192,9 +217,11 @@
  
  	if (rcu_needs_cpu(cpu) || printk_needs_cpu(cpu) ||
  	    arch_needs_cpu(cpu)) {
+diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
+index 03e67d4..03493fd 100644
 --- a/kernel/time/timekeeping.c
 +++ b/kernel/time/timekeeping.c
-@@ -139,8 +139,8 @@ static inline s64 timekeeping_get_ns_raw
+@@ -139,8 +139,8 @@ static inline s64 timekeeping_get_ns_raw(void)
   * This read-write spinlock protects us from races in SMP while
   * playing with xtime.
   */
@@ -257,7 +284,7 @@
  
  	set_normalized_timespec(ts, ts->tv_sec + tomono.tv_sec,
  				ts->tv_nsec + tomono.tv_nsec + nsecs);
-@@ -333,7 +333,7 @@ void getnstime_raw_and_real(struct times
+@@ -333,7 +333,7 @@ void getnstime_raw_and_real(struct timespec *ts_raw, struct timespec *ts_real)
  	do {
  		u32 arch_offset;
  
@@ -266,7 +293,7 @@
  
  		*ts_raw = raw_time;
  		*ts_real = xtime;
-@@ -346,7 +346,7 @@ void getnstime_raw_and_real(struct times
+@@ -346,7 +346,7 @@ void getnstime_raw_and_real(struct timespec *ts_raw, struct timespec *ts_real)
  		nsecs_raw += arch_offset;
  		nsecs_real += arch_offset;
  
@@ -275,7 +302,7 @@
  
  	timespec_add_ns(ts_raw, nsecs_raw);
  	timespec_add_ns(ts_real, nsecs_real);
-@@ -385,7 +385,8 @@ int do_settimeofday(const struct timespe
+@@ -385,7 +385,8 @@ int do_settimeofday(const struct timespec *tv)
  	if ((unsigned long)tv->tv_nsec >= NSEC_PER_SEC)
  		return -EINVAL;
  
@@ -285,7 +312,7 @@
  
  	timekeeping_forward_now();
  
-@@ -397,7 +398,8 @@ int do_settimeofday(const struct timespe
+@@ -397,7 +398,8 @@ int do_settimeofday(const struct timespec *tv)
  
  	timekeeping_update(true);
  
@@ -295,7 +322,7 @@
  
  	/* signal hrtimers about time change */
  	clock_was_set();
-@@ -421,7 +423,8 @@ int timekeeping_inject_offset(struct tim
+@@ -421,7 +423,8 @@ int timekeeping_inject_offset(struct timespec *ts)
  	if ((unsigned long)ts->tv_nsec >= NSEC_PER_SEC)
  		return -EINVAL;
  
@@ -305,7 +332,7 @@
  
  	timekeeping_forward_now();
  
-@@ -430,7 +433,8 @@ int timekeeping_inject_offset(struct tim
+@@ -430,7 +433,8 @@ int timekeeping_inject_offset(struct timespec *ts)
  
  	timekeeping_update(true);
  
@@ -315,7 +342,7 @@
  
  	/* signal hrtimers about time change */
  	clock_was_set();
-@@ -502,11 +506,11 @@ void getrawmonotonic(struct timespec *ts
+@@ -502,11 +506,11 @@ void getrawmonotonic(struct timespec *ts)
  	s64 nsecs;
  
  	do {
@@ -363,7 +390,7 @@
  }
  
  /* time in seconds when suspend began */
-@@ -659,14 +665,16 @@ void timekeeping_inject_sleeptime(struct
+@@ -659,14 +665,16 @@ void timekeeping_inject_sleeptime(struct timespec *delta)
  	if (!(ts.tv_sec == 0 && ts.tv_nsec == 0))
  		return;
  
@@ -422,7 +449,7 @@
  
  	clockevents_notify(CLOCK_EVT_NOTIFY_SUSPEND, NULL);
  	clocksource_suspend();
-@@ -1126,13 +1138,13 @@ void get_monotonic_boottime(struct times
+@@ -1126,13 +1138,13 @@ void get_monotonic_boottime(struct timespec *ts)
  	WARN_ON(timekeeping_suspended);
  
  	do {
@@ -438,7 +465,7 @@
  
  	set_normalized_timespec(ts, ts->tv_sec + tomono.tv_sec + sleep.tv_sec,
  			ts->tv_nsec + tomono.tv_nsec + sleep.tv_nsec + nsecs);
-@@ -1183,10 +1195,10 @@ struct timespec current_kernel_time(void
+@@ -1183,10 +1195,10 @@ struct timespec current_kernel_time(void)
  	unsigned long seq;
  
  	do {
@@ -451,7 +478,7 @@
  
  	return now;
  }
-@@ -1198,11 +1210,11 @@ struct timespec get_monotonic_coarse(voi
+@@ -1198,11 +1210,11 @@ struct timespec get_monotonic_coarse(void)
  	unsigned long seq;
  
  	do {
@@ -465,7 +492,7 @@
  
  	set_normalized_timespec(&now, now.tv_sec + mono.tv_sec,
  				now.tv_nsec + mono.tv_nsec);
-@@ -1234,11 +1246,11 @@ void get_xtime_and_monotonic_and_sleep_o
+@@ -1234,11 +1246,11 @@ void get_xtime_and_monotonic_and_sleep_offset(struct timespec *xtim,
  	unsigned long seq;
  
  	do {

Added: dists/sid/linux/debian/patches/features/all/rt/0282-time-rt-Fix-up-leap-second-backport-for-RT-changes.patch
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/sid/linux/debian/patches/features/all/rt/0282-time-rt-Fix-up-leap-second-backport-for-RT-changes.patch	Tue Aug  7 05:50:17 2012	(r19313)
@@ -0,0 +1,66 @@
+From 363513520a462b2208bd8fd37a08c198c84d80e2 Mon Sep 17 00:00:00 2001
+From: Steven Rostedt <rostedt at goodmis.org>
+Date: Thu, 2 Aug 2012 18:56:52 -0400
+Subject: [PATCH 282/283] time/rt: Fix up leap-second backport for RT changes
+
+The leap-second backport broke RT, and a few changes had to be done.
+
+1) The second_overflow now encompasses ntp_leap_second, and since
+second_overflow is called with the xtime_lock held, we can not take that
+lock either.
+
+2) Change ktime_get_update_offsets() to use read_seqcount_begin() instead
+of read_seq_begin() (and retry).
+
+Signed-off-by: Steven Rostedt <rostedt at goodmis.org>
+---
+ kernel/time/ntp.c         |    6 ------
+ kernel/time/timekeeping.c |    4 ++--
+ 2 files changed, 2 insertions(+), 8 deletions(-)
+
+diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c
+index 09079b7..4b63943 100644
+--- a/kernel/time/ntp.c
++++ b/kernel/time/ntp.c
+@@ -362,9 +362,6 @@ int second_overflow(unsigned long secs)
+ 	int leap = 0;
+ 	s64 delta;
+ 
+-	raw_spin_lock(&xtime_lock);
+-	write_seqcount_begin(&xtime_seq);
+-
+ 	/*
+ 	 * Leap second processing. If in leap-insert state at the end of the
+ 	 * day, the system clock is set back one second; if in leap-delete
+@@ -405,9 +402,6 @@ int second_overflow(unsigned long secs)
+ 		break;
+ 	}
+ 
+-	write_seqcount_end(&xtime_seq);
+-	raw_spin_unlock(&xtime_lock);
+-
+ 	/* Bump the maxerror field */
+ 	time_maxerror += MAXFREQ / NSEC_PER_USEC;
+ 	if (time_maxerror > NTP_PHASE_LIMIT) {
+diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
+index 03493fd..991259a 100644
+--- a/kernel/time/timekeeping.c
++++ b/kernel/time/timekeeping.c
+@@ -1269,7 +1269,7 @@ ktime_t ktime_get_update_offsets(ktime_t *real, ktime_t *boot)
+ 	u64 secs, nsecs;
+ 
+ 	do {
+-		seq = read_seqbegin(&xtime_lock);
++		seq = read_seqcount_begin(&xtime_seq);
+ 
+ 		secs = xtime.tv_sec;
+ 		nsecs = xtime.tv_nsec;
+@@ -1279,7 +1279,7 @@ ktime_t ktime_get_update_offsets(ktime_t *real, ktime_t *boot)
+ 
+ 		*real = offs_real;
+ 		*boot = offs_boot;
+-	} while (read_seqretry(&xtime_lock, seq));
++	} while (read_seqcount_retry(&xtime_seq, seq));
+ 
+ 	now = ktime_add_ns(ktime_set(secs, 0), nsecs);
+ 	now = ktime_sub(now, *real);

Added: dists/sid/linux/debian/patches/features/all/rt/0283-Linux-3.2.24-rt38-REBASE.patch
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/sid/linux/debian/patches/features/all/rt/0283-Linux-3.2.24-rt38-REBASE.patch	Tue Aug  7 05:50:17 2012	(r19313)
@@ -0,0 +1,16 @@
+From 0d0416ade8d0737e775738d92836fca39bd088e3 Mon Sep 17 00:00:00 2001
+From: Steven Rostedt <srostedt at redhat.com>
+Date: Tue, 17 Jul 2012 21:59:04 -0400
+Subject: [PATCH 283/283] Linux 3.2.24-rt38 REBASE
+
+---
+ localversion-rt |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/localversion-rt b/localversion-rt
+index b2111a2..49bae8d 100644
+--- a/localversion-rt
++++ b/localversion-rt
+@@ -1 +1 @@
+--rt24
++-rt38

Added: dists/sid/linux/debian/patches/features/all/rt/0284-Linux-3.2.26-rt39.patch
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/sid/linux/debian/patches/features/all/rt/0284-Linux-3.2.26-rt39.patch	Tue Aug  7 05:50:17 2012	(r19313)
@@ -0,0 +1,16 @@
+From 69ebd1210e5fc6535320c9da4c6196b95fa0668c Mon Sep 17 00:00:00 2001
+From: Steven Rostedt <srostedt at redhat.com>
+Date: Mon, 6 Aug 2012 19:43:11 -0400
+Subject: [PATCH] Linux 3.2.26-rt39
+
+---
+ localversion-rt |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/localversion-rt b/localversion-rt
+index 49bae8d..5498386 100644
+--- a/localversion-rt
++++ b/localversion-rt
+@@ -1 +1 @@
+--rt38
++-rt39

Modified: dists/sid/linux/debian/patches/features/all/rt/series
==============================================================================
--- dists/sid/linux/debian/patches/features/all/rt/series	Tue Aug  7 05:41:22 2012	(r19312)
+++ dists/sid/linux/debian/patches/features/all/rt/series	Tue Aug  7 05:50:17 2012	(r19313)
@@ -273,4 +273,6 @@
 0277-perf-Make-swevent-hrtimer-run-in-irq-instead-of-soft.patch
 0278-cpu-rt-Rework-cpu-down-for-PREEMPT_RT.patch
 0279-cpu-rt-Fix-cpu_hotplug-variable-initialization.patch
-0282-Linux-3.2.23-rt37-REBASE.patch
+0282-time-rt-Fix-up-leap-second-backport-for-RT-changes.patch
+0283-Linux-3.2.24-rt38-REBASE.patch
+0284-Linux-3.2.26-rt39.patch

Modified: dists/sid/linux/debian/patches/series-rt
==============================================================================
--- dists/sid/linux/debian/patches/series-rt	Tue Aug  7 05:41:22 2012	(r19312)
+++ dists/sid/linux/debian/patches/series-rt	Tue Aug  7 05:50:17 2012	(r19313)
@@ -273,4 +273,6 @@
 features/all/rt/0277-perf-Make-swevent-hrtimer-run-in-irq-instead-of-soft.patch
 features/all/rt/0278-cpu-rt-Rework-cpu-down-for-PREEMPT_RT.patch
 features/all/rt/0279-cpu-rt-Fix-cpu_hotplug-variable-initialization.patch
-features/all/rt/0282-Linux-3.2.23-rt37-REBASE.patch
+features/all/rt/0282-time-rt-Fix-up-leap-second-backport-for-RT-changes.patch
+features/all/rt/0283-Linux-3.2.24-rt38-REBASE.patch
+features/all/rt/0284-Linux-3.2.26-rt39.patch



More information about the Kernel-svn-changes mailing list