mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/2] block: fail short atomic bounce bios in bio_iov_iter_bounce_write()
@ 2026-11-08  4:24 Tal Zussman
  2026-11-08  4:24 ` [PATCH 1/2] block: fail a short atomic bounce " Tal Zussman
  2026-11-08  4:24 ` [PATCH 2/2] iomap: remove the atomic write length check in iomap_dio_bio_iter_one() Tal Zussman
  0 siblings, 2 replies; 5+ messages in thread
From: Tal Zussman @ 2026-11-08  4:24 UTC (permalink / raw)
  To: Jens Axboe, Christian Brauner
  Cc: John Garry, Christoph Hellwig, linux-block, linux-kernel,
	linux-xfs, linux-fsdevel, Tal Zussman

bio_iov_iter_get_pages() fails a short REQ_ATOMIC bio. In contrast,
bio_iov_iter_bounce_write() doesn't, so a bounced atomic write that runs
into a folio allocation failure triggers a WARN_ON_ONCE() in
iomap_dio_bio_iter_one().

The first patch makes bio_iov_iter_bounce_write() also check that a
REQ_ATOMIC bio covers the whole iterator, and clean up and return
-EINVAL if it doesn't. With both paths covered the iomap check can't
trigger, so the second patch removes it, as suggested by John Garry.

---
Tal Zussman (2):
      block: fail a short atomic bounce in bio_iov_iter_bounce_write()
      iomap: remove the atomic write length check in iomap_dio_bio_iter_one()

 block/bio.c          | 10 ++++++++++
 fs/iomap/direct-io.c | 14 --------------
 2 files changed, 10 insertions(+), 14 deletions(-)
---
base-commit: 839203759f536e6ef1267c80309c3532a7d588cc
change-id: 20261014-blkdev-atomic-bounce-fc9c583083d7

Best regards,
--  
Tal Zussman <tz2294@columbia.edu>


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-11-08 17:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-08  4:24 [PATCH 0/2] block: fail short atomic bounce bios in bio_iov_iter_bounce_write() Tal Zussman
2026-11-08  4:24 ` [PATCH 1/2] block: fail a short atomic bounce " Tal Zussman
2026-11-08 17:13   ` John Garry
2026-11-08  4:24 ` [PATCH 2/2] iomap: remove the atomic write length check in iomap_dio_bio_iter_one() Tal Zussman
2026-11-08 17:06   ` John Garry

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®