Enabling Orin Dev Kit PCIe EP mode

Hi,

Using mmap and memcpy from main(), write from EP, read from PC RP, the results are unexpected, received data speed vs. reported send speed is very different.

EP->RP, 16KB 1000 times, 16MB overall
EP reports 0.0005s, 16/0.0005=32GB/s=240Gb/s
RP reports 2.2s, 16/2.2=7.4MB/s=60Mb/s

When data on RP is observed, it comes in blocks with jitter upto 0.5s so clearly most of the data is dropped or overwritten. On EP, 32GB/s is higher than theoretical for x1 reported by lspci LnkSta. Also there is a limit of 16384 bytes mmap size, if 32768 is used, Orin segfaults and restarts, not sure how to increase the limit?

RP->EP
EP reports 0.0005s, 16/0.0005=32GB/s=240Gb/s
RP reports 0.7s, 16/0.7=22MB/s=182Mb/s

When data on RP is observed, 182Mb/s is lower than using tvnet, and again EP 32GB/s is more than theoretical. Since there are similarly divergent results reported Performance issues of data transmission speed in PCIe EP mode, is mmap a viable option for data transfers over PCIe EP from user space to physical address space mapped for PCIe EP (RAM), and are these results due to temporary instability of PCIe driver, or even when fixed, will not be performant? If it is the latter, is writing custom kernel driver Custom Endpoint Function Driver the only option left or there are some other shortcuts there for using DMA from user space?

Thanks.

1 Like