STRUCT GLOBAL_PSTATE_INFO(9)
π NAME π
okay so bestie, struct global_pstate_info(9) β from the Kernel API Manual, hi β is the per policy data structure to maintain history of global pstates. That's the whole assignment, no cap. π
β¨ SYNOPSIS β¨
struct global_pstate_info {
int highest_lpstate_idx;
unsigned int elapsed_time;
unsigned int last_sampled_time;
int last_lpstate_idx;
int last_gpstate_idx;
spinlock_t gpstate_lock;
struct timer_list timer;
struct cpufreq_policy *policy;
};
π«Ά Members π«Ά
highest_lpstate_idxβ the local pstate index from which we are ramping down. iconic.elapsed_timeβ time in ms spent in ramping down fromhighest_lpstate_idx.last_sampled_timeβ time from boot in ms when global pstates were last set.last_lpstate_idxβ last set value of local pstate and global. iykyk.last_gpstate_idxβ pstate in terms of cpufreq table index.gpstate_lockβ a spinlock to maintain synchronization between routines called by the timer handler and governer'starget_indexcalls. keeping that spelling exactly, bestie π«Άtimerβ is used for ramping down if cpu goes idle for a long time with global pstate held high.policyβ associated CPUFreq policy.
π SEE ALSO π
Kernel file ./drivers/cpufreq/powernv-cpufreq.c β plus struct pstate_idx_revmap_data(9), calc_global_pstate(9), and gpstate_timer_handler(9). Go read those too, fr fr.
xoxo, your kernel bestie π§π β source/version: ./drivers/cpufreq; date: October 2026; this page: struct global_pstate_info(9). periodt β¨
π¦ 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