diff options
author | Aleksandr Mishin <amishin@t-argos.ru> | 2024-04-08 12:35:36 +0300 |
---|---|---|
committer | Viresh Kumar <viresh.kumar@linaro.org> | 2024-04-19 11:59:16 +0530 |
commit | cf7de25878a1f4508c69dc9f6819c21ba177dbfe (patch) | |
tree | dac4ae92293cf0be48f8352bc65b7b8116a3792c /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | b5e230aa8d0359bba49659c8358074755c6eb9e4 (diff) |
cppc_cpufreq: Fix possible null pointer dereference
cppc_cpufreq_get_rate() and hisi_cppc_cpufreq_get_rate() can be called from
different places with various parameters. So cpufreq_cpu_get() can return
null as 'policy' in some circumstances.
Fix this bug by adding null return check.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
Fixes: a28b2bfc099c ("cppc_cpufreq: replace per-cpu data array with a list")
Signed-off-by: Aleksandr Mishin <amishin@t-argos.ru>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions