All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Biggers <ebiggers@kernel.org>
To: Christoph Hellwig <hch@lst.de>
Cc: Jens Axboe <axboe@kernel.dk>,
	linux-block@vger.kernel.org, linux-fsdevel@vger.kernel.org,
	linux-fscrypt@vger.kernel.org
Subject: Re: move blk-crypto-fallback to sit above the block layer v5
Date: Fri, 9 Jan 2026 20:18:56 +0000	[thread overview]
Message-ID: <20260109201856.GA2915893@google.com> (raw)
In-Reply-To: <20260109060813.2226714-1-hch@lst.de>

On Fri, Jan 09, 2026 at 07:07:40AM +0100, Christoph Hellwig wrote:
> Hi all,
> 
> in the past we had various discussions that doing the blk-crypto fallback
> below the block layer causes all kinds of problems due to very late
> splitting and communicating up features.
> 
> This series turns that call chain upside down by requiring the caller to
> call into blk-crypto using a new submit_bio wrapper instead so that only
> hardware encryption bios are passed through the block layer as such.
> 
> While doings this I also noticed that the existing blk-crypto-fallback
> code does various unprotected memory allocations which this converts to
> mempools, or from loops of mempool allocations to the new safe batch
> mempool allocator.
> 
> There might be future avenues for optimization by using high order
> folio allocations that match the file systems preferred folio size,
> but for that'd probably want a batch folio allocator first, in addition
> to deferring it to avoid scope creep.

Reviewed-by: Eric Biggers <ebiggers@kernel.org>

> Jens and Eric: I guess despite the fscrypt patches, the block tree
> would probably be the best fit.  Or do we need a separate branch?

Please go ahead and take these through the block tree.  Thanks!

- Eric

  parent reply	other threads:[~2026-01-09 20:18 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-09  6:07 move blk-crypto-fallback to sit above the block layer v5 Christoph Hellwig
2026-01-09  6:07 ` [PATCH 1/9] fscrypt: pass a real sector_t to fscrypt_zeroout_range_inline_crypt Christoph Hellwig
2026-01-09  6:07 ` [PATCH 2/9] fscrypt: keep multiple bios in flight in fscrypt_zeroout_range_inline_crypt Christoph Hellwig
2026-01-09  6:07 ` [PATCH 3/9] blk-crypto: add a bio_crypt_ctx() helper Christoph Hellwig
2026-01-09  6:07 ` [PATCH 4/9] blk-crypto: submit the encrypted bio in blk_crypto_fallback_bio_prep Christoph Hellwig
2026-01-09  6:07 ` [PATCH 5/9] blk-crypto: optimize bio splitting in blk_crypto_fallback_encrypt_bio Christoph Hellwig
2026-01-09  6:07 ` [PATCH 6/9] blk-crypto: use on-stack skcipher requests for fallback en/decryption Christoph Hellwig
2026-01-09  6:07 ` [PATCH 7/9] blk-crypto: use mempool_alloc_bulk for encrypted bio page allocation Christoph Hellwig
2026-01-09  6:07 ` [PATCH 8/9] blk-crypto: optimize data unit alignment checking Christoph Hellwig
2026-01-09  6:07 ` [PATCH 9/9] blk-crypto: handle the fallback above the block layer Christoph Hellwig
2026-01-09 20:18 ` Eric Biggers [this message]
2026-01-11 19:56 ` move blk-crypto-fallback to sit above the block layer v5 Jens Axboe

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=20260109201856.GA2915893@google.com \
    --to=ebiggers@kernel.org \
    --cc=axboe@kernel.dk \
    --cc=hch@lst.de \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-fscrypt@vger.kernel.org \
    --cc=linux-fsdevel@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.