[PATCH] drm/msm/devfreq: Insert missing null check in msm_devfreq_idle

AngeloGioacchino Del Regno angelogioacchino.delregno at collabora.com
Wed Nov 17 14:09:47 UTC 2021


Il 17/11/21 12:11, Marijn Suijten ha scritto:
> msm_devfreq_init only initializes the idle_work hrtimer when it succeeds
> to create a devfreq instance (devfreq support is optional), yet
> msm_devfreq_idle is called unconditionally from retire_submit and queues
> work on it.  We're seeing:
> 
>      [    2.005265] adreno 1c00000.gpu: [drm:msm_devfreq_init] *ERROR* Couldn't initialize GPU devfreq
> 
> Followed by a pagefault in:
> 
>      [   16.650316] pc : hrtimer_start_range_ns+0x64/0x360
>      [   16.650336] lr : msm_hrtimer_queue_work+0x18/0x2c
> 
> Moments later.  Just like msm_devfreq_active, check if the devfreq
> instance is not NULL before proceeding.
> 
> Fixes: 658f4c829688 ("drm/msm/devfreq: Add 1ms delay before clamping freq")
> Reviewed-by: Konrad Dybcio <konrad.dybcio at somainline.org>
> Signed-off-by: Marijn Suijten <marijn.suijten at somainline.org>

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno at collabora.com>


More information about the dri-devel mailing list