of_property_present(9)
π¦ of_property_present(9) β like, the whole vibe check for one tiny lil property π¦
okay so real talk, this one lives in the Kernel API Manual, and it is genuinely one of the most "yes bestie, just tell me if it's there" functions in the whole device tree situation. no drama, no parsing, no allocating β just a yes or a no. iconic behaviour honestly π
β¨ NAME β¨
of_property_present β the function that checks whether a property is present in a node. that's it. that's the whole job. she's a specialist π
πΈ SYNOPSIS πΈ
bool of_property_present (const struct device_node *np , const char
*propname );
she returns a bool, she takes two things, she does not elaborate. main character energy fr fr π
π«Ά ARGUMENTS π«Ά
npβ the device node you wanna search for the property. like, the node. the place where the property would be chillin' if it exists. πpropnameβ the name of the property you're searching for. the actual string you're hunting down. π
π DESCRIPTION π
so basically πββοΈ you're testing for a property being present in a device node. that's the whole thing. you hand her a node, you hand her a property name, and she goes and checks. no cap, that is the entire description β she is not a complicated girl, she just knows what she's about β¨
like, the point is present. is it there or is it not there. that's the question, that's the function, periodt. π
π RETURN π
trueβ if the property exists πfalseβ otherwise π₯
literally a two-outcome queen. no in-between, no "maybe", no "it depends". iykyk π
β SEE ALSO β
okay bestie this list is LONG, so buckle up β but these are all her neighbours in the kernel file ./include/linux/of.h and they're all lowkey obsessed with the same device-tree situation π§:
of_node_init(9)of_machine_is_compatible(9)of_parse_phandle(9)of_parse_phandle_with_args(9)of_parse_phandle_with_fixed_args(9)of_parse_phandle_with_optional_args(9)of_phandle_args_equal(9)of_property_count_u8_elems(9)of_property_count_u16_elems(9)of_property_count_u32_elems(9)of_property_count_u64_elems(9)of_property_read_string_array(9)of_property_count_strings(9)of_property_read_string_index(9)of_property_read_u8_array(9)of_property_read_u16_array(9)of_property_read_u32_array(9)of_property_read_u64_array(9)struct of_changeset_entry(9)struct of_changeset(9)of_device_is_system_power_controller(9)of_have_populated_dt(9)
like, go off, entire of.h friend group π«Άπ
aaaand that's the page!! πΈ source situation: this one comes from ./include/linux, dated October 2026, and yes the manual name is of_property_present(9) in case you forgot already π hope that helped bestie, go forth and check your properties β¨ππ¦
π¦ 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