5.5medium
mm/swapfile: add cond_resched() in get_swap_pages()
- Severity
- 5.5medium CVSS:3.1 by CISA-ADP
- Exploit likelihood
- 0.20% (higher than 10% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- Linux
Description
In the Linux kernel, the following vulnerability has been resolved: mm/swapfile: add cond_resched() in get_swap_pages() The softlockup still occurs in get_swap_pages() under memory pressure. 64 CPU cores, 64GB memory, and 28 zram devices, the disksize of each zram device is 50MB with same priority as si. Use the stress-ng tool to increase memory pressure, causing the system to oom frequently. The plist_for_each_entry_safe() loops in get_swap_pages() could reach tens of thousands of times to find available space (extreme case: cond_resched() is not called in scan_swap_map_slots()). Let's add cond_resched() into get_swap_pages() when failed to find available space to avoid softlockup.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| Linux Linux | from adfab836f4908deb049a5128082719e689eed964 before 29f0349c5c76b627fe06b87d4b13fa03a6ce8e64, from adfab836f4908deb049a5128082719e689eed964 before 387217b97e99699c34e6d95ce2b91b327fcd853e, from adfab836f4908deb049a5128082719e689eed964 before d49c85a1913385eed46dd16a25ad0928253767f0, from adfab836f4908deb049a5128082719e689eed964 before 30187be29052bba9203b0ae2bdd815e0bc2faaab, from adfab836f4908deb049a5128082719e689eed964 before 5dbe1ebd56470d03b78fc31491a9e4d433106ef2, from adfab836f4908deb049a5128082719e689eed964 before 49178d4d61e78aed8c837dfeea8a450700f196e2, from adfab836f4908deb049a5128082719e689eed964 before 7717fc1a12f88701573f9ed897cc4f6699c661e3, 75b1f2d3ed3169675b69b2f68217ebb839414657 and 4 more Not affected: before 3.16, from 4.14.306 up to 4.14.*, from 4.19.273 up to 4.19.*, from 5.4.232 up to 5.4.*, from 5.10.168 up to 5.10.*, from 5.15.93 up to 5.15.* | CVE List |
| linux linux_kernel | before 4.14.306, from 4.15 before 4.19.273, from 4.20 before 5.4.232, from 5.5 before 5.10.168, from 5.11 before 5.15.93, from 5.16 before 6.1.11, 6.2 | NVD |
All scores
| CISA-ADP | 5.5medium CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
| NVD | 5.5medium CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.
What each source says
CVE List
In the Linux kernel, the following vulnerability has been resolved: mm/swapfile: add cond_resched() in get_swap_pages() The softlockup still occurs in get_swap_pages() under memory pressure. 64 CPU cores, 64GB memory, and 28 zram devices, the disksize of each zram device is 50MB with same priority as si. Use the stress-ng tool to increase memory pressure, causing the system to oom frequently. The plist_for_each_entry_safe() loops in get_swap_pages() could reach tens of thousands of times to find available space (extreme case: cond_resched() is not called in scan_swap_map_slots()). Let's add cond_resched() into get_swap_pages() when failed to find available space to avoid softlockup.
NVD (es)
En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: mm/swapfile: añadir cond_resched() en get_swap_pages() El bloqueo suave todavía ocurre en get_swap_pages() bajo presión de memoria. 64 núcleos de CPU, 64 GB de memoria y 28 dispositivos zram, el tamaño del disco de cada dispositivo zram es de 50 MB con la misma prioridad que si. Utilice la herramienta stress-ng para aumentar la presión de memoria, lo que hace que el sistema se sobrecargue con frecuencia. Los bucles plist_for_each_entry_safe() en get_swap_pages() podrían alcanzar decenas de miles de veces para encontrar espacio disponible (caso extremo: cond_resched() no se llama en scan_swap_map_slots()). Agreguemos cond_resched() a get_swap_pages() cuando no se pueda encontrar espacio disponible para evitar el bloqueo suave.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2023-52932 changed 2026-05-23 | CVE Terms of Use |
| NVD | CVE-2023-52932 changed 2026-06-17 | Public domain |