Re: [RFC][PATCH v6 0/2] printk: Make printk() completely async

From: Pavel Machek
Date: Sun Apr 24 2016 - 09:38:22 EST


On Sun 2016-04-24 14:14:49, Sergey Senozhatsky wrote:
> On (04/23/16 21:40), Pavel Machek wrote:
> [..]
> > > > The patch set is against next-20160321
> > > >
> > > > the series in total has 3 patches:
> > > > - printk: Make printk() completely async
> > > > - printk: Make wake_up_klogd_work_func() async
> > > > - printk: make console_unlock() async
> > > >
> > > > per discussion, "printk: make console_unlock() async" will be posted
> > > > later on.
> > >
> > > Patches look good to me. I don't think you need to mention the
> > > console_unlock() async patch when it is not part of the series. BTW, you
> > > seemed to have dropped my patch to skip if there are too many buffered
> > > messages when oops is in progress. Any reason for that?
> >
> > So... from basically linux 0.0, cli() printk("") could be used for
> > debugging. ... and that's now gone. Right?
> >
> > Can you explain why that is good idea?
>
> it's not gone. you need to explicitly enable async printk mode. the case
> you mentioned -- cli() printk("")->console_unlock() -- apart from being
> useful in some scenarios, can cause problems in others, simply because
> under some circumstances it can run forever, as long as there are printk()
> calls coming from other CPUs (which can happen during, f.e., debugging).
> did you mean UP systems? well, async printk is sort of useless on UP systems
> anyway.

Well, yes, it has been long known that printk() can take long
time.. Still that's not a problem for smaller system.

Now, patch set above says "Make printk() completely async" -- so I
assumed that it does...

Best regards,
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html