CVE-2026-138840: mailbox: qcom-ipcc: Guard against NULL con_priv in send_data()
In the Linux kernel, the following vulnerability has been resolved:
mailbox: qcom-ipcc: Guard against NULL conpriv in senddata()
qcomipccmboxshutdown() clears chan->conpriv with no locking. qcomipccmboxsenddata() dereferences the same field without checking for NULL first, so a send racing a concurrent shutdown can crash:
mchan = chan->conpriv; ... hwirq = qcomipccgethwirq(mchan->clientid, mchan->signalid);
Add the same NULL guard mboxsendmessage() already uses for chan->cl, and bail out before dereferencing a cleared conpriv.
To close the remaining race where senddata() reads conpriv a moment before a concurrent shutdown clears it, acquire the spinlock in qcomipccmboxshutdown() using the modern guard(spinlockirqsave) primitive before setting conpriv to NULL.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In qcom_ipcc_mbox_send_data(), acquire chan->cl with guard(spinlock_irqsave), check chan->con_priv for NULL, and bail out before dereferencing it.
Event History
Frequently Asked Questions
What conditions are required to trigger the crash?
A send operation must race with a concurrent mailbox shutdown on the same channel. The shutdown clears chan->con_priv while send_data() may dereference it, causing a NULL-pointer crash.
What is the impact if the race occurs?
The kernel can crash when send_data() dereferences the cleared con_priv field. The provided information describes a denial-of-service condition; it does not establish privilege escalation or code execution.
How does the fix address the race?
The fix checks whether con_priv is NULL before dereferencing it and exits if it has been cleared. It also takes the channel spinlock during shutdown before clearing con_priv, preventing the remaining race with a send that has already begun reading the field.