summaryrefslogtreecommitdiffstats
path: root/src/dpdk
diff options
context:
space:
mode:
Diffstat (limited to 'src/dpdk')
-rwxr-xr-xsrc/dpdk/Makefile1
-rw-r--r--src/dpdk/dpdk.py8
2 files changed, 8 insertions, 1 deletions
diff --git a/src/dpdk/Makefile b/src/dpdk/Makefile
index 1cd85e3e..29967029 100755
--- a/src/dpdk/Makefile
+++ b/src/dpdk/Makefile
@@ -72,6 +72,7 @@ ifdef CONFIG_FILE_BASE
$(AT)sed -i -e 's/CONFIG_RTE_LIBRTE_VHOST_USER=.\+/CONFIG_RTE_LIBRTE_VHOST_USER=$(VHOST_USER)/g' $(CONFIG_FILE_BASE)
$(AT)sed -i -e 's/CONFIG_RTE_LIBRTE_VHOST=./CONFIG_RTE_LIBRTE_VHOST=y/g' $(CONFIG_FILE_BASE)
$(AT)sed -i -e 's/CONFIG_RTE_LIBRTE_KNI=./CONFIG_RTE_LIBRTE_KNI=n/g' $(CONFIG_FILE_BASE)
+ $(AT)sed -i -e 's/CONFIG_RTE_LIBRTE_VHOST_NUMA=./CONFIG_RTE_LIBRTE_VHOST_NUMA=y/g' $(CONFIG_FILE_BASE)
else
$(AT)sed -i -e 's/CONFIG_RTE_LIBRTE_VHOST_USER=.\+/CONFIG_RTE_LIBRTE_VHOST_USER=$(VHOST_USER)/g' $(CONFIG_FILE_LINUXAPP)
$(AT)sed -i -e 's/CONFIG_RTE_BUILD_COMBINE_LIBS=./CONFIG_RTE_BUILD_COMBINE_LIBS=y/g' $(CONFIG_FILE_LINUXAPP)
diff --git a/src/dpdk/dpdk.py b/src/dpdk/dpdk.py
index 16223915..0c5ed9f4 100644
--- a/src/dpdk/dpdk.py
+++ b/src/dpdk/dpdk.py
@@ -139,6 +139,9 @@ def _vhost_user_cleanup():
def _bind_nics():
"""Bind NICs using the Intel DPDK ``dpdk*bind.py`` tool.
"""
+ if not len(_NICS_PCI):
+ _LOGGER.info('NICs are not configured - nothing to bind')
+ return
try:
_driver = 'igb_uio'
if 'vfio-pci' in S.getValue('TOOLS')['dpdk_modules']:
@@ -151,7 +154,7 @@ def _bind_nics():
True)
tasks.run_task(['sudo', S.getValue('TOOLS')['bind-tool'],
- '--bind=' + _driver] +
+ '--bind=' + _driver] +
_NICS_PCI, _LOGGER,
'Binding NICs %s...' % _NICS_PCI,
True)
@@ -161,6 +164,9 @@ def _bind_nics():
def _unbind_nics():
"""Unbind NICs using the Intel DPDK ``dpdk*bind.py`` tool.
"""
+ if not len(_NICS_PCI):
+ _LOGGER.info('NICs are not configured - nothing to unbind')
+ return
try:
tasks.run_task(['sudo', S.getValue('TOOLS')['bind-tool'], '--unbind'] +
_NICS_PCI, _LOGGER,