af_alg_count_tsgl(9)
π af_alg_count_tsgl(9)
okay so bestie, welcome to the Kernel API Manual β we're literally in af_alg_count_tsgl(9) territory and it's giving "tiny function, big responsibility" energy. This one's whole thing? Counting TX SG entries. that's it. that's the vibe. β¨
πΈ NAME πΈ
af_alg_count_tsgl β Count number of TX SG entries
like, it counts SG entries. TX ones. for real. π
π¦ SYNOPSIS π¦
unsigned int af_alg_count_tsgl (struct sock *sk , size_t bytes );
that's literally the whole signature, no cap π
β¨ ARGUMENTS β¨
skβ the socket of the connection to user space. bestie's channel to the outside world π«Άbytesβ count the number of SG entries holding the given number of bytes. you tell it how many bytes, it tells you how many entries are holding them π
π₯ DESCRIPTION π₯
the counting starts from the beginning of the SGL and runs up to bytes. that's it. that's the whole journey: from the top of the scatterlist, all the way to your bytes cutoff. slay π
β RETURN β
number of TX SG entries found, given the constraints. a plain unsigned int, no drama, no error codes, just a count ππ
π SEE ALSO π
- Kernel file
./crypto/af_alg.c af_alg_alloc_tsgl(9)af_alg_pull_tsgl(9)af_alg_free_areq_sgls(9)af_alg_wait_for_wmem(9)af_alg_wmem_wakeup(9)af_alg_wait_for_data(9)af_alg_data_wakeup(9)af_alg_sendmsg(9)af_alg_free_resources(9)af_alg_poll(9)af_alg_alloc_areq(9)af_alg_get_rsgl(9)
the whole af_alg friend group, honestly β go read them all, iykyk π§π
ok that's the page!! tiny but iconic. go count some SG entries bestie, you got this π
made its home in ./crypto, dated October 2026, and it's filed under af_alg_count_tsgl(9) in the Kernel API Manual β mwah, periodt πβ¨
π¦ 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