acpi_find_processor_node(9)
π acpi_find_processor_node(9) β a Kernel API Manual moment
okay so bestie, welcome to the acpi_find_processor_node(9) page, straight out of the Kernel API Manual. this one's a little lookup function and honestly it's giving "where's my CPU at" energy. let's get into it π
β¨ NAME β¨
acpi_find_processor_node β given a PPTT table, find the requested processor
likeβ¦ you hand it a table, it hands you a processor node. match made in heaven fr fr π«Ά
πΈ SYNOPSIS πΈ
struct acpi_pptt_processor * acpi_find_processor_node (struct
acpi_table_header *table_hdr , u32 acpi_cpu_id );
yep, that's the whole signature. it takes two things and gives you back a struct acpi_pptt_processor * (or NULL, we'll get there π).
π¦ ARGUMENTS π¦
table_hdrβ pointer to the head of the PPTT table. like, the very top of it. the main character of the table world πacpi_cpu_idβ the CPU we are searching for. this is your target, your person, your one. π―
π DESCRIPTION π
so what's the vibe? this function finds the subtable entry that describes the processor you handed it. that's the whole job. iconic, honestly.
how does it do it? by iterating the PPTT table β just walking through it, one step at a time πΆββοΈ β looking for processor nodes that have an acpi_processor_id matching the acpi_cpu_id parameter you passed into the function. yes, that exact one.
and then!! if it finds a node that matches this criteria, it verifies that it's a leaf node in the topology, rather than depending on the valid flag β because, and this is important, that flag doesn't need to be set for leaf nodes. so don't come for it about the valid flag, it's literally not the vibe check being used here π
ngl the leaf-node check is the whole trick β the code goes by topology position, not by the valid flag. keep that straight and you're golden β¨
β RETURN β
NULL, or the processor's acpi_pptt_processor*
so either you get nothing (sad π₯²) or you get your node (slay π₯). no in-between, no drama.
π SEE ALSO π
kernel file ./drivers/acpi/pptt.c β and while you're there, go say hi to the whole friend group:
acpi_pptt_walk_cache(9)acpi_count_levels(9)acpi_pptt_leaf_node(9)update_cache_properties(9)topology_get_acpi_cpu_tag(9)check_acpi_cpu_flag(9)acpi_get_cache_info(9)cache_setup_acpi(9)acpi_pptt_cpu_is_thread(9)find_acpi_cpu_topology(9)find_acpi_cpu_topology_package(9)find_acpi_cpu_topology_cluster(9)find_acpi_cpu_topology_hetero_id(9)acpi_pptt_get_child_cpus(9)acpi_pptt_get_cpus_from_container(9)find_acpi_cache_level_from_id(9)acpi_pptt_get_cpumask_from_cache_id(9)
like, the entire pptt.c clique. go read them all, iykyk π§
and that's the page!! mwah π this lil manual page lives under ./drivers/acpi, and it's dated October 2026 β so mark your calendar bestie, acpi_find_processor_node(9) is timeless. bye babes, go find those leaf nodes ππ
π¦ 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