device_prope...ad_u32_array(9)
π
device_prope...ad_u32_array(9) β like, the device_property_read_u32_array page, bestie
okay so this is a page from the Kernel API Manual, section 9 β yes, the big-kid kernel developer section π§β¨ pull up a chair, we're reading firmware properties together.
β¨ NAME β¨
device_property_read_u32_array β grab a whole u32 array property off a device and hand it back to you, no cap π
πΈ SYNOPSIS πΈ
int device_property_read_u32_array (const struct device *dev , const
char *propname , u32 *val , size_t nval );
literally that's it. one function call and the array is yours, iykyk π«Ά
π ARGUMENTS π
devβ the device you're pulling the property off of. like, whose firmware description are we snooping through, bestie πpropnameβ the name of the property. this is the string you're looking for πvalβ this is where the values get stashed. or passNULLhere and instead it just tells you how many values there are β iconic dual-purpose behavior, periodt β¨nvalβ the size of thevalarray. just how much room you're giving it π
π DESCRIPTION π
so the function reads an array of u32 properties with propname out of the device firmware description, and if it finds them it stores them into val. slay π
ok important side note: it's recommended to calldevice_property_count_u32instead of calling this function withvalequalsNULLandnvalequals0. like, that's the vibe-approved way to count, fr fr π
π₯ RETURN π₯
here's the vibe check on what you get back:
- number of values β if
valwasNULLπ« 0β if the property was found (that's success, we ate) π-EINVALβ if the arguments you gave are not valid π-ENODATAβ if the property doesn't 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 there's no suitable firmware interface present π
π SEE ALSO π
kernel file ./drivers/base/property.c, plus literally the entire friend group:
device_property_present(9)fwnode_property_present(9)device_property_read_bool(9)fwnode_property_read_bool(9)device_property_read_u8_array(9)device_property_read_u16_array(9)device_property_read_u64_array(9)device_property_read_string_array(9)device_property_read_string(9)device_property_match_string(9)fwnode_property_read_u8_array(9)fwnode_property_read_u16_array(9)fwnode_property_read_u32_array(9)fwnode_property_read_u64_array(9)fwnode_property_read_string_array(9)fwnode_property_read_string(9)fwnode_property_match_string(9)fwnode_property_match_property_string(9)fwnode_property_get_reference_args(9)fwnode_find_reference(9)fwnode_get_name(9)fwnode_get_name_prefix(9)fwnode_name_eq(9)fwnode_get_parent(9)fwnode_get_next_parent(9)fwnode_count_parents(9)fwnode_get_nth_parent(9)fwnode_get_next_child_node(9)fwnode_get_next_available_child_node(9)device_get_next_child_node(9)fwnode_get_named_child_node(9)device_get_named_child_node(9)fwnode_handle_get(9)fwnode_device_is_available(9)fwnode_get_child_node_count(9)fwnode_get_named_child_node_count(9)fwnode_get_phy_mode(9)device_get_phy_mode(9)fwnode_iomap(9)fwnode_irq_get(9)fwnode_irq_get_byname(9)fwnode_graph_get_next_endpoint(9)fwnode_graph_get_port_parent(9)fwnode_graph_get_remote_port_parent(9)fwnode_graph_get_remote_port(9)fwnode_graph_get_remote_endpoint(9)fwnode_graph_get_endpoint_by_id(9)fwnode_graph_get_endpoint_count(9)fwnode_graph_parse_endpoint(9)fwnode_connection_find_match(9)fwnode_connection_find_matches(9)
like, that's the whole group chat, go say hi π
ok bye bestie, go read some firmware properties π«Ά this page came from ./drivers/base and it's dated October 2026, and the header said device_prope...ad_u32_array(9) in case you forgot already πβ¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms