Set DPDK_MLX4_PMD and DPDK_MLX5_PMD compile with default dlopen links

dlopen linkage allow more transparent use for Mellanox nics.
Mellanox shared library librte_pmd_mlx5/4_glue.so* placed in LD_LIBRARY_PATH
At run time Mellanox code will be loaded only when Mellanox nics explicty used.
i.e if VPP is used with other vendor Mellanox code is not loaded.

Change-Id: Ib05bdbfc4cbb6e447c67186c98361f9c5b447140
Signed-off-by: Amir Zeidner <amirzei@mellanox.com>
This commit is contained in:
Amir Zeidner
2018-03-05 14:32:22 +02:00
committed by Damjan Marion
parent f7b7fa53b7
commit 0e7fe4fddb
3 changed files with 2 additions and 25 deletions

View File

@ -197,6 +197,8 @@ $(B)/custom-config: $(B)/.patch.ok Makefile
$(call set,RTE_LIBRTE_PMD_AESNI_GCM,$(AESNI))
$(call set,RTE_LIBRTE_MLX4_PMD,$(DPDK_MLX4_PMD))
$(call set,RTE_LIBRTE_MLX5_PMD,$(DPDK_MLX5_PMD))
$(call set,RTE_LIBRTE_MLX4_DLOPEN_DEPS,$(DPDK_MLX4_PMD))
$(call set,RTE_LIBRTE_MLX5_DLOPEN_DEPS,$(DPDK_MLX5_PMD))
@# not needed
$(call set,RTE_LIBRTE_PMD_TAP,n)
$(call set,RTE_LIBRTE_TIMER,n)

View File

@ -271,28 +271,6 @@ AM_CONDITIONAL(WITH_AESNI_MB_LIB, test "$with_aesni_mb_lib" = "yes")
m4_append([list_of_with], [isa_l_crypto_lib], [, ])
AM_CONDITIONAL(WITH_ISA_L_CRYPTO_LIB, test "$with_isa_l_crypto_lib" = "yes")
with_ibverbs_lib=no
DPDK_IS_PMD_ENABLED(LIBRTE_MLX4_PMD, dpdk_mlx4_pmd)
AM_COND_IF([WITH_DPDK_MLX4_PMD],
[
AC_CHECK_LIB([ibverbs], [ibv_fork_init],
[with_ibverbs_lib=yes],
[AC_MSG_ERROR([ibverbs library not found])])
])
DPDK_IS_PMD_ENABLED(LIBRTE_MLX5_PMD, dpdk_mlx5_pmd)
AM_COND_IF([WITH_DPDK_MLX5_PMD],
[
AC_CHECK_LIB([ibverbs], [ibv_fork_init],
[with_ibverbs_lib=yes],
[AC_MSG_ERROR([ibverbs library not found])])
])
m4_append([list_of_with], [ibverbs_lib], [, ])
AM_CONDITIONAL(WITH_IBVERBS_LIB, test "$with_ibverbs_lib" = "yes")
AM_COND_IF([ENABLE_G2],
[
PKG_CHECK_MODULES(g2, gtk+-2.0)

View File

@ -25,9 +25,6 @@ endif
if WITH_ISA_L_CRYPTO_LIB
dpdk_plugin_la_LDFLAGS += -Wl,--exclude-libs,libisal_crypto.a,-l:libisal_crypto.a
endif
if WITH_IBVERBS_LIB
dpdk_plugin_la_LDFLAGS += -Wl,-libverbs
endif
dpdk_plugin_la_CFLAGS = $(AM_CFLAGS)
dpdk_plugin_la_LDFLAGS += -Wl,-lnuma