Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1488430
| Path | csiph.com!feeder.erje.net!1.eu.feeder.erje.net!weretis.net!feeder4.news.weretis.net!news.mixmin.net!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | Al Viro <viro@ZenIV.linux.org.uk> |
| Newsgroups | linux.kernel |
| Subject | [rfc] weirdness in bio_map_user_iov() |
| Date | Thu, 22 Sep 2016 00:00:02 +0200 |
| Message-ID | <sjXIC-5Zf-5@gated-at.bofh.it> (permalink) |
| MIME-Version | 1.0 |
| Content-Type | text/plain; charset=us-ascii |
| Content-Disposition | inline |
| User-Agent | Mutt/1.6.1 (2016-04-27) |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 15 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | linux-block@vger.kernel.org, linux-kernel@vger.kernel.org |
| X-Original-Date | Wed, 21 Sep 2016 22:52:26 +0100 |
| X-Original-Message-ID | <20160921215226.GU2356@ZenIV.linux.org.uk> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1488430 |
Show key headers only | View raw
What happens if we feed it a 3-element iovec array, one page in each?
AFAICS, bio_add_pc_page() is called for each of those pages, even if
the previous calls have failed - break is only out of the inner loop.
Sure, failure due to exceeded request size means that everything after
that one will fail, but what of e.g.
/*
* If the queue doesn't support SG gaps and adding this
* offset would create a gap, disallow it.
*/
if (bvec_gap_to_prev(q, prev, offset))
return 0;
in there? Won't we risk having the first and the third pages added, with
the second one quietly skipped? Jens, looks like it had come from you
(by way of jejb). Am I missing something subtle here?
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
[rfc] weirdness in bio_map_user_iov() Al Viro <viro@ZenIV.linux.org.uk> - 2016-09-22 00:00 +0200
csiph-web