[PATCH] cpufreq: scmi: Fix possible null pointer dereference

Chenyuan Yang chenyuan0y at gmail.com
Sat Apr 12 11:32:10 PDT 2025


On Sat, Apr 12, 2025 at 1:31 PM Dan Carpenter <dan.carpenter at linaro.org> wrote:
>
> On Sat, Apr 12, 2025 at 01:08:31PM -0500, Chenyuan Yang wrote:
> > Check if policy is NULL before dereferencing it.
> >
> > This is similar to the commit cf7de25878a1
> > ("cppc_cpufreq: Fix possible null pointer dereference").
> >
> > This is found by our static analysis tool KNighter.
> >
> > Signed-off-by: Chenyuan Yang <chenyuan0y at gmail.com>
> > Fixes: 99d6bdf33877 ("cpufreq: add support for CPU DVFS based on SCMI message protocol")
>
> Henry Martin already fixed this in commit 484d3f15cc6c ("cpufreq: scmi:
> Fix null-ptr-deref in scmi_cpufreq_get_rate()").

Thanks so much for pointing this out!
It is good to hear that there is already a fix.

> regards,
> dan carpenter

-Chenyuan



More information about the linux-arm-kernel mailing list