Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1496717

Re: [RFC][PATCHv2 0/7] printk: use alt_printk to handle printk() recursive calls

From Petr Mladek <pmladek@suse.com>
Newsgroups linux.kernel
Subject Re: [RFC][PATCHv2 0/7] printk: use alt_printk to handle printk() recursive calls
Date 2016-10-06 18:00 +0200
Message-ID <spjfs-2fb-15@gated-at.bofh.it> (permalink)
References <sn7Lr-3r4-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Sat 2016-10-01 00:17:51, Sergey Senozhatsky wrote:
> Hello,
> 
>         RFC
> 
>         This patch set extends a lock-less NMI per-cpu buffers idea to
> handle recursive printk() calls. The basic mechanism is pretty much the
> same -- at the beginning of a deadlock-prone section we switch to lock-less
> printk callback, and return back to a default printk implementation at the
> end; the messages are getting flushed to a logbuf buffer from a safer
> context.

OK, I think again that this patch set makes sense. It looks good after
all my doubts ;-)

Just I would like you to consider using some more meaningful name
instead of the "alt" prefix. I wonder how the following prefix
would look like:

	printk_safe*
	printk_safe_nmi*

I am not sure. It is possible that I am also confused that
you used prefix rather than a suffix. I was actually forced
to rename many new functions in the kthread worker API (my other
pet project) to start with the name of the subsystem (kthread
in this case).

Also "alt_printk_ctx" per-CPU variable describes a global
printk state. I think that the alt_ prefix is not needed
and "printk_context" would be better readable.

Thanks for patience with me.

Best Regards,
Petr

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[RFC][PATCHv2 0/7] printk: use alt_printk to handle printk() recursive calls Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-09-30 17:20 +0200
  [RFC][PATCHv2 7/7] printk: remove zap_locks() function Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-09-30 17:20 +0200
  [RFC][PATCHv2 4/7] printk: make alt_printk available when config printk set Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-09-30 17:20 +0200
    Re: [RFC][PATCHv2 4/7] printk: make alt_printk available when config  printk set Petr Mladek <pmladek@suse.com> - 2016-10-06 17:30 +0200
      Re: [RFC][PATCHv2 4/7] printk: make alt_printk available when config  printk set Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-10-10 03:40 +0200
  [RFC][PATCHv2 5/7] printk: use alternative printk buffers Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-09-30 17:20 +0200
  [RFC][PATCHv2 3/7] printk: introduce per-cpu alt_print seq buffer Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-09-30 17:30 +0200
    Re: [RFC][PATCHv2 3/7] printk: introduce per-cpu alt_print seq buffer Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-10-01 04:30 +0200
      Re: [RFC][PATCHv2 3/7] printk: introduce per-cpu alt_print seq buffer Petr Mladek <pmladek@suse.com> - 2016-10-06 17:00 +0200
        Re: [RFC][PATCHv2 3/7] printk: introduce per-cpu alt_print seq buffer Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-10-10 04:10 +0200
          Re: [RFC][PATCHv2 3/7] printk: introduce per-cpu alt_print seq buffer Petr Mladek <pmladek@suse.com> - 2016-10-10 13:10 +0200
    Re: [RFC][PATCHv2 3/7] printk: introduce per-cpu alt_print seq buffer Petr Mladek <pmladek@suse.com> - 2016-10-06 15:10 +0200
      Re: [RFC][PATCHv2 3/7] printk: introduce per-cpu alt_print seq buffer Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-10-10 04:00 +0200
  [RFC][PATCHv2 6/7] printk: report printk recursion from alt_printk flush Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-09-30 17:30 +0200
    Re: [RFC][PATCHv2 6/7] printk: report printk recursion from  alt_printk flush Petr Mladek <pmladek@suse.com> - 2016-10-06 17:50 +0200
      Re: [RFC][PATCHv2 6/7] printk: report printk recursion from  alt_printk flush Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-10-10 03:30 +0200
        Re: [RFC][PATCHv2 6/7] printk: report printk recursion from  alt_printk flush Petr Mladek <pmladek@suse.com> - 2016-10-10 13:10 +0200
  Re: [RFC][PATCHv2 0/7] printk: use alt_printk to handle printk()  recursive calls Petr Mladek <pmladek@suse.com> - 2016-10-06 18:00 +0200
    Re: [RFC][PATCHv2 0/7] printk: use alt_printk to handle printk()  recursive calls Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-10-10 03:30 +0200

csiph-web