diff options
Diffstat (limited to 'meta-isg/common/recipes-extended/dpdk/dpdk.inc')
-rw-r--r-- | meta-isg/common/recipes-extended/dpdk/dpdk.inc | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/meta-isg/common/recipes-extended/dpdk/dpdk.inc b/meta-isg/common/recipes-extended/dpdk/dpdk.inc index 85b88fa0..1bd2a26e 100644 --- a/meta-isg/common/recipes-extended/dpdk/dpdk.inc +++ b/meta-isg/common/recipes-extended/dpdk/dpdk.inc | |||
@@ -3,6 +3,27 @@ HOMEPAGE = "http://dpdk.org" | |||
3 | LICENSE = "BSD & LGPLv2 & GPLv2" | 3 | LICENSE = "BSD & LGPLv2 & GPLv2" |
4 | LIC_FILES_CHKSUM = "file://LICENSE.GPL;md5=751419260aa954499f7abaabaa882bbe" | 4 | LIC_FILES_CHKSUM = "file://LICENSE.GPL;md5=751419260aa954499f7abaabaa882bbe" |
5 | 5 | ||
6 | SRC_URI = "http://dpdk.org/browse/dpdk/snapshot/dpdk-${PV}.tar.gz;name=dpdk \ | ||
7 | file://dpdk-1.8.0-and-2.0.0-examples-add-config-variable-to-enable-disable-dpdk.patch \ | ||
8 | file://dpdk-1.8.0-and-2.0.0-add-RTE_KERNELDIR_OUT-to-split-kernel-bu.patch \ | ||
9 | file://dpdk-1.8.0-and-2.0.0-add-sysroot-option-within-app-makefile.patch \ | ||
10 | file://dpdk-1.8.0-and-2.0.0-point-to-the-right-include-and-lib-path.patch \ | ||
11 | " | ||
12 | |||
13 | # dpdk example apps dpdk_qat and vhost have dependancy on fuse and qat. | ||
14 | # fuse is in meta-filesystems and qat is not yet upstreamed. | ||
15 | # So adding mechanism to explicitly disable the use of fuse and qat. | ||
16 | # To enable, uncomment the below line or include in .bbappend. | ||
17 | # PACKAGECONFIG ?= " dpdk_qat vhost libvirt" | ||
18 | |||
19 | PACKAGECONFIG[dpdk_qat] = ",,virtual/qat" | ||
20 | PACKAGECONFIG[vhost] = ",,fuse" | ||
21 | PACKAGECONFIG[libvirt] = ",,libvirt" | ||
22 | |||
23 | export CONFIG_EXAMPLE_DPDK_QAT = "${@base_contains('PACKAGECONFIG', 'dpdk_qat', 'y', 'n', d)}" | ||
24 | export CONFIG_EXAMPLE_VM_POWER_MANAGER = "${@base_contains('PACKAGECONFIG', 'libvirt', 'y', 'n', d)}" | ||
25 | export CONFIG_VHOST_ENABLED = "${@base_contains('PACKAGECONFIG', 'vhost', 'y', 'n', d)}" | ||
26 | |||
6 | RDEPENDS_${PN} += "python-subprocess" | 27 | RDEPENDS_${PN} += "python-subprocess" |
7 | DEPENDS = "virtual/kernel" | 28 | DEPENDS = "virtual/kernel" |
8 | do_configure[depends] += "virtual/kernel:do_shared_workdir" | 29 | do_configure[depends] += "virtual/kernel:do_shared_workdir" |
@@ -20,6 +41,7 @@ export RTE_KERNELDIR_OUT = "${STAGING_KERNEL_BUILDDIR}" | |||
20 | export INSTALL_PATH = "${prefix}/dpdk" | 41 | export INSTALL_PATH = "${prefix}/dpdk" |
21 | export SYSROOTPATH = "--sysroot=${STAGING_DIR_HOST}" | 42 | export SYSROOTPATH = "--sysroot=${STAGING_DIR_HOST}" |
22 | export DPDK_TARGET_MACH = "${@get_dpdk_target_mach(bb,d)}" | 43 | export DPDK_TARGET_MACH = "${@get_dpdk_target_mach(bb,d)}" |
44 | export ICP_LAC_API_DIR = "${STAGING_DIR_TARGET}${includedir}/lac" | ||
23 | 45 | ||
24 | # The list of intel Comms platforms and their target machine | 46 | # The list of intel Comms platforms and their target machine |
25 | # process mapping. The supported target machine is listed under | 47 | # process mapping. The supported target machine is listed under |
@@ -46,6 +68,15 @@ do_configure () { | |||
46 | ############################################################# | 68 | ############################################################# |
47 | unset prefix | 69 | unset prefix |
48 | 70 | ||
71 | # Fix-up CONFIG_RTE_MACHINE based on target machine | ||
72 | sed -e "s#CONFIG_RTE_MACHINE=\"native\"#CONFIG_RTE_MACHINE=\"${DPDK_TARGET_MACH}\"#" -i ${S}/config/defconfig_x86_64-native-linuxapp-gcc | ||
73 | sed -e "s#CONFIG_RTE_MACHINE=\"native\"#CONFIG_RTE_MACHINE=\"${DPDK_TARGET_MACH}\"#" -i ${S}/config/defconfig_i686-native-linuxapp-gcc | ||
74 | |||
75 | # Fix-up vhost configs based on package config | ||
76 | sed -e "s#CONFIG_RTE_KNI_VHOST=n#CONFIG_RTE_KNI_VHOST=${CONFIG_VHOST_ENABLED}#" -i ${S}/config/common_linuxapp | ||
77 | sed -e "s#CONFIG_RTE_KNI_VHOST_VNET_HDR_EN=n#CONFIG_RTE_KNI_VHOST_VNET_HDR_EN=${CONFIG_VHOST_ENABLED}#" -i ${S}/config/common_linuxapp | ||
78 | sed -e "s#CONFIG_RTE_LIBRTE_VHOST=n#CONFIG_RTE_LIBRTE_VHOST=${CONFIG_VHOST_ENABLED}#" -i ${S}/config/common_linuxapp | ||
79 | |||
49 | make O=$RTE_TARGET T=$RTE_TARGET config | 80 | make O=$RTE_TARGET T=$RTE_TARGET config |
50 | } | 81 | } |
51 | 82 | ||