STRUCT SA_ALG_TMPL(9)
πΈ NAME πΈ
okay so bestie, welcome to struct sa_alg_tmpl β it's literally a generic template that wraps around crypto/aead algorithms π
one struct to hold 'em all, no cap.
(this is the struct sa_alg_tmpl(9) page from the Kernel API Manual, bestie β section 9, we're in the big-leagues part of the docs β¨)
β¨ SYNOPSIS β¨
here's the whole vibe, copy it exactly, character for character, because I am not about to let you typo a kernel struct π«Ά
struct sa_alg_tmpl {
u32 type;
union {
struct skcipher_alg skcipher;
struct ahash_alg ahash;
struct aead_alg aead;
} alg;
bool registered;
};
it's giving "one container, three possible algorithm flavours, and a little flag to remember whether we've registered yet" π iconic honestly.
π Members π
typeβ the type of the crypto algorithm. like, which kind of algorithm are we even talking about here. that's the whole job. keep it πalgβ a union of crypto algorithm definitions. so it's one ofskcipher,ahash, oraeadβ the union means those bad boys all share the same space, so only one of them is living there at a time. main character energy, but only one main character β¨registeredβ a flag indicating if the crypto algorithm is already registered.true= we're already in the group chat,false= not yet bestie, hold on π
lowkey important: it's a bool, so don't go stuffing arbitrary numbers in there and expecting the universe to sort it out π
π₯ SEE ALSO π₯
go read the kernel file ./drivers/crypto/sa2ul.c and then spiral with me through the whole friend group:
struct sa_cmdl_cfg(9)struct algo_data(9)struct sa_mapped_sg(9)struct sa_rx_data(9)struct sa_req(9)
that's the whole page bestie, you ate it up π the source is in ./drivers/crypto and this drop is dated October 2026 β struct sa_alg_tmpl(9), out now, streaming everywhere πβ¨π
π¦ 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