I am writing a driver which uses the GPUDirect RDMA on the Jetson for direct access to CUDA-Memory. I have a number of distinct data streams, which are transfered via DMA. The different streams are managed by different threads (in the userland). Via fileopts I can manage these transfers.
Can I call the interface (see below) from different threads without additional precautions, like mutex or spinlocks? Or do I need some sort of synchronization? Due to the architecture the calls for one data-region/stream are always sequential. But I could e.g. have two parallel calls to nvidia_p2p_dma_map_pages for different memory regions.
I am using the following functions:
Best regards and thanks in advance,