Skip to main content

Boteraser | Website and Server Security Solutions

🛡️ CVE-2025-22127 — kernel

🟡 CVSS 5.5 — Medium ✅ No Known Exploit NVD
5.5
CVSS Score
0 Low4 Medium7 High9 Critical10

Description

f2fs: fix potential deadloop in prepare_compress_overwrite()

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

f2fs: fix potential deadloop in prepare_compress_overwrite()

Jan Prusakowski reported a kernel hang issue as below:

When running xfstests on linux-next kernel (6.14.0-rc3, 6.12) I

encountered a problem in generic/475 test where fsstress process

gets blocked in __f2fs_write_data_pages() and the test hangs.

The options I used are:

MKFS_OPTIONS -- -O compression -O extra_attr -O project_quota -O quota /dev/vdc

MOUNT_OPTIONS -- -o acl,user_xattr -o discard,compress_extension=* /dev/vdc /vdc

INFO: task kworker/u8:0:11 blocked for more than 122 seconds.

Not tainted 6.14.0-rc3-xfstests-lockdep #1

"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.

task:kworker/u8:0 state:D stack:0 pid:11 tgid:11 ppid:2 task_flags:0x4208160 flags:0x00004000

Workqueue: writeback wb_workfn (flush-253:0)

Call Trace:

<TASK>

__schedule+0x309/0x8e0

schedule+0x3a/0x100

schedule_preempt_disabled+0x15/0x30

__mutex_lock+0x59a/0xdb0

__f2fs_write_data_pages+0x3ac/0x400

do_writepages+0xe8/0x290

__writeback_single_inode+0x5c/0x360

writeback_sb_inodes+0x22f/0x570

wb_writeback+0xb0/0x410

wb_do_writeback+0x47/0x2f0

wb_workfn+0x5a/0x1c0

process_one_work+0x223/0x5b0

worker_thread+0x1d5/0x3c0

kthread+0xfd/0x230

ret_from_fork+0x31/0x50

ret_from_fork_asm+0x1a/0x30

</TASK>

The root cause is: once generic/475 starts toload error table to dm

device, f2fs_prepare_compress_overwrite() will loop reading compressed

cluster pages due to IO error, meanwhile it has held .writepages lock,

it can block all other writeback tasks.

Let's fix this issue w/ below changes:

  • add f2fs_handle_page_eio() in prepare_compress_overwrite() to

detect IO error.

  • detect cp_error earler in f2fs_read_multi_pages().

How this vulnerability can be exploited

This issue can be reached with local access to the system, attack complexity is low, an attacker needs low-level privileges on the target. No user interaction is required. The scope is unchanged, so the impact stays within the vulnerable component. Rated impact: confidentiality none, integrity none, availability high.

Affected software

CVE-2025-22127 is recorded against 2 packages.

  • kernel (from 5.6.0 up to 6.14.2)
  • linux-kernel (from 5.6 up to 6.14.2)

Timeline and source

Published on 16 April 2025 and last revised on 12 August 2026. No public exploit is currently recorded for this entry. A vendor advisory or fix has been published. Record sourced from NVD.

References

git.kernel.org (Web)
git.kernel.org (Web)
github.com (Advisory)
nvd.nist.gov (Advisory)
git.kernel.org (Package)

CVE-2025-22127 on other distributions

Each distribution ships its own build and its own fixed version. Pick the one you run:

Details

Severity Medium
CVSS Score 5.5
CVSS Vector CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
CWE N/A
Public Exploit ✅ No
Source NVD
Published 2025-04-16
Updated 2026-08-20
Modified 2026-08-12

Affected Packages

Software From version Fixed in
kernel 5.6.0 6.14.2
linux-kernel 5.6 6.14.2

Similar Threats

Vulnerability Monitoring

Track new vulnerabilities in kernel

CVE-2025-22127 is rated CVSS 5.5 Medium. BotEraser monitors your WordPress installation and notifies you when software you use appears in our vulnerability database.

Set Up Free Alerts →

No credit card required  ·  Results in minutes

ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.