libnvme(9)

πŸ’– libnvme(9) β€” the API Manual, but make it make sense

okay bestie, buckle up πŸŽ€ this is a page out of the libnvme API Manual, and it's all about one lil struct. it's called struct nvme_mi_aem_config, and the whole reason it exists is to be provided for nvme_mi_aem_enable. that's literally the NAME section, that's the tea β˜•


✨ NAME ✨

struct nvme_mi_aem_config β€” Provided for nvme_mi_aem_enable

like… it's giving "I'm the config struct your AEM enable call has been waiting for" πŸ’…


🌸 SYNOPSIS 🌸

here's the whole shape of it, no cap, copy it exactly:

struct nvme_mi_aem_config {
    enum nvme_mi_aem_handler_next_action (*aem_handler)(nvme_mi_ep_t
ep,size_t num_events, void *userdata);
    struct nvme_mi_aem_enabled_map enabled_map;
    bool envfa;
    bool empfa;
    bool encfa;
    __u8 aemd;
    __u8 aerd;
 };

she's a struct, she's got a function pointer, she's got a map, she's got three lil bools and two __u8s. iconic honestly πŸ‘‘


πŸ¦‹ Members πŸ¦‹

every single one of these, explained with love:

  • aem_handler β€” the callback function where your application gets to do the event processing. it's YOUR moment, main character energy ✨
  • enabled_map β€” the map that says which AE should be enabled on the endpoint. like a little guest list for events 🎟️
  • envfa β€” Enable SR-IOV virtual functions AE
  • empfa β€” Enable SR-IOV physical functions AE
  • encfa β€” Enable PCIe functions AE
  • aemd β€” AEM Delay (that's time in seconds from when the event happens to when the AEM gets batched and sent). so it's the "how long do we sit on this" number ⏳
  • aerd β€” AEM Retry Delay (time in 100s of ms between AEM retries from the endpoint). yes, hundreds of milliseconds, not plain ms, read it again bestie 🫢

πŸ’œ Description πŸ’œ

so here's the vibe: application callbacks for nvme_mi_aem_process will be able to call nvme_mi_aem_get_next_event, and that call returns a pointer to an identifier like this one β€” for the next event the application should parse. that's it. that's the whole plot πŸ“

ngl the wording here is doing the absolute most with the fewest words, but the fact is the fact: nvme_mi_aem_process callbacks β†’ can call nvme_mi_aem_get_next_event β†’ get a pointer to such an identifier β†’ for the next event your app needs to parse. periodt. πŸ’€

that's the page!! short, sweet, very demure, very mindful 🌈

sign-off time πŸŽ€ this was libnvme(9) β€” struct nvme_mi_aem_config β€” from August 2026, the API Manual edition. go forth and parse your events, bestie, you got this πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from