From bf279a4aa50a94c64087936bde5bd3e6f1618c21 Mon Sep 17 00:00:00 2001 From: yexin Date: Sat, 28 Jul 2018 11:55:13 +0800 Subject: Fix: disable dpdk1802 KNI mode by default Change-Id: Ie36d2c50514f6c66b12f2b3920d60f9315e2320e Signed-off-by: yexin --- scripts/build_dpdk1802.sh | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'scripts/build_dpdk1802.sh') diff --git a/scripts/build_dpdk1802.sh b/scripts/build_dpdk1802.sh index 6430aed..6f2008c 100755 --- a/scripts/build_dpdk1802.sh +++ b/scripts/build_dpdk1802.sh @@ -1,3 +1,4 @@ +#!/bin/bash -x ######################################################################### # # Copyright (c) 2018 Huawei Technologies Co.,Ltd. @@ -13,11 +14,10 @@ # See the License for the specific language governing permissions and # limitations under the License. ######################################################################### -#!/bin/bash -x echo "check whether dpdk installed" cur_directory=${PWD} -check_dpdk=$(rpm -qa | grep dpdk) +check_dpdk=$(rpm -qa | grep dpdk-devel) if [ -z "$check_dpdk" ]; then echo "system will install the dpdk" else @@ -56,6 +56,12 @@ sed -i '83a sed -i '\''s!CONFIG_RTE_BUILD_SHARED_LIB=.*!CONFIG_RTE_BUILD_SHARED_ sed -i '84a sed -i '\''s!CONFIG_RTE_LIBRTE_EAL=.*!CONFIG_RTE_LIBRTE_EAL=y!1'\'' config/common_base' dpdk.spec sed -i '85a sed -i '\''s!CONFIG_RTE_EAL_PMD_PATH=.*!CONFIG_RTE_EAL_PMD_PATH="/tmp/dpdk/drivers/"!1'\'' config/common_base' dpdk.spec +#disable KNI mode by default +sed -i '93a sed -ri '\''s!CONFIG_RTE_LIBRARY_KNI=.*!CONFIG_RTE_LIBRARY_KNI=n!1'\'' %{target}/.config' dpdk.spec +sed -i '94a sed -ri '\''s!CONFIG_RTE_LIBRARY_PMD_KNI=.*!CONFIG_RTE_LIBRARY_PMD_KNI=n!1'\'' %{target}/.config' dpdk.spec +sed -i '95a sed -ri '\''s!CONFIG_RTE_KNI_KMOD=.*!CONFIG_RTE_KNI_KMOD=n!1'\'' %{target}/.config' dpdk.spec +sed -i '96a sed -ri '\''s!CONFIG_RTE_KNI_PREEMPT_DEFAULT=.*!CONFIG_RTE_KNI_PREEMPT_DEFAULT=n!1'\'' %{target}/.config' dpdk.spec + echo "build the dependence" #sudo yum-builddep -y dpdk.spec sudo yum install -y libpcap-devel python-sphinx inkscape -- cgit 1.2.3-korg