diff options
Diffstat (limited to 'recipes-extended')
3 files changed, 151 insertions, 0 deletions
diff --git a/recipes-extended/dpdk/dpdk-module_21.11.0.bb b/recipes-extended/dpdk/dpdk-module_21.11.0.bb new file mode 100644 index 0000000..c21bc62 --- /dev/null +++ b/recipes-extended/dpdk/dpdk-module_21.11.0.bb | |||
@@ -0,0 +1,45 @@ | |||
1 | include dpdk.inc | ||
2 | |||
3 | FILESEXTRAPATHS:prepend := "${THISDIR}/dpdk:" | ||
4 | |||
5 | SRC_URI += " \ | ||
6 | file://0001-Makefile-add-makefile.patch \ | ||
7 | " | ||
8 | STABLE = "-stable" | ||
9 | BRANCH = "21.11" | ||
10 | SRCREV = "45f04d88ae8fa6217812abdaa623d66b05fc7b6a" | ||
11 | S = "${WORKDIR}/git" | ||
12 | |||
13 | inherit module | ||
14 | |||
15 | #kernel module needs 'rte_build_config.h', which is generated at buid time | ||
16 | DEPENDS += "dpdk" | ||
17 | |||
18 | export S | ||
19 | export STAGING_KERNEL_DIR | ||
20 | export STAGING_INCDIR | ||
21 | export INSTALL_MOD_DIR="dpdk" | ||
22 | |||
23 | do_configure[noexec] = "1" | ||
24 | |||
25 | do_compile() { | ||
26 | cd ${S}/kernel/linux/kni | ||
27 | unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS | ||
28 | oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \ | ||
29 | KERNEL_VERSION=${KERNEL_VERSION} \ | ||
30 | CC="${KERNEL_CC}" LD="${KERNEL_LD}" \ | ||
31 | AR="${KERNEL_AR}" \ | ||
32 | O=${STAGING_KERNEL_BUILDDIR} \ | ||
33 | KBUILD_EXTRA_SYMBOLS="${KBUILD_EXTRA_SYMBOLS}" \ | ||
34 | ${MAKE_TARGETS} | ||
35 | } | ||
36 | |||
37 | do_install() { | ||
38 | cd ${S}/kernel/linux/kni | ||
39 | unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS | ||
40 | oe_runmake DEPMOD=echo MODLIB="${D}${nonarch_base_libdir}/modules/${KERNEL_VERSION}" \ | ||
41 | INSTALL_FW_PATH="${D}${nonarch_base_libdir}/firmware" \ | ||
42 | CC="${KERNEL_CC}" LD="${KERNEL_LD}" \ | ||
43 | O=${STAGING_KERNEL_BUILDDIR} \ | ||
44 | ${MODULES_INSTALL_TARGET} | ||
45 | } | ||
diff --git a/recipes-extended/dpdk/dpdk/0001-meson.build-march-and-mcpu-already-passed-by-Yocto-21.11.patch b/recipes-extended/dpdk/dpdk/0001-meson.build-march-and-mcpu-already-passed-by-Yocto-21.11.patch new file mode 100644 index 0000000..a74869d --- /dev/null +++ b/recipes-extended/dpdk/dpdk/0001-meson.build-march-and-mcpu-already-passed-by-Yocto-21.11.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | From 9aeb0bedf63f0f8f132194705b63ed0045452354 Mon Sep 17 00:00:00 2001 | ||
2 | From: Naveen Saini <naveen.kumar.saini@intel.com> | ||
3 | Date: Wed, 8 Dec 2021 11:48:27 +0800 | ||
4 | Subject: [PATCH] meson.build:-march and -mcpu already passed by Yocto | ||
5 | |||
6 | Upstream-Status: Inappropriate | ||
7 | |||
8 | Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com> | ||
9 | --- | ||
10 | config/meson.build | 12 ++++++------ | ||
11 | 1 file changed, 6 insertions(+), 6 deletions(-) | ||
12 | |||
13 | diff --git a/config/meson.build b/config/meson.build | ||
14 | index 805d5d51d0..620331a736 100644 | ||
15 | --- a/config/meson.build | ||
16 | +++ b/config/meson.build | ||
17 | @@ -127,12 +127,12 @@ dpdk_conf.set('RTE_MACHINE', cpu_instruction_set) | ||
18 | machine_args = [] | ||
19 | |||
20 | # ppc64 does not support -march= at all, use -mcpu and -mtune for that | ||
21 | -if host_machine.cpu_family().startswith('ppc') | ||
22 | - machine_args += '-mcpu=' + cpu_instruction_set | ||
23 | - machine_args += '-mtune=' + cpu_instruction_set | ||
24 | -else | ||
25 | - machine_args += '-march=' + cpu_instruction_set | ||
26 | -endif | ||
27 | +#if host_machine.cpu_family().startswith('ppc') | ||
28 | +# machine_args += '-mcpu=' + cpu_instruction_set | ||
29 | +# machine_args += '-mtune=' + cpu_instruction_set | ||
30 | +#else | ||
31 | +# machine_args += '-march=' + cpu_instruction_set | ||
32 | +#endif | ||
33 | |||
34 | toolchain = cc.get_id() | ||
35 | dpdk_conf.set_quoted('RTE_TOOLCHAIN', toolchain) | ||
36 | -- | ||
37 | 2.17.1 | ||
38 | |||
diff --git a/recipes-extended/dpdk/dpdk_21.11.0.bb b/recipes-extended/dpdk/dpdk_21.11.0.bb new file mode 100644 index 0000000..f7cdf0f --- /dev/null +++ b/recipes-extended/dpdk/dpdk_21.11.0.bb | |||
@@ -0,0 +1,68 @@ | |||
1 | include dpdk.inc | ||
2 | |||
3 | SRC_URI += " \ | ||
4 | file://0001-meson.build-march-and-mcpu-already-passed-by-Yocto-21.11.patch \ | ||
5 | " | ||
6 | |||
7 | STABLE = "-stable" | ||
8 | BRANCH = "21.11" | ||
9 | SRCREV = "45f04d88ae8fa6217812abdaa623d66b05fc7b6a" | ||
10 | S = "${WORKDIR}/git" | ||
11 | |||
12 | # kernel module is provide by dpdk-module recipe, so disable here | ||
13 | EXTRA_OEMESON = " -Denable_kmods=false \ | ||
14 | -Dexamples=all \ | ||
15 | " | ||
16 | |||
17 | COMPATIBLE_MACHINE = "null" | ||
18 | COMPATIBLE_HOST:libc-musl:class-target = "null" | ||
19 | COMPATIBLE_HOST:linux-gnux32 = "null" | ||
20 | |||
21 | PACKAGECONFIG ??= " " | ||
22 | PACKAGECONFIG[afxdp] = ",,libbpf" | ||
23 | PACKAGECONFIG[libvirt] = ",,libvirt" | ||
24 | |||
25 | RDEPENDS:${PN} += "pciutils python3-core" | ||
26 | RDEPENDS:${PN}-examples += "bash" | ||
27 | DEPENDS = "numactl python3-pyelftools-native" | ||
28 | |||
29 | inherit meson | ||
30 | |||
31 | INSTALL_PATH = "${prefix}/share/dpdk" | ||
32 | |||
33 | do_install:append(){ | ||
34 | # remove source files | ||
35 | rm -rf ${D}/${INSTALL_PATH}/examples/* | ||
36 | |||
37 | # Install examples | ||
38 | install -m 0755 -d ${D}/${INSTALL_PATH}/examples/ | ||
39 | for dirname in ${B}/examples/dpdk-* | ||
40 | do | ||
41 | if [ ! -d ${dirname} ] && [ -x ${dirname} ]; then | ||
42 | install -m 0755 ${dirname} ${D}/${INSTALL_PATH}/examples/ | ||
43 | fi | ||
44 | done | ||
45 | |||
46 | } | ||
47 | |||
48 | PACKAGES =+ "${PN}-examples ${PN}-tools" | ||
49 | |||
50 | FILES:${PN} = " ${bindir}/dpdk-testpmd \ | ||
51 | ${bindir}/dpdk-proc-info \ | ||
52 | ${libdir}/*.so* \ | ||
53 | ${libdir}/dpdk/pmds-22.0/*.so* \ | ||
54 | " | ||
55 | FILES:${PN}-examples = " \ | ||
56 | ${prefix}/share/dpdk/examples/* \ | ||
57 | " | ||
58 | |||
59 | FILES:${PN}-tools = " \ | ||
60 | ${bindir}/dpdk-pdump \ | ||
61 | ${bindir}/dpdk-test \ | ||
62 | ${bindir}/dpdk-test-* \ | ||
63 | ${bindir}/dpdk-*.py \ | ||
64 | " | ||
65 | |||
66 | CVE_PRODUCT = "data_plane_development_kit" | ||
67 | |||
68 | INSANE_SKIP:${PN} = "dev-so" | ||