Skip to contentSkip to conversation

doc: add limitation on MPRQ usage in multi-process app

PATCH In review Alexander Kozyrev 2 participants 2 messages Feb 4, 2022 – Feb 9, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 doc: add limitation on MPRQ usage in multi-process app

MPRQ cannot be used in multi-process applications because of externally attached MPRQ buffers. A callback is registered by a primary process to free MPRQ buffers once they are no longer needed. But this information is shared among all the processes. The virtual address of the mlx5_mprq_buf_free_cb function is different in a secondary process, which leads to a segmentation fault. Document that MPRQ is not supported in a multi-process app, since there is no way to find out if this is the one.

---
 doc/guides/nics/mlx5.rst | 3 +++
 1 file changed, 3 insertions(+)
doc/guides/nics/mlx5.rst +3 -0
index daa7f2affb..7ac997ac27 100644
@@ -138,6 +138,9 @@ Limitations
 - For secondary process:
 
   - Forked secondary process not supported.
+  - MPRQ is not supported. Callback to free externally attached MPRQ buffer is sets
+    in a primary process, but has a different virtual address in a secondary process.
+    Calling a function at the wrong address leads to a segmentation fault.
   - External memory unregistered in EAL memseg list cannot be used for DMA
     unless such memory has been registered by ``mlx5_mr_update_ext_mp()`` in
     primary process and remapped to the same virtual address in secondary
Signature · 1 line
2.18.2
#1 lore raw

Hi,

Quoted 17 lines

-----Original Message-----
From: Alexander Kozyrev <[email protected]>
Sent: Friday, February 4, 2022 5:19 AM
To: [email protected]
Cc: Raslan Darawsheh <[email protected]>; Slava Ovsiienko <[email protected]>; Matan Azrad <[email protected]>
Subject: [PATCH] doc: add limitation on MPRQ usage in multi-process app

MPRQ cannot be used in multi-process applications because of externally attached MPRQ buffers. A callback is registered by a primary process to free MPRQ buffers once they are no longer needed. But this information is shared among all the processes. The virtual address of the mlx5_mprq_buf_free_cb function is different in a secondary process, which leads to a segmentation fault. Document that MPRQ is not supported in a multi-process app, since there is no way to find out if this is the one.

Quoted 2 lines

Patch applied to next-net-mlx,

Kindest regards,
Raslan Darawsheh