amd_detect_prefcore(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… amd_detect_prefcore β€” the kernel manual, but make it make sense

okay bestie, so this is a page from the Kernel API Manual β€” it's called amd_detect_prefcore(9) and it's genuinely so niche but honestly kinda iconic? it's giving "small function, big feelings". let's get into it ✨


🌸 NAME 🌸

amd_detect_prefcore β€” lowkey just answers the question: do the CPUs in this system support preferred cores or not? 🫢


⭐ SYNOPSIS ⭐

int amd_detect_prefcore (bool *detected );

that's it. one function, one pointer, zero drama. periodt. πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • detected β€” the output variable where the result of the detection gets dropped off. like a little mailbox for the answer πŸ“¬

πŸ¦‹ DESCRIPTION πŸ¦‹

so what does it actually do? it determines whether the CPUs in the system support preferred cores. that's the whole vibe check.

here's the tea on how you can tell, no cap:

  • on systems that do support preferred cores, you'll find different highest perf values on different cores πŸ‘€
  • on other systems, the highest perf value is just the same on all cores β€” very "everyone got the same grade" energy 😭

and the result of the detection? it gets stored in the detected parameter. yes bestie, that's literally what it's for. 🎯


πŸ”₯ RETURN πŸ”₯

  • 0 for success β€” slay, it worked πŸ’–
  • negative error code otherwise β€” not the serve we wanted, but that's the contract πŸ™ˆ

🌈 SEE ALSO 🌈

  • Kernel file ./arch/x86/kernel/acpi/cppc.c β€” go read the source, iykyk πŸ“–
  • amd_get_boost_ratio_numerator(9) β€” its little friend, also worth a look πŸ‘‘

fr fr, don't forget: the result lands in detected, and anything other than 0 coming back means something went sideways. no guessing, that's literally what the page says πŸ’€

and that's the whole page, bestie β€” it lives under ./arch/x86/kernel/acpi, and this particular glow-up is dated October 2026, straight from the Kernel API Manual. mwah, go touch some cores πŸ’œπŸŽ€

πŸ“¦ where this page comes from