CVE-2025-22020 memstick: rtsx_usb_ms: Fix slab-use-after-free in rtsx_usb_ms_drv_remove
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- No known exploitation · automatable: no · technical impact: total
- Technology
- Linux KernelUbuntuDebianCloud Platforms
Description
In the Linux kernel, the following vulnerability has been resolved:
memstick: rtsx_usb_ms: Fix slab-use-after-free in rtsx_usb_ms_drv_remove
This fixes the following crash:
==================================================================
BUG: KASAN: slab-use-after-free in rtsx_usb_ms_poll_card+0x159/0x200 [rtsx_usb_ms]
Read of size 8 at addr ffff888136335380 by task kworker/6:0/140241
CPU: 6 UID: 0 PID: 140241 Comm: kworker/6:0 Kdump: loaded Tainted: G E 6.14.0-rc6+ #1
Tainted: [E]=UNSIGNED_MODULE
Hardware name: LENOVO 30FNA1V7CW/1057, BIOS S0EKT54A 07/01/2024
Workqueue: events rtsx_usb_ms_poll_card [rtsx_usb_ms]
Call Trace:
<TASK>
dump_stack_lvl+0x51/0x70
print_address_description.constprop.0+0x27/0x320
? rtsx_usb_ms_poll_card+0x159/0x200 [rtsx_usb_ms]
print_report+0x3e/0x70
kasan_report+0xab/0xe0
? rtsx_usb_ms_poll_card+0x159/0x200 [rtsx_usb_ms]
rtsx_usb_ms_poll_card+0x159/0x200 [rtsx_usb_ms]
? __pfx_rtsx_usb_ms_poll_card+0x10/0x10 [rtsx_usb_ms]
? __pfx___schedule+0x10/0x10
? kick_pool+0x3b/0x270
process_one_work+0x357/0x660
worker_thread+0x390/0x4c0
? __pfx_worker_thread+0x10/0x10
kthread+0x190/0x1d0
? __pfx_kthread+0x10/0x10
ret_from_fork+0x2d/0x50
? __pfx_kthread+0x10/0x10
ret_from_fork_asm+0x1a/0x30
</TASK>
Allocated by task 161446:
kasan_save_stack+0x20/0x40
kasan_save_track+0x10/0x30
__kasan_kmalloc+0x7b/0x90
__kmalloc_noprof+0x1a7/0x470
memstick_alloc_host+0x1f/0xe0 [memstick]
rtsx_usb_ms_drv_probe+0x47/0x320 [rtsx_usb_ms]
platform_probe+0x60/0xe0
call_driver_probe+0x35/0x120
really_probe+0x123/0x410
__driver_probe_device+0xc7/0x1e0
driver_probe_device+0x49/0xf0
__device_attach_driver+0xc6/0x160
bus_for_each_drv+0xe4/0x160
__device_attach+0x13a/0x2b0
bus_probe_device+0xbd/0xd0
device_add+0x4a5/0x760
platform_device_add+0x189/0x370
mfd_add_device+0x587/0x5e0
mfd_add_devices+0xb1/0x130
rtsx_usb_probe+0x28e/0x2e0 [rtsx_usb]
usb_probe_interface+0x15c/0x460
call_driver_probe+0x35/0x120
really_probe+0x123/0x410
__driver_probe_device+0xc7/0x1e0
driver_probe_device+0x49/0xf0
__device_attach_driver+0xc6/0x160
bus_for_each_drv+0xe4/0x160
__device_attach+0x13a/0x2b0
rebind_marked_interfaces.isra.0+0xcc/0x110
usb_reset_device+0x352/0x410
usbdev_do_ioctl+0xe5c/0x1860
usbdev_ioctl+0xa/0x20
__x64_sys_ioctl+0xc5/0xf0
do_syscall_64+0x59/0x170
entry_SYSCALL_64_after_hwframe+0x76/0x7e
Freed by task 161506:
kasan_save_stack+0x20/0x40
kasan_save_track+0x10/0x30
kasan_save_free_info+0x36/0x60
__kasan_slab_free+0x34/0x50
kfree+0x1fd/0x3b0
device_release+0x56/0xf0
kobject_cleanup+0x73/0x1c0
rtsx_usb_ms_drv_remove+0x13d/0x220 [rtsx_usb_ms]
platform_remove+0x2f/0x50
device_release_driver_internal+0x24b/0x2e0
bus_remove_device+0x124/0x1d0
device_del+0x239/0x530
platform_device_del.part.0+0x19/0xe0
platform_device_unregister+0x1c/0x40
mfd_remove_devices_fn+0x167/0x170
device_for_each_child_reverse+0xc9/0x130
mfd_remove_devices+0x6e/0xa0
rtsx_usb_disconnect+0x2e/0xd0 [rtsx_usb]
usb_unbind_interface+0xf3/0x3f0
device_release_driver_internal+0x24b/0x2e0
proc_disconnect_claim+0x13d/0x220
usbdev_do_ioctl+0xb5e/0x1860
usbdev_ioctl+0xa/0x20
__x64_sys_ioctl+0xc5/0xf0
do_syscall_64+0x59/0x170
entry_SYSCALL_64_after_hwframe+0x76/0x7e
Last potentially related work creation:
kasan_save_stack+0x20/0x40
kasan_record_aux_stack+0x85/0x90
insert_work+0x29/0x100
__queue_work+0x34a/0x540
call_timer_fn+0x2a/0x160
expire_timers+0x5f/0x1f0
__run_timer_base.part.0+0x1b6/0x1e0
run_timer_softirq+0x8b/0xe0
handle_softirqs+0xf9/0x360
__irq_exit_rcu+0x114/0x130
sysvec_apic_timer_interrupt+0x72/0x90
asm_sysvec_apic_timer_interrupt+0x16/0x20
Second to last potentially related work creation:
kasan_save_stack+0x20/0x40
kasan_record_aux_stack+0x85/0x90
insert_work+0x29/0x100
__queue_work+0x34a/0x540
call_timer_fn+0x2a/0x160
expire_timers+0x5f/0x1f0
__run_timer_base.part.0+0x1b6/0x1e0
run_timer_softirq+0x8b/0xe0
handle_softirqs+0xf9/0x
---truncated---
Upgrade path
10 packages: 10 fixed.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| debian/linux(Debian 12) | < 6.1.133-1; = 6.1.27-1; = 6.1.37-1; = 6.1.38-1 +33 more | 6.1.133-1 | Fixed |
| debian/linux(Debian 13) | < 6.12.22-1 | 6.12.22-1 | Fixed |
| debian/linux(Debian 14) | < 6.12.22-1 | 6.12.22-1 | Fixed |
| Linux kernel | < 5.4.292; < 5.10.236; < 5.15.180; < 6.1.133 +23 more | 5.4.292, 5.10.236, 5.15.180, 6.1.133, 6.6.86, 6.12.22, 6.13.10, 6.14.1, 6.15, 9dfaf4d723c62bda8d9d1340e2e78acf0c190439, 31f0eaed6914333f42501fc7e0f6830879f5ef2d, 52d942a5302eefb3b7a3bfee310a5a33feeedc21, 0067cb7d7e7c277e91a0887a3c24e71462379469, 914c5e5bfceb9878f3056eaf4d1c88f2cbe0a185, 6186fb2cd36317277a8423687982140a7f3f7841, 75123adf204f997e11bbddee48408c284f51c050, 4676741a3464b300b486e70585c3c9b692be1632, b094e8e3988e02e8cef7a756c8d2cea9c12509ab | Fixed |
| Microsoft azure linux | < 6.6.92.2-1 | 6.6.92.2-1 | Fixed |
| ubuntu/linux(Ubuntu 22.04) | < 5.15.0-142.152 | 5.15.0-142.152 | Fixed |
| ubuntu/linux(Ubuntu 24.04) | < 6.8.0-86.87 | 6.8.0-86.87 | Fixed |
| ubuntu/linux-kvm(Ubuntu 22.04) | < 5.15.0-1082.87 | 5.15.0-1082.87 | Fixed |
| ubuntu/linux-raspi(Ubuntu 22.04) | < 5.15.0-1080.83 | 5.15.0-1080.83 | Fixed |
| ubuntu/linux-raspi(Ubuntu 24.04) | < 6.8.0-1041.45 | 6.8.0-1041.45 | Fixed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| Microsoft azure linux | < 6.6.92.2-1 | 6.6.92.2-1 |
| debian/linux(Debian:12) | < 6.1.133-1 | 6.1.133-1 |
| debian/linux(Debian:12) | = 6.1.106-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.106-2 | No fix listed |
| debian/linux(Debian:12) | = 6.1.106-3 | No fix listed |
| debian/linux(Debian:12) | = 6.1.112-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.115-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.119-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.123-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.124-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.128-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.129-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.27-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.37-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-2 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-2~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-3 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-4 | No fix listed |
| debian/linux(Debian:12) | = 6.1.38-4~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.52-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.55-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.55-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.64-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.66-1 | No fix listed |
Show 47 more
| Product | Affected versions | Fixed in |
|---|---|---|
| debian/linux(Debian:12) | = 6.1.67-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.69-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.69-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.76-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.76-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.82-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.85-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.90-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.90-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.94-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.94-1~bpo11+1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.98-1 | No fix listed |
| debian/linux(Debian:12) | = 6.1.99-1 | No fix listed |
| debian/linux(Debian:13) | < 6.12.22-1 | 6.12.22-1 |
| debian/linux(Debian:14) | < 6.12.22-1 | 6.12.22-1 |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 914c5e5bfceb9878f3056eaf4d1c88f2cbe0a185 | 914c5e5bfceb9878f3056eaf4d1c88f2cbe0a185 |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 9dfaf4d723c62bda8d9d1340e2e78acf0c190439 | 9dfaf4d723c62bda8d9d1340e2e78acf0c190439 |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 31f0eaed6914333f42501fc7e0f6830879f5ef2d | 31f0eaed6914333f42501fc7e0f6830879f5ef2d |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 52d942a5302eefb3b7a3bfee310a5a33feeedc21 | 52d942a5302eefb3b7a3bfee310a5a33feeedc21 |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 6186fb2cd36317277a8423687982140a7f3f7841 | 6186fb2cd36317277a8423687982140a7f3f7841 |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < b094e8e3988e02e8cef7a756c8d2cea9c12509ab | b094e8e3988e02e8cef7a756c8d2cea9c12509ab |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 0067cb7d7e7c277e91a0887a3c24e71462379469 | 0067cb7d7e7c277e91a0887a3c24e71462379469 |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 75123adf204f997e11bbddee48408c284f51c050 | 75123adf204f997e11bbddee48408c284f51c050 |
| Linux kernel | >= 6827ca573c03385439fdfc8b512d556dc7c54fc9, < 4676741a3464b300b486e70585c3c9b692be1632 | 4676741a3464b300b486e70585c3c9b692be1632 |
| Linux kernel | = 5.0 | No fix listed |
| Linux kernel | < 5.4.292 | 5.4.292 |
| Linux kernel | < 5.10.236 | 5.10.236 |
| Linux kernel | < 5.15.180 | 5.15.180 |
| Linux kernel | < 6.1.133 | 6.1.133 |
| Linux kernel | < 6.6.86 | 6.6.86 |
| Linux kernel | < 6.12.22 | 6.12.22 |
| Linux kernel | < 6.13.10 | 6.13.10 |
| Linux kernel | < 6.14.1 | 6.14.1 |
| Linux kernel | < 6.15 | 6.15 |
| ubuntu/linux(Ubuntu:22.04) | < 5.15.0-142.152 | 5.15.0-142.152 |
| ubuntu/linux-kvm(Ubuntu:22.04) | < 5.15.0-1082.87 | 5.15.0-1082.87 |
| ubuntu/linux-raspi(Ubuntu:22.04) | < 5.15.0-1080.83 | 5.15.0-1080.83 |
| ubuntu/linux(Ubuntu:24.04) | < 6.8.0-86.87 | 6.8.0-86.87 |
| ubuntu/linux-raspi(Ubuntu:24.04) | < 6.8.0-1041.45 | 6.8.0-1041.45 |
| Linux kernel | >= 5.0, < 5.4.292 | 5.4.292 |
| Linux kernel | >= 5.5, < 5.10.236 | 5.10.236 |
| Linux kernel | >= 5.11, < 5.15.180 | 5.15.180 |
| Linux kernel | >= 5.16, < 6.1.133 | 6.1.133 |
| Linux kernel | >= 6.2, < 6.6.86 | 6.6.86 |
| Linux kernel | >= 6.7, < 6.12.22 | 6.12.22 |
| Linux kernel | >= 6.13, < 6.13.10 | 6.13.10 |
| Linux kernel | >= 6.14, < 6.14.1 | 6.14.1 |
References
- MSRC Security Update Guide vendor-advisory
- kernel vendor-advisory
- Debian Security Tracker CVE-2025-22020 vendor-advisory
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- git.kernel.org patch
- lists.debian.org
- lists.debian.org
- Ubuntu CVE tracker vendor-advisory
- USN-7585-1 vendor-advisory
- USN-7585-2 vendor-advisory
- USN-7591-1 vendor-advisory
- USN-7591-2 vendor-advisory
- USN-7591-3 vendor-advisory
- USN-7592-1 vendor-advisory
- USN-7593-1 vendor-advisory
- USN-7594-1 vendor-advisory
- USN-7591-4 vendor-advisory
- USN-7597-1 vendor-advisory
- USN-7597-2 vendor-advisory
- USN-7598-1 vendor-advisory
- USN-7585-3 vendor-advisory
- USN-7585-4 vendor-advisory
- USN-7594-2 vendor-advisory
- USN-7602-1 vendor-advisory
- USN-7585-5 vendor-advisory
- USN-7605-1 vendor-advisory
- USN-7606-1 vendor-advisory
- USN-7585-6 vendor-advisory
- USN-7591-5 vendor-advisory
- USN-7605-2 vendor-advisory
- USN-7594-3 vendor-advisory
- USN-7628-1 vendor-advisory
- USN-7585-7 vendor-advisory
- USN-7640-1 vendor-advisory
- USN-7591-6 vendor-advisory
- USN-7655-1 vendor-advisory
- USN-7835-1 vendor-advisory
- USN-7835-2 vendor-advisory
- USN-7835-3 vendor-advisory
- USN-7835-4 vendor-advisory
- USN-7835-5 vendor-advisory
- USN-7835-6 vendor-advisory
- USN-7887-1 vendor-advisory
- USN-7887-2 vendor-advisory
- USN-7940-1 vendor-advisory
- USN-7940-2 vendor-advisory
- www.cve.org
- ENISA EUVD EUVD-2025-11365 third-party-advisory