Re: [PATCH 1/4] vtime: Remove the underscore prefix invasion
From: Steven Rostedt
Date: Wed Nov 14 2012 - 11:57:43 EST
On Wed, 2012-11-14 at 17:48 +0100, Frederic Weisbecker wrote:
> 2012/11/14 Steven Rostedt <rostedt@xxxxxxxxxxx>:
> > On Wed, 2012-11-14 at 17:26 +0100, Frederic Weisbecker wrote:
> >> Prepending irq-unsafe vtime APIs with underscores was actually
> >> a bad idea as the result is a big mess in the API namespace that
> >> is even waiting to be further extended. Also these helpers
> >> are always called from irq safe callers except kvm. Just
> >> provide a vtime_account_system_irqsafe() for this specific
> >> case so that we can remove the underscore prefix on other
> >> vtime functions.
> >>
> >
> >
> >> -void __vtime_account_system(struct task_struct *tsk)
> >> +void vtime_account_system(struct task_struct *tsk)
> >> {
> >> cputime_t delta = vtime_delta(tsk);
> >
> > Should we add a WARN_ON(!irqs_disabled()) check here?
>
> Why not, I'll add one in vtime_delta().
Probably make it a WARN_ON_ONCE() no need to spam the console.
-- 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/