CVE-2024-56610
kcsan: Turn report_filterlist_lock into a raw_spinlock
Reported by linux · Published December 27, 2024
In the Linux kernel, the following vulnerability has been resolved: kcsan: Turn report_filterlist_lock into a raw_spinlock Ran Xiaokai reports that with a KCSAN-enabled PREEMPT_RT kernel, we can see splats like: | BUG: sleeping function called from invalid context at kernel/locking/spinlock_rt.c:48 | in_atomic(): 1, irqs_disabled(): 1, non_block: 0, pid: 0, name: swapper/1 | preempt_count: 10002, expected: 0 | RCU nest depth: 0, expected: 0 | no locks held by swapper/1/0. | irq event stamp: 156674 | hardirqs last enabled at (156673): [<ffffffff81130bd9>] do_idle+0x1f9/0x240 | hardirqs last disabled at (156674): [<ffffffff82254f84>] sysvec_apic_timer_interrupt+0x14/0xc0 | softirqs last enabled at (0): [<ffffffff81099f47>] copy_process+0xfc7/0x4b60 | softirqs last disabled at (0): [<0000000000000000>] 0x0 | Preemption disabled at: | [<ffffffff814a3e2a>] paint_ptr+0x2a/0x90 | CPU: 1 UID: 0 PID: 0 Comm: swapper/1 Not tainted 6.11.0+ #3 | Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.12.0-0-ga698c8995f-prebuilt.qemu.org 04/01/2014 | Call Trace: | <IRQ> | dump_stack_lvl+0x7e/0xc0 | dump_stack+0x1d/0x30 | __might_resched+0x1a2/0x270 | rt_spin_lock+0x68/0x170 | kcsan_skip_report_debugfs+0x43/0xe0 | print_report+0xb5/0x590 | kcsan_report_known_origin+0x1b1/0x1d0 | kcsan_setup_watchpoint+0x348/0x650 | __tsan_unaligned_write1+0x16d/0x1d0 | hrtimer_interrupt+0x3d6/0x430 | __sysvec_apic_timer_interrupt+0xe8/0x3a0 | sysvec_apic_timer_interrupt+0x97/0xc0 | </IRQ> On a detected data race, KCSAN's reporting logic checks if it should filter the report. That list is protected by the report_filterlist_lock *non-raw* spinlock which may sleep on RT kernels. Since KCSAN may report data races in any context, convert it to a raw_spinlock. This requires being careful about when to allocate memory for the filter list itself which can be done via KCSAN's debugfs interface. Concurrent modification of the filter list via debugfs should be rare: the chosen strategy is to optimistically pre-allocate memory before the critical section and discard if unused.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| kernel-libbpf-devel | Amazon Linux | 6.1.124-134.200.amzn2023 |
| Linux | Linux | f4f2ef66d288ea796ddb8ecbdc2df074ab2d5f4d, dca4e74a918586913d251c0b359e8cc96a3883ea, 0ab4951c1473c7d1ceaf1232eb927109cd1c4859 |
Affected products
| Vendor | Product | Versions |
|---|---|---|
| Linux | Linux | dfd402a4c4baae42398ce9180ff424d589b8bffc, dfd402a4c4baae42398ce9180ff424d589b8bffc, dfd402a4c4baae42398ce9180ff424d589b8bffc |
| Linux | Linux | 5.8, 0, 5.10.231 |
| amazon:2023 | kernel-libbpf-devel | 0 |
| Linux | Linux | *, *, * |
| amazon:2023 | kernel-livepatch-6.1.124-134.200 | 0 |
| amazon:2023 | kernel-devel | 0 |
| amazon:2023 | python3-perf | 0 |
| amazon:2023 | kernel-libbpf | 0 |
| amazon:2023 | kernel-headers | 0 |
| amazon:2023 | kernel | 0 |
| amazon:2023 | bpftool | 0 |
| linux | linux_kernel | 5.8, 5.8, 5.8 |
| amazon:2023 | kernel-modules-extra | 0 |
| amazon:2023 | kernel-modules-extra-common | 0 |
| amazon:2023 | perf | 0 |
| amazon:2023 | kernel-tools-devel | 0 |
| amazon:2023 | kernel-tools | 0 |
| amazon:2023 | kernel-libbpf-static | 0 |
Timeline
- Dec 27, 2024 CVE Published
- Dec 28, 2024 EPSS Score (30 in total, the first dated here)
- Mar 11, 2025 Coalition ESS Score (8 in total, the first dated here)
- Dec 16, 2025 PoC Published
- Dec 29, 2025 Security Advisory (438 in total, the first dated here)
- Apr 29, 2026 Distribution Patch (356 in total, the first dated here)
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2024-56610
vulnetix vdb fixes CVE-2024-56610
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2024-56610/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart