public inbox for io-uring@vger.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Yang Xiuwei <yangxiuwei@kylinos.cn>
Cc: io-uring@vger.kernel.org
Subject: Re: [PATCH 1/2] io_uring/rw: fix link failure on successful pipe short reads
Date: Thu, 11 Jun 2026 12:36:22 -0600	[thread overview]
Message-ID: <d75fe34f-dc14-455c-8d80-04d341a9744d@kernel.dk> (raw)
In-Reply-To: <20260611012236.3020181-2-yangxiuwei@kylinos.cn>

On 6/10/26 7:22 PM, Yang Xiuwei wrote:
> __io_read() treats a short read on pipes and sockets as success and
> returns without filling the iov. However, __io_complete_rw_common()
> compared the transfer length against the original iov size and set
> REQ_F_FAIL when they did not match. That incorrectly failed linked
> requests behind a successful head request, for example a nop after a
> naturally disarmed link timeout.
> 
> Treat short reads and writes on non-regular files as success in
> __io_complete_rw_common(), matching the issue path.

Not sure I follow - the "short read/write is an IOSQE_IO_LINK failure"
is widely documented. So not sure I agree with this approach.

-- 
Jens Axboe

  reply	other threads:[~2026-06-11 18:36 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-11  1:22 [PATCH 0/2] io_uring: fix short read links and align link timeout cancel Yang Xiuwei
2026-06-11  1:22 ` [PATCH 1/2] io_uring/rw: fix link failure on successful pipe short reads Yang Xiuwei
2026-06-11 18:36   ` Jens Axboe [this message]
2026-06-12  0:59     ` Yang Xiuwei
2026-06-12  6:29       ` Yang Xiuwei
2026-06-12 21:41         ` Jens Axboe
2026-06-11  1:22 ` [PATCH 2/2] io_uring/timeout: cancel pending link timeouts from ltimeout_list Yang Xiuwei

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d75fe34f-dc14-455c-8d80-04d341a9744d@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=io-uring@vger.kernel.org \
    --cc=yangxiuwei@kylinos.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox