]> git.baikalelectronics.ru Git - kernel.git/commit
cpufreq: CPPC: Add u64 casts to avoid overflowing
authorPierre Gondois <pierre.gondois@arm.com>
Tue, 20 Dec 2022 10:12:25 +0000 (11:12 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 1 Feb 2023 07:34:28 +0000 (08:34 +0100)
commit5619b64b0442d667ebdde8cf869dd29ce34a88eb
tree100f941caceead3caab53c2691b4174ed7d7b177
parent3f1778eb88f3354ba24bbbe08c750118582447ef
cpufreq: CPPC: Add u64 casts to avoid overflowing

[ Upstream commit f5f94b9c8b805d87ff185caf9779c3a4d07819e3 ]

The fields of the _CPC object are unsigned 32-bits values.
To avoid overflows while using _CPC's values, add 'u64' casts.

Signed-off-by: Pierre Gondois <pierre.gondois@arm.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/cpufreq/cppc_cpufreq.c