From: Qiliang Yuan <qiliang.yuan@linux.dev>
To: Benjamin Marzinski <bmarzins@redhat.com>
Cc: Qiliang Yuan <qiliang.yuan@linux.dev>,
Alasdair Kergon <agk@redhat.com>,
Mike Snitzer <snitzer@kernel.org>,
Mikulas Patocka <mpatocka@redhat.com>,
dm-devel@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 0/2] dm thin: stop waiting for grace periods when activating and removing thins
Date: Thu, 19 Nov 2026 00:46:50 -0500 [thread overview]
Message-ID: <20261119054650.990874-1-qiliang.yuan@linux.dev> (raw)
In-Reply-To: <av6IBa44Erp0gWBN@redhat.com>
On Thu, Nov 19, 2026 at 12:24:21AM -0500, Benjamin Marzinski wrote:
> I posted an alternate version of your [PATCH 2/2] that fixes the issue
> I mentioned. Can you verify that it works for you?
>
> I squashed it with your patch, since it your original patch did most of
> the work of fixing the issue, and it seemed easier to just have one
> patch to backport to fix it. I could refactor it into two patches: one
> the fixes the bug, and a second that just swaps the synchronize_rcu()
> for kfree_rcu(), if people would rather not mix the bug fix and feature.
Thanks. I had a v2 ready along the same lines and sent it before seeing
this:
https://lore.kernel.org/r/20261119-bug-dm-thin-rcu-gp-v2-0-055d627763c3@linux.dev
It carries the fix as its own patch 2/3, ahead of the kfree_rcu()
change in 3/3. It differs from your version in two places: it takes the
thin off the list in the thin_put() that drops the last reference,
under pool->lock, where yours does it in thin_dtr() after the
completion, which is simpler; and it does not skip dying thins in
requeue_bios() and error_retry_list_with_code(), which yours does.
Your Fixes tag is the right one. 17181fb7a0c3 moved list_del_rcu()
ahead of waiting for the references; v2 points at b10ebd34cccae, which
is wrong.
I have not run your version yet. I will run the KASAN reproducer and
the timing on it and report back.
Thanks,
Qiliang
prev parent reply other threads:[~2026-11-19 5:46 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-16 5:12 Qiliang Yuan
2026-11-16 5:12 ` [PATCH 1/2] dm thin: drop the grace period from thin_ctr() Qiliang Yuan
2026-11-18 0:51 ` Benjamin Marzinski
2026-11-16 5:12 ` [PATCH 2/2] dm thin: free thins with kfree_rcu() instead of waiting in thin_dtr() Qiliang Yuan
2026-11-18 1:13 ` Benjamin Marzinski
2026-11-19 5:16 ` [PATCH v2] " Benjamin Marzinski
2026-11-19 6:14 ` Qiliang Yuan
2026-11-19 5:24 ` [PATCH 0/2] dm thin: stop waiting for grace periods when activating and removing thins Benjamin Marzinski
2026-11-19 5:46 ` Qiliang Yuan [this message]
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=20261119054650.990874-1-qiliang.yuan@linux.dev \
--to=qiliang.yuan@linux.dev \
--cc=agk@redhat.com \
--cc=bmarzins@redhat.com \
--cc=dm-devel@lists.linux.dev \
--cc=linux-kernel@vger.kernel.org \
--cc=mpatocka@redhat.com \
--cc=snitzer@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®