cppc_get_perf_ctrs(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… cppc_get_perf_ctrs(9) β€” like, the Kernel API Manual page, bestie

okay so picture this: it's a Kernel API Manual page, the function is cppc_get_perf_ctrs, and it does exactly one iconic thing β€” it reads a CPU's performance feedback counters. that's it. that's the whole vibe. ✨


✨ NAME ✨

cppc_get_perf_ctrs β€” Read a CPU's performance feedback counters. πŸŽ€

πŸ¦‹ SYNOPSIS πŸ¦‹

int cppc_get_perf_ctrs (int cpunum , struct cppc_perf_fb_ctrs
*perf_fb_ctrs );

no cap, that's the whole signature. look at it. giving very much "small function, big responsibility." πŸ‘‘

🌸 ARGUMENTS 🌸

  • cpunum β€” the CPU you're pulling counters from. like, which CPU bestie. you gotta say. πŸ’…
  • perf_fb_ctrs β€” a ptr to cppc_perf_fb_ctrs. and where do you find that? cppc_acpi.h, obviously. go look, i'll wait. 🫢

πŸ”₯ RETURN πŸ”₯

0 for success with perf_fb_ctrs populated β€” slay, you got your data πŸ’– β€” else -ERRNO. yep, the classic negative-errno situation. it's giving "something went wrong and we're telling you in the most unix way possible." 😭

🌈 SEE ALSO 🌈

okay this list is long and honestly kind of a flex. all of these live in the kernel file ./drivers/acpi/cppc_acpi.c. iykyk ✨


bestie a little reminder: perf_fb_ctrs is a ptr, so make sure it points at something real before you call this. we love a valid pointer in this house. πŸ™ˆ

and that's the page!! mwah πŸ’‹ β€” this one came from the source path ./drivers/acpi, dated October 2026, and yes the header/footer both said cppc_get_perf_ctrs(9) because consistency is hot. periodt. β­πŸ“

πŸ“¦ where this page comes from