lkml.org 
[lkml]   [2016]   [Oct]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC][PATCHv2 0/7] printk: use alt_printk to handle printk() recursive calls
    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

    \
     
     \ /
      Last update: 2016-10-06 17:55    [W:6.075 / U:1.040 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site