From: John Ogness <john.ogness@linutronix.de>
To: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
Cc: Petr Mladek <pmladek@suse.com>, Marco Elver <elver@google.com>,
Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>,
Peter Zijlstra <peterz@infradead.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
kexec@lists.infradead.org, linux-kernel@vger.kernel.org,
Steven Rostedt <rostedt@goodmis.org>,
Sergey Senozhatsky <sergey.senozhatsky@gmail.com>,
Thomas Gleixner <tglx@linutronix.de>,
Linus Torvalds <torvalds@linux-foundation.org>
Subject: Re: [PATCH][next] printk: ringbuffer: support dataless records
Date: Tue, 21 Jul 2020 12:36:55 +0206 [thread overview]
Message-ID: <87lfjdw468.fsf@jogness.linutronix.de> (raw)
In-Reply-To: <20200721025450.GA5678@jagdpanzerIV.localdomain>
On 2020-07-21, Sergey Senozhatsky <sergey.senozhatsky@gmail.com> wrote:
>> @@ -1402,7 +1396,9 @@ static int prb_read(struct printk_ringbuffer *rb, u64 seq,
>> /* Copy text data. If it fails, this is a data-less record. */
>> if (!copy_data(&rb->text_data_ring, &desc.text_blk_lpos, desc.info.text_len,
>> r->text_buf, r->text_buf_size, line_count)) {
>> - return -ENOENT;
>> + /* Report an error if there should have been data. */
>> + if (desc.info.text_len != 0)
>> + return -ENOENT;
>> }
>
> If this is a dataless record then should copy_data() return error?
You are correct. That makes more sense. I will send a v2.
John Ogness
_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec
prev parent reply other threads:[~2020-07-21 10:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-20 14:01 [PATCH][next] printk: ringbuffer: support dataless records John Ogness
2020-07-20 14:19 ` Marco Elver
2020-07-21 2:54 ` Sergey Senozhatsky
2020-07-21 10:30 ` John Ogness [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87lfjdw468.fsf@jogness.linutronix.de \
--to=john.ogness@linutronix.de \
--cc=elver@google.com \
--cc=gregkh@linuxfoundation.org \
--cc=kexec@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=pmladek@suse.com \
--cc=rostedt@goodmis.org \
--cc=sergey.senozhatsky.work@gmail.com \
--cc=sergey.senozhatsky@gmail.com \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox