summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-stm32-qspi.c
diff options
context:
space:
mode:
authorLudovic Barre <ludovic.barre@st.com>2019-06-27 09:43:59 +0200
committerMark Brown <broonie@kernel.org>2019-06-28 15:25:40 +0100
commit775c4c0032c408b8a57a3fc2695eeda101da003a (patch)
treece1e935899c705bb35a2bb8b8b1fb31cfe1e6a3e /drivers/spi/spi-stm32-qspi.c
parentcae86eac98cd90934f94072028c362550338e084 (diff)
downloadlinux-775c4c0032c408b8a57a3fc2695eeda101da003a.tar.bz2
spi: stm32-qspi: remove signal sensitive on completion
On umount step a sigkill signal is set (without user specific action), due to sigkill signal the completion will be interrupted and the data transfer can't be finished if a sync is needed. Signed-off-by: Ludovic Barre <ludovic.barre@st.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi-stm32-qspi.c')
-rw-r--r--drivers/spi/spi-stm32-qspi.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/spi/spi-stm32-qspi.c b/drivers/spi/spi-stm32-qspi.c
index 42f8e3c6aa1f..0b07182f5660 100644
--- a/drivers/spi/spi-stm32-qspi.c
+++ b/drivers/spi/spi-stm32-qspi.c
@@ -245,12 +245,8 @@ static int stm32_qspi_tx_dma(struct stm32_qspi *qspi,
writel_relaxed(cr | CR_DMAEN, qspi->io_base + QSPI_CR);
t_out = sgt.nents * STM32_COMP_TIMEOUT_MS;
- if (!wait_for_completion_interruptible_timeout(&qspi->dma_completion,
- msecs_to_jiffies(t_out)))
- err = -ETIMEDOUT;
-
- if (dma_async_is_tx_complete(dma_ch, cookie,
- NULL, NULL) != DMA_COMPLETE)
+ if (!wait_for_completion_timeout(&qspi->dma_completion,
+ msecs_to_jiffies(t_out)))
err = -ETIMEDOUT;
if (err)
@@ -304,7 +300,7 @@ static int stm32_qspi_wait_cmd(struct stm32_qspi *qspi,
cr = readl_relaxed(qspi->io_base + QSPI_CR);
writel_relaxed(cr | CR_TCIE | CR_TEIE, qspi->io_base + QSPI_CR);
- if (!wait_for_completion_interruptible_timeout(&qspi->data_completion,
+ if (!wait_for_completion_timeout(&qspi->data_completion,
msecs_to_jiffies(STM32_COMP_TIMEOUT_MS))) {
err = -ETIMEDOUT;
} else {