---
id: CVE-2026-89644
title: |-
  In the Linux kernel, the following vulnerability has been resolved:

  btrfs: fix extent map leak in NOCOW direct I/O write

  btrfs_dio_iomap_begin() calls btrfs_get_extent(), which returns an
  extent map reference that must be dropped on al…
summary: |-
  In the Linux kernel, the following vulnerability has been resolved:

  btrfs: fix extent map leak in NOCOW direct I/O write

  btrfs_dio_iomap_begin() calls btrfs_get_extent(), which returns an
  extent map reference that must be dropped on al…
severity: medium
cvss: 5.5
cvssVector: 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H'
cwe:
  - CWE-772
vendor: Linux
product: Linux
affected:
  - >-
    Linux >= 5f9a8a51d8b95505d8de8b7191ae2ed8c504d4af <
    b7c873765875645b11503f94c9bae2ca80127375
  - >-
    Linux >= 5f9a8a51d8b95505d8de8b7191ae2ed8c504d4af <
    f42efd634c0ae7ba0ce2fc5e30e291b0803b0ae2
  - >-
    Linux >= 5f9a8a51d8b95505d8de8b7191ae2ed8c504d4af <
    05a1a816eef8b3e4332620a64fc8cf45c4eb5c0d
  - >-
    Linux >= 5f9a8a51d8b95505d8de8b7191ae2ed8c504d4af <
    3f950867c307c5413d628a153ac44915bd117ffd
  - Linux 4.7
published: '2026-09-11'
updated: '2026-09-21'
sourceUpdated: '2026-09-21T14:17:24.403'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2026-89644'
references:
  - url: 'https://git.kernel.org/stable/c/05a1a816eef8b3e4332620a64fc8cf45c4eb5c0d'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: 'https://git.kernel.org/stable/c/3f950867c307c5413d628a153ac44915bd117ffd'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: 'https://git.kernel.org/stable/c/b7c873765875645b11503f94c9bae2ca80127375'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: 'https://git.kernel.org/stable/c/f42efd634c0ae7ba0ce2fc5e30e291b0803b0ae2'
    label: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
  - url: >-
      https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-89644.json
  - url: 'https://access.redhat.com/security/cve/CVE-2026-89644'
  - url: 'https://bugzilla.redhat.com/show_bug.cgi?id=2532063'
  - url: 'https://www.cve.org/CVERecord?id=CVE-2026-89644'
  - url: 'https://nvd.nist.gov/vuln/detail/CVE-2026-89644'
  - url: >-
      https://git.kernel.org/pub/scm/linux/security/vulns.git/plain/cve/published/2026/CVE-2026-89644.mbox
tags:
  - nvd
  - cve.org
  - csaf
  - vex
  - red-hat
epss: 0.00168
epssPercentile: 0.06441
cvssSource: vendor
ingestedAt: '2026-09-14T11:11:19.885Z'
---

## Overview

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

btrfs: fix extent map leak in NOCOW direct I/O write

btrfs_dio_iomap_begin() calls btrfs_get_extent(), which returns an
extent map reference that must be dropped on all exit paths.

For direct writes into a NOCOW range, btrfs_get_blocks_direct_write()
keeps using that extent map and asks btrfs_create_dio_extent() to
allocate the ordered extent. If that fails, for example because
btrfs_alloc_ordered_extent() fails, the function returns the error
without dropping the input extent map. The PREALLOC path avoided this by
dropping the input extent map before replacing it with the newly created
one.

Check the error from btrfs_create_dio_extent() before replacing the
map and drop the input extent map on failure.

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.

## Vendor advisories

- **Red Hat VEX** · Low · affected: Red Hat Enterprise Linux 10 · no fix planned: Red Hat Enterprise Linux 10 · updated 2026-09-14 · [vex](https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-89644.json)
