nvmf_reg_write32(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… nvmf_reg_write32(9) β€” the Kernel API Manual, bestie edition

okay so you're in the Kernel API Manual and the page is literally called nvmf_reg_write32, and honestly? she's a little legend. let's get into it πŸŽ€

✨ NAME ✨

nvmf_reg_write32 β€” the NVMe Fabrics "Property Write" API function. that's it, that's her whole job πŸ’–


πŸ¦‹ SYNOPSIS πŸ¦‹

int nvmf_reg_write32 (struct nvme_ctrl *ctrl , u32 off , u32 val );

like yes she returns an int, we love a return value queen πŸ‘‘


🌸 ARGUMENTS 🌸

  • ctrl β€” your host NVMe controller instance 🫢 she's the one holding down the admin queue, and that admin queue is what gets used to submit the property read command over to the allocated NVMe controller resource sitting on the target system. so basically she's the main character carrying the whole operation.
  • off β€” the starting offset value of the property register you're targeting ✨ (peep the fabrics section of the NVMe standard, iykyk).
  • val β€” the input parameter, aka the actual value you want written to the property. she's the payload, she's the moment πŸ’…

πŸ”₯ DESCRIPTION πŸ”₯

the NVMe host system uses this to write a 32-bit capsule property value to an NVMe controller on the target system. simple, clean, slay 🌈

and if you're sitting there like "capsule property?? what does that even mean" β€” no worries bestie, the page says it plain: a "Capsule property" is a "PCIe register concept" that's been applied to the NVMe fabrics space. it's giving repurposed, it's giving cross-over episode πŸ’€


⭐ RETURN ⭐

here's the vibe check, verbatim:

0: successful write > 0: NVMe error status code < 0: Linux errno error code

so: 0 means the write went through, anything above 0 is an NVMe error status code 😭, and anything below 0 is a Linux errno error code πŸ™ˆ. read your return values, bestie, don't leave her on read.


πŸ‘‘ SEE ALSO πŸ‘‘

the whole friend group, assembled 🫢✨


heads up: if your return value is negative, that's a Linux errno, not an NVMe status β€” don't mix your eras πŸ’€

and that's the page!! she lives over in ./drivers/nvme/host, dated October 2026, and she's part of the Kernel API Manual (kernel API manual, in the 9 section, obvi). go forth and write your 32-bit capsule property values, bestie πŸ’œπŸŽ€πŸ§š

πŸ“¦ where this page comes from