fwnode_get_parent(9)
π fwnode_get_parent(9) β¨
okay so bestie, welcome to the Kernel API Manual β this one's a little baby page about the fwnode_get_parent(9) function π and honestly it's short but she's important, so let's get into it π«Ά
β¨ NAME β¨
fwnode_get_parent β return parent firwmare node πΈ
(yes that spelling is literally what the page says, i'm not touching it, i don't make the rules π)
π SYNOPSIS π
struct fwnode_handle * fwnode_get_parent (const struct fwnode_handle
*fwnode );
like... she returns a struct fwnode_handle * and she takes one const struct fwnode_handle * and that's the whole vibe β¨
π¦ ARGUMENTS π¦
fwnodeβ the firmware whose parent is being retrieved, i.e. the node you're asking "who's ur mom" about π fwnode is the placeholder name here btw, that's just how manpages talk
π DESCRIPTION π
ok so this is the part where you have to actually be responsible π
The caller is responsible for callingfwnode_handle_puton the returnedfwnodepointer. π¨
like no cap, if you get a pointer back you own a reference and you gotta give it back with fwnode_handle_put, otherwise you're leaking and that's not icon energy π
β RETURN β
you get the parent firmware node of the given node if possible π± β or NULL if there was no parent available π (device at the top of the tree, you're on your own bestie)
πΈ SEE ALSO πΈ
first up, the source of truth is literally the kernel file ./drivers/base/property.c and the whole squad lives in ./drivers/base π§
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_u32_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_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 friend group, and yes they all have (9) after them, iykyk π
and that's the page bestie!! π literally so short but so real
signing off from ./drivers/base β October 2026 β this page was brought to you by the Kernel API Manual, mwah ππ¦
π¦ 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