STRUCT BLK_CRYPTO_CONFIG(9)
β¨ NAME β¨
struct blk_crypto_config β an inline encryption key's crypto configuration, bestie. This page is struct blk_crypto_config(9) from the Kernel API Manual, and it's lowkey the blueprint for how a key does its crypto thing. π
πΈ SYNOPSIS πΈ
struct blk_crypto_config {
enum blk_crypto_mode_num crypto_mode;
unsigned int data_unit_size;
unsigned int dun_bytes;
enum blk_crypto_key_type key_type;
int flags;
};
π Members π
Okay so here's the member-by-member vibe check:
crypto_modeβ the encryption algorithm this key is for. That's the whole assignment. β¨data_unit_sizeβ the data unit size for all encryption/decryptions with this key. It's the size in bytes of each individual plaintext and ciphertext, and it is always a power of 2. It might be, e.g., the filesystem block size or the disk sector size. Slay. πdun_bytesβ the maximum number of bytes of DUN used when using this key. No cap, just DUN bytes. π₯key_typeβ the type of this key, bestie: either raw or hardware-wrapped. Pick your fighter. πflagsβBLK_CRYPTO_CFG_*flags. The asterisk is doing a lot of work, iykyk. β
π¦ SEE ALSO π¦
Kernel file ./include/linux/blk-crypto.h, plus these iconic besties:
struct blk_crypto_key(9)struct bio_crypt_ctx(9)blk_crypto_submit_bio(9)bio_crypt_clone(9)
Go read them if you want the full lore. This page is literally the config struct, not the whole saga. π
Okay that's the page, bestie β source/version ./include/linux, dated October 2026, for struct blk_crypto_config(9). Bye, love you, mwah ππ«Ά
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms