usb: renesas_usbhs: fix use-after-free in ISR during device removal
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ f1407d5c66240b33d11a7f1a41d55ccf6a9d7647 · < 0b7d11fd6e742ecc0b1eca44b4f0b93140c74bae| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
usb: renesas_usbhs: fix use-after-free in ISR during device removal
In usbhs_remove(), the driver frees resources (including the pipe array) while the interrupt handler (usbhs_interrupt) is still registered. If an interrupt fires after usbhs_pipe_remove() but before the driver is fully unbound, the ISR may access freed memory, causing a use-after-free.
Fix this by calling devm_free_irq() before freeing resources. This ensures the interrupt handler is both disabled and synchronized (waits for any running ISR to complete) before usbhs_pipe_remove() is called.
From the CVE record · Linux
The Linux kernel's renesas_usbhs driver can access freed memory if an interrupt fires while the device is being removed. The input does not establish whether an attacker can trigger this condition or whether access or user interaction is required.
Engineers running Linux kernels with the renesas_usbhs driver should check their kernel versions; affected versions were not provided.