|
@@ -184,6 +184,11 @@ static irqreturn_t bcm2835aux_spi_interrupt(int irq, void *dev_id)
|
|
|
struct bcm2835aux_spi *bs = spi_master_get_devdata(master);
|
|
|
irqreturn_t ret = IRQ_NONE;
|
|
|
|
|
|
+ /* IRQ may be shared, so return if our interrupts are disabled */
|
|
|
+ if (!(bcm2835aux_rd(bs, BCM2835_AUX_SPI_CNTL1) &
|
|
|
+ (BCM2835_AUX_SPI_CNTL1_TXEMPTY | BCM2835_AUX_SPI_CNTL1_IDLE)))
|
|
|
+ return ret;
|
|
|
+
|
|
|
/* check if we have data to read */
|
|
|
while (bs->rx_len &&
|
|
|
(!(bcm2835aux_rd(bs, BCM2835_AUX_SPI_STAT) &
|