> -----Original Message-----
> From: Dmitry Kozlyuk <[email protected]>
> Sent: Tuesday, November 16, 2021 10:58
> To: [email protected]
> Cc: Matan Azrad <[email protected]>; Raslan Darawsheh
> <[email protected]>; Slava Ovsiienko <[email protected]>
> Subject: [PATCH] common/mlx5: fix MPRQ mempool registration
>
> Mempool registration code had a wrong assumption that it is always dealing
> with packet mempools and always called rte_pktmbuf_priv_flags(), which
> returned a random value for different types of mempools.
> In particular, it could consider MPRQ mempools as having externally pinned
> buffers, which is wrong.
> Packet mempools cannot be reliably recognized, but it is sufficient to check
> that the mempool is not a packet one, so it cannot have externally pinned
> buffers.
> Compare mempool private data size to that of packet mempools to check.
>
> Fixes: 690b2a88c2f7 ("common/mlx5: add mempool registration facilities")
> Fixes: fec28ca0e3a9 ("net/mlx5: support mempool registration")
>
> Signed-off-by: Dmitry Kozlyuk <[email protected]>
Acked-by: Viacheslav Ovsiienko <[email protected]>