Thread (66 messages) 66 messages, 14 authors, 2023-01-31

Re: [PATCH 20/23] rxrpc: use bvec_set_page to initialize a bvec

From: David Howells <dhowells@redhat.com>
Date: 2023-01-30 11:26:00
Also in: ceph-devel, io-uring, kvm, linux-block, linux-cifs, linux-fsdevel, linux-mm, linux-nfs, linux-nvme, linux-scsi, target-devel, virtualization

Christoph Hellwig [off-list ref] wrote:
On Mon, Jan 30, 2023 at 10:31:23AM +0000, David Howells wrote:
quoted
Christoph Hellwig [off-list ref] wrote:
quoted
+		bvec_set_page(&bv, ZERO_PAGE(0), len, 0);
Maybe bvec_set_zero_page()?
Why?
Seems to be something people want to do quite a lot and don't know about.
I've seen places where someone allocates a buffer and clears it just to use as
a source of zeros.  There's at least one place in cifs, for example.  I know
about it from wrangling arch code, but most people working on Linux haven't
done that.

David
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help