From f77bed265a4c66293ca387139e20ce3ddb71d83c Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Wed, 16 Jul 2025 09:44:19 +0800 Subject: [PATCH 1/8] linux: add virtio.cfg * Add virtio.cfg to support for virtio, e.g. running an iso image with qemu. Enable virtio.cfg by default for iso images such as kp920 and x86. Enable CONFIG_NETFILTER_XTABLES and IP_VS for k8s. Signed-off-by: hanzongcheng --- bsp/meta-kunpeng/recipes-kernel/linux/linux-kp920.inc | 1 + .../linux/files/config/cfg-fragments/embedded-build.cfg | 3 --- .../linux/files/config/cfg-fragments/virtio.cfg | 7 +++++++ meta-openeuler/recipes-kernel/linux/linux-openeuler.inc | 1 + 4 files changed, 9 insertions(+), 3 deletions(-) create mode 100644 meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/virtio.cfg diff --git a/bsp/meta-kunpeng/recipes-kernel/linux/linux-kp920.inc b/bsp/meta-kunpeng/recipes-kernel/linux/linux-kp920.inc index 4f558a6d051..aa785eca21d 100644 --- a/bsp/meta-kunpeng/recipes-kernel/linux/linux-kp920.inc +++ b/bsp/meta-kunpeng/recipes-kernel/linux/linux-kp920.inc @@ -14,6 +14,7 @@ CONFIGVERSION="${@bb.utils.contains('DISTRO_FEATURES', 'kernel6', 'kernel6-', '' SRC_URI:append = " \ file://config/cfg-fragments/embedded-build.cfg \ file://config/cfg-fragments/common-pc-drivers.cfg \ + file://config/cfg-fragments/virtio.cfg \ " # The kp920 kernel configuration now supports k8s and does not require a separate configuration file. diff --git a/meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/embedded-build.cfg b/meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/embedded-build.cfg index 8f36c5663ce..fdb891edb11 100644 --- a/meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/embedded-build.cfg +++ b/meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/embedded-build.cfg @@ -35,9 +35,6 @@ CONFIG_MODULE_SIG_KEY="" # CONFIG_ATM is not set # CONFIG_L2TP is not set # CONFIG_VSOCKETS is not set -# CONFIG_NETFILTER_XTABLES is not set -# CONFIG_IP_SET is not set -# CONFIG_IP_VS is not set # # Netdevice diff --git a/meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/virtio.cfg b/meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/virtio.cfg new file mode 100644 index 00000000000..b6f5b380c16 --- /dev/null +++ b/meta-openeuler/recipes-kernel/linux/files/config/cfg-fragments/virtio.cfg @@ -0,0 +1,7 @@ +# +# Modify some kernel configs to support for virtio, e.g. running an iso image with qemu +# +CONFIG_VIRTIO=y +CONFIG_VIRTIO_PCI_LIB=y +CONFIG_VIRTIO_PCI=y +CONFIG_VIRTIO_MMIO=y diff --git a/meta-openeuler/recipes-kernel/linux/linux-openeuler.inc b/meta-openeuler/recipes-kernel/linux/linux-openeuler.inc index 0a7452b9fb5..4aaf7ee09dd 100644 --- a/meta-openeuler/recipes-kernel/linux/linux-openeuler.inc +++ b/meta-openeuler/recipes-kernel/linux/linux-openeuler.inc @@ -60,6 +60,7 @@ KBUILD_DEFCONFIG:x86-64 = "openeuler_defconfig" SRC_URI:append:x86-64 = " \ file://config/cfg-fragments/embedded-build.cfg \ file://config/cfg-fragments/common-pc-drivers.cfg \ + file://config/cfg-fragments/virtio.cfg \ " # strip modules for x86 image EXTRA_OEMAKE:x86-64 += "INSTALL_MOD_STRIP=1" -- Gitee From 3862b97da9c1bf6d9fa7925a5210ec3c9188ea77 Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Wed, 16 Jul 2025 09:45:12 +0800 Subject: [PATCH 2/8] samples: tweak sample.yaml for kp920 * Remove meta-virt for kp920-industry.yaml and replace the Tsinghua Repo with the USTC repo (ustc.repo is relatively stable). Signed-off-by: hanzongcheng --- .oebuild/samples/aarch64/kp920-industry-kernel6.yaml | 2 +- .oebuild/samples/aarch64/kp920-industry.yaml | 4 ---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/.oebuild/samples/aarch64/kp920-industry-kernel6.yaml b/.oebuild/samples/aarch64/kp920-industry-kernel6.yaml index 2abc6883d13..fcc06619701 100644 --- a/.oebuild/samples/aarch64/kp920-industry-kernel6.yaml +++ b/.oebuild/samples/aarch64/kp920-industry-kernel6.yaml @@ -35,7 +35,7 @@ local_conf: |+ DISTRO_FEATURES:append = " preempt-rt " DISTRO_FEATURES:append = " oebridge " - SERVER_MIRROR = "https://mirrors.tuna.tsinghua.edu.cn/openeuler" + SERVER_MIRROR = "https://mirrors.ustc.edu.cn/openeuler" SERVER_VERSION = "openEuler-24.03-LTS-SP1" layers: diff --git a/.oebuild/samples/aarch64/kp920-industry.yaml b/.oebuild/samples/aarch64/kp920-industry.yaml index 9191133c410..9549a2ed46a 100644 --- a/.oebuild/samples/aarch64/kp920-industry.yaml +++ b/.oebuild/samples/aarch64/kp920-industry.yaml @@ -7,7 +7,6 @@ repos: - yocto-poky - yocto-meta-openembedded - yocto-meta-qt5 -- yocto-meta-virtualization local_conf: |+ MCS_FEATURES ?= "openamp" DISTRO_FEATURES:append = " mcs" @@ -27,14 +26,11 @@ local_conf: |+ INIT_MANAGER = "systemd" DISTRO_FEATURES:append = " epkg" - DISTRO_FEATURES:append = " k8s virtualization" - layers: - yocto-meta-openeuler/bsp/meta-kunpeng - yocto-meta-openembedded/meta-oe - yocto-meta-qt5 - yocto-meta-openeuler/rtos/meta-openeuler-rtos -- yocto-meta-virtualization docker_param: image: swr.cn-north-4.myhuaweicloud.com/openeuler-embedded/openeuler-container:latest parameters: -itd --network host -- Gitee From 405b6169392206cd3030e7d89def07886eaeba5d Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Wed, 16 Jul 2025 10:00:47 +0800 Subject: [PATCH 3/8] oebridge: fix some bug * Currently, oebridge triggers the do_download_epkg function for all tasks, but only the class-target actually needs it. Other tasks, such as nativesdk, do not need to include the do_download_epkg function. Signed-off-by: hanzongcheng --- meta-openeuler/classes/oebridge.bbclass | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/meta-openeuler/classes/oebridge.bbclass b/meta-openeuler/classes/oebridge.bbclass index 607b4b4b96f..7b1bc4e2686 100644 --- a/meta-openeuler/classes/oebridge.bbclass +++ b/meta-openeuler/classes/oebridge.bbclass @@ -35,6 +35,8 @@ python(){ } addtask do_download_oepkg before do_package_write_rpm after do_package_qa +# Any tasks that access the network must be marked as such using the network flag. +do_download_oepkg[network] = "1" inherit oebridge-common @@ -50,7 +52,13 @@ def get_package_details(base, package_name): "Checksum": pkg.chksum[1].hex() } -python do_download_oepkg(){ +# Currently, oebridge triggers the do_download_epkg function for all tasks, +# but only the class-target actually needs it. Other tasks, such as nativesdk, +# do not need to include the do_download_epkg function. +python do_download_oepkg() { +} + +python do_download_oepkg:class-target(){ import os import subprocess -- Gitee From 5b8110f8ddfff2e08abd21e46deb92f67612a134 Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Tue, 15 Jul 2025 19:15:22 +0800 Subject: [PATCH 4/8] procps-ng: Adjust the ASSUME_PROVIDE_PKGS * The ASSUME_PROVIDE_PKGS is procps-ng. Signed-off-by: hanzongcheng --- meta-openeuler/recipes-extended/procps/procps_%.bbappend | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta-openeuler/recipes-extended/procps/procps_%.bbappend b/meta-openeuler/recipes-extended/procps/procps_%.bbappend index 87ed6b6d076..328c04b1762 100644 --- a/meta-openeuler/recipes-extended/procps/procps_%.bbappend +++ b/meta-openeuler/recipes-extended/procps/procps_%.bbappend @@ -46,4 +46,4 @@ do_configure:prepend() { SRC_URI[sha256sum] = "ee3fcd2ea6ff94aa43a81ba5cc7912b7c9615acd2911c7a3d3ea081287fdf47a" -ASSUME_PROVIDE_PKGS = "procps" +ASSUME_PROVIDE_PKGS = "procps-ng" -- Gitee From 8562fa912013e6112bbc7feda86de2697714c053 Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Wed, 16 Jul 2025 10:05:24 +0800 Subject: [PATCH 5/8] yocto: modify the repo address * Replace the repo with the USTC repo(ustc.repo is relatively stable). Signed-off-by: hanzongcheng --- .oebuild/features/oebridge.yaml | 4 ++-- meta-openeuler/recipes-core/isulad/lib-shim-v2-bin_0.0.1.bb | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.oebuild/features/oebridge.yaml b/.oebuild/features/oebridge.yaml index 1a193744ddf..647c3d0d4c3 100644 --- a/.oebuild/features/oebridge.yaml +++ b/.oebuild/features/oebridge.yaml @@ -2,5 +2,5 @@ type: feature local_conf: | DISTRO_FEATURES:append = " oebridge " - SERVER_MIRROR = "https://mirrors.tuna.tsinghua.edu.cn/openeuler" - SERVER_VERSION = "openEuler-24.03-LTS" + SERVER_MIRROR = "https://mirrors.ustc.edu.cn/openeuler" + SERVER_VERSION = "openEuler-24.03-LTS-SP2" diff --git a/meta-openeuler/recipes-core/isulad/lib-shim-v2-bin_0.0.1.bb b/meta-openeuler/recipes-core/isulad/lib-shim-v2-bin_0.0.1.bb index 3ef633cf6c6..3e29b596ab5 100644 --- a/meta-openeuler/recipes-core/isulad/lib-shim-v2-bin_0.0.1.bb +++ b/meta-openeuler/recipes-core/isulad/lib-shim-v2-bin_0.0.1.bb @@ -8,15 +8,15 @@ LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/MulanPSL-2.0;m inherit bin_package SRC_URI:aarch64 = " \ - https://repo.openeuler.openatom.cn/openEuler-23.09/OS/aarch64/Packages/lib-shim-v2-0.0.1-8.oe2309.aarch64.rpm;name=arm64;subdir=${BP} \ + https://mirrors.ustc.edu.cn/openeuler/openEuler-23.09/OS/aarch64/Packages/lib-shim-v2-0.0.1-8.oe2309.aarch64.rpm;name=arm64;subdir=${BP} \ " SRC_URI:x86-64 = " \ - https://repo.openeuler.openatom.cn/openEuler-23.09/OS/x86_64/Packages/lib-shim-v2-0.0.1-8.oe2309.x86_64.rpm;name=x86;subdir=${BP} \ + https://mirrors.ustc.edu.cn/openeuler/openEuler-23.09/OS/x86_64/Packages/lib-shim-v2-0.0.1-8.oe2309.x86_64.rpm;name=x86;subdir=${BP} \ " SRC_URI:append = " \ - https://repo.openeuler.openatom.cn/openEuler-23.09/everything/aarch64/Packages/lib-shim-v2-devel-0.0.1-8.oe2309.aarch64.rpm;name=header;subdir=${BP} \ + https://mirrors.ustc.edu.cn/openeuler/openEuler-23.09/everything/aarch64/Packages/lib-shim-v2-devel-0.0.1-8.oe2309.aarch64.rpm;name=header;subdir=${BP} \ " SRC_URI[arm64.md5sum] = "3bf4618ffba4196a9bdcf3d9ec4e8e83" -- Gitee From 47bd08ca9a2dae49bc966495dbb9fbe26da953db Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Tue, 15 Jul 2025 20:03:50 +0800 Subject: [PATCH 6/8] kp920: remove 10-eth-static.network for kp920 * The kp920 does not configure static ip by default. Signed-off-by: hanzongcheng --- bsp/meta-kunpeng/recipes-core/os-base/os-base_1.0.bbappend | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 bsp/meta-kunpeng/recipes-core/os-base/os-base_1.0.bbappend diff --git a/bsp/meta-kunpeng/recipes-core/os-base/os-base_1.0.bbappend b/bsp/meta-kunpeng/recipes-core/os-base/os-base_1.0.bbappend new file mode 100644 index 00000000000..8dbc460f936 --- /dev/null +++ b/bsp/meta-kunpeng/recipes-core/os-base/os-base_1.0.bbappend @@ -0,0 +1,7 @@ +# The kp920 does not configure static ip by default +do_install:append() { + ## systemd related basic configuration + if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then + rm ${D}${sysconfdir}/systemd/network/10-eth-static.network + fi +} -- Gitee From 9d66775e2de62a62f277a75cdc34991fccbd650b Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Tue, 15 Jul 2025 20:53:02 +0800 Subject: [PATCH 7/8] oedeploy: upgrade to 1.1.1 * Add the command 'oedp list' to support querying the plugin list. Signed-off-by: hanzongcheng --- .oebuild/manifest.yaml | 2 +- .../oedeploy/{oedeploy_1.1.0.bb => oedeploy_1.1.1.bb} | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename meta-openeuler/recipes-extended/oedeploy/{oedeploy_1.1.0.bb => oedeploy_1.1.1.bb} (99%) diff --git a/.oebuild/manifest.yaml b/.oebuild/manifest.yaml index d8c6d08f312..133be41ddcb 100644 --- a/.oebuild/manifest.yaml +++ b/.oebuild/manifest.yaml @@ -1250,7 +1250,7 @@ manifest_list: version: 47a7c941bad0100b291352db561ff880b66927ef oedeploy: remote_url: https://gitee.com/src-openeuler/oeDeploy.git - version: 1613af12e65533c32bfba2e5f3a6d77ff94657fb + version: c00c5e07c3b559374ed4c9786fa707e73084311a ompl: remote_url: https://gitee.com/src-openeuler/ompl.git version: 42759f06c9a8d712a5ba86f1f3b22a569ec81232 diff --git a/meta-openeuler/recipes-extended/oedeploy/oedeploy_1.1.0.bb b/meta-openeuler/recipes-extended/oedeploy/oedeploy_1.1.1.bb similarity index 99% rename from meta-openeuler/recipes-extended/oedeploy/oedeploy_1.1.0.bb rename to meta-openeuler/recipes-extended/oedeploy/oedeploy_1.1.1.bb index a1c86c6cc37..6ac0bf8b792 100644 --- a/meta-openeuler/recipes-extended/oedeploy/oedeploy_1.1.0.bb +++ b/meta-openeuler/recipes-extended/oedeploy/oedeploy_1.1.1.bb @@ -2,7 +2,7 @@ SUMMARY = "Tool suite for app installation and deployment" DESCRIPTION = "oeDeploy" HOMEPAGE = "https://gitee.com/openeuler/oeDeploy" -PV = "1.1.0" +PV = "1.1.1" SRC_URI += " \ file://oedp-${PV}.tar.gz \ -- Gitee From 1a0fd4772c461379772c6d7d6a8250deea7f8400 Mon Sep 17 00:00:00 2001 From: hanzongcheng Date: Wed, 16 Jul 2025 02:12:26 +0800 Subject: [PATCH 8/8] ansible: install more ansible modules for kp920 * Install all modules except windows to support oedeploy. Signed-off-by: hanzongcheng --- .../recipes-devtools/python/python3-ansible_%.bbappend | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 bsp/meta-kunpeng/recipes-devtools/python/python3-ansible_%.bbappend diff --git a/bsp/meta-kunpeng/recipes-devtools/python/python3-ansible_%.bbappend b/bsp/meta-kunpeng/recipes-devtools/python/python3-ansible_%.bbappend new file mode 100644 index 00000000000..f958a1eedb3 --- /dev/null +++ b/bsp/meta-kunpeng/recipes-devtools/python/python3-ansible_%.bbappend @@ -0,0 +1,4 @@ +# Install all modules except windows +ANSIBLE_WHITELIST_MODULES = "cloud clustering commands crypto database files identity inventory \ + list messaging monitoring net_tools network notification packaging __pycache__ remote_management \ + source_control storage system utilities web_infrastructure" -- Gitee