In the Linux kernel, the following vulnerability has been resolved:
spi: bcm2835: bcm2835spihandle_err(): fix NULL pointer deref for non DMA transfers
In case a IRQ based transfer times out the bcm2835spihandleerr() function is called. Since commit 1513ceee70f2 ("spi: bcm2835: Drop dmapending flag") the TX and RX DMA transfers are unconditionally canceled, leading to NULL pointer derefs if ctlr->dmatx or ctlr->dmarx are not set.
Fix the NULL pointer deref by checking that ctlr->dmatx and ctlr->dmarx are valid pointers before accessing them.