From: Mike Snitzer <snitzer@kernel.org>
To: Hou Tao <houtao@huaweicloud.com>
Cc: dm-devel@redhat.com, Alasdair Kergon <agk@redhat.com>,
Ignat Korchagin <ignat@cloudflare.com>,
linux-kernel@vger.kernel.org, houtao1@huawei.com
Subject: Re: dm crypt: initialize tasklet in crypt_io_init()
Date: Mon, 6 Mar 2023 14:31:47 -0500 [thread overview]
Message-ID: <ZAY/o9ew9AtrCLE5@redhat.com> (raw)
In-Reply-To: <20230306134930.2878660-1-houtao@huaweicloud.com>
On Mon, Mar 06 2023 at 8:49P -0500,
Hou Tao <houtao@huaweicloud.com> wrote:
> From: Hou Tao <houtao1@huawei.com>
>
> When neither no_read_workqueue nor no_write_workqueue are enabled,
> tasklet_trylock() in crypt_dec_pending() may still return false due to
> an uninitialized state, and dm-crypt will do io completion in io_queue
> instead of current context unnecessarily.
Have you actually experienced this?
> Fix it by initializing io->tasklet in crypt_io_init().
Really would rather avoid always calling tasklet_init(). But I can
optimize it away with a later patch.
Mike
next prev parent reply other threads:[~2023-03-06 19:32 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-06 13:49 [PATCH] dm crypt: initialize tasklet in crypt_io_init() Hou Tao
2023-03-06 19:31 ` Mike Snitzer [this message]
2023-03-07 2:12 ` Hou Tao
2023-03-07 14:47 ` Mike Snitzer
2023-03-08 2:56 ` Hou Tao
2023-03-08 13:55 ` Ignat Korchagin
2023-03-08 19:19 ` Mike Snitzer
2023-03-08 20:27 ` Mike Snitzer
2023-03-09 11:27 ` Ignat Korchagin
2023-03-09 11:21 ` Ignat Korchagin
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=ZAY/o9ew9AtrCLE5@redhat.com \
--to=snitzer@kernel.org \
--cc=agk@redhat.com \
--cc=dm-devel@redhat.com \
--cc=houtao1@huawei.com \
--cc=houtao@huaweicloud.com \
--cc=ignat@cloudflare.com \
--cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox