From db25c9e8fc8bda94399ec154687667216b89109f Mon Sep 17 00:00:00 2001 From: imi415 Date: Wed, 9 Mar 2022 12:37:02 +0800 Subject: [PATCH] Suppress compiler warnings. --- BSP/StdDriver/src/pdma.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/BSP/StdDriver/src/pdma.c b/BSP/StdDriver/src/pdma.c index 044b81a..a0e3ab5 100644 --- a/BSP/StdDriver/src/pdma.c +++ b/BSP/StdDriver/src/pdma.c @@ -156,9 +156,9 @@ void PDMA_SetTransferMode(uint32_t u32Ch, uint32_t u32Peripheral, uint32_t u32Sc if(u32Peripheral > PDMA_ADC) /* Memory-to-Memory */ pdma->CSR = (pdma->CSR & ~(PDMA_CSR_MODE_SEL_Msk)); else if(u32Peripheral > PDMA_I2S_TX) /* Peripheral-to-Memory */ - pdma->CSR = (pdma->CSR & ~(PDMA_CSR_MODE_SEL_Msk) | (0x1 << PDMA_CSR_MODE_SEL_Pos)); + pdma->CSR = ((pdma->CSR & ~(PDMA_CSR_MODE_SEL_Msk)) | (0x1 << PDMA_CSR_MODE_SEL_Pos)); else /* Memory-to-Peripheral */ - pdma->CSR = (pdma->CSR & ~(PDMA_CSR_MODE_SEL_Msk) | (0x2 << PDMA_CSR_MODE_SEL_Pos)); + pdma->CSR = ((pdma->CSR & ~(PDMA_CSR_MODE_SEL_Msk)) | (0x2 << PDMA_CSR_MODE_SEL_Pos)); switch(u32Peripheral) {