CVE-2023-54288
Gravedad:
Pendiente de análisis
Tipo:
No Disponible / Otro tipo
Fecha de publicación:
30/12/2025
Última modificación:
30/12/2025
Descripción
*** Pendiente de traducción *** In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
wifi: mac80211: fortify the spinlock against deadlock by interrupt<br />
<br />
In the function ieee80211_tx_dequeue() there is a particular locking<br />
sequence:<br />
<br />
begin:<br />
spin_lock(&local->queue_stop_reason_lock);<br />
q_stopped = local->queue_stop_reasons[q];<br />
spin_unlock(&local->queue_stop_reason_lock);<br />
<br />
However small the chance (increased by ftracetest), an asynchronous<br />
interrupt can occur in between of spin_lock() and spin_unlock(),<br />
and the interrupt routine will attempt to lock the same<br />
&local->queue_stop_reason_lock again.<br />
<br />
This will cause a costly reset of the CPU and the wifi device or an<br />
altogether hang in the single CPU and single core scenario.<br />
<br />
The only remaining spin_lock(&local->queue_stop_reason_lock) that<br />
did not disable interrupts was patched, which should prevent any<br />
deadlocks on the same CPU/core and the same wifi device.<br />
<br />
This is the probable trace of the deadlock:<br />
<br />
kernel: ================================<br />
kernel: WARNING: inconsistent lock state<br />
kernel: 6.3.0-rc6-mt-20230401-00001-gf86822a1170f #4 Tainted: G W<br />
kernel: --------------------------------<br />
kernel: inconsistent {IN-SOFTIRQ-W} -> {SOFTIRQ-ON-W} usage.<br />
kernel: kworker/5:0/25656 [HC0[0]:SC0[0]:HE1:SE1] takes:<br />
kernel: ffff9d6190779478 (&local->queue_stop_reason_lock){+.?.}-{2:2}, at: return_to_handler+0x0/0x40<br />
kernel: {IN-SOFTIRQ-W} state was registered at:<br />
kernel: lock_acquire+0xc7/0x2d0<br />
kernel: _raw_spin_lock+0x36/0x50<br />
kernel: ieee80211_tx_dequeue+0xb4/0x1330 [mac80211]<br />
kernel: iwl_mvm_mac_itxq_xmit+0xae/0x210 [iwlmvm]<br />
kernel: iwl_mvm_mac_wake_tx_queue+0x2d/0xd0 [iwlmvm]<br />
kernel: ieee80211_queue_skb+0x450/0x730 [mac80211]<br />
kernel: __ieee80211_xmit_fast.constprop.66+0x834/0xa50 [mac80211]<br />
kernel: __ieee80211_subif_start_xmit+0x217/0x530 [mac80211]<br />
kernel: ieee80211_subif_start_xmit+0x60/0x580 [mac80211]<br />
kernel: dev_hard_start_xmit+0xb5/0x260<br />
kernel: __dev_queue_xmit+0xdbe/0x1200<br />
kernel: neigh_resolve_output+0x166/0x260<br />
kernel: ip_finish_output2+0x216/0xb80<br />
kernel: __ip_finish_output+0x2a4/0x4d0<br />
kernel: ip_finish_output+0x2d/0xd0<br />
kernel: ip_output+0x82/0x2b0<br />
kernel: ip_local_out+0xec/0x110<br />
kernel: igmpv3_sendpack+0x5c/0x90<br />
kernel: igmp_ifc_timer_expire+0x26e/0x4e0<br />
kernel: call_timer_fn+0xa5/0x230<br />
kernel: run_timer_softirq+0x27f/0x550<br />
kernel: __do_softirq+0xb4/0x3a4<br />
kernel: irq_exit_rcu+0x9b/0xc0<br />
kernel: sysvec_apic_timer_interrupt+0x80/0xa0<br />
kernel: asm_sysvec_apic_timer_interrupt+0x1f/0x30<br />
kernel: _raw_spin_unlock_irqrestore+0x3f/0x70<br />
kernel: free_to_partial_list+0x3d6/0x590<br />
kernel: __slab_free+0x1b7/0x310<br />
kernel: kmem_cache_free+0x52d/0x550<br />
kernel: putname+0x5d/0x70<br />
kernel: do_sys_openat2+0x1d7/0x310<br />
kernel: do_sys_open+0x51/0x80<br />
kernel: __x64_sys_openat+0x24/0x30<br />
kernel: do_syscall_64+0x5c/0x90<br />
kernel: entry_SYSCALL_64_after_hwframe+0x72/0xdc<br />
kernel: irq event stamp: 5120729<br />
kernel: hardirqs last enabled at (5120729): [] trace_graph_return+0xd6/0x120<br />
kernel: hardirqs last disabled at (5120728): [] trace_graph_return+0xf0/0x120<br />
kernel: softirqs last enabled at (5069900): [] return_to_handler+0x0/0x40<br />
kernel: softirqs last disabled at (5067555): [] return_to_handler+0x0/0x40<br />
kernel:<br />
other info that might help us debug this:<br />
kernel: Possible unsafe locking scenario:<br />
kernel: CPU0<br />
kernel: ----<br />
kernel: lock(&local->queue_stop_reason_lock);<br />
kernel: <br />
kernel: lock(&local->queue_stop_reason_lock);<br />
kernel:<br />
*** DEADLOCK ***<br />
kernel: 8 locks held by kworker/5:0/25656:<br />
kernel: #0: ffff9d618009d138 ((wq_completion)events_freezable){+.+.}-{0:0}, at: process_one_work+0x1ca/0x530<br />
kernel: #1: ffffb1ef4637fe68 ((work_completion)(&local->restart_work)){+.+.}-{0:0}, at: process_one_work+0x1ce/0x530<br />
kernel: #2: ffffffff9f166548 (rtnl_mutex){+.+.}-{3:3}, at: return_to_handler+0x0/0x40<br />
kernel: #3: ffff9d619<br />
---truncated---



