[v2,2/2] drivers: skip build of sub-libs not supporting IOVA mode
Checks
Commit Message
If IOVA as PA is disabled and the driver requires the IOVA field,
the build of the driver was disabled.
Unfortunately some drivers were building some sub-libraries
(with specific options for vector paths) which were not disabled.
The build parsing of those drivers need to be skipped earlier
to avoid defining the sub-libraries.
Fixes: a986c2b7973d ("build: add option to configure IOVA mode as PA")
Cc: stable@dpdk.org
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Shijith Thotton <sthotton@marvell.com>
---
drivers/common/idpf/meson.build | 4 ++++
drivers/event/dlb2/meson.build | 5 ++++-
drivers/net/bnxt/meson.build | 4 ++++
drivers/net/enic/meson.build | 4 ++++
drivers/net/i40e/meson.build | 4 ++++
drivers/net/iavf/meson.build | 3 +++
drivers/net/virtio/meson.build | 4 ++++
7 files changed, 27 insertions(+), 1 deletion(-)
@@ -1,6 +1,10 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2022 Intel Corporation
+if not get_option('enable_iova_as_pa')
+ subdir_done()
+endif
+
deps += ['mbuf']
sources = files(
@@ -1,4 +1,3 @@
-
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2019-2020 Intel Corporation
@@ -8,6 +7,10 @@ if not is_linux or not dpdk_conf.has('RTE_ARCH_X86_64')
subdir_done()
endif
+if not get_option('enable_iova_as_pa')
+ subdir_done()
+endif
+
sources = files(
'dlb2.c',
'dlb2_iface.c',
@@ -8,6 +8,10 @@ if is_windows
subdir_done()
endif
+if not get_option('enable_iova_as_pa')
+ subdir_done()
+endif
+
headers = files('rte_pmd_bnxt.h')
cflags_options = [
'-DSUPPORT_CFA_HW_ALL=1',
@@ -7,6 +7,10 @@ if is_windows
subdir_done()
endif
+if not get_option('enable_iova_as_pa')
+ subdir_done()
+endif
+
sources = files(
'base/vnic_cq.c',
'base/vnic_dev.c',
@@ -13,6 +13,10 @@ if arch_subdir == 'riscv'
subdir_done()
endif
+if not get_option('enable_iova_as_pa')
+ subdir_done()
+endif
+
cflags += ['-DPF_DRIVER',
'-DVF_DRIVER',
'-DINTEGRATED_VF',
@@ -1,6 +1,9 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2018 Luca Boccassi <bluca@debian.org>
+if not get_option('enable_iova_as_pa')
+ subdir_done()
+endif
cflags += ['-Wno-strict-aliasing']
@@ -7,6 +7,10 @@ if is_windows
subdir_done()
endif
+if not get_option('enable_iova_as_pa')
+ subdir_done()
+endif
+
sources += files(
'virtio.c',
'virtio_cvq.c',