cpufreq_set(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… cpufreq_set β€” kernel API manual, but make it cute

Hiii bestie, welcome to the cpufreq_set(9) page β€” yes it's a section 9 kernel API manual, yes we're doing this, and yes it's lowkey iconic. Sit down, hydrate, let's go 🫢


✨ NAME ✨

cpufreq_set β€” set the CPU frequency. That's it, that's the whole vibe. πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

int cpufreq_set (struct cpufreq_policy *policy , unsigned int freq );

Look at her. Gorgeous. No cap, this is the entire function signature and we're copying it exactly because we do not freestyle with code. πŸ”₯


🌸 ARGUMENTS 🌸

  • policy β€” a pointer to the policy struct, and it's the one where freq is being set. Like, this is the main character struct, the freq is being set on it. πŸŽ€
  • freq β€” the target frequency, measured in kHz. Not MHz, not Hz, kHz, bestie. Units matter, iykyk. ⭐

πŸ¦‹ DESCRIPTION πŸ¦‹

So like… it sets the CPU frequency to freq. ✨

That's genuinely the whole description. Short queen energy. Sets. The CPU frequency. To freq. Periodt. πŸ’–

No plot twists, no hidden clauses, no "but only if the moon is in retrograde" β€” the doc says it does the thing and we are not out here inventing lore. πŸ™ˆ


πŸ‘‘ SEE ALSO πŸ‘‘

  • Kernel file ./drivers/cpufreq/cpufreq_userspace.c β€” go peek if you want, she's the source of truth. πŸ’œ

fr fr, if you're setting frequencies, keep your units straight β€” freq is in kHz. That's the one detail that'll trip you up and it's giving "easy mistake, big consequences". 😭

🌈 okay that's the whole page, hope it slayed! this masterpiece lives in the ./drivers/cpufreq corner of the tree and the page itself is dated October 2026 β€” Kernel API Manual, section 9, no notes. mwah, bye bestie πŸ’‹πŸŽ€βœ¨

πŸ“¦ where this page comes from