of_find_prop...alue_of_size(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ of_find_prop…alue_of_size(9) πŸ¦‹

okay so bestie, welcome to the glow-up of of_find_prop...alue_of_size, straight out of the Kernel API Manual (yes the header on the original was literally of_find_prop...alue_of_size(9) twice, the truncated name is iconic honestly, we stan a mysterious queen πŸ’…).


✨ NAME ✨

of_find_property_value_of_size β€” and that's literally it, the manpage gives us a dash and then nothing, no cap 😭 she said "my name is enough."


🌸 SYNOPSIS 🌸

void * of_find_property_value_of_size (const struct device_node *np ,
const char *propname , u32 min , u32 max , size_t *len );

like yes she returns a void *, she's flexible, she contains multitudes 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • np β€” the device node you're pulling this property value out of. your source of truth, your main character node πŸ‘‘
  • propname β€” the name of the property we're hunting for. the search term, the vibe check πŸ”
  • min β€” the minimum allowed length of the property value. she has standards.
  • max β€” the maximum allowed length of the property value, and heads up: 0 means unlimited ✨ (zero says "no thoughts, no ceiling, go off")
  • len β€” if it's !=NULL, the actual length gets written right here. a lil out-parameter, a lil gift 🎁

πŸ’– DESCRIPTION πŸ’–

Search for a property in a device node and valid the requested size. πŸ¦‹

(that's the original wording's grammar, we're keeping the energy fr fr β€” the point is: you go looking for the property, and you check that its size is within the bounds you asked for. size validation, that's the whole gig.)


πŸ”₯ RETURN πŸ”₯

  • The property value on success β€” slay, she ate πŸ’…
  • -EINVAL β€” if the property does not exist 😭 (no property, no prophecy)
  • -ENODATA β€” if the property does not have a value πŸ’€ (she exists but she's empty, giving ghost)
  • -EOVERFLOW β€” if the property data is too small or too large πŸ™ˆ (goldilocks violation, neither porridge is acceptable)
ngl always check your return value, bestie β€” those error codes are not decorative 🌈

🌟 SEE ALSO 🌟

Kernel file ./drivers/of/property.c, plus the whole friend group right here:

like that's the entire group chat, every single one of them πŸ’œ


and that's the whole page!! mwah πŸ§šβ€β™€οΈ huge thanks to the fine folks over at ./drivers/of β€” this one's dated October 2026, and the original footer still signs off with of_find_prop...alue_of_size(9) so we're matching that energy, periodt. πŸ“β­πŸ’«

πŸ“¦ where this page comes from