You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/03/29 16:41:12 UTC

[GitHub] [incubator-nuttx] gustavonihei opened a new pull request #3233: ESP32: Bugfixes and Improvements for SPI DMA Exchange function

gustavonihei opened a new pull request #3233:
URL: https://github.com/apache/incubator-nuttx/pull/3233


   ## Summary
   This PR intends to address two issues and bring two small improvements to the ESP32 SPI driver:
   
   **Bugfixes**:
   1) For SPI SNDBLOCK operations, RX Buffer will be NULL. Currently, every loop unconditionally increments the RX buffer pointer by 4, even when it is `NULL`. For some reason (probably compiler optimizations) the `if (rp)` condition is never satisfied, so I couldn't actually reproduce this issue.
   2) On `esp32_spi_dma_exchange`, MISO/MOSI data length fields were being configured with the total number of remaining bytes instead of the number of bytes actually bound to DMA descriptors. While it didn't cause any issue, this could induce a wrong operation of the DMA engine.
   
   **Improvements**:
   1) Remove the check for a pointer that is guaranteed to be valid, assuming that the TX buffer of a SPI DMA exchange will always be non-NULL.
   2) In order to avoid consistency issues during Mixed mode, the `esp32_spi_setbits` configuration will be commited before the transaction operation.
   
   ## Impact
   Impact to SPI peripherals on ESP32.
   
   ## Testing
   Tested with `ESP-WROVER-KIT` board.
   


-- 
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.

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



[GitHub] [incubator-nuttx] xiaoxiang781216 merged pull request #3233: ESP32: Bugfixes and Improvements for SPI DMA Exchange function

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 merged pull request #3233:
URL: https://github.com/apache/incubator-nuttx/pull/3233


   


-- 
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.

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