[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 3/3] automation: Add a gzip compressed kernel image test on arm32


  • To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Michal Orzel <michal.orzel@xxxxxxx>
  • Date: Mon, 13 Feb 2023 15:22:10 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=KX0x3F3iElls3V3KW1MLbB7hkF0jKt3vYL8OtbmKh2M=; b=XzLqUsBSY3kysSnsJVf+24qVv3abZL3LNTZFaJgLfNSTj5sMtPH6ctSWg3H18w3JaFg9F1IifR+4UMHOREzveEAvHp3KlAtEXEIXfuQAlLZ7GOyamjTnHA5NhlkTCdwWecgd/ar+MtyKfhyz4MG/VtBuaLOiEU/AmRHxVIrglBAeTCfqdm5iM26DSIUij64GaBfvwdv/RE4wYKc5iRGB3EUzBwwIzsxNPT3TjuBIQjl3B9uOWo6vgDt/Mu7lB/wxdHB2sQNThYIzEEEf1vVmuUG1uIEYXBIpJl1yf3pHUMBpRexpRwNrNMtL8X3awLXmMej2u0FQRBVcZyqutgv5dg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LTTksxpAQHNbli+WIZ8vx4dbGg/st3TmObF8aO+q5t4D0JbxXjndPsm+Z4rcToKJcmOuDesegZ9NfP8FAl5t+8x/q1+mNpK2eA//DyulapZNw9huzqGYDawiOVyLYNfNJtqJDQm3DWcVkF3V+AVyNN6xOdJab8ahQlpc+qtPyCwXK7cqJI3l3HkUQ4XZJYLiYf2Y2rSqCrE/RYOozABX8ewUPaeV0IKlR2hn3lbOPH9xdoOYgvGFe8oYR7J+So13GwA4/9FbAOvP+8SYsFMpEs5rzEOhrsUIUsvosG3ofUxq9IJiqJa/Ga0RIvhLDIjSzizArC+ZxC+nNpNBHuNp3Q==
  • Cc: Michal Orzel <michal.orzel@xxxxxxx>, Doug Goldstein <cardoe@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • Delivery-date: Mon, 13 Feb 2023 14:22:31 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

Xen supports booting gzip compressed kernels, therefore add a new test
job qemu-smoke-dom0less-arm32-gcc-gzip in debug and non-debug variant
that will execute qemu-smoke-dom0less-arm32.sh script to test booting
a domU with a gzip compressed kernel image (in our case zImage).

By passing "gzip" as a test variant, the test will call gzip command
to compress kernel image and use it in ImageBuilder configuration.
No need for a specific check to be executed from domU. Being able to
see a test message from a boot log is sufficient to mark a test as
passed.

Signed-off-by: Michal Orzel <michal.orzel@xxxxxxx>
---
 automation/gitlab-ci/test.yaml                  | 16 ++++++++++++++++
 automation/scripts/qemu-smoke-dom0less-arm32.sh | 13 +++++++++++++
 2 files changed, 29 insertions(+)

diff --git a/automation/gitlab-ci/test.yaml b/automation/gitlab-ci/test.yaml
index c2bcc5d4d3e5..be7a55d89708 100644
--- a/automation/gitlab-ci/test.yaml
+++ b/automation/gitlab-ci/test.yaml
@@ -242,6 +242,22 @@ qemu-smoke-dom0less-arm32-gcc-debug-staticmem:
     - *arm32-test-needs
     - debian-unstable-gcc-arm32-debug-staticmem
 
+qemu-smoke-dom0less-arm32-gcc-gzip:
+  extends: .qemu-arm32
+  script:
+    - ./automation/scripts/qemu-smoke-dom0less-arm32.sh gzip 2>&1 | tee 
${LOGFILE}
+  needs:
+    - *arm32-test-needs
+    - debian-unstable-gcc-arm32
+
+qemu-smoke-dom0less-arm32-gcc-debug-gzip:
+  extends: .qemu-arm32
+  script:
+    - ./automation/scripts/qemu-smoke-dom0less-arm32.sh gzip 2>&1 | tee 
${LOGFILE}
+  needs:
+    - *arm32-test-needs
+    - debian-unstable-gcc-arm32-debug
+
 qemu-alpine-x86_64-gcc:
   extends: .qemu-x86-64
   script:
diff --git a/automation/scripts/qemu-smoke-dom0less-arm32.sh 
b/automation/scripts/qemu-smoke-dom0less-arm32.sh
index f89ee8b6464a..b420ee444f2a 100755
--- a/automation/scripts/qemu-smoke-dom0less-arm32.sh
+++ b/automation/scripts/qemu-smoke-dom0less-arm32.sh
@@ -30,6 +30,15 @@ fi
 "
 fi
 
+if [[ "${test_variant}" == "gzip" ]]; then
+    # Compress kernel image with gzip
+    gzip vmlinuz
+    passed="${test_variant} test passed"
+    domU_check="
+echo \"${passed}\"
+"
+fi
+
 # domU rootfs
 mkdir rootfs
 cd rootfs
@@ -79,6 +88,10 @@ if [[ "${test_variant}" == "static-mem" ]]; then
     echo -e "\nDOMU_STATIC_MEM[0]=\"${domu_base} ${domu_size}\"" >> config
 fi
 
+if [[ "${test_variant}" == "gzip" ]]; then
+    sed -i "s/vmlinuz/vmlinuz.gz/g" config
+fi
+
 rm -rf imagebuilder
 git clone https://gitlab.com/ViryaOS/imagebuilder
 bash imagebuilder/scripts/uboot-script-gen -t tftp -d . -c config
-- 
2.25.1




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.