[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250209180214.GA23386@redhat.com>
Date: Sun, 9 Feb 2025 19:02:14 +0100
From: Oleg Nesterov <oleg@...hat.com>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Christian Brauner <brauner@...nel.org>,
Jeff Layton <jlayton@...nel.org>,
David Howells <dhowells@...hat.com>,
"Gautham R. Shenoy" <gautham.shenoy@....com>,
K Prateek Nayak <kprateek.nayak@....com>,
Mateusz Guzik <mjguzik@...il.com>,
Neeraj Upadhyay <Neeraj.Upadhyay@....com>,
Oliver Sang <oliver.sang@...el.com>,
Swapnil Sapkal <swapnil.sapkal@....com>,
WangYuli <wangyuli@...ontech.com>, linux-fsdevel@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] pipe: change pipe_write() to never add a zero-sized
buffer
On 02/09, Linus Torvalds wrote:
>
> This patch seems to be the right thing to do and removes the vestiges
> of the old model.
OK, thanks.
> But I don't think you need that pipe_buf_assert_len() thing.
Well, I'd prefer to keep this WARN_ON_ONCE() for some time... If
nobody hits this warning we can kill eat_empty_buffer() and more
hopefully dead checks, for example
/* zero-length bvecs are not supported, skip them */
if (!this_len)
continue;
in iter_file_splice_write().
> And if
> you do, please don't make it a pointless inline helper that only hides
> what it does.
Could you explain what do you think should I do if I keep this check?
make pipe_buf_assert_len() return void? or just replace it with
WARN_ON_ONCE(!buf->len) in its callers?
Oleg.
Powered by blists - more mailing lists