# CVE-2025-37827: btrfs: zoned: return EIO on RAID1 block group write pointer mismatch

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

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; 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.27% (percentile 13, 2026-11-26)
- **CWE:** CWE-476
- **Published:** 2025-05-08T06:26:19.320Z
- **Modified:** 2026-06-17T09:15:31.187Z

## Who should check

- Anyone running Linux \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< 9a447f748f6c7287dad68fa91913cd382fa0fcc8; \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< f4717a02cc422cf4bb2dbb280b154a1ae65c5f84; \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< b0c26f47992672661340dd6ea931240213016609; e91dab550dd1d2221333cac9f5c012ab5193696f; \>= 6.10.10, \< 6.11
- Anyone running Linux 6.11

## Description

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

btrfs: zoned: return EIO on RAID1 block group write pointer mismatch

There was a bug report about a NULL pointer dereference in
\_\_btrfs\_add\_free\_space\_zoned() that ultimately happens because a
conversion from the default metadata profile DUP to a RAID1 profile on two
disks.

The stack trace has the following signature:

  BTRFS error (device sdc): zoned: write pointer offset mismatch of zones in raid1 profile
  BUG: kernel NULL pointer dereference, address: 0000000000000058
  \#PF: supervisor read access in kernel mode
  \#PF: error\_code(0x0000) - not-present page
  PGD 0 P4D 0
  Oops: Oops: 0000 \[\#1\] PREEMPT SMP NOPTI
  RIP: 0010:\_\_btrfs\_add\_free\_space\_zoned.isra.0+0x61/0x1a0
  RSP: 0018:ffffa236b6f3f6d0 EFLAGS: 00010246
  RAX: 0000000000000000 RBX: ffff96c8132f3400 RCX: 0000000000000001
  RDX: 0000000010000000 RSI: 0000000000000000 RDI: ffff96c8132f3410
  RBP: 0000000010000000 R08: 0000000000000003 R09: 0000000000000000
  R10: 0000000000000000 R11: 00000000ffffffff R12: 0000000000000000
  R13: ffff96c758f65a40 R14: 0000000000000001 R15: 000011aac0000000
  FS: 00007fdab1cb2900(0000) GS:ffff96e60ca00000(0000) knlGS:0000000000000000
  CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
  CR2: 0000000000000058 CR3: 00000001a05ae000 CR4: 0000000000350ef0
  Call Trace:
  \<TASK\>
  ? \_\_die\_body.cold+0x19/0x27
  ? page\_fault\_oops+0x15c/0x2f0
  ? exc\_page\_fault+0x7e/0x180
  ? asm\_exc\_page\_fault+0x26/0x30
  ? \_\_btrfs\_add\_free\_space\_zoned.isra.0+0x61/0x1a0
  btrfs\_add\_free\_space\_async\_trimmed+0x34/0x40
  btrfs\_add\_new\_free\_space+0x107/0x120
  btrfs\_make\_block\_group+0x104/0x2b0
  btrfs\_create\_chunk+0x977/0xf20
  btrfs\_chunk\_alloc+0x174/0x510
  ? srso\_return\_thunk+0x5/0x5f
  btrfs\_inc\_block\_group\_ro+0x1b1/0x230
  btrfs\_relocate\_block\_group+0x9e/0x410
  btrfs\_relocate\_chunk+0x3f/0x130
  btrfs\_balance+0x8ac/0x12b0
  ? srso\_return\_thunk+0x5/0x5f
  ? srso\_return\_thunk+0x5/0x5f
  ? \_\_kmalloc\_cache\_noprof+0x14c/0x3e0
  btrfs\_ioctl+0x2686/0x2a80
  ? srso\_return\_thunk+0x5/0x5f
  ? ioctl\_has\_perm.constprop.0.isra.0+0xd2/0x120
  \_\_x64\_sys\_ioctl+0x97/0xc0
  do\_syscall\_64+0x82/0x160
  ? srso\_return\_thunk+0x5/0x5f
  ? \_\_memcg\_slab\_free\_hook+0x11a/0x170
  ? srso\_return\_thunk+0x5/0x5f
  ? kmem\_cache\_free+0x3f0/0x450
  ? srso\_return\_thunk+0x5/0x5f
  ? srso\_return\_thunk+0x5/0x5f
  ? syscall\_exit\_to\_user\_mode+0x10/0x210
  ? srso\_return\_thunk+0x5/0x5f
  ? do\_syscall\_64+0x8e/0x160
  ? sysfs\_emit+0xaf/0xc0
  ? srso\_return\_thunk+0x5/0x5f
  ? srso\_return\_thunk+0x5/0x5f
  ? seq\_read\_iter+0x207/0x460
  ? srso\_return\_thunk+0x5/0x5f
  ? vfs\_read+0x29c/0x370
  ? srso\_return\_thunk+0x5/0x5f
  ? srso\_return\_thunk+0x5/0x5f
  ? syscall\_exit\_to\_user\_mode+0x10/0x210
  ? srso\_return\_thunk+0x5/0x5f
  ? do\_syscall\_64+0x8e/0x160
  ? srso\_return\_thunk+0x5/0x5f
  ? exc\_page\_fault+0x7e/0x180
  entry\_SYSCALL\_64\_after\_hwframe+0x76/0x7e
  RIP: 0033:0x7fdab1e0ca6d
  RSP: 002b:00007ffeb2b60c80 EFLAGS: 00000246 ORIG\_RAX: 0000000000000010
  RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 00007fdab1e0ca6d
  RDX: 00007ffeb2b60d80 RSI: 00000000c4009420 RDI: 0000000000000003
  RBP: 00007ffeb2b60cd0 R08: 0000000000000000 R09: 0000000000000013
  R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
  R13: 00007ffeb2b6343b R14: 00007ffeb2b60d80 R15: 0000000000000001
  \</TASK\>
  CR2: 0000000000000058
  ---\[ end trace 0000000000000000 \]---

The 1st line is the most interesting here:

 BTRFS error (device sdc): zoned: write pointer offset mismatch of zones in raid1 profile

When a RAID1 block-group is created and a write pointer mismatch between
the disks in the RAID set is detected, btrfs sets the alloc\_offset to the
length of the block group marking it as full. Afterwards the code expects
that a balance operation will evacuate the data in this block-group and
repair the problems.

But before this is possible, the new space of this block-group will be
accounted in the free space cache. But in \_\_btrfs\_
---truncated---

## Affected and fixed versions

- Linux: \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< 9a447f748f6c7287dad68fa91913cd382fa0fcc8; \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< f4717a02cc422cf4bb2dbb280b154a1ae65c5f84; \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< b0c26f47992672661340dd6ea931240213016609; e91dab550dd1d2221333cac9f5c012ab5193696f; \>= 6.10.10, \< 6.11 (cvelist)
- Linux: 6.11 (cvelist)

## Mitigation

- Upgrade Linux to 6.11 or later.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2025-37827.md
Affected: Linux >= b1934cd6069538db2255dc94ba573771ecf3b560, < 9a447f748f6c7287dad68fa91913cd382fa0fcc8; >= b1934cd6069538db2255dc94ba573771ecf3b560, < f4717a02cc422cf4bb2dbb280b154a1ae65c5f84; >= b1934cd6069538db2255dc94ba573771ecf3b560, < b0c26f47992672661340dd6ea931240213016609; e91dab550dd1d2221333cac9f5…
Fixed in: Linux 9a447f748f6c7287dad68fa91913cd382fa0fcc8, Linux 6.11

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-2025-37827 being exploited?

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

### How serious is CVE-2025-37827?

Medium: CVSS 5.5 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2025-37827?

Linux \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< 9a447f748f6c7287dad68fa91913cd382fa0fcc8; \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< f4717a02cc422cf4bb2dbb280b154a1ae65c5f84; \>= b1934cd6069538db2255dc94ba573771ecf3b560, \< b0c26f47992672661340dd6ea931240213016609; e91dab550dd1d2221333cac9f5c012ab5193696f; \>= 6.10.10, \< 6.11; Linux 6.11.

### Is there a fix for CVE-2025-37827?

Yes. Fixed in Linux 9a447f748f6c7287dad68fa91913cd382fa0fcc8, Linux 6.11. Upgrade Linux to 6.11 or later.

### How do I check if I'm affected by CVE-2025-37827?

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/9a447f748f6c7287dad68fa91913cd382fa0fcc8>
- patch: <https://git.kernel.org/stable/c/f4717a02cc422cf4bb2dbb280b154a1ae65c5f84>
- patch: <https://git.kernel.org/stable/c/b0c26f47992672661340dd6ea931240213016609>

## 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-2025-37827>

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