CVE-2021-47492 json
mm, thp: bail out early in collapse_file for writeback page
published 2024-05-22 2 y ago modified 2026-08-05 3 mo ago also EUVD-2021-34496
- cvss
- 7.8
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.2%
- EPSS 0.2% chance of exploitation in 30 days, percentile 12%
- public exploits
- 0
- none known
Summary
In the Linux kernel, the following vulnerability has been resolved:
mm, thp: bail out early in collapse_file for writeback page
Currently collapse_file does not explicitly check PG_writeback, instead, page_has_private and try_to_release_page are used to filter writeback pages. This does not work for xfs with blocksize equal to or larger than pagesize, because in such case xfs has no page->private.
This makes collapse_file bail out early for writeback page. Otherwise, xfs end_page_writeback will panic as follows.
page:fffffe00201bcc80 refcount:0 mapcount:0 mapping:ffff0003f88c86a8 index:0x0 pfn:0x84ef32 aops:xfs_address_space_operations [xfs] ino:30000b7 dentry name:"libtest.so" flags: 0x57fffe0000008027(locked|referenced|uptodate|active|writeback) raw: 57fffe0000008027 ffff80001b48bc28 ffff80001b48bc28 ffff0003f88c86a8 raw: 0000000000000000 0000000000000000 00000000ffffffff ffff0000c3e9a000 page dumped because: VM_BUG_ON_PAGE(((unsigned int) page_ref_count(page) + 127u <= 127u)) page->mem_cgroup:ffff0000c3e9a000 ------------[ cut here ]------------ kernel BUG at include/linux/mm.h:1212! Internal error: Oops - BUG: 0 [#1] SMP Modules linked in: BUG: Bad page state in process khugepaged pfn:84ef32 xfs(E) page:fffffe00201bcc80 refcount:0 mapcount:0 mapping:0 index:0x0 pfn:0x84ef32 libcrc32c(E) rfkill(E) aes_ce_blk(E) crypto_simd(E) ... CPU: 25 PID: 0 Comm: swapper/25 Kdump: loaded Tainted: ... pstate: 60400005 (nZCv daif +PAN -UAO -TCO BTYPE=--) Call trace: end_page_writeback+0x1c0/0x214 iomap_finish_page_writeback+0x13c/0x204 iomap_finish_ioend+0xe8/0x19c iomap_writepage_end_bio+0x38/0x50 bio_endio+0x168/0x1ec blk_update_request+0x278/0x3f0 blk_mq_end_request+0x34/0x15c virtblk_request_done+0x38/0x74 [virtio_blk] blk_done_softirq+0xc4/0x110 __do_softirq+0x128/0x38c __irq_exit_rcu+0x118/0x150 irq_exit+0x1c/0x30 __handle_domain_irq+0x8c/0xf0 gic_handle_irq+0x84/0x108 el1_irq+0xcc/0x180 arch_cpu_idle+0x18/0x40 default_idle_call+0x4c/0x1a0 cpuidle_idle_call+0x168/0x1e0 do_idle+0xb4/0x104 cpu_startup_entry+0x30/0x9c secondary_start_kernel+0x104/0x180 Code: d4210000 b0006161 910c8021 94013f4d (d4210000) ---[ end trace 4a88c6a074082f8c ]--- Kernel panic - not syncing: Oops - BUG: Fatal exception in interrupt
Patch / fix
- Linux Linux 5.10.77, 5.14.16, 5.15
- linux Debian 14, Debian 13, Debian 12 5.15.3-1
debian advisories DEBIAN-CVE-2021-47492
- kernel RHEL 8.6 TUS, RHEL 8.6 E4S, RHEL 8.6 AUS 4.18.0-372.123.1.el8_6
- perf RHEL 8.6 TUS, RHEL 8.6 E4S, RHEL 8.6 AUS 4.18.0-372.123.1.el8_6
- bpftool RHEL 8.6 TUS, RHEL 8.6 E4S, RHEL 8.6 AUS 4.18.0-372.123.1.el8_6
- kernel-core RHEL 8.6 TUS, RHEL 8.6 E4S, RHEL 8.6 AUS 4.18.0-372.123.1.el8_6
- kernel-tools RHEL 8.6 TUS, RHEL 8.6 E4S, RHEL 8.6 AUS 4.18.0-372.123.1.el8_6
- python3-perf RHEL 8.6 TUS, RHEL 8.6 E4S, RHEL 8.6 AUS 4.18.0-372.123.1.el8_6
- kernel-modules RHEL 8.6 TUS, RHEL 8.6 E4S, RHEL 8.6 AUS 4.18.0-372.123.1.el8_6
- kernel-zfcpdump RHEL 8.6 E4S 4.18.0-372.123.1.el8_6
red hat advisories RHSA-2024:6753
- kernel-rt SLE Micro 5.4, SLE Micro 5.3 5.14.21-150400.15.106.1
- kernel-source-rt SLE Micro 5.4, SLE Micro 5.3 5.14.21-150400.15.106.1
- dtb-aarch64 openSUSE Leap 15.5 5.14.21-150500.55.68.1
- kernel-64kb SLE Module for Basesystem 15 SP5, openSUSE Leap 15.5 5.14.21-150500.55.68.1
- kernel-syms SLE Module for Development Tools 15 SP5, openSUSE Leap 15.5 5.14.21-150500.55.68.1
- kernel-obs-qa openSUSE Leap 15.5 5.14.21-150500.55.68.1
- kernel-source SLE Module for Development Tools 15 SP5, SLE Module for Basesystem 15 SP5, openSUSE Leap 15.5 5.14.21-150500.55.68.1
- kernel-default SLE Workstation Extension 15 SP5, SLE Module for Legacy 15 SP5, SLE Module for Basesystem 15 SP5 +4 more 5.14.21-150500.55.68.1
suse advisories SUSE-SU-2025:0231-1SUSE-SU-2024:2190-1SUSE-SU-2024:2189-1SUSE-SU-2024:2019-1SUSE-SU-2024:2011-1SUSE-SU-2024:2008-1
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2021-47492 updated cvss 5.5
kernel: mm, thp: bail out early in collapse_file for writeback page
-
Red Hat Enterprise Linux 6 perf, kernel, python-perf, kernel-kdump, kernel-firmware, kernel-bootwrapper, +1 more Red Hat Enterprise Linux 7 perf, kernel, bpftool, kernel-rt, python-perf, kernel-kdump, +8 moreaffected: no fix planned “Out of support scope”
-
Red Hat Enterprise Linux 8 perf, kernel, bpftool, kernel-rt, kernel-core, kernel-tools, +29 moreaffected: no fix available
-
Red Hat Enterprise Linux BaseOS AUS (v.8.6) perf 4.18.0-372.123.1.el8_6, kernel 4.18.0-372.123.1.el8_6, bpftool 4.18.0-372.123.1.el8_6, kernel-core 4.18.0-372.123.1.el8_6, kernel-tools 4.18.0-372.123.1.el8_6, python3-perf 4.18.0-372.123.1.el8_6, +8 more Red Hat Enterprise Linux BaseOS E4S (v.8.6) perf 4.18.0-372.123.1.el8_6, kernel 4.18.0-372.123.1.el8_6, bpftool 4.18.0-372.123.1.el8_6, kernel-core 4.18.0-372.123.1.el8_6, kernel-tools 4.18.0-372.123.1.el8_6, python3-perf 4.18.0-372.123.1.el8_6, +15 more Red Hat Enterprise Linux BaseOS TUS (v.8.6) perf 4.18.0-372.123.1.el8_6, kernel 4.18.0-372.123.1.el8_6, bpftool 4.18.0-372.123.1.el8_6, kernel-core 4.18.0-372.123.1.el8_6, kernel-tools 4.18.0-372.123.1.el8_6, python3-perf 4.18.0-372.123.1.el8_6, +8 morefixed: vendor fix RHSA-2024:6753
-
Red Hat Enterprise Linux 9 rv, perf, rtla, kernel, bpftool, libperf, +83 morenot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- partial
- Assessed
- 2 y ago
Exploit prediction
0.22% chance of exploitation in the next 30 days, higher than 12% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 7.8 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVD | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Affected products
- Linux Linux
Classification
- Technology feeds
References
Sources
- CVE List CVE-2021-47492
- NVD CVE-2021-47492
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.