---
name: "libnvme_subsystem_get_serial-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/libnvme_subsystem_get_serial-libnvme3"
---

# libnvme\_subsystem\_get\_serial-libnvme3(2)

Get serial.

## NAME

libnvme\_subsystem\_get\_serial - Get serial.

## SYNOPSIS

**int libnvme\_subsystem\_get\_serial** **(const struct libnvme\_subsystem \*p** *,* **const char \*\*serial** *,* **const char \*dflt** *);*

## ARGUMENTS

- p

  The *struct libnvme\_subsystem* instance to query.

- serial

  Where to store the value on success.

- dflt

  Value to store in *serial* on failure.

## RETURN

0 on success, -ENOENT if the attribute does not exist, or a negative errno on failure.
