STRUCT MV_CESA_ENGINE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct mv_cesa_engine(9) πŸ’…

okay so this is a page from the Kernel API Manual and honestly? it's giving crypto-engine realness. bestie, we're about to get into struct mv_cesa_engine and you're gonna slay this.


✨ NAME ✨

struct mv_cesa_engine β€” the CESA engine, periodt πŸ’–


πŸŽ€ SYNOPSIS πŸŽ€

struct mv_cesa_engine {
    int id;
    void __iomem *regs;
    union {
      void __iomem *sram;
      void *sram_pool;
    };
    dma_addr_t sram_dma;
    spinlock_t lock;
    struct crypto_async_request *req;
    struct clk *clk;
    struct clk *zclk;
    size_t max_req_len;
    u32 int_mask;
    struct mv_cesa_dev *cesa;
    struct gen_pool *pool;
    struct crypto_queue queue;
    atomic_t load;
    struct mv_cesa_tdma_chain chain_hw;
    struct mv_cesa_tdma_chain chain_sw;
    struct list_head complete_queue;
    int irq;
 };

like, look at all those fields. the way that this struct just holds everything? main character energy fr fr πŸ‘‘


πŸ¦‹ MEMBERS πŸ¦‹

  • id β€” the engine id. that's it, that's the field πŸͺͺ
  • regs β€” the engine registers, the actual hardware door πŸšͺ
  • {unnamed_union} β€” it's anonymous. no name. mysterious. iconic πŸ™ˆ
    • sram β€” the SRAM memory region πŸ’Ύ
    • sram_pool β€” the SRAM memory region but pulled from a pool 🏊
  • sram_dma β€” the DMA address of that SRAM memory region ✨
  • lock β€” the engine lock, keep it locked bestie πŸ”’
  • req β€” the current crypto request, like the one being dealt with right now πŸ“¨
  • clk β€” the engine clk ⏰
  • zclk β€” the engine zclk ⏰⏰ (yes there's two, no I will not explain further, it's literally in the struct)
  • max_req_len β€” the maximum chunk length, and the manpage says this is useful to create the TDMA chain πŸ“
  • int_mask β€” the interrupt mask cache 🎭
  • cesa β€” back-pointer to the parent CESA device, so it knows where it came from 🫢
  • pool β€” the memory pool pointing to the memory region reserved in SRAM 🧺
  • queue β€” the fifo of the pending crypto requests, they're waiting their turn in line πŸšΆβ€β™€οΈ
  • load β€” the engine load counter, useful for load balancing, it's literally doing the most βš–οΈ
  • chain_hw β€” the list of the current tdma descriptors being processed by the hardware. hardware is busy, do not disturb πŸ’€
  • chain_sw β€” the list of the current tdma descriptors that will be submitted to the hardware. the next-up squad 🌸
  • complete_queue β€” the fifo of the processed requests by the engine, aka the finished-it pile βœ…
  • irq β€” the interrupt request line, it's giving "notice me" πŸ“£

🌈 DESCRIPTION 🌈

It's a structure storing CESA engine information. that's the whole vibe. it holds the info. it's the info-holder. no cap 🧚


πŸ”₯ SEE ALSO πŸ”₯

  • Kernel file ./drivers/crypto/marvell/cesa/cesa.h
  • struct mv_cesa_sec_accel_desc(9)
  • struct mv_cesa_skcipher_op_ctx(9)
  • struct mv_cesa_hash_op_ctx(9)
  • struct mv_cesa_op_ctx(9)
  • struct mv_cesa_tdma_desc(9)
  • struct mv_cesa_sg_dma_iter(9)
  • struct mv_cesa_dma_iter(9)
  • struct mv_cesa_tdma_chain(9)
  • struct mv_cesa_caps(9)
  • struct mv_cesa_dev_dma(9)
  • struct mv_cesa_dev(9)
  • struct mv_cesa_req_ops(9)
  • struct mv_cesa_ctx(9)
  • struct mv_cesa_hash_ctx(9)
  • enum mv_cesa_req_type(9)
  • struct mv_cesa_req(9)
  • struct mv_cesa_sg_std_iter(9)
  • struct mv_cesa_skcipher_std_req(9)
  • struct mv_cesa_skcipher_req(9)
  • struct mv_cesa_ahash_std_req(9)
  • struct mv_cesa_ahash_dma_req(9)
  • struct mv_cesa_ahash_req(9)

like that's the whole friend group right there, go read all of them, iykyk πŸ’œ


and that's the page bestie!! 🫢 this one lives in ./drivers/crypto/marvell/cesa and it's dated October 2026 β€” so yeah, future-coded of it. mwah, go forth and understand your CESA engines πŸ’…β­

πŸ“¦ where this page comes from