nvme_get_log_discovery(2)
nvme_get_log_discovery π
okay bestie, so this one lives in the libnvme API manual, section 2 β it's nvme_get_log_discovery, and it's literally the key to pulling the Discovery log page off your NVMe device. β¨ Put your hair up, grab a matcha, we're going log-diving. π¦
πΈ NAME πΈ
nvme_get_log_discovery β Retrieve Discovery log page π
β¨ SYNOPSIS β¨
int nvme_get_log_discovery (int fd , bool rae , __u32 offset , __u32 len
, void *log );
likeβ¦ she takes five args and hands you back an int, no cap. π
π ARGUMENTS π
fdβ File descriptor of nvme device π«Ά your little handle to the device, the main character of the whole operation.raeβ Retain asynchronous events β abool, so it's giving yes/no energy.offsetβ Offset of this log to retrieve π an__u32, so you're telling her exactly where in the log to start scooping.lenβ The allocated size for this portion of the log π an__u32too β how much room you've got for this chunk specifically.logβ User address to store the discovery log π avoid *β this is where the goodies land, so make sure it's actually somewhere valid, bestie, or it's gonna be a bad time π.
π¦ DESCRIPTION π¦
Supported only by fabrics discovery controllers, and she returns discovery records. π That's the whole vibe. If you're not on a fabrics discovery controller, this is not your moment β no notes, just a fact. π
π₯ RETURN π₯
She hands you back The nvme command status if a response was received β check enum nvme_status_field for what those statuses actually mean, iykyk π β or you get -1 with errno set otherwise. π So yeah, negative one = something went sideways, and errno is gonna tell you what.
heads up bestie: that's-1, not "minus one-ish". literally-1. anderrnois set. respect the classic. π
and that's the whole page, babe β this was the libnvme API manual, nvme_get_log_discovery in section 2, dated July 2026. π slay, go get your discovery records, mwah π«Άπβ¨
π¦ 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