How to access Host/Arm memory in DPA device?

I use the function to get a ptr, but i can not read/write memory by the ptr

doca_dpa_dev_uintptr_t doca_dpa_dev_mmap_get_external_ptr(doca_dpa_dev_mmap_t mmap_handle, uint64_t addr)

The function claim that after calling this API, users can read/write the memory indicated by the returned pointer from the DPA kernel. But i do not know the next step when i get the returned pointer.

Hi 1563901725,

Please refer to the official DOCA DPA documentation for doca_dpa_dev_mmap_get_external_ptr and related APIs here:

https://docs.nvidia.com/doca/sdk/doca-dpa/index.html

In particular, the “Memory Subsystem” → “Accessing External Memory” section describes:

  • doca_dpa_dev_mmap_get_external_ptr(doca_dpa_dev_mmap_t mmap_handle, uint64_t addr)

  • doca_dpa_dev_buf_get_external_ptr(doca_dpa_dev_buf_t buf)

and explains how, after calling these APIs, you can read/write the indicated memory from the DPA kernel and the constraints on how to use the returned pointers.

Regards,

Quanying