cnv_err_stats_alloc(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… cnv_err_stats_alloc β€” like, the whole manual, bestie

okay so this is a page from the Kernel API Manual (manual section 9, kernel API vibes, iykyk) and it's about one single little function that lowkey carries the CNV stats game. buckle up, it's short and it slays πŸŽ€


✨ NAME ✨

cnv_err_stats_alloc β€” get CNV stats for the provided device. that's it, that's the whole job, no cap πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

struct cnv_err_stats * cnv_err_stats_alloc (struct adf_accel_dev *accel_dev );

like... it takes a device pointer and hands you back a struct cnv_err_stats *. main character function energy, honestly.


🌸 ARGUMENTS 🌸

  • accel_dev β€” pointer to a QAT acceleration device. yeah, that's the thing you're asking for stats about 🫢

πŸ’– DESCRIPTION πŸ’–

so here's the tea β˜• β€” this function allocates and populates a whole table of CNV error statistics, and it does it for each non-admin AE that's available through the acceleration device you passed in. every single one. not just the admin one. we're being thorough, periodt ✨

important, bestie: the caller becomes the owner of that memory. it's yours now. you are responsible for deallocating it β€” and the way you do that is by calling kfree. not me forgetting to free and leaking memory 😭 don't be that girl. free your stuff.

⭐ RETURN ⭐

  • on success β†’ a pointer to a dynamically allocated struct cnv_err_stats πŸŽ‰
  • on error β†’ a negative value πŸ™ˆ

so like, vibe check your return value before you dereference it, fr fr.


🌈 SEE ALSO 🌈

  • Kernel file ./drivers/crypto/intel/qat/qat_common/adf_cnv_dbgfs.c β€” go read the source, it's giving lore πŸ‘‘

that's the whole page, bestie, you ate it up πŸ“πŸ’œ this cutie was brought to you by source ./drivers/crypto/intel/qat/qat..., dated October 2026 β€” mwah, go free your memory πŸŽ€πŸ§šπŸ”₯

πŸ“¦ where this page comes from