lkml.org 
[lkml]   [2014]   [Apr]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/2] nohz: stop updating sleep stats from get_cpu_{idle,iowait}_time_us()
On Tue, Apr 15, 2014 at 10:48:54AM +0200, Peter Zijlstra wrote:
> On Thu, Apr 10, 2014 at 06:11:03PM +0900, Hidetoshi Seto wrote:
> > - if (ts->idle_active) {
> > - delta = ktime_sub(now, ts->idle_entrytime);
> > - if (nr_iowait_cpu(cpu) > 0)
> > - ts->iowait_sleeptime = ktime_add(ts->iowait_sleeptime, delta);
> > - else
> > - ts->idle_sleeptime = ktime_add(ts->idle_sleeptime, delta);
> > - ts->idle_entrytime = now;
> > - }
> > -
> > - if (last_update_time)
> > - *last_update_time = ktime_to_us(now);
> > -
> > -}
> > -
> > -static void tick_nohz_stop_idle(struct tick_sched *ts, ktime_t now)
> > -{
> > - update_ts_time_stats(smp_processor_id(), ts, now, NULL);
> > + /* Updates the per cpu time idle statistics counters */
> > + delta = ktime_sub(now, ts->idle_entrytime);
> > + if (nr_iowait_cpu(smp_processor_id()) > 0)
>
> Now I know the old code also uses nr_iowait_cpu(), but that function is
> crackbrained. This cannot possibly be right.
>
> Anything using nr_iowait_cpu() is broken beyond repair.

Argh, still need to wake up.. so it uses the old rq to decrement
against.

never mind, I'll go stare at it more


\
 
 \ /
  Last update: 2014-04-15 11:41    [W:0.125 / U:13.112 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site