Skip to content

iter revert problems

Pavel Begunkov io-uring linux-fsdevel lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest2 patches 4 repliesIn review
  2. v22 patches 5 repliesSuperseded
  3. v12 patches 3 repliesSuperseded

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2iov_iter: track truncated sizeinclude/linux/uio.h+5 -10 replies
2/2io_uring: reexpand under-reexpanded itersfs/io_uring.c+2 -00 replies

Reviews trailers per patch

None of the 2 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

Patch[email protected]Jens Axboe
SeriesR-b
1/2
2/2Reported-and-tested-by

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/2] iter revert problems

iov_iter_revert() doesn't go well with iov_iter_truncate() in all cases, see 2/2 for the bug description. As mentioned there the current problems is because of generic_write_checks(), but there was also a similar case fixed in 5.12, which should have been triggerable by normal write(2)/read(2) and others.

It may be better to enforce reexpands as a long term solution, but for now this patchset is quickier and easier to backport.

v2: don't fail if it was justly fully reverted
v3: use truncated size + reexapand based approach

Pavel Begunkov (2):
iov_iter: track truncated size
io_uring: reexpand under-reexpanded iters

 fs/io_uring.c       | 2 ++
 include/linux/uio.h | 6 +++++-
 2 files changed, 7 insertions(+), 1 deletion(-)
Signature · 1 line
2.32.0