lkml.org 
[lkml]   [2011]   [Dec]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC][PATCH 6/7] printk: Poke printk extra hard

* Peter Zijlstra <a.p.zijlstra@chello.nl> wrote:

> On Thu, 2011-12-22 at 08:02 +0100, Ingo Molnar wrote:
> > * Linus Torvalds <torvalds@linux-foundation.org> wrote:
> >
> > > On Wed, Dec 21, 2011 at 2:57 AM, Peter Zijlstra <a.p.zijlstra@chello.nl> wrote:
> > > >
> > > >
> > > > +#ifdef CONFIG_PRINTK_DEBUG
> > > > +void printk_init(void)
> > > > +{
> > > > + struct rq *rq;
> > > > + unsigned long flags;
> > > > +
> > > > + local_irq_save(flags);
> > > > + rq = this_rq();
> > > > + raw_spin_lock(&rq->lock);
> > > > + printk(KERN_DEBUG "printk: echo echo echo..\n");
> > > > + raw_spin_unlock(&rq->lock);
> > > > + local_irq_restore(flags);
> > >
> > > Ok, I can't really say that I think this is worth a config option like this.
> > >
> > > Maybe an example module or something?
>
> I really really really don't want to expose struct rq to
> modules, that's just asking for trouble. But yeah, I know what
> you mean with not being worth the config option, but then, I
> thought I might as well post it, it can't be more horrible
> than the sem patch, can it ;-)

Could be made part of the locking self-tests - that way it does
not add an extra config option! ;-)

Thanks,

Ingo


\
 
 \ /
  Last update: 2011-12-22 10:09    [W:0.709 / U:0.284 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site