Re: [PATCH RESEND v6 2/8] blk-throttle: prevent overflow while calculating wait time

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

 



在 2022/07/28 2:28, Tejun Heo 写道:
On Fri, Jul 01, 2022 at 05:34:35PM +0800, Yu Kuai wrote:
From: Yu Kuai <yukuai3@xxxxxxxxxx>

In tg_with_in_bps_limit(), 'bps_limit * jiffy_elapsed_rnd' might
overflow. FIx the problem by calling mul_u64_u64_div_u64() instead.

Signed-off-by: Yu Kuai <yukuai3@xxxxxxxxxx>

Acked-by: Tejun Heo <tj@xxxxxxxxxx>

BTW, have you observed this happening or is it from just reviewing the code?

It's just from code review.

Thanks.

Thanks.





[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux