SPRAD26 April   2022 TDA4VM

 

  1.   Trademarks
  2. 1SPI: Serial Peripheral Interface
  3. 2J7200/J721e MCSPI Support
    1. 2.1 MCSPI Features
  4. 3SPI: Master Mode Enabling and Validation on Linux
    1. 3.1 Enable SPI Instances of J721e/TDA4VM
    2. 3.2 Enable SPIDEV on TD4VM SDK
    3. 3.3 Exercise SPI From User Space on TI J7/TDA4x Using Standard Linux spidev_test Tool
  5. 4SPI: Slave Mode Enabling and Validation on Linux
    1. 4.1 Enable SPI Instances of J7200
    2. 4.2 Enable DMA for MCSPI4 Slave Node
    3. 4.3 Enable SPIDEV and SPI_SLAVE Configs
    4. 4.4 Test SPI Slave Functionality From User Space on TI J7200 Using Standard Linux spidev_test Tool
    5. 4.5 SPI Slave Testing Using spi-slave-time
    6. 4.6 Linux SPI Slave Challenges
    7. 4.7 Linux SPI Slave Mode General Limitations
    8. 4.8 McSPI SPI Slave Mode Limitations
  6. 5References

Linux SPI Slave Mode General Limitations

  • SPI slave controller processes one request at a time. No batch processing of requests
  • Linux slave cannot respond in real time
  • No flow control or protocol negotiation support
  • No support for multiple outstanding DMA request in SPI slave(and master) framework
  • Userspace stack running on master and slave needs to implement and agree on certain protocol
    • Slave RX: Slave needs to know in advance how much data to receive and when
    • Slave TX: Slave needs to be ready with data and queue DMA before Master starts clock

Kernel does not take care of meeting above requirements, its up to protocol drivers at users pace to make sure above conditions are met.