All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Ming Lei <ming.lei@redhat.com>
Cc: Christoph Hellwig <hch@infradead.org>,
	Jens Axboe <axboe@kernel.dk>,
	linux-block@vger.kernel.org,
	Mikulas Patocka <mpatocka@redhat.com>,
	Zhaoyang Huang <zhaoyang.huang@unisoc.com>,
	Dave Chinner <dchinner@redhat.com>,
	linux-fsdevel@vger.kernel.org, io-uring@vger.kernel.org
Subject: Re: [PATCH V4 6/6] loop: add hint for handling aio via IOCB_NOWAIT
Date: Mon, 6 Oct 2025 23:33:17 -0700	[thread overview]
Message-ID: <aOS0LdM6nMVcLPv_@infradead.org> (raw)
In-Reply-To: <aOPPpEPnClM-4CSy@fedora>

On Mon, Oct 06, 2025 at 10:18:12PM +0800, Ming Lei wrote:
> On Fri, Oct 03, 2025 at 12:06:44AM -0700, Christoph Hellwig wrote:
> > On Sun, Sep 28, 2025 at 09:29:25PM +0800, Ming Lei wrote:
> > > - there isn't any queued blocking async WRITEs, because NOWAIT won't cause
> > > contention with blocking WRITE, which often implies exclusive lock
> > 
> > Isn't this a generic thing we should be doing in core code so that
> > it applies to io_uring I/O as well?
> 
> No.
> 
> It is just policy of using NOWAIT or not, so far:
> 
> - RWF_NOWAIT can be set from preadv/pwritev
> 
> - used for handling io_uring FS read/write
> 
> Even though loop's situation is similar with io-uring, however, both two are
> different subsystem, and there is nothing `core code` for both, more importantly
> it is just one policy: use it or not use it, each subsystem can make its
> own decision based on subsystem internal.

I fail to parse what you say here.  You are encoding special magic
about what underlying file systems do in an upper layer.  I'd much
rather have a flag similar FOP_DIO_PARALLEL_WRITE that makes this
limitation clear rather then opencoding it in the loop driver while
leabing the primary user of RWF_NOWAIT out in the cold.


  reply	other threads:[~2025-10-07  6:33 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-28 13:29 [PATCH V4 0/6] loop: improve loop aio perf by IOCB_NOWAIT Ming Lei
2025-09-28 13:29 ` [PATCH V4 1/6] loop: add helper lo_cmd_nr_bvec() Ming Lei
2025-10-03  7:04   ` Christoph Hellwig
2025-09-28 13:29 ` [PATCH V4 2/6] loop: add helper lo_rw_aio_prep() Ming Lei
2025-10-03  7:04   ` Christoph Hellwig
2025-09-28 13:29 ` [PATCH V4 3/6] loop: add lo_submit_rw_aio() Ming Lei
2025-10-03  7:04   ` Christoph Hellwig
2025-09-28 13:29 ` [PATCH V4 4/6] loop: move command blkcg/memcg initialization into loop_queue_work Ming Lei
2025-09-28 13:29 ` [PATCH V4 5/6] loop: try to handle loop aio command via NOWAIT IO first Ming Lei
2025-09-29  6:44   ` Yu Kuai
2025-09-29  9:18     ` Ming Lei
2025-09-28 13:29 ` [PATCH V4 6/6] loop: add hint for handling aio via IOCB_NOWAIT Ming Lei
2025-10-03  7:06   ` Christoph Hellwig
2025-10-06 14:18     ` Ming Lei
2025-10-07  6:33       ` Christoph Hellwig [this message]
2025-10-07 12:15         ` Ming Lei
2025-10-08  5:56           ` Christoph Hellwig
2025-10-09  1:25             ` Ming Lei
2025-10-13  6:26               ` Christoph Hellwig
2025-10-13  8:26                 ` Ming Lei
2025-09-28 18:42 ` [syzbot ci] Re: loop: improve loop aio perf by IOCB_NOWAIT syzbot ci
2025-09-29  1:13   ` Ming Lei

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=aOS0LdM6nMVcLPv_@infradead.org \
    --to=hch@infradead.org \
    --cc=axboe@kernel.dk \
    --cc=dchinner@redhat.com \
    --cc=io-uring@vger.kernel.org \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=ming.lei@redhat.com \
    --cc=mpatocka@redhat.com \
    --cc=zhaoyang.huang@unisoc.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.