Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1632582

[patch] Re: x86-tip tsc/tick gripage

From Mike Galbraith <efault@gmx.de>
Newsgroups linux.kernel
Subject [patch] Re: x86-tip tsc/tick gripage
Date 2017-04-28 09:40 +0200
Message-ID <tB8Fr-4jD-11@gated-at.bofh.it> (permalink)
References (2 earlier) <tAquJ-87M-5@gated-at.bofh.it> <tAqEq-8cm-23@gated-at.bofh.it> <tAr7s-bV-21@gated-at.bofh.it> <tAsmS-Y5-15@gated-at.bofh.it> <tAtCh-1In-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, 2017-04-26 at 13:39 +0200, Mike Galbraith wrote:
> On Wed, 2017-04-26 at 12:26 +0200, Peter Zijlstra wrote:
> > On Wed, Apr 26, 2017 at 10:57:42AM +0200, Mike Galbraith wrote:
> > 
> > > Both still lose their TSC.
> > > 
> > > [   11.982468] tsc: Refined TSC clocksource calibration: 2260.999 MHz
> > > [   11.994275] clocksource: tsc: mask: 0xffffffffffffffff max_cycles: 0x20974a4d8bb, max_idle_ns: 440795246623 ns
> > > [   13.064172] clocksource: Switched to clocksource tsc
> > > [  240.247851] clocksource: timekeeping watchdog on CPU23: Marking clocksource 'tsc' as unstable because the skew is too large:
> > > [  240.462501] clocksource:                       'tsc' cs_now: 108fe5be09f cs_last: b90a6a0676 mask: ffffffffffffffff
> > > [  240.675057] tsc: Marking TSC unstable due to clocksource watchdog
> > 
> > 
> > And they didn't use to? We don't typically write to TSC or TSC_ADJUST
> > and thus would not cause such behaviour.
> 
> Nope.  The DL980 is my RT jitter test box, which I use all the time. 

I found evidence of lysdexia at play (hunk 2), below is an RFFS (frozen
shark) which makes my DL980 a happy camper with tip.

timer/nohz: Call tick_tmigr_idle() with proper parameter order

Extremely late timer expiration soon leads to the clocksource watchdog
killing the TSC clocksource on multisocket boxen.  Call tmigr_cpu_idle(
) with proper parameter order, and pass next_local to tmigr_cpu_idle()
so it can return what it says it returns.

Signed-off-by: Mike Galbraith <efault@gmx.de>
Fixes: ec2206b91d43 timer: Implement the hierarchical pull model
---
 kernel/time/tick-sched.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/kernel/time/tick-sched.c
+++ b/kernel/time/tick-sched.c
@@ -695,7 +695,7 @@ tick_tmigr_idle(struct tick_sched *ts, u
 	if (next_global >= next_local)
 		next_global = KTIME_MAX;
 
-	next_global = tmigr_cpu_idle(next_global);
+	next_local = tmigr_cpu_idle(next_local);
 
 	return min_t(u64, next_local, next_global);
 }
@@ -768,7 +768,7 @@ static ktime_t tick_nohz_stop_sched_tick
 	 */
 	delta = next_local - basemono;
 	if (delta > (u64)TICK_NSEC)
-		next_local = tick_tmigr_idle(ts, next_local, next_global);
+		next_local = tick_tmigr_idle(ts, next_global, next_local);
 
 	ts->next_timer = next_local;
 

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 10:20 +0200
  Re: x86-tip tsc/tick gripage Ingo Molnar <mingo@kernel.org> - 2017-04-26 10:30 +0200
    Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 10:40 +0200
      Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 11:10 +0200
        Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 11:50 +0200
        Re: x86-tip tsc/tick gripage Peter Zijlstra <peterz@infradead.org> - 2017-04-26 12:30 +0200
          Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 13:50 +0200
            Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 14:40 +0200
              Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 20:20 +0200
              Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-27 07:30 +0200
              [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() Mike Galbraith <efault@gmx.de> - 2017-04-29 18:10 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-04-29 20:10 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() Mike Galbraith <efault@gmx.de> - 2017-04-29 20:30 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-04-29 23:50 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() Mike Galbraith <efault@gmx.de> - 2017-04-30 03:30 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-04-30 05:50 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() Mike Galbraith <efault@gmx.de> - 2017-04-30 06:30 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-04-30 06:40 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-05-01 00:50 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() Thomas Gleixner <tglx@linutronix.de> - 2017-05-01 10:00 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() "Paul E. McKenney" <paulmck@linux.vnet.ibm.com> - 2017-05-01 21:40 +0200
                Re: [patch] timer: Fix timers_update_migration(), and call it in  tmigr_init() Mike Galbraith <efault@gmx.de> - 2017-04-30 07:10 +0200
            [patch] Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-28 09:40 +0200
              Re: [patch] Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-28 10:50 +0200
                Re: [patch] Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-28 16:20 +0200
  Re: x86-tip tsc/tick gripage Mike Galbraith <efault@gmx.de> - 2017-04-26 10:30 +0200

csiph-web