Re: [PATCH v2] hwmon: (xgene-hwmon) use appropriate type for the latency value

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Feb 04, 2025 at 09:54:08AM +0000, Ваторопин Андрей wrote:
> From: Andrey Vatoropin <a.vatoropin@xxxxxxx>
> 
> The expression PCC_NUM_RETRIES * pcc_chan->latency is currently being
> evaluated using 32-bit arithmetic.
> 
> Since a value of type 'u64' is used to store the eventual result,
> and this result is later sent to the function usecs_to_jiffies with 
> input parameter unsigned int, the current data type is too wide to 
> store the value of ctx->usecs_lat.
> 
> Change the data type of "usecs_lat" to a more suitable (narrower) type.
> 
> Found by Linux Verification Center (linuxtesting.org) with SVACE.
> 
> Signed-off-by: Andrey Vatoropin <a.vatoropin@xxxxxxx>

Applied.

Thanks,
Guenter




[Index of Archives]     [LM Sensors]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux