diff options
author | Yu Kuai <yukuai3@huawei.com> | 2022-08-29 10:22:38 +0800 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2022-09-12 00:19:48 -0600 |
commit | 8d6bbaada2e0a65f9012ac4c2506460160e7237a (patch) | |
tree | 38f8337cf068641d2680da5e44e522b68b0f3434 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | 320fb0f91e55ba248d4bad106b408e59099cfa89 (diff) |
blk-throttle: prevent overflow while calculating wait time
There is a problem found by code review in tg_with_in_bps_limit() that
'bps_limit * jiffy_elapsed_rnd' might overflow. Fix the problem by
calling mul_u64_u64_div_u64() instead.
Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Acked-by: Tejun Heo <tj@kernel.org>
Link: https://lore.kernel.org/r/20220829022240.3348319-3-yukuai1@huaweicloud.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions