STRUCT MSM_GPU_DEVFREQ(9)
π struct msm_gpu_devfreq(9) β the Kernel API Manual glow-up
okay so bestie, this is a page from the Kernel API Manual, section 9, and we're talking about struct msm_gpu_devfreq. It's literally the lil state-holder for all things devfreq on the msm GPU driver. Buckle up π
β¨ NAME β¨
struct msm_gpu_devfreq β devfreq related state π¦
Like, that's it. That's the whole job. It holds the devfreq-related state. Slay.
πΈ SYNOPSIS πΈ
struct msm_gpu_devfreq {
struct devfreq *devfreq;
struct mutex lock;
unsigned long idle_freq;
struct dev_pm_qos_request boost_freq;
u64 busy_cycles;
ktime_t time;
ktime_t idle_time;
struct msm_hrtimer_work idle_work;
struct msm_hrtimer_work boost_work;
bool suspended;
};
Look at her. Iconic. Every field accounted for, no notes π
π«Ά Members β a field-by-field vibe check π«Ά
devfreqβ the devfreq instance itself. The main character, honestly.lockβ the lock guarding"suspended","busy_cycles", and"time". Three whole fields under one lock, that's her job fr fr π₯idle_freqβ a shadow frequency used while the GPU is idle. Lowkey genius: from the PoV of the devfreq governor, we're still out here sampling busyness and adjusting frequency the whole time the GPU is idle β but we use this shadow value instead, because the GPU is actually clamped to minimum frequency while it's inactive. Sneaky. Correct. Obsessed πboost_freqβ a PM QoS constraint that boosts min freq for a period of time, right up until the boost expires βbusy_cyclesβ the last busy counter value, kept around so we can calculate elapsed busy cycles since the last sampling period πtimeβ time of the last sampling period. Timestamp bestie πidle_timeβ time of the last transition to idle πidle_workβ used to delay clamping to idle freq on the active->idle transition. Patience is a virtue, and also a work item πboost_workβ used to reset the boost_constraint after the boost period has elapsed. Cleanup crew, no cap β¨suspendedβ tracks if we're suspended π
π SEE ALSO π
Go read these next, bestie, they're all in the same friend group:
- Kernel file
./drivers/gpu/drm/msm/msm_gpu.hstruct msm_perfcntr_group_state(9)struct msm_perfcntr_state(9)struct msm_context(9)msm_context_is_vmbind(9)msm_gpu_convert_priority(9)struct msm_gpu_submitqueue(9)
π Sign-off π
That's the whole page, bestie β brought to you by ./drivers/gpu/drm/msm, version October 2026, and struct msm_gpu_devfreq(9). Go forth and sample some busyness. 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