You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ag...@apache.org on 2020/05/15 22:11:50 UTC
[incubator-nuttx] 07/07: arch/arm/src/stm32h7/stm32_sdmmc.c: Fix
wrong selection in modifying the conflict.
This is an automated email from the ASF dual-hosted git repository.
aguettouche pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit e6a984dc2b40b8fd96195b5c90e2305561a65e4c
Author: Gregory Nutt <gn...@nuttx.org>
AuthorDate: Fri May 15 15:40:39 2020 -0600
arch/arm/src/stm32h7/stm32_sdmmc.c: Fix wrong selection in modifying the conflict.
---
arch/arm/src/stm32h7/stm32_sdmmc.c | 21 +++++----------------
1 file changed, 5 insertions(+), 16 deletions(-)
diff --git a/arch/arm/src/stm32h7/stm32_sdmmc.c b/arch/arm/src/stm32h7/stm32_sdmmc.c
index 93af586..4c087ab 100644
--- a/arch/arm/src/stm32h7/stm32_sdmmc.c
+++ b/arch/arm/src/stm32h7/stm32_sdmmc.c
@@ -1526,17 +1526,6 @@ static void stm32_endtransfer(struct stm32_dev_s *priv,
sdmmc_putreg32(priv, STM32_SDMMC_XFRDONE_ICR, STM32_SDMMC_ICR_OFFSET);
-#if defined(CONFIG_STM32H7_SDMMC_IDMA) && \
- !defined(CONFIG_ARCH_HAVE_SDIO_DELAYED_INVLDT)
- /* invalidate dcache in case of DMA receive. */
-
- if (priv->receivecnt)
- {
- up_invalidate_dcache((uintptr_t)priv->buffer,
- (uintptr_t)priv->buffer + priv->remaining);
- }
-#endif
-
/* DMA debug instrumentation */
stm32_sample(priv, SAMPLENDX_END_TRANSFER);
@@ -1748,7 +1737,7 @@ static int stm32_sdmmc_interrupt(int irq, void *context, void *arg)
*/
mcerr("ERROR: Data block CRC failure, remaining: %d\n",
- priv->remaining);
+ priv->remaining);
stm32_endtransfer(priv,
SDIOWAIT_TRANSFERDONE | SDIOWAIT_ERROR);
@@ -3081,8 +3070,8 @@ static int stm32_dmapreflight(FAR struct sdio_dev_s *dev,
(uintptr_t)buffer + buflen <= SRAM4_END))
{
mcerr("invalid IDMA address "
- "buffer:0x%08x end:0x%08x\n",
- buffer, buffer + buflen - 1);
+ "buffer:0x%08x end:0x%08x\n",
+ buffer, buffer + buflen - 1);
return -EFAULT;
}
}
@@ -3101,8 +3090,8 @@ static int stm32_dmapreflight(FAR struct sdio_dev_s *dev,
((uintptr_t)(buffer + buflen) & (ARMV7M_DCACHE_LINESIZE - 1)) != 0))
{
mcerr("dcache unaligned "
- "buffer:0x%08x end:0x%08x\n",
- buffer, buffer + buflen - 1);
+ "buffer:0x%08x end:0x%08x\n",
+ buffer, buffer + buflen - 1);
return -EFAULT;
}
# endif