# CVE-2026-45942: ext4: fix e4b bitmap inconsistency reports

> 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.14% (percentile 1, 2026-11-26)
- **CWE:** CWE-362
- **Published:** 2026-05-27T12:17:57.950Z
- **Modified:** 2026-10-30T13:18:53.790Z

## Who should check

- Anyone running Linux \>= c9de560ded61faa5b754137b7753da252391c55a, \< a3a7d360252c0d84ae8bda067fb296c9e82928d3; \>= c9de560ded61faa5b754137b7753da252391c55a, \< 57e83bfbe1e412ac42daced2086f3c6f9a17bba0; \>= c9de560ded61faa5b754137b7753da252391c55a, \< c05033cfc5c7699cd4df8d48cef94d01da755f24; \>= c9de560ded61faa5b754137b7753da252391c55a, \< 29a07d691d282faf38c33d4b61839b89399110f9; \>= c9de560ded61faa5b754137b7753da252391c55a, \< f29709a7a3fc38f5015d850504762cdef0e151f9; \>= c9de560ded61faa5b754137b7753da252391c55a, \< bdc56a9c46b2a99c12313122b9352b619a2e719e
- Anyone running Linux 2.6.25

## Description

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

ext4: fix e4b bitmap inconsistency reports

A bitmap inconsistency issue was observed during stress tests under
mixed huge-page workloads. Ext4 reported multiple e4b bitmap check
failures like:

ext4\_mb\_complex\_scan\_group:2508: group 350, 8179 free clusters as
per group info. But got 8192 blocks

Analysis and experimentation confirmed that the issue is caused by a
race condition between page migration and bitmap modification. Although
this timing window is extremely narrow, it is still hit in practice:

folio\_lock                        ext4\_mb\_load\_buddy
\_\_migrate\_folio
  check ref count
  folio\_mc\_copy                     \_\_filemap\_get\_folio
                                      folio\_try\_get(folio)
                                  ......
                                  mb\_mark\_used
                                  ext4\_mb\_unload\_buddy
  \_\_folio\_migrate\_mapping
    folio\_ref\_freeze
folio\_unlock

The root cause of this issue is that the fast path of load\_buddy only
increments the folio's reference count, which is insufficient to prevent
concurrent folio migration. We observed that the folio migration process
acquires the folio lock. Therefore, we can determine whether to take the
fast path in load\_buddy by checking the lock status. If the folio is
locked, we opt for the slow path (which acquires the lock) to close this
concurrency window.

Additionally, this change addresses the following issues:

When the DOUBLE\_CHECK macro is enabled to inspect bitmap-related
issues, the following error may be triggered:

corruption in group 324 at byte 784(6272): f in copy != ff on
disk/prealloc

Analysis reveals that this is a false positive. There is a specific race
window where the bitmap and the group descriptor become momentarily
inconsistent, leading to this error report:

ext4\_mb\_load\_buddy                   ext4\_mb\_load\_buddy
  \_\_filemap\_get\_folio(create\|lock)
    folio\_lock
  ext4\_mb\_init\_cache
    folio\_mark\_uptodate
                                     \_\_filemap\_get\_folio(no lock)
                                     ......
                                     mb\_mark\_used
                                       mb\_mark\_used\_double
  mb\_cmp\_bitmaps
                                       mb\_set\_bits(e4b-\>bd\_bitmap)
  folio\_unlock

The original logic assumed that since mb\_cmp\_bitmaps is called when the
bitmap is newly loaded from disk, the folio lock would be sufficient to
prevent concurrent access. However, this overlooks a specific race
condition: if another process attempts to load buddy and finds the folio
is already in an uptodate state, it will immediately begin using it without
holding folio lock.

## Affected and fixed versions

- Linux: \>= c9de560ded61faa5b754137b7753da252391c55a, \< a3a7d360252c0d84ae8bda067fb296c9e82928d3; \>= c9de560ded61faa5b754137b7753da252391c55a, \< 57e83bfbe1e412ac42daced2086f3c6f9a17bba0; \>= c9de560ded61faa5b754137b7753da252391c55a, \< c05033cfc5c7699cd4df8d48cef94d01da755f24; \>= c9de560ded61faa5b754137b7753da252391c55a, \< 29a07d691d282faf38c33d4b61839b89399110f9; \>= c9de560ded61faa5b754137b7753da252391c55a, \< f29709a7a3fc38f5015d850504762cdef0e151f9; \>= c9de560ded61faa5b754137b7753da252391c55a, \< bdc56a9c46b2a99c12313122b9352b619a2e719e (cvelist)
- Linux: 2.6.25 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2026-45942.md
Affected: Linux >= c9de560ded61faa5b754137b7753da252391c55a, < a3a7d360252c0d84ae8bda067fb296c9e82928d3; >= c9de560ded61faa5b754137b7753da252391c55a, < 57e83bfbe1e412ac42daced2086f3c6f9a17bba0; >= c9de560ded61faa5b754137b7753da252391c55a, < c05033cfc5c7699cd4df8d48cef94d01da755f24; >= c9de560ded61faa5b754137…
Fixed in: Linux 57e83bfbe1e412ac42daced2086f3c6f9a17bba0, Linux 29a07d691d282faf38c33d4b61839b89399110f9

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-2026-45942 being exploited?

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

### How serious is CVE-2026-45942?

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

### Which versions are affected by CVE-2026-45942?

Linux \>= c9de560ded61faa5b754137b7753da252391c55a, \< a3a7d360252c0d84ae8bda067fb296c9e82928d3; \>= c9de560ded61faa5b754137b7753da252391c55a, \< 57e83bfbe1e412ac42daced2086f3c6f9a17bba0; \>= c9de560ded61faa5b754137b7753da252391c55a, \< c05033cfc5c7699cd4df8d48cef94d01da755f24; \>= c9de560ded61faa5b754137b7753da252391c55a, \< 29a07d691d282faf38c33d4b61839b89399110f9; \>= c9de560ded61faa5b754137b7753da252391c55a, \< f29709a7a3fc38f5015d850504762cdef0e151f9; \>= c9de560ded61faa5b754137b7753da252391c55a, \< bdc56a9c46b2a99c12313122b9352b619a2e719e; Linux 2.6.25.

### Is there a fix for CVE-2026-45942?

Yes. Fixed in Linux 57e83bfbe1e412ac42daced2086f3c6f9a17bba0, Linux 29a07d691d282faf38c33d4b61839b89399110f9. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2026-45942?

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/57e83bfbe1e412ac42daced2086f3c6f9a17bba0>
- patch: <https://git.kernel.org/stable/c/c05033cfc5c7699cd4df8d48cef94d01da755f24>
- patch: <https://git.kernel.org/stable/c/29a07d691d282faf38c33d4b61839b89399110f9>
- patch: <https://git.kernel.org/stable/c/f29709a7a3fc38f5015d850504762cdef0e151f9>
- patch: <https://git.kernel.org/stable/c/bdc56a9c46b2a99c12313122b9352b619a2e719e>
- other: <https://git.kernel.org/stable/c/a3a7d360252c0d84ae8bda067fb296c9e82928d3>

## 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-2026-45942>

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