CVE-2022-50580: blk-throttle: prevent overflow while calculating wait time
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
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.
The Linux kernel CVE team has assigned CVE-2022-50580 to this issue.
Affected and fixed versions
===========================
Fixed in 5.10.150 with commit 19c010ae44f0ce52b5436080492a61a092ee0cf4 Fixed in 5.15.75 with commit 70b2adb1d698fbc63d3b3848c452524dc15872c5 Fixed in 5.19.17 with commit cc6f0855bf8d9b729df28ff443ced7350c380dbd Fixed in 6.0.3 with commit ca67b0563b39e79290c23e509319c178b9ca9104 Fixed in 6.1 with commit 8d6bbaada2e0a65f9012ac4c2506460160e7237a
Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.
Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at
https://cve.org/CVERecord/?id=CVE-2022-50580
will be updated if fixes are backported, please check that for the most up to date information about this issue.
Affected files
==============
The file(s) affected by this issue are:
block/blk-throttle.c
Mitigation
==========
The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:
https://git.kernel.org/stable/c/19c010ae44f0ce52b5436080492a61a092ee0cf4 https://git.kernel.org/stable/c/70b2adb1d698fbc63d3b3848c452524dc15872c5 https://git.kernel.org/stable/c/cc6f0855bf8d9b729df28ff443ced7350c380dbd https://git.kernel.org/stable/c/ca67b0563b39e79290c23e509319c178b9ca9104 https://git.kernel.org/stable/c/8d6bbaada2e0a65f9012ac4c2506460160e7237a