nvme_get_log_ana_groups(2)
π nvme_get_log_ana_groups β bestie edition π
okay so this is a page from the libnvme API manual, section 2, and the function we're obsessing over today is nvme_get_log_ana_groups. she's giving "let me get you the Asymmetric Namespace Access groups only log page" and honestly? iconic. π¦
β¨ NAME β¨
nvme_get_log_ana_groups β Retrieve Asymmetric Namespace Access groups only log page
πΈ SYNOPSIS πΈ
int nvme_get_log_ana_groups (int fd , bool rae , __u32 len , struct
nvme_ana_log *log );
like yes she takes four things and gives you back an int, we love a straightforward queen. π
π ARGUMENTS π
fdβ File descriptor of nvme device. this is your lil ticket to the device, no ticket no entry bestie ποΈraeβ Retain asynchronous events. so like, do we keep the async events around? that's the vibe check right there β¨lenβ The allocated length of the log page. how much room you set aside for the log page, so be generous πlogβ User address to store the ana group log. this is where the log actually lands, hand her a valid address bestie π«Ά
π DESCRIPTION π
See struct nvme_ana_log for the definition of the returned structure. that's it, that's the whole description β she's a "go read the struct" kind of girl and honestly respect. go look at struct nvme_ana_log, the answers are all in there πβ¨
π« RETURN π«
The nvme command status if a response was received (see enum nvme_status_field) or -1 with errno set otherwise.
so: got a response? you get the nvme command status, peek at enum nvme_status_field for what it means π. no response? it's a -1 and errno is doing the talking. no cap. π
lowkey important:-1always comes witherrnoset, so don't just stare at the return value, checkerrnotoo bestie π
and that's the whole page, you ate that π
this lil guide came from the libnvme API manual, dated July 2026, and yeah the page literally names herself nvme_get_log_ana_groups twice because she contains multitudes π mwah, go log some ana groups π
π¦ where this page comes from
- ubuntu stonking: libnvme-dev 1.16.2-1build1 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms