Re: [PATCH 2/2] tracing, sched: Add delay info to sched_switch

From: Steven Rostedt
Date: Mon Dec 19 2011 - 18:34:49 EST


On Tue, 2011-12-20 at 00:28 +0100, Peter Zijlstra wrote:
> On Mon, 2011-12-19 at 15:23 -0800, Arun Sharma wrote:
> > +#ifdef CONFIG_SCHEDSTATS
> > + __entry->delay = next->se.statistics.block_start ? next->se.statistics.block_start
> > + : next->se.statistics.sleep_start ? next->se.statistics.sleep_start : 0;
> > + __entry->delay = __entry->delay ? now - __entry->delay : 0;
> > +#else
> > + __entry->delay = 0;
> > +#endif
>
> I don't really like this, this should be one of those sched_*_stat
> thingies, not sched_switch().

Agreed.

-- Steve


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/