STRUCT CAAM_CTX(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct caam_ctx(9) πŸ’–

okay bestie, welcome to the Kernel API Manual β€” this one's a struct page, she's a little technical but we're gonna slay it together 🫢


✨ NAME ✨

struct caam_ctx β€” the per-session context, aka the little vibe-holder that keeps track of one crypto session's whole situation πŸ’…


🌸 SYNOPSIS 🌸

struct caam_ctx {
    struct caam_flc flc[NUM_OP];
    u8 key[CAAM_MAX_KEY_SIZE];
    dma_addr_t flc_dma[NUM_OP];
    dma_addr_t key_dma;
    enum dma_data_direction dir;
    struct device *dev;
    struct alginfo adata;
    struct alginfo cdata;
    unsigned int authsize;
    bool xts_key_fallback;
    struct crypto_skcipher *fallback;
 };

like, look at her. every field is doing something. main character struct energy fr fr πŸ‘‘


πŸŽ€ Members πŸŽ€

  • flc β€” the Flow Contexts array. plural, she contains multitudes ✨
  • key β€” the [authentication key], encryption key. yes both, she's versatile πŸ’…
  • flc_dma β€” I/O virtual addresses of the Flow Contexts πŸ¦‹
  • key_dma β€” the I/O virtual address of the key πŸ”‘
  • dir β€” DMA direction used for mapping the key and the Flow Contexts 🧭
  • dev β€” the dpseci device πŸ–₯️
  • adata β€” authentication algorithm details 🌸
  • cdata β€” encryption algorithm details πŸ”
  • authsize β€” authentication tag size, a.k.a. the ICV / MAC size πŸŽ€
  • xts_key_fallback β€” true if a fallback tfm needs to be used because the xts key lengths aren't supported 😭 (yes, it's a whole thing)
  • fallback β€” the xts fallback tfm 🫢
ngl bestie, if you're poking at xts_key_fallback you already know what you're doing β€” that flag only flips when the xts key lengths just aren't supported and the fallback tfm has to step in πŸ’€

πŸ¦‹ SEE ALSO πŸ¦‹

  • Kernel file ./drivers/crypto/caam/caamalg_qi2.c
  • struct caam_hash_ctx(9) β€” her cousin, go say hi πŸ’–

and that's the whole page, bestie!! πŸŒˆβ­πŸ’œ this iconic little number lives over at ./drivers/crypto/caam, dated October 2026, and yes the manual name is struct caam_ctx(9) β€” same as the title, she's consistent like that πŸ’…βœ¨πŸŽ€ go forth and map those DMA addresses πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from