summaryrefslogtreecommitdiff
path: root/scripts/lib/kdoc/kdoc_output.py
diff options
context:
space:
mode:
authorSergey Shtylyov <s.shtylyov@omp.ru>2025-05-14 23:35:58 +0300
committerHelge Deller <deller@gmx.de>2025-05-31 10:24:02 +0200
commit3f6dae09fc8c306eb70fdfef70726e1f154e173a (patch)
tree513e3bdbeec015ce44b01ae3a49a111dc26d4f2c /scripts/lib/kdoc/kdoc_output.py
parentcedc1b63394a866bf8663a3e40f4546f1d28c8d8 (diff)
fbdev: core: fbcvt: avoid division by 0 in fb_cvt_hperiod()
In fb_find_mode_cvt(), iff mode->refresh somehow happens to be 0x80000000, cvt.f_refresh will become 0 when multiplying it by 2 due to overflow. It's then passed to fb_cvt_hperiod(), where it's used as a divider -- division by 0 will result in kernel oops. Add a sanity check for cvt.f_refresh to avoid such overflow... Found by Linux Verification Center (linuxtesting.org) with the Svace static analysis tool. Fixes: 96fe6a2109db ("[PATCH] fbdev: Add VESA Coordinated Video Timings (CVT) support") Signed-off-by: Sergey Shtylyov <s.shtylyov@omp.ru> Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'scripts/lib/kdoc/kdoc_output.py')
0 files changed, 0 insertions, 0 deletions