All of lore.kernel.org
 help / color / mirror / Atom feed
From: Damien Le Moal <dlemoal@kernel.org>
To: Christoph Hellwig <hch@lst.de>
Cc: Jens Axboe <axboe@kernel.dk>, linux-block@vger.kernel.org
Subject: Re: [PATCH] block: avoid potential deadlock on zone revalidation failure
Date: Fri, 26 Jun 2026 14:40:39 +0900	[thread overview]
Message-ID: <254e6964-d9bf-467b-a045-e3907de5b226@kernel.org> (raw)
In-Reply-To: <20260625115232.GC18076@lst.de>

On 6/25/26 8:52 PM, Christoph Hellwig wrote:
> On Thu, Jun 25, 2026 at 03:28:24PM +0900, Damien Le Moal wrote:
> 
> [very long lockdep trace]
> 
>> +	/*
>> +	 * We may already have a zone write plug workqueue as this function may
>> +	 * be called after disk_free_zone_resources(), which does not destroy
>> +	 * the workqueue (the zone write plugs workqueue is destroyed at
>> +	 * disk_release() time).
>> +	 */
>> +	if (!disk->zone_wplugs_wq) {
> 
> Can't we just allocate this at add_disk time instead of the magic NULL
> check here to mirror the freeing side?

Just tried and yes, that is fine to do. A bit more code reshuffling that I
wanted for a fix, but in the end, a lot cleaner and simpler.
Will send V2 after some more tests.

-- 
Damien Le Moal
Western Digital Research

  reply	other threads:[~2026-06-26  5:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-25  6:28 [PATCH] block: avoid potential deadlock on zone revalidation failure Damien Le Moal
2026-06-25 11:52 ` Christoph Hellwig
2026-06-26  5:40   ` Damien Le Moal [this message]
2026-06-26 22:42   ` Damien Le Moal

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=254e6964-d9bf-467b-a045-e3907de5b226@kernel.org \
    --to=dlemoal@kernel.org \
    --cc=axboe@kernel.dk \
    --cc=hch@lst.de \
    --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.