cpufreq_quick_get(9)
π cpufreq_quick_get β girl, just tell me the frequency already
okay so this is a page out of the Kernel API Manual (section 9, kernel-space functions, iykyk) and the star of the show is cpufreq_quick_get(9). Sit down, bestie, we're learning about CPU frequencies and it's gonna be adorable. π
β¨ NAME β¨
cpufreq_quick_get β gets the CPU frequency (in kHz) straight from policy->cur
like, that's it. that's the whole job. she's a simple girl and she delivers. π
πΈ SYNOPSIS πΈ
unsigned int cpufreq_quick_get (unsigned int cpu );
one function, one argument, one unsigned int coming back at you. no cap, it's that clean. β¨
π¦ ARGUMENTS π¦
cpuβ the CPU number. which little guy are we asking about? that one. π«Ά
π DESCRIPTION π
okay so here's the vibe: this is the last known freq, and the crucial part is that it does not actually go ask the driver for it. no door-knocking, no waiting, no whole production. she already knows. main character energy honestly. π
and the return value? it's gonna be the same as what's shown in scaling_cur_freq in sysfs. same number, same energy, no surprises. if you've ever stared at scaling_cur_freq wondering what it'd look like as a C function β boom, it's this. ππ
lowkey the whole appeal is that it's quick β she's not going to the source, she's reporting what's already on the books. that's the bit. don't forget the bit.
π SEE ALSO π
bestie there is a whole extended universe of cpufreq functions and honestly they all ate. go read the source at ./drivers/cpufreq/cpufreq.c and then spiral through these icons:
cpufreq_cpu_get(9)cpufreq_cpu_put(9)adjust_jiffies(9)cpufreq_notify_transition(9)cpufreq_enable_fast_switch(9)cpufreq_disable_fast_switch(9)cpufreq_driver_resolve_freq(9)cpufreq_parse_governor(9)cpufreq_add_dev(9)cpufreq_out_of_sync(9)cpufreq_quick_get_max(9)cpufreq_get_hw_max_freq(9)cpufreq_get(9)cpufreq_suspend(9)cpufreq_resume(9)cpufreq_driver_test_flags(9)cpufreq_get_current_driver(9)cpufreq_get_driver_data(9)cpufreq_register_notifier(9)cpufreq_unregister_notifier(9)cpufreq_driver_fast_switch(9)cpufreq_driver_adjust_perf(9)cpufreq_driver_has_adjust_perf(9)cpufreq_update_pressure(9)cpufreq_set_policy(9)cpufreq_update_policy(9)cpufreq_update_limits(9)cpufreq_register_driver(9)
fr fr that's twenty-eight whole entries, go off. π₯
mkay that's the page!! this one lives in ./drivers/cpufreq, dated October 2026, and it's filed as cpufreq_quick_get(9) in the Kernel API Manual β mwah, slay, see you in the next manpage bestie π
πβ¨
π¦ 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