From patchwork Wed Oct 12 10:06:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felix Moessbauer X-Patchwork-Id: 13005232 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mta-64-226.siemens.flowmailer.net (mta-64-226.siemens.flowmailer.net [185.136.64.226]) by mx.groups.io with SMTP id smtpd.web08.18280.1665569270037460042 for ; Wed, 12 Oct 2022 03:07:50 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=felix.moessbauer@siemens.com header.s=fm1 header.b=qaGoMImi; spf=pass (domain: rts-flowmailer.siemens.com, ip: 185.136.64.226, mailfrom: fm-72506-20221012100747dae08a649a8a181328-fezpyq@rts-flowmailer.siemens.com) Received: by mta-64-226.siemens.flowmailer.net with ESMTPSA id 20221012100747dae08a649a8a181328 for ; Wed, 12 Oct 2022 12:07:47 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; s=fm1; d=siemens.com; i=felix.moessbauer@siemens.com; h=Date:From:Subject:To:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding:Cc:References:In-Reply-To; bh=rq//Y0q9n2ZrOo7o9/hHzQf6QjtlBull1c6HZxKExQ0=; b=qaGoMImiCn76ShOPQfO5DKDavc3lAYI3kWkTV0O6bIftPmidNVH5f9837xPISW64HzBPkK euSqo7anNl324tTUejXsD1jgVS/KOHtATcAQ36oI1jmafXxfxV2+5QGsS7POHe1gs1TZkf9o viCaWJR5gYupV5SisoiIWvqSyXUK8=; From: Felix Moessbauer To: cip-dev@lists.cip-project.org Cc: jan.kiszka@siemens.com, quirin.gylstorff@siemens.com, pluto.svc.chengdu.cn@siemens.com, Felix Moessbauer Subject: [isar-cip-core][PATCH 1/3] fix: add missing class dependencies in image_uuid Date: Wed, 12 Oct 2022 12:06:39 +0200 Message-Id: <20221012100641.2986740-2-felix.moessbauer@siemens.com> In-Reply-To: <20221012100641.2986740-1-felix.moessbauer@siemens.com> References: <20221012100641.2986740-1-felix.moessbauer@siemens.com> MIME-Version: 1.0 X-Flowmailer-Platform: Siemens Feedback-ID: 519:519-72506:519-21489:flowmailer List-Id: The image_uuid class references tasks and variables from image and rootfs. By that, the class has to inherit the other classes to ensure that the components are available, independent of the overall include / parse order. Signed-off-by: Felix Moessbauer --- classes/image_uuid.bbclass | 3 +++ 1 file changed, 3 insertions(+) diff --git a/classes/image_uuid.bbclass b/classes/image_uuid.bbclass index 71cc3ad..277941b 100644 --- a/classes/image_uuid.bbclass +++ b/classes/image_uuid.bbclass @@ -10,6 +10,9 @@ # SPDX-License-Identifier: MIT # +inherit rootfs +inherit image + def generate_image_uuid(d): import uuid From patchwork Wed Oct 12 10:06:40 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felix Moessbauer X-Patchwork-Id: 13005231 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mta-64-227.siemens.flowmailer.net (mta-64-227.siemens.flowmailer.net [185.136.64.227]) by mx.groups.io with SMTP id smtpd.web12.18652.1665569276056380120 for ; Wed, 12 Oct 2022 03:07:58 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=felix.moessbauer@siemens.com header.s=fm1 header.b=EbS4Rfps; spf=pass (domain: rts-flowmailer.siemens.com, ip: 185.136.64.227, mailfrom: fm-72506-202210121007548dfc7516190af709bd-ugbw1d@rts-flowmailer.siemens.com) Received: by mta-64-227.siemens.flowmailer.net with ESMTPSA id 202210121007548dfc7516190af709bd for ; Wed, 12 Oct 2022 12:07:54 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; s=fm1; d=siemens.com; i=felix.moessbauer@siemens.com; h=Date:From:Subject:To:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding:Cc:References:In-Reply-To; bh=4Hmb18/h4s6/emlkQbXQJK7xoRWnRmFpFcQWrDqte/Q=; b=EbS4RfpsGaLP+O3VvOE8xMLNtF5u2z/ETyvVkctS6fRMcPqi0H8LXUzzzwJriXnqH7orui gNxfJ/xQtkbDWMTDpay+LlrNbqO2VBQLbYkd1FjwdNtaloQTsndJHnzxGdESAzPPvO+dby+y WB5ysAd/RjmAlBGrD8duOyTwma5A4=; From: Felix Moessbauer To: cip-dev@lists.cip-project.org Cc: jan.kiszka@siemens.com, quirin.gylstorff@siemens.com, pluto.svc.chengdu.cn@siemens.com, Felix Moessbauer Subject: [isar-cip-core][PATCH 2/3] fix: add squashfs hook to enforce load of module Date: Wed, 12 Oct 2022 12:06:40 +0200 Message-Id: <20221012100641.2986740-3-felix.moessbauer@siemens.com> In-Reply-To: <20221012100641.2986740-1-felix.moessbauer@siemens.com> References: <20221012100641.2986740-1-felix.moessbauer@siemens.com> MIME-Version: 1.0 X-Flowmailer-Platform: Siemens Feedback-ID: 519:519-72506:519-21489:flowmailer List-Id: This patch fixes issues when using a stock debian kernel, as this kernel has no compiled-in support for sqashfs. By explicitly adding the module to the initramfs we ensure that it is available. Signed-off-by: Felix Moessbauer --- kas/opt/ebg-swu.yml | 2 +- .../files/squashfs.hook | 25 +++++++++++++++++++ .../initramfs-squashfs-hook_0.1.bb | 24 ++++++++++++++++++ 3 files changed, 50 insertions(+), 1 deletion(-) create mode 100644 recipes-initramfs/initramfs-squashfs-hook/files/squashfs.hook create mode 100644 recipes-initramfs/initramfs-squashfs-hook/initramfs-squashfs-hook_0.1.bb diff --git a/kas/opt/ebg-swu.yml b/kas/opt/ebg-swu.yml index ce37c36..914c743 100644 --- a/kas/opt/ebg-swu.yml +++ b/kas/opt/ebg-swu.yml @@ -22,7 +22,7 @@ local_conf_header: ebg_swu_image_options: | CIP_IMAGE_OPTIONS_append = " efibootguard.inc image-uuid.inc" initramfs: | - INITRAMFS_INSTALL_append = " initramfs-abrootfs-hook" + INITRAMFS_INSTALL_append = " initramfs-abrootfs-hook initramfs-squashfs-hook" firmware-binaries: | # Add ovmf binaries for qemu IMAGER_BUILD_DEPS_append_qemu-amd64 += "ovmf-binaries" diff --git a/recipes-initramfs/initramfs-squashfs-hook/files/squashfs.hook b/recipes-initramfs/initramfs-squashfs-hook/files/squashfs.hook new file mode 100644 index 0000000..0b9b208 --- /dev/null +++ b/recipes-initramfs/initramfs-squashfs-hook/files/squashfs.hook @@ -0,0 +1,25 @@ +#!/bin/sh +# +# CIP Core, generic profile +# +# Copyright (c) Siemens AG, 2022 +# +# Authors: +# Felix Moessbauer +# + +PREREQ="" +prereqs() +{ + echo "$PREREQ" +} +case $1 in +prereqs) + prereqs + exit 0 + ;; +esac + +. /usr/share/initramfs-tools/hook-functions + +manual_add_modules squashfs diff --git a/recipes-initramfs/initramfs-squashfs-hook/initramfs-squashfs-hook_0.1.bb b/recipes-initramfs/initramfs-squashfs-hook/initramfs-squashfs-hook_0.1.bb new file mode 100644 index 0000000..332278f --- /dev/null +++ b/recipes-initramfs/initramfs-squashfs-hook/initramfs-squashfs-hook_0.1.bb @@ -0,0 +1,24 @@ +# +# CIP Core, generic profile +# +# Copyright (c) Siemens AG, 2022 +# +# Authors: +# Felix Moessbauer +# +# SPDX-License-Identifier: MIT +# + +inherit dpkg-raw + +SRC_URI += "file://squashfs.hook" + +DEBIAN_DEPENDS = "initramfs-tools" + +do_install[cleandirs] += " \ + ${D}/usr/share/initramfs-tools/hooks" + +do_install() { + install -m 0755 "${WORKDIR}/squashfs.hook" \ + "${D}/usr/share/initramfs-tools/hooks/squashfs" +} From patchwork Wed Oct 12 10:06:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felix Moessbauer X-Patchwork-Id: 13005234 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mta-65-227.siemens.flowmailer.net (mta-65-227.siemens.flowmailer.net [185.136.65.227]) by mx.groups.io with SMTP id smtpd.web11.18436.1665569293760706027 for ; Wed, 12 Oct 2022 03:08:14 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=felix.moessbauer@siemens.com header.s=fm1 header.b=ESt0htsL; spf=pass (domain: rts-flowmailer.siemens.com, ip: 185.136.65.227, mailfrom: fm-72506-20221012100811394cf4af91c6d34a7b-89ytoa@rts-flowmailer.siemens.com) Received: by mta-65-227.siemens.flowmailer.net with ESMTPSA id 20221012100811394cf4af91c6d34a7b for ; Wed, 12 Oct 2022 12:08:11 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; s=fm1; d=siemens.com; i=felix.moessbauer@siemens.com; h=Date:From:Subject:To:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding:Cc:References:In-Reply-To; bh=rOOoxzW+tB/eJQCkRcDk1+5FA+OWq0sbHYM3he06YPc=; b=ESt0htsLQMgOGPDqBsuUWU+QwgfCgprp5WOrL5mVmItBYuXiKGJcOKR0H/oeBxBxk+JDof Xi/ibGKJLg0Y1C8HZm45iBs4GCkUz6LUBe6Y7fKFeO1OJ85nUH8QDPou3hz9LwpV0quDTo5Y egbxxYFudMQjBz9IAOw0yoUCJ+myI=; From: Felix Moessbauer To: cip-dev@lists.cip-project.org Cc: jan.kiszka@siemens.com, quirin.gylstorff@siemens.com, pluto.svc.chengdu.cn@siemens.com, Felix Moessbauer Subject: [isar-cip-core][PATCH 3/3] activate nodoc profile for swupdate build Date: Wed, 12 Oct 2022 12:06:41 +0200 Message-Id: <20221012100641.2986740-4-felix.moessbauer@siemens.com> In-Reply-To: <20221012100641.2986740-1-felix.moessbauer@siemens.com> References: <20221012100641.2986740-1-felix.moessbauer@siemens.com> MIME-Version: 1.0 X-Flowmailer-Platform: Siemens Feedback-ID: 519:519-72506:519-21489:flowmailer List-Id: This patch enables the nodoc debian build profile for swupdate. By that, the overall download and build time is drastically reduced. It also helps when building behind proxies that sometimes have issues with large pagets like texlive-extra. Signed-off-by: Felix Moessbauer --- recipes-core/swupdate/swupdate_2021.11-1+debian-gbp.bb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/recipes-core/swupdate/swupdate_2021.11-1+debian-gbp.bb b/recipes-core/swupdate/swupdate_2021.11-1+debian-gbp.bb index 7bcf015..a81c521 100644 --- a/recipes-core/swupdate/swupdate_2021.11-1+debian-gbp.bb +++ b/recipes-core/swupdate/swupdate_2021.11-1+debian-gbp.bb @@ -12,6 +12,10 @@ inherit dpkg-gbp require swupdate.inc + +DEB_BUILD_PROFILES += "nodoc" +DEB_BUILD_OPTIONS += "nodoc" + SRC_URI = "git://salsa.debian.org/debian/swupdate.git;protocol=https;branch=debian/master" SRCREV ="344548c816b555c58ec199f31e45703897d23fb5"