NVME_MI_ADMIN_GET_LOG_SMART(2)

๐Ÿ’– nvme_mi_admin_get_log_smart(2) ๐Ÿ’–

okay bestie, welcome to the libnvme API manual โœจ this one's a lil function from the libnvme crew and she is so useful, trust.


๐ŸŒธ NAME ๐ŸŒธ

nvme_mi_admin_get_log_smart โ€” retrieve nvme smart log ๐Ÿง โœจ


๐ŸŽ€ SYNOPSIS ๐ŸŽ€

int nvme_mi_admin_get_log_smart (nvme_mi_ctrl_t ctrl , __u32 nsid , bool
rae , struct nvme_smart_log *smart_log );

๐Ÿ’… ARGUMENTS ๐Ÿ’…

  • ctrl โ€” the controller you wanna query, bestie ๐ŸŽฎ
  • nsid โ€” optional namespace identifier (yes bb, it's optional, we love options)
  • rae โ€” retain asynchronous events ๐Ÿ‘€
  • smart_log โ€” a user address to store the smart log in ๐Ÿ ๐Ÿ“‹

๐Ÿฆ‹ DESCRIPTION ๐Ÿฆ‹

so this log page is literally the SMART and general health info, like the vibe check of your controller's whole existence ๐Ÿ’ซ

the tea is: this info lives over the life of the controller and it stays put across power cycles โ€” she does not forget, no cap ๐Ÿ”‹โœจ

if you wanna request the controller log page, the namespace identifier you specify is FFFFFFFFh ๐Ÿ“Œ

the controller may also support requesting the log page on a per namespace basis, and that's indicated by bit 0 of the LPA field in the Identify Controller data structure ๐Ÿ‘‘ (iykyk)


โญ RETURN โญ

you get back the nvme command status if a response was received (peep enum nvme_status_field for that) ๐Ÿ”

or otherwise? -1 with errno set ๐Ÿ˜ญ like okay noted, we move.

fr fr, check that errno before you spiral, bestie ๐Ÿ™ˆ

and that's the whole page, periodt ๐Ÿ’…โœจ

signing off from the libnvme API manual, July 2026 โ€” stay iconic, go get that smart log, mwah ๐Ÿซถ๐Ÿ’–๐ŸŒˆ

๐Ÿ“ฆ where this page comes from