---
name: "libnvmf_registry_retrieve-libnvme3"
section: "2"
platform: "linux"
package: "nvme-cli"
version: "3.2-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/libnvmf_registry_retrieve-libnvme3"
---

# libnvmf\_registry\_retrieve-libnvme3(2)

Read an attribute from a controller's registry entry

## NAME

libnvmf\_registry\_retrieve - Read an attribute from a controller's registry entry

## SYNOPSIS

**int libnvmf\_registry\_retrieve** **(struct libnvme\_global\_ctx \*ctx** *,* **const char \*device** *,* **const char \*attr** *,* **char \*\*value** *);*

## ARGUMENTS

- ctx

  libnvme global context; must not be NULL

- device

  Kernel device name (e.g. "nvme3")

- attr

  Attribute name to retrieve (e.g. "owner")

- value

  On success, set to a newly allocated string with the attribute value.  The caller must free this string.

## RETURN

0 on success, -ENOENT if the controller is not registered or the attribute is not present, -ENOMEM on allocation failure, negative errno from underlying system calls otherwise.
