2017-11-15 18:10:25 +00:00
|
|
|
#!/bin/sh
|
|
|
|
# -*- mode:sh; tab-width:4; indent-tabs-mode:nil -*
|
|
|
|
|
|
|
|
setconf() {
|
|
|
|
local key=$1
|
|
|
|
local val=$2
|
|
|
|
if grep -q ^$key= ${conf}; then
|
2017-11-21 02:52:50 +00:00
|
|
|
sed -i -e "s:^$key=.*$:$key=$val:g" ${conf}
|
2017-11-15 18:10:25 +00:00
|
|
|
else
|
|
|
|
echo $key=$val >> ${conf}
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
conf=$1/.config
|
|
|
|
shift
|
|
|
|
machine=$1
|
|
|
|
shift
|
2018-05-06 06:32:45 +00:00
|
|
|
arch=$1
|
|
|
|
shift
|
2017-11-15 18:10:25 +00:00
|
|
|
|
|
|
|
setconf CONFIG_RTE_MACHINE "${machine}"
|
2018-05-06 06:32:45 +00:00
|
|
|
setconf CONFIG_RTE_ARCH "${arch}"
|
|
|
|
|
2017-11-15 18:10:25 +00:00
|
|
|
# Disable experimental features
|
|
|
|
setconf CONFIG_RTE_NEXT_ABI n
|
|
|
|
setconf CONFIG_RTE_LIBRTE_MBUF_OFFLOAD n
|
|
|
|
# Disable unmaintained features
|
|
|
|
setconf CONFIG_RTE_LIBRTE_POWER n
|
|
|
|
|
|
|
|
setconf CONFIG_RTE_EAL_IGB_UIO n
|
|
|
|
setconf CONFIG_RTE_LIBRTE_KNI n
|
|
|
|
setconf CONFIG_RTE_KNI_KMOD n
|
|
|
|
setconf CONFIG_RTE_KNI_PREEMPT_DEFAULT n
|
|
|
|
|
|
|
|
# no pdump
|
|
|
|
setconf CONFIG_RTE_LIBRTE_PDUMP n
|
|
|
|
|
|
|
|
# no vm support
|
|
|
|
setconf CONFIG_RTE_LIBRTE_EAL_VMWARE_TSC_MAP_SUPPORT n
|
|
|
|
setconf CONFIG_RTE_LIBRTE_VHOST n
|
2017-11-28 10:00:37 +00:00
|
|
|
setconf CONFIG_RTE_LIBRTE_VHOST_NUMA n
|
2017-11-15 18:10:25 +00:00
|
|
|
setconf CONFIG_RTE_LIBRTE_VMXNET3_PMD n
|
|
|
|
setconf CONFIG_RTE_LIBRTE_PMD_VHOST n
|
|
|
|
setconf CONFIG_RTE_APP_EVENTDEV n
|
2018-05-06 06:32:45 +00:00
|
|
|
setconf CONFIG_RTE_MAX_VFIO_GROUPS 64
|
2017-11-15 18:10:25 +00:00
|
|
|
|
|
|
|
# no test
|
|
|
|
setconf CONFIG_RTE_APP_TEST n
|
|
|
|
setconf CONFIG_RTE_TEST_PMD n
|
|
|
|
|
|
|
|
# async/dpdk does not like it
|
|
|
|
setconf CONFIG_RTE_MBUF_REFCNT_ATOMIC n
|
2017-11-28 10:00:37 +00:00
|
|
|
|
|
|
|
# balanced allocation of hugepages
|
|
|
|
setconf CONFIG_RTE_EAL_NUMA_AWARE_HUGEPAGES n
|