fwnode_prope...ad_u16_array(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

okay so bestie, welcome to fwnode_property_read_u16_array(9) β€” she's a Kernel API Manual girlie, and her whole job is literally: return a u16 array property of firmware node. that's it, that's the assignment ✨


🌸 SYNOPSIS 🌸

no cap, here's the whole signature, copy it exactly, don't get creative:

int fwnode_property_read_u16_array (const struct fwnode_handle *fwnode ,
const char *propname , u16 *val , size_t nval );

πŸŽ€ ARGUMENTS πŸŽ€

  • fwnode β€” the Firmware node you're getting the property of 🫢 like, this is the one you're snooping on
  • propname β€” Name of the property, iykyk
  • val β€” The values are stored here ✨ or NULL to return the number of values (yes that's a whole thing, see below)
  • nval β€” Size of the val array, so she knows how much room she's got πŸ’…

πŸ¦‹ DESCRIPTION πŸ¦‹

So what she does is: read an array of u16 properties with propname from fwnode and store them to val if found. simple as that, iconic behaviour πŸ’…

✨ real talk though β€” it's recommended to call fwnode_property_count_u16 instead of calling this function with val equals NULL and nval equals 0. like, that's the move, trust πŸ’–

πŸ”₯ RETURN πŸ”₯

she returns a whole vibe-check of values, so pay attention bestie:

  • number of values if val was NULL πŸ‘€
  • 0 if the property was found (success) β€” slay, we love a zero πŸŽ‰
  • -EINVAL if given arguments are not valid πŸ™ˆ
  • -ENODATA if the property does not have a value 😭
  • -EPROTO if the property is not an array of numbers πŸ’€
  • -EOVERFLOW if the size of the property is not as expected 🫠
  • -ENXIO if no suitable firmware interface is present 🌸

🌈 SEE ALSO 🌈

she does NOT come alone, she brought the whole friend group. Kernel file ./drivers/base/property.c, plus:


okay that's the whole page, you ate that πŸ“ she lives in ./drivers/base, she's dated October 2026, and her version tag is literally fwnode_prope...ad_u16_array(9) β€” yes the truncation is part of the brand, don't come for her πŸ’€πŸ’– bye bestie, go read some properties πŸ§šβ€β™€οΈ

πŸ“¦ where this page comes from