{"id":"CVE-2022-49978","aliases":["CVE-2022-49978"],"related":[],"kind":"vulnerability","state":"published","title":"fbdev: fb_pm2fb: Avoid potential divide by zero error","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nfbdev: fb_pm2fb: Avoid potential divide by zero error\n\nIn `do_fb_ioctl()` of fbmem.c, if cmd is FBIOPUT_VSCREENINFO, var will be\ncopied from user, then go through `fb_set_var()` and\n`info->fbops->fb_check_var()` which could may be `pm2fb_check_var()`.\nAlong the path, `var->pixclock` won't be modified. This function checks\nwhether reciprocal of `var->pixclock` is too high. If `var->pixclock` is\nzero, there will be a divide by zero error. So, it is necessary to check\nwhether denominator is zero to avoid crash. As this bug is found by\nSyzkaller, logs are listed below.\n\ndivide error in pm2fb_check_var\nCall Trace:\n <TASK>\n fb_set_var+0x367/0xeb0 drivers/video/fbdev/core/fbmem.c:1015\n do_fb_ioctl+0x234/0x670 drivers/video/fbdev/core/fbmem.c:1110\n fb_ioctl+0xdd/0x130 drivers/video/fbdev/core/fbmem.c:1189","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nfbdev: fb_pm2fb: Avoid potential divide by zero error\n\nIn `do_fb_ioctl()` of fbmem.c, if cmd is FBIOPUT_VSCREENINFO, var will be\ncopied from user, then go through `fb_set_var()` and\n`info->fbops->fb_check_var()` which could may be `pm2fb_check_var()`.\nAlong the path, `var->pixclock` won't be modified. This function checks\nwhether reciprocal of `var->pixclock` is too high. If `var->pixclock` is\nzero, there will be a divide by zero error. So, it is necessary to check\nwhether denominator is zero to avoid crash. As this bug is found by\nSyzkaller, logs are listed below.\n\ndivide error in pm2fb_check_var\nCall Trace:\n <TASK>\n fb_set_var+0x367/0xeb0 drivers/video/fbdev/core/fbmem.c:1015\n do_fb_ioctl+0x234/0x670 drivers/video/fbdev/core/fbmem.c:1110\n fb_ioctl+0xdd/0x130 drivers/video/fbdev/core/fbmem.c:1189","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: fbdev: fb_pm2fb: Evitar posible error de división por cero En `do_fb_ioctl()` de fbmem.c, si cmd es FBIOPUT_VSCREENINFO, var se copiará del usuario, luego pasará por `fb_set_var()` e `info-&gt;fbops-&gt;fb_check_var()` que podrían ser `pm2fb_check_var()`. A lo largo de la ruta, `var-&gt;pixclock` no se modificará. Esta función verifica si el recíproco de `var-&gt;pixclock` es demasiado alto. Si `var-&gt;pixclock` es cero, habrá un error de división por cero. Por lo tanto, es necesario verificar si el denominador es cero para evitar un bloqueo. Como Syzkaller encontró este error, los registros se enumeran a continuación. Error de división en el seguimiento de llamadas pm2fb_check_var:  fb_set_var+0x367/0xeb0 drivers/video/fbdev/core/fbmem.c:1015 do_fb_ioctl+0x234/0x670 drivers/video/fbdev/core/fbmem.c:1110 fb_ioctl+0xdd/0x130 drivers/video/fbdev/core/fbmem.c:1189","source":"nvd"}],"published":"2025-06-18T11:00:40.693Z","modified":"2026-06-17T05:19:39.880Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"}],"cwes":["CWE-369"],"affected":[{"ranges":[{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"0f1174f4972ea9fad6becf8881d71adca8e9ca91","status":"affected"},{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"3ec326a6a0d4667585ca595f438c7293e5ced7c4","status":"affected"},{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"7f88cdfea8d7f4dbaf423d808241403b2bb945e4","status":"affected"},{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"7d9591b32a9092fc6391a316b56e8016c6181c3d","status":"affected"},{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"8fc778ee2fb2853f7a3531fa7273349640d8e4e9","status":"affected"},{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"34c3dea1189525cd533071ed5c176fc4ea8d982b","status":"affected"},{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"cb4bb011a683532841344ca7f281b5e04389b4f8","status":"affected"},{"type":"git","introduced":"1da177e4c3f41524e886b7f1b8a0c1fc7321cac2","fixed":"19f953e7435644b81332dd632ba1b2d80b1e37af","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"2.6.12","status":"affected"},{"type":"semver","introduced":"0","fixed":"2.6.12","status":"unaffected"},{"type":"semver","introduced":"4.9.327","lastAffected":"4.9.*","status":"unaffected"},{"type":"semver","introduced":"4.14.292","lastAffected":"4.14.*","status":"unaffected"},{"type":"semver","introduced":"4.19.257","lastAffected":"4.19.*","status":"unaffected"},{"type":"semver","introduced":"5.4.212","lastAffected":"5.4.*","status":"unaffected"},{"type":"semver","introduced":"5.10.141","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.65","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"5.19.7","lastAffected":"5.19.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.0","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","fixed":"4.9.327"},{"status":"affected","introduced":"4.10","fixed":"4.14.292"},{"status":"affected","introduced":"4.15","fixed":"4.19.257"},{"status":"affected","introduced":"4.20","fixed":"5.4.212"},{"status":"affected","introduced":"5.5","fixed":"5.10.141"},{"status":"affected","introduced":"5.11","fixed":"5.15.65"},{"status":"affected","introduced":"5.16","fixed":"5.19.7"},{"status":"affected","version":"6.0"},{"status":"affected","version":"6.0"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/0f1174f4972ea9fad6becf8881d71adca8e9ca91","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/3ec326a6a0d4667585ca595f438c7293e5ced7c4","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/7f88cdfea8d7f4dbaf423d808241403b2bb945e4","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/7d9591b32a9092fc6391a316b56e8016c6181c3d","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/8fc778ee2fb2853f7a3531fa7273349640d8e4e9","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/34c3dea1189525cd533071ed5c176fc4ea8d982b","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/cb4bb011a683532841344ca7f281b5e04389b4f8","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/19f953e7435644b81332dd632ba1b2d80b1e37af","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-49978","url":"https://www.cve.org/CVERecord?id=CVE-2022-49978","licence":"CVE Terms of Use","modified":"2026-05-11T19:10:22.754Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-49978","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-49978","licence":"Public domain","modified":"2026-06-17T05:19:39.880Z"}],"updatedAt":"2026-11-25T22:58:20.991Z","epss":{"score":0.00264,"percentile":0.19595,"date":"2026-12-01T12:00:22.000Z"}}