# CVE-2024-53220: f2fs: fix to account dirty data in \_\_get\_secs\_required()

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.32% (percentile 18, 2026-11-28)
- **Published:** 2024-12-27T13:50:05.416Z
- **Modified:** 2026-08-05T11:44:43.413Z

## Who should check

- Anyone running Linux \>= 4354994f097d068a894aa1a0860da54571df3582, \< 6e58b2987960efcd917bc42da781cee256213618; \>= 4354994f097d068a894aa1a0860da54571df3582, \< f1b8bfe8d2f2fdf905d37c174d5bc1cd2b6910c5; \>= 4354994f097d068a894aa1a0860da54571df3582, \< 9313b85ddc120e2d2f0efaf86d0204d4c98d60b1; \>= 4354994f097d068a894aa1a0860da54571df3582, \< e812871c068cc0f91ff9f5cee87d00df1c44aae4; \>= 4354994f097d068a894aa1a0860da54571df3582, \< 1acd73edbbfef2c3c5b43cba4006a7797eca7050
- Anyone running Linux 4.20

## Description

In the Linux kernel, the following vulnerability has been resolved:

f2fs: fix to account dirty data in \_\_get\_secs\_required()

It will trigger system panic w/ testcase in \[1\]:

------------\[ cut here \]------------
kernel BUG at fs/f2fs/segment.c:2752!
RIP: 0010:new\_curseg+0xc81/0x2110
Call Trace:
 f2fs\_allocate\_data\_block+0x1c91/0x4540
 do\_write\_page+0x163/0xdf0
 f2fs\_outplace\_write\_data+0x1aa/0x340
 f2fs\_do\_write\_data\_page+0x797/0x2280
 f2fs\_write\_single\_data\_page+0x16cd/0x2190
 f2fs\_write\_cache\_pages+0x994/0x1c80
 f2fs\_write\_data\_pages+0x9cc/0xea0
 do\_writepages+0x194/0x7a0
 filemap\_fdatawrite\_wbc+0x12b/0x1a0
 \_\_filemap\_fdatawrite\_range+0xbb/0xf0
 file\_write\_and\_wait\_range+0xa1/0x110
 f2fs\_do\_sync\_file+0x26f/0x1c50
 f2fs\_sync\_file+0x12b/0x1d0
 vfs\_fsync\_range+0xfa/0x230
 do\_fsync+0x3d/0x80
 \_\_x64\_sys\_fsync+0x37/0x50
 x64\_sys\_call+0x1e88/0x20d0
 do\_syscall\_64+0x4b/0x110
 entry\_SYSCALL\_64\_after\_hwframe+0x76/0x7e

The root cause is if checkpoint\_disabling and lfs\_mode are both on,
it will trigger OPU for all overwritten data, it may cost more free
segment than expected, so f2fs must account those data correctly to
calculate cosumed free segments later, and return ENOSPC earlier to
avoid run out of free segment during block allocation.

\[1\] https://lore.kernel.org/fstests/20241015025106.3203676-1-chao@kernel.org/

## Affected and fixed versions

- Linux: \>= 4354994f097d068a894aa1a0860da54571df3582, \< 6e58b2987960efcd917bc42da781cee256213618; \>= 4354994f097d068a894aa1a0860da54571df3582, \< f1b8bfe8d2f2fdf905d37c174d5bc1cd2b6910c5; \>= 4354994f097d068a894aa1a0860da54571df3582, \< 9313b85ddc120e2d2f0efaf86d0204d4c98d60b1; \>= 4354994f097d068a894aa1a0860da54571df3582, \< e812871c068cc0f91ff9f5cee87d00df1c44aae4; \>= 4354994f097d068a894aa1a0860da54571df3582, \< 1acd73edbbfef2c3c5b43cba4006a7797eca7050 (cvelist)
- Linux: 4.20 (cvelist)

## Mitigation

- Upgrade Linux to 1acd73edbbfef2c3c5b43cba4006a7797eca7050 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2024-53220. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2024-53220.md
Affected: Linux >= 4354994f097d068a894aa1a0860da54571df3582, < 6e58b2987960efcd917bc42da781cee256213618; >= 4354994f097d068a894aa1a0860da54571df3582, < f1b8bfe8d2f2fdf905d37c174d5bc1cd2b6910c5; >= 4354994f097d068a894aa1a0860da54571df3582, < 9313b85ddc120e2d2f0efaf86d0204d4c98d60b1; >= 4354994f097d068a894aa1a…
Fixed in: Linux 6e58b2987960efcd917bc42da781cee256213618, Linux 9313b85ddc120e2d2f0efaf86d0204d4c98d60b1, Linux 1acd73edbbfef2c3c5b43cba4006a7797eca7050

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2024-53220 being exploited?

There is no confirmed exploitation: CVE-2024-53220 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.32% chance of exploitation in the next 30 days (as of 2026-11-28).

### How serious is CVE-2024-53220?

High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2024-53220?

Linux \>= 4354994f097d068a894aa1a0860da54571df3582, \< 6e58b2987960efcd917bc42da781cee256213618; \>= 4354994f097d068a894aa1a0860da54571df3582, \< f1b8bfe8d2f2fdf905d37c174d5bc1cd2b6910c5; \>= 4354994f097d068a894aa1a0860da54571df3582, \< 9313b85ddc120e2d2f0efaf86d0204d4c98d60b1; \>= 4354994f097d068a894aa1a0860da54571df3582, \< e812871c068cc0f91ff9f5cee87d00df1c44aae4; \>= 4354994f097d068a894aa1a0860da54571df3582, \< 1acd73edbbfef2c3c5b43cba4006a7797eca7050; Linux 4.20.

### Is there a fix for CVE-2024-53220?

Yes. Fixed in Linux 6e58b2987960efcd917bc42da781cee256213618, Linux 9313b85ddc120e2d2f0efaf86d0204d4c98d60b1, Linux 1acd73edbbfef2c3c5b43cba4006a7797eca7050. Upgrade Linux to 1acd73edbbfef2c3c5b43cba4006a7797eca7050 or later.

### How do I check if I'm affected by CVE-2024-53220?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/6e58b2987960efcd917bc42da781cee256213618>
- patch: <https://git.kernel.org/stable/c/f1b8bfe8d2f2fdf905d37c174d5bc1cd2b6910c5>
- patch: <https://git.kernel.org/stable/c/9313b85ddc120e2d2f0efaf86d0204d4c98d60b1>
- patch: <https://git.kernel.org/stable/c/e812871c068cc0f91ff9f5cee87d00df1c44aae4>
- patch: <https://git.kernel.org/stable/c/1acd73edbbfef2c3c5b43cba4006a7797eca7050>
- other: <https://lists.debian.org/debian-lts-announce/2025/03/msg00001.html>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2024-53220>

HTML: <https://flawdb.com/CVE-2024-53220> · JSON: <https://flawdb.com/api/v1/entries/CVE-2024-53220>
