of_machine_get_match(9)
π of_machine_get_match β Kernel API Manual, section 9 π
okay bestie, so this is a section 9 kernel API page, and honestly? it's a short one. a little snack. a lil' appetizer of a function. but we're gonna learn it properly because that's just who we are π
β¨ NAME β¨
of_machine_get_match β the girlie who tests the root of the device tree against an of_device_id array. that's it. that's the whole job. and she does it flawlessly, no cap.
πΈ SYNOPSIS πΈ
const struct of_device_id * of_machine_get_match (const struct
of_device_id *matches );
like, one argument. one return. immaculate vibes. π
π¦ ARGUMENTS π¦
matchesβ aNULLterminated array ofof_device_idmatch structures, i.e. the lil' list she's gonna search through. theNULLat the end is literally the periodt of the list β it's how she knows to stop looking. π
π DESCRIPTION π
returns the matched entry, or NULL if nothing matched. that's the whole description, bestie β she said "short and sweet, i'm busy". πβ¨
so like, if she finds her match you get a pointer to that entry, and if she doesn't? NULL. no drama, no error code, no essay. just NULL. lowkey iconic.
π₯ SEE ALSO π₯
okay so this is the part where the manpage just... lists everyone she knows. it's giving group chat roster. it's giving "mutuals". there's a Kernel file ./drivers/of/base.c in here too, so go say hi to the source if you want the full lore π
of_find_all_nodes(9)__of_device_is_compatible(9)of_machine_compatible_match(9)of_machine_read_compatible(9)of_machine_read_model(9)of_machine_get_match_data(9)__of_device_is_available(9)__of_device_is_reserved(9)of_device_is_available(9)__of_device_is_fail(9)of_device_is_big_endian(9)of_get_parent(9)of_get_next_parent(9)of_get_next_child(9)of_get_next_child_with_prefix(9)of_get_next_available_child(9)of_get_next_reserved_child(9)of_get_next_cpu_node(9)of_get_compatible_child(9)of_get_child_by_name(9)of_get_available_child_by_name(9)of_find_node_opts_by_path(9)of_find_node_by_name(9)of_find_node_by_type(9)of_find_compatible_node(9)of_find_node_with_property(9)of_match_node(9)of_find_matching_node_and_match(9)of_alias_from_compatible(9)of_find_node_by_phandle(9)of_parse_phandle_with_args_map(9)of_count_phandle_with_args(9)__of_add_property(9)of_add_property(9)of_remove_property(9)of_alias_scan(9)of_alias_get_id(9)of_alias_get_highest_id(9)of_console_check(9)of_find_next_cache_node(9)of_find_last_cache_level(9)of_map_id(9)of_map_iommu_id(9)of_map_msi_id(9)
forty-four entries. i counted. we don't gatekeep here π«Ά
quick vibe check: this page has no warnings, no bugs section, no exit statuses, no env vars β she's a minimal queen. everything you need is up there. don't go inventing extra options, bestie, that's not the assignment π
and that's the page! brought to you by the source directory ./drivers/of, dated October 2026 π β mwah, go read some more kernel docs, you're doing amazing sweetie πβ¨π
π¦ 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