All of lore.kernel.org
 help / color / mirror / Atom feed
From: Damien Le Moal <dlemoal@kernel.org>
To: Chaitanya Kulkarni <ckulkarnilinux@gmail.com>,
	linux-block@vger.kernel.org
Cc: axboe@kernel.dk, hch@lst.de, kch@nvidia.com
Subject: Re: [PATCH 2/2] zloop: respect REQ_NOWAIT for memory allocation
Date: Sun, 16 Nov 2025 12:44:49 +0900	[thread overview]
Message-ID: <5631b99a-dd89-4f89-a5ac-e8a445ae954d@kernel.org> (raw)
In-Reply-To: <20251116025229.29136-2-ckulkarnilinux@gmail.com>

On 11/16/25 11:52, Chaitanya Kulkarni wrote:
>   6. Zloop driver:
>    zloop_queue_rq()
>     zloop_rw()
>      kmalloc_array(..., GFP_NOIO) <-- BLOCKS (REQ_NOWAIT violation)

Absolutely not. Please re-read the code and see that zloop_queue_rq() adds the
request (zloop command) to a workqueue and zloop_rw() is executed within the
work item context, that is, a different context from zloop_queue_rq.

So this patch is not necessary at all, there is no blocking violation as
zloop_queue_rq() never blocks.

>       -> Should use GFP_NOWAIT when rq->cmd_flags & REQ_NOWAIT



-- 
Damien Le Moal
Western Digital Research

  reply	other threads:[~2025-11-16  3:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-16  2:52 [PATCH 1/2] loop: respect REQ_NOWAIT for memory allocation Chaitanya Kulkarni
2025-11-16  2:52 ` [PATCH 2/2] zloop: " Chaitanya Kulkarni
2025-11-16  3:44   ` Damien Le Moal [this message]
2025-11-16  3:50 ` [PATCH 1/2] loop: " Damien Le Moal
2025-11-16  5:43   ` Chaitanya Kulkarni
2025-11-16  6:26     ` Damien Le Moal
2025-11-18  1:52       ` Chaitanya Kulkarni
2025-11-18  5:21     ` hch
2025-11-18 13:57       ` Jens Axboe
2025-11-19  0:39         ` Chaitanya Kulkarni

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=5631b99a-dd89-4f89-a5ac-e8a445ae954d@kernel.org \
    --to=dlemoal@kernel.org \
    --cc=axboe@kernel.dk \
    --cc=ckulkarnilinux@gmail.com \
    --cc=hch@lst.de \
    --cc=kch@nvidia.com \
    --cc=linux-block@vger.kernel.org \
    /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.