dibs: initialise dibs->lock in dibs_dev_alloc()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
6.18.457.1.97.2In the Linux kernel, the following vulnerability has been resolved:
dibs: initialise dibs->lock in dibs_dev_alloc()
dibs->lock is initialised by dibs_dev_add(), but a dibs device can already take interrupts before that call: ism_probe() runs ism_dev_init(), and hence request_irq(), before it calls dibs_dev_add(). No client can have registered a dmb at that point, so no dmb interrupt can occur, but a GID event interrupt can, and ism_handle_irq() takes dibs->lock unconditionally on entry, before it inspects anything else.
Initialise the lock in dibs_dev_alloc() instead, so that it is valid as soon as a driver can publish the device to its interrupt handler.
From the CVE record · Linux
The Linux kernel initializes dibs->lock too late: a GID event interrupt can reach ism_handle_irq() during device setup, before the lock is initialized. The input does not establish whether an attacker can trigger the interrupt, or specify network, authentication, or user-interaction requirements.
Engineers running Linux kernels with dibs and ism device support should check their versions; affected versions are not specified.