Thread (55 messages) flat view 55 messages, 8 authors, 2022-03-02

Re: [PATCH v4 5/6] block: enable zone-append for iov_iter of bvec type

From: Christoph Hellwig <hch@infradead.org>
Date: 2020-07-26 15:20:24
Also in: io-uring, linux-block, linux-fsdevel, lkml

On Fri, Jul 24, 2020 at 09:19:21PM +0530, Kanchan Joshi wrote:
quoted hunk ↗ jump to hunk
zone-append with bvec iov_iter gives WARN_ON, and returns -EINVAL.
Add new helper to process such iov_iter and add pages in bio honoring
zone-append specific constraints.
This is used to enable zone-append with io-uring fixed-buffer.

Signed-off-by: Kanchan Joshi <redacted>
Signed-off-by: Selvakumar S <redacted>
Signed-off-by: Nitesh Shetty <redacted>
Signed-off-by: Javier Gonzalez <redacted>
---
 block/bio.c | 31 ++++++++++++++++++++++++++++---
 1 file changed, 28 insertions(+), 3 deletions(-)
diff --git a/block/bio.c b/block/bio.c
index 0cecdbc..ade9da7 100644
--- a/block/bio.c
+++ b/block/bio.c
@@ -975,6 +975,30 @@ static int __bio_iov_bvec_add_pages(struct bio *bio, struct iov_iter *iter)
 	iov_iter_advance(iter, size);
 	return 0;
 }
+static int __bio_iov_bvec_append_add_pages(struct bio *bio, struct iov_iter *iter)
Missing empty line and too long line, please stick to 80 chars for this
code.

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