net/mlx5: initialize context list mutex dynamically
authorTal Shnaiderman <talshn@nvidia.com>
Mon, 28 Dec 2020 12:32:59 +0000 (14:32 +0200)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 8 Jan 2021 15:03:08 +0000 (16:03 +0100)
commitef65067c46cbb0903cdbd07fa196fb1586a9681a
tree23b18d46ed1a7904fd64a82f905fbc2e86eda2bb
parentadc65dee4f96b91ce9793821dcf1652de51c62b7
net/mlx5: initialize context list mutex dynamically

The mutex mlx5_dev_ctx_list_mutex was initialized with
PTHREAD_MUTEX_INITIALIZER global macro however this macro
is not supported on Windows OS shim implementation of pthreads
in DPDK.

Moved the init of this mutex to RTE_INIT to support this mutex
on both OSs.

Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
drivers/net/mlx5/mlx5.c