1.5. DMA Operation Flow
- Software allocates free memory space in the system memory to populate the descriptor table.
- Software allocates free space in the system memory for the data to be moved to and from the system memory by the DMA.
- Software writes all descriptors into the descriptor table in the system memory. The DMA supports up to 128 descriptors. Each descriptor has an ID, from descriptor ID 0 to descriptor ID 127. Each descriptor contains the source address, destination address, and size of the data to be moved. The source address specifies the location of the data to be moved from by the DMA. The destination address specifies the location of the data to be moved to by the DMA.
- For the read DMA operation, the software initializes the random data in the system memory space. The Read Data Mover moves this data from the system memory to the on-chip memory. For write DMA operation, the software initializes the random data in the on-chip memory. The Write Data Mover moves the data from the on-chip memory to the system memory space.
- As the last step to start the DMA, software writes the ID of the last descriptor into the Descriptor Controller's control logic. This write triggers the Descriptor Controller to start the DMA. The DMA then starts fetching the descriptors in order from descriptor 0 to the last descriptor.
- After the last descriptor completes, the Descriptor Controller writes a "1" to the Done bit in the last descriptor in the PCIe domain through the Txs port.
- Software continues polling the Done bit in the last descriptor. The DMA operation is said to be completed when the Done bit is set and the performance number is calculated. Once the DMA completes, Software compares the data in system memory and the on-chip memory. The test passes if there is no data mismatch.
- For simultaneous operation, the software starts the read DMA operation followed by the write DMA. The operation is considered done after both the read and write DMA operation flows complete.
Did you find the information on this page useful?