|
@@ -1661,12 +1661,12 @@ static int atmel_spi_remove(struct platform_device *pdev)
|
|
|
pm_runtime_get_sync(&pdev->dev);
|
|
|
|
|
|
/* reset the hardware and block queue progress */
|
|
|
- spin_lock_irq(&as->lock);
|
|
|
if (as->use_dma) {
|
|
|
atmel_spi_stop_dma(master);
|
|
|
atmel_spi_release_dma(master);
|
|
|
}
|
|
|
|
|
|
+ spin_lock_irq(&as->lock);
|
|
|
spi_writel(as, CR, SPI_BIT(SWRST));
|
|
|
spi_writel(as, CR, SPI_BIT(SWRST)); /* AT91SAM9263 Rev B workaround */
|
|
|
spi_readl(as, SR);
|