efa_ah_cache_get(9)
β¨ efa_ah_cache_get(9) β¨
okay so bestie, welcome to the Kernel API Manual π
this one's efa_ah_cache_get and it's literally the moment where we go find (or make!) an AH cache entry. no cap, it's giving main character energy for address handles π
πΈ SYNOPSIS πΈ
struct efa_ah_cache_entry * efa_ah_cache_get (struct efa_ah_cache *ah_cache, u16 pd, u8 *gid);
like, you hand it a cache, a PD number, and a GID, and it hands you back a pointer. slay. β¨
π¦ ARGUMENTS π¦
ah_cacheβ the AH cache itself, the whole vibe π«Άpdβ protection domain number,u16bestie, don't forgetgidβ the GID address, anu8 *pointer
π DESCRIPTION π
so the way this works is: it looks up an AH cache entry by PD and GID. if it finds one, it takes a reference and returns it to you β iconic behavior, honestly. π
if it does not find one? it allocates a brand new entry and inserts it. new entry, who dis. π¦
important bestie: the caller must lock the entry mutex and check usecnt to figure out whether a device create command is needed. don't skip this, i'm literally begging π that's the whole point.
β RETURN β
- Success β a pointer to the entry π
- Failure β
ERR_PTRπ
π SEE ALSO π
- Kernel file
./drivers/infiniband/hw/efa/efa_ah_cache.c efa_ah_cache_put(9)β the other half of the story, go read it too β¨
alright that's the whole page bestie, go forth and cache responsibly π§ββοΈπ
sign-off time: this little beauty lives under ./drivers/infiniband/hw/efa, dated October 2026 β kernel API manual, 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