xiaoxiang781216 commented on code in PR #7472:
URL: https://github.com/apache/incubator-nuttx/pull/7472#discussion_r1016100505


##########
arch/arm/src/cxd56xx/cxd56_spi.c:
##########
@@ -1204,7 +1217,6 @@ struct spi_dev_s *cxd56_spibus_initialize(int port)
   /* DMA settings */
 
 #ifdef CONFIG_CXD56_DMAC
-  priv->dmaenable = false;

Review Comment:
   reply 
https://github.com/apache/incubator-nuttx/pull/7472#discussion_r1016100185



##########
arch/arm/src/cxd56xx/cxd56_spi.c:
##########
@@ -1328,25 +1336,13 @@ void cxd56_spi_dmaconfig(int port, int chtype, 
DMA_HANDLE handle,
 
           priv->txdmach = handle;
           memcpy(&priv->txconfig, conf, sizeof(dma_config_t));
-
-          if (!priv->dmaenable)
-            {
-              nxsem_init(&priv->dmasem, 0, 0);
-              priv->dmaenable = true;
-            }
         }

Review Comment:
   ditto



##########
arch/arm/src/cxd56xx/cxd56_spi.c:
##########
@@ -1328,25 +1336,13 @@ void cxd56_spi_dmaconfig(int port, int chtype, 
DMA_HANDLE handle,
 
           priv->txdmach = handle;
           memcpy(&priv->txconfig, conf, sizeof(dma_config_t));
-
-          if (!priv->dmaenable)
-            {
-              nxsem_init(&priv->dmasem, 0, 0);
-              priv->dmaenable = true;
-            }
         }
       else if ((chtype == CXD56_SPI_DMAC_CHTYPE_RX) && (!priv->rxdmach))
         {
           /* RX DMA setting */
 
           priv->rxdmach = handle;
           memcpy(&priv->rxconfig, conf, sizeof(dma_config_t));
-
-          if (!priv->dmaenable)
-            {
-              nxsem_init(&priv->dmasem, 0, 0);
-              priv->dmaenable = true;
-            }
         }

Review Comment:
   ditto



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to