From: Eric Biggers <ebiggers@kernel.org>
To: Fengnan Chang <changfengnan@bytedance.com>
Cc: Jens Axboe <axboe@kernel.dk>, linux-block@vger.kernel.org
Subject: Re: [PATCH] blk-crypto: clear REQ_POLLED on software-encrypted write bios
Date: Mon, 30 Nov 2026 19:58:09 -0800 [thread overview]
Message-ID: <20261201035809.GA7060@sol> (raw)
In-Reply-To: <20261201033650.193709-1-changfengnan@bytedance.com>
On Tue, Dec 01, 2026 at 03:36:50AM +0000, Fengnan Chang wrote:
> blk-crypto-fallback encrypts a write into new bios and completes the
> source bio from their endio callback. The submitter only polls the
> source bio, which is never queued to hardware and never gets a cookie.
> If the encrypted bios inherit REQ_POLLED and land on a poll queue,
> nothing polls them, and the write stalls until the request times out.
>
> Let the encrypted bios use interrupt completion. Reads are not
> affected: the source bio itself is submitted and decrypted after it
> completes.
>
> Reproduced with io_uring IOPOLL O_DIRECT writes to an fscrypt-encrypted
> ext4 file (mounted with -o inlinecrypt) on a null_blk device with poll
> queues: every write failed with -ETIMEDOUT after the request timeout.
> With this change the writes complete and read back correctly.
>
> Signed-off-by: Fengnan Chang <changfengnan@bytedance.com>
Looks correct, but it needs Fixes and Cc stable. I think the following:
Fixes: 3e08773c3841 ("block: switch polling to be bio based")
Cc: stable@vger.kernel.org
- Eric
prev parent reply other threads:[~2026-12-01 3:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-01 3:36 [PATCH] blk-crypto: clear REQ_POLLED on software-encrypted write bios Fengnan Chang
2026-12-01 3:58 ` Eric Biggers [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=20261201035809.GA7060@sol \
--to=ebiggers@kernel.org \
--cc=axboe@kernel.dk \
--cc=changfengnan@bytedance.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.