[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFxs9T4oTs5MR7rcnrBUeUgORXWWNx+T6x52ynqrN38C6Q@mail.gmail.com>
Date: Tue, 29 Aug 2017 16:59:24 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>,
Pavel Machek <pavel@....cz>,
Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
Petr Mladek <pmladek@...e.com>, Jan Kara <jack@...e.cz>,
Andrew Morton <akpm@...ux-foundation.org>,
Jiri Slaby <jslaby@...e.com>, Andreas Mohr <andi@...as.de>,
Tetsuo Handa <penguin-kernel@...ove.sakura.ne.jp>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: printk: what is going on with additional newlines?
On Tue, Aug 29, 2017 at 4:50 PM, Steven Rostedt <rostedt@...dmis.org> wrote:
>
> What about using the seq_buf*() then?
They do have the nice property that because we use them for various
/proc files, there are some helper functions in addition to just the
puts/printt/vprintf.
Ie seq_buf_putmem_hex().
And yeah, you can just do
char buffer[80];
struct seq_buf s;
seq_buf_init(&s, buffer, sizeof(buffer));
if you want to use a stack buffer for a single line.
Linus
Powered by blists - more mailing lists