fdt_first_property_offset(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… fdt_first_property_offset β€” a.k.a. the Kernel API Manual page you're about to slay

okay so bestie, welcome to fdt_first_property_offset(9) β€” yes that's the whole name, she's long but she's worth it πŸŽ€. This is the Kernel API Manual entry, and no cap, it's the little function that finds the offset of a node's first property. Let's get into it ✨


🌸 NAME 🌸

fdt_first_property_offset β€” finds the offset of a node's first property. that's literally her whole job and she does it flawlessly πŸ’…


✨ SYNOPSIS ✨

int fdt_first_property_offset (const void *fdt , int nodeoffset );

look at that signature. iconic. two args, returns an int, no drama πŸ¦‹


🫢 ARGUMENTS 🫢

  • fdt β€” pointer to the device tree blob. your whole tree lives here, so treat her with respect πŸ’–
  • nodeoffset β€” structure block offset of a node. that's the specific node you're poking at πŸ”

πŸ‘‘ DESCRIPTION πŸ‘‘

so here's the tea β˜•: fdt_first_property_offset finds the first property of the node sitting at the given structure block offset. that's it, that's the vibe. you hand her a node, she hands you back where its first property begins. main character energy, zero wasted motion 🌟


πŸ”₯ RETURN πŸ”₯

bestie, the return value is where it gets juicy β€” she'll give you one of these:

  • structure block offset of the property (>=0), on success β€” periodt, that's the good ending πŸŽ‰
  • -FDT_ERR_NOTFOUND, if the requested node has no properties β€” she looked, it's empty, moving on 😭
  • -FDT_ERR_BADOFFSET, if nodeoffset did not point to an FDT_BEGIN_NODE tag β€” wrong door, try again πŸ™ˆ
  • -FDT_ERR_BADMAGIC, -FDT_ERR_BADVERSION, -FDT_ERR_BADSTATE, -FDT_ERR_BADSTRUCTURE, -FDT_ERR_TRUNCATED β€” the standard meanings, iykyk πŸ’€

🌈 SEE ALSO 🌈

the whole friend group came out for this one 🫢 β€” and also the kernel file ./scripts/dtc/libfdt/libfdt.h:


and that's the whole page, bestie πŸ’œ mwah πŸ’‹ β€” this one came from the source ./scripts/dtc/libfdt, dated October 2026. go forth and find those properties πŸ§šβ€β™€οΈβ­

πŸ“¦ where this page comes from