lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240520084744.sb2rk7l2pjf4whyd@vireshk-i7>
Date: Mon, 20 May 2024 14:17:44 +0530
From: Viresh Kumar <viresh.kumar@...aro.org>
To: Jagadeesh Kona <quic_jkona@...cinc.com>
Cc: Sudeep Holla <sudeep.holla@....com>,
	"Rafael J . Wysocki" <rafael@...nel.org>,
	Cristian Marussi <cristian.marussi@....com>,
	linux-arm-kernel@...ts.infradead.org, linux-pm@...r.kernel.org,
	linux-kernel@...r.kernel.org, Taniya Das <quic_tdas@...cinc.com>,
	Ajit Pandey <quic_ajipan@...cinc.com>,
	Imran Shaik <quic_imrashai@...cinc.com>,
	Vivek Aknurwar <quic_viveka@...cinc.com>,
	Mike Tipton <quic_mdtipton@...cinc.com>
Subject: Re: [PATCH V2] cpufreq: scmi: Avoid overflow of target_freq in fast
 switch

On 20-05-24, 12:07, Jagadeesh Kona wrote:
> Conversion of target_freq to HZ in scmi_cpufreq_fast_switch()
> can lead to overflow if the multiplied result is greater than
> UINT_MAX, since type of target_freq is unsigned int. Avoid this
> overflow by assigning target_freq to unsigned long variable for
> converting it to HZ.
> 
> Signed-off-by: Jagadeesh Kona <quic_jkona@...cinc.com>
> ---
> Changes in V2:
>   - Updated freq variable from u64 to unsigned long to keep it
>     consistent with the rate parameter in scmi .freq_set() callback
>   - Link to v1: https://lore.kernel.org/all/20240517070157.19553-1-quic_jkona@quicinc.com/
> ---
>  drivers/cpufreq/scmi-cpufreq.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Applied. Thanks.

-- 
viresh

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ