From nobody Fri Nov 29 05:43:09 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=none dis=none) header.from=kernel.org ARC-Seal: i=1; a=rsa-sha256; t=1647650050; cv=none; d=zohomail.com; s=zohoarc; b=BoM32lVhquTFf7H9CBo5yNouerYpJTZGC/e8q2+vLBVrbXYs04hr5nxKtde9/frBy9mUuvodY8m2np/6m4ILy8pY8C64DWe0tVODNBQDB/0jstD3wejbO6Z2MyJ/NDG6q/HkSx9TNj9ve/dw7blgEzYyRl91MU6a8/YU3ToHuEQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1647650050; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=14/HvlAHYpEQdFaLoR9muAnQTGsP+XXXOZD12fXZZIg=; b=PeGn/Zlkhz7LCH8+lOMpIQ05y/PjgzT7C15308m08g9LUo4f7FrMe1s/+LGV+YwReN3rYJikDhYxods8TirwDvHGZ/ZXEDYhoObrSy87JdOe9+14y2Mp2P1TWh+Q4LA6IWanlwsvCNgLD5QAHby8jkkbjrVbqDdkzDbXKkt7vWc= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1647650050353523.8108134688849; Fri, 18 Mar 2022 17:34:10 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.292295.496518 (Exim 4.92) (envelope-from ) id 1nVN2V-0000ox-Hp; Sat, 19 Mar 2022 00:33:51 +0000 Received: by outflank-mailman (output) from mailman id 292295.496518; Sat, 19 Mar 2022 00:33:51 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nVN2V-0000oq-Ed; Sat, 19 Mar 2022 00:33:51 +0000 Received: by outflank-mailman (input) for mailman id 292295; Sat, 19 Mar 2022 00:33:51 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nVN2U-0000oh-Vh for xen-devel@lists.xenproject.org; Sat, 19 Mar 2022 00:33:50 +0000 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 3e6952fc-a71c-11ec-a405-831a346695d4; Sat, 19 Mar 2022 01:33:49 +0100 (CET) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 965C96172C; Sat, 19 Mar 2022 00:33:48 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 72EB3C340E8; Sat, 19 Mar 2022 00:33:47 +0000 (UTC) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 3e6952fc-a71c-11ec-a405-831a346695d4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1647650027; bh=6fcuGmN0VOLiEsFwZuvE42PfLHtwz8AS00f3BuXsHLc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=VJBrcvGzAwk2NJLCL2vgWEwgRqsm7D2NQAs4UedGwFSJxTl1OJlLAS7gPybXIgyWU 0IIXrncNTajY95Ybj5a+X9DJahIfJOvThqIfat3MajaaE/gaUXXviIVALvB+U94Ui5 kmlm6kT9b/foecyKTD0AC6MCjtLqAjLBODqIaTM5t3jHkWMMXFo3G0pnAgmVkpL/4q XM2xD5uAxomGi9jPLFqew504SNpqu7Wcz57Q1JMyrAOh0JGqkI/xXchwuXHMvUD61X PY4NTlbhJVAY+aaDhjXczlTY6lN9Lo4Fh1Xxva4/8CjKQLm8myn7jwGYJvZyTxb7dn nRxY01Vkm74pw== From: Stefano Stabellini To: xen-devel@lists.xenproject.org Cc: sstabellini@kernel.org, cardoe@cardoe.com, wl@xen.org, andrew.cooper3@citrix.com, anthony.perard@citrix.com, bertrand.marquis@arm.com, Stefano Stabellini Subject: [PATCH v3 1/2] gitlab-ci: add qemu-system-arm to the existing tests-artifacts container Date: Fri, 18 Mar 2022 17:32:20 -0700 Message-Id: <20220319003221.3012314-1-sstabellini@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @kernel.org) X-ZM-MESSAGEID: 1647650051931100001 Content-Type: text/plain; charset="utf-8" From: Stefano Stabellini Add qemu-system-arm to the existing test-artifacts qemu container (which doesn't get build for every iteration but only updated once in a while.) With qemu-system-arm available, we'll be able to run ARM32 tests. This patch also bumps the QEMU version to v6.0.0 for both arm32 and arm64 (the test-artifacts container is one, shared for both). Signed-off-by: Stefano Stabellini Reviewed-by: Anthony PERARD --- automation/gitlab-ci/build.yaml | 14 ++++++++++++-- automation/gitlab-ci/test.yaml | 4 ++-- ...arm64v8.dockerfile =3D> 6.0.0-arm64v8.dockerfile} | 5 +++-- 3 files changed, 17 insertions(+), 6 deletions(-) rename automation/tests-artifacts/qemu-system-aarch64/{5.2.0-arm64v8.docke= rfile =3D> 6.0.0-arm64v8.dockerfile} (95%) diff --git a/automation/gitlab-ci/build.yaml b/automation/gitlab-ci/build.y= aml index cc36428cf5..72f2a317ac 100644 --- a/automation/gitlab-ci/build.yaml +++ b/automation/gitlab-ci/build.yaml @@ -591,9 +591,9 @@ kernel-5.9.9-arm64-export: tags: - arm64 =20 -qemu-system-aarch64-5.2.0-arm64-export: +qemu-system-aarch64-6.0.0-arm64-export: stage: build - image: registry.gitlab.com/xen-project/xen/tests-artifacts/qemu-system-a= arch64:5.2.0-arm64v8 + image: registry.gitlab.com/xen-project/xen/tests-artifacts/qemu-system-a= arch64:6.0.0-arm64v8 script: - mkdir binaries && cp /qemu-system-aarch64 binaries/qemu-system-aarch= 64 artifacts: @@ -602,6 +602,16 @@ qemu-system-aarch64-5.2.0-arm64-export: tags: - arm64 =20 +qemu-system-aarch64-6.0.0-arm32-export: + stage: build + image: registry.gitlab.com/xen-project/xen/tests-artifacts/qemu-system-a= arch64:6.0.0-arm64v8 + script: + - mkdir binaries && cp /qemu-system-arm binaries/qemu-system-arm + artifacts: + paths: + - binaries/qemu-system-arm + tags: + - arm64 =20 # x86_64 test artifacts =20 diff --git a/automation/gitlab-ci/test.yaml b/automation/gitlab-ci/test.yaml index 47e8704df3..ec2a2e1607 100644 --- a/automation/gitlab-ci/test.yaml +++ b/automation/gitlab-ci/test.yaml @@ -33,7 +33,7 @@ qemu-alpine-arm64-gcc: - alpine-3.12-gcc-arm64 - alpine-3.12-arm64-rootfs-export - kernel-5.9.9-arm64-export - - qemu-system-aarch64-5.2.0-arm64-export + - qemu-system-aarch64-6.0.0-arm64-export artifacts: paths: - smoke.serial @@ -81,7 +81,7 @@ qemu-smoke-arm64-gcc: dependencies: - debian-unstable-gcc-arm64 - kernel-5.9.9-arm64-export - - qemu-system-aarch64-5.2.0-arm64-export + - qemu-system-aarch64-6.0.0-arm64-export artifacts: paths: - smoke.serial diff --git a/automation/tests-artifacts/qemu-system-aarch64/5.2.0-arm64v8.d= ockerfile b/automation/tests-artifacts/qemu-system-aarch64/6.0.0-arm64v8.do= ckerfile similarity index 95% rename from automation/tests-artifacts/qemu-system-aarch64/5.2.0-arm64v8.do= ckerfile rename to automation/tests-artifacts/qemu-system-aarch64/6.0.0-arm64v8.dock= erfile index e105a1c636..793432d40b 100644 --- a/automation/tests-artifacts/qemu-system-aarch64/5.2.0-arm64v8.dockerfi= le +++ b/automation/tests-artifacts/qemu-system-aarch64/6.0.0-arm64v8.dockerfi= le @@ -3,7 +3,7 @@ LABEL maintainer.name=3D"The Xen Project" \ maintainer.email=3D"xen-devel@lists.xenproject.org" =20 ENV DEBIAN_FRONTEND=3Dnoninteractive -ENV QEMU_VERSION=3D5.2.0 +ENV QEMU_VERSION=3D6.0.0 ENV USER root =20 RUN mkdir /build @@ -25,7 +25,7 @@ RUN apt-get update && \ tar xvJf qemu-"$QEMU_VERSION".tar.xz && \ cd qemu-"$QEMU_VERSION" && \ ./configure \ - --target-list=3Daarch64-softmmu \ + --target-list=3Darm-softmmu,aarch64-softmmu \ --enable-system \ --disable-blobs \ --disable-bsd-user \ @@ -68,6 +68,7 @@ RUN apt-get update && \ && \ make -j$(nproc) && \ cp ./build/qemu-system-aarch64 / && \ + cp ./build/qemu-system-arm / && \ cd /build && \ rm -rf qemu-"$QEMU_VERSION"* && \ apt-get autoremove -y && \ --=20 2.25.1 From nobody Fri Nov 29 05:43:09 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=none dis=none) header.from=kernel.org ARC-Seal: i=1; a=rsa-sha256; t=1647650067; cv=none; d=zohomail.com; s=zohoarc; b=gDcOlD4QwlkkCyomfTk2guKl1h9BMvQz/IjqIWeOFV1HchIB4p5JKKI5Cm5AXBUukIBl/fudMP/TPyd5M4X/4ZJ46SdiyNN3awo8UWV1S8yJVKNZi87KDOthyuzNbUgKsATBcr9hhehCkidJkdJLCZanXej3XKGQFUSeIFO9vIE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1647650067; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=HXvBbsqTqrsuIcyjD5nzXZi/AbYzK0FV4O6FNWMjoCo=; b=nKq4WPiU0/5lN8ANInppougOY9hEnGq8UaFwKVJyBt4m4UpMNiWDtSOxD/Xutkw3/6L49b+hdHDt9O5QqRDP8U0r5ok08jmm+OZP0xmZSTpRE2Mt5kPj0LGm5N6G0kirPB1fwucV8zEr1XQaa/UBF5FD/GK9jl99JtxhjRtNVvw= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1647650067023546.0900517605003; Fri, 18 Mar 2022 17:34:27 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.292296.496529 (Exim 4.92) (envelope-from ) id 1nVN2W-00014v-Pk; Sat, 19 Mar 2022 00:33:52 +0000 Received: by outflank-mailman (output) from mailman id 292296.496529; Sat, 19 Mar 2022 00:33:52 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nVN2W-00014o-Lr; Sat, 19 Mar 2022 00:33:52 +0000 Received: by outflank-mailman (input) for mailman id 292296; Sat, 19 Mar 2022 00:33:51 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nVN2V-0000oo-Gd for xen-devel@lists.xenproject.org; Sat, 19 Mar 2022 00:33:51 +0000 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 3eb09780-a71c-11ec-8fbc-03012f2f19d4; Sat, 19 Mar 2022 01:33:50 +0100 (CET) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 1C53061678; Sat, 19 Mar 2022 00:33:49 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 09C39C36AE3; Sat, 19 Mar 2022 00:33:48 +0000 (UTC) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 3eb09780-a71c-11ec-8fbc-03012f2f19d4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1647650028; bh=LePh5pv9odEWqM2WQtVDEeyx/R3Q3BxHjixjaGq6vMk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hliFhbz9amOFiTAErL5AkOGEad8uSa3lyrkx9BGpvomg698YruxzkSurphzOgIZhD 10aZqbyIrfc43+VG6bztJLNZkjzyRELVkNXskyWoFEdJYKaWvdPgmzZsLNfSpHXElP Q2r23puAITXMV0CQEOxpiDxL07MI1i3KDPjRUshqoJtLQkrw87rSaI5rIBBS3DluYj CZ23DVSqWD9X47wwVdJAVtDcZKml4NlIAqIdFL+vZ9cYUsD8iuNHJtKIAFX/EackgR M9tgHtK1CsjaiXakblv5ryPDyZm6MTHlnKBNUbpIET0BhG566er7/eXavWh5Lg4n0s Z05WFSqQENi9A== From: Stefano Stabellini To: xen-devel@lists.xenproject.org Cc: sstabellini@kernel.org, cardoe@cardoe.com, wl@xen.org, andrew.cooper3@citrix.com, anthony.perard@citrix.com, bertrand.marquis@arm.com, Stefano Stabellini Subject: [PATCH v3 2/2] gitlab-ci: add an ARM32 qemu-based smoke test Date: Fri, 18 Mar 2022 17:32:21 -0700 Message-Id: <20220319003221.3012314-2-sstabellini@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @kernel.org) X-ZM-MESSAGEID: 1647650067409100001 Content-Type: text/plain; charset="utf-8" Add a minimal ARM32 smoke test based on qemu-system-arm, as provided by the test-artifacts qemu container. The minimal test simply boots Xen (built from previous build stages) and Dom0. The test is fetching the Dom0 kernel and initrd from Debian Jessie: they work just fine and this way we don't have to maintain a build for them too. Signed-off-by: Stefano Stabellini --- Changes in v3: - use long options for curl - use curl --output Changes in v2: - improve comments - don't limit dom0 cpus - decrease mem to 1024M and dom0_mem=3D512M - use Debian Bullseye instead of Jessie --- automation/gitlab-ci/test.yaml | 23 ++++++++ automation/scripts/qemu-smoke-arm32.sh | 72 ++++++++++++++++++++++++++ 2 files changed, 95 insertions(+) create mode 100755 automation/scripts/qemu-smoke-arm32.sh diff --git a/automation/gitlab-ci/test.yaml b/automation/gitlab-ci/test.yaml index ec2a2e1607..42cd725a12 100644 --- a/automation/gitlab-ci/test.yaml +++ b/automation/gitlab-ci/test.yaml @@ -95,6 +95,29 @@ qemu-smoke-arm64-gcc: - /^coverity-tested\/.*/ - /^stable-.*/ =20 +qemu-smoke-arm32-gcc: + stage: test + image: registry.gitlab.com/xen-project/xen/${CONTAINER} + variables: + CONTAINER: debian:unstable-arm64v8 + script: + - ./automation/scripts/qemu-smoke-arm32.sh 2>&1 | tee qemu-smoke-arm32= .log + dependencies: + - debian-unstable-gcc-arm32 + - qemu-system-aarch64-6.0.0-arm32-export + artifacts: + paths: + - smoke.serial + - '*.log' + when: always + tags: + - arm64 + except: + - master + - smoke + - /^coverity-tested\/.*/ + - /^stable-.*/ + qemu-smoke-x86-64-gcc: stage: test image: registry.gitlab.com/xen-project/xen/${CONTAINER} diff --git a/automation/scripts/qemu-smoke-arm32.sh b/automation/scripts/qe= mu-smoke-arm32.sh new file mode 100755 index 0000000000..162922ace5 --- /dev/null +++ b/automation/scripts/qemu-smoke-arm32.sh @@ -0,0 +1,72 @@ +#!/bin/bash + +set -ex + +export DEBIAN_FRONTENT=3Dnoninteractive +apt-get -qy update +apt-get -qy install --no-install-recommends device-tree-compiler \ + curl + +cd binaries +curl --fail --silent --show-error --location --output vmlinuz http://http.= us.debian.org/debian/dists/jessie/main/installer-armhf/current/images/netbo= ot/vmlinuz +curl --fail --silent --show-error --location --output initrd.gz http://htt= p.us.debian.org/debian/dists/jessie/main/installer-armhf/current/images/net= boot/initrd.gz + +kernel=3D`stat -L --printf=3D"%s" vmlinuz` +initrd=3D`stat -L --printf=3D"%s" initrd.gz` + +# For Xen, we need a couple of more node. Dump the DT from QEMU and add th= em +# XXX QEMU looks for "efi-virtio.rom" even if it is unneeded +curl -fsSLO https://github.com/qemu/qemu/raw/v5.2.0/pc-bios/efi-virtio.rom +./qemu-system-arm \ + -machine virt-6.0 \ + -machine virtualization=3Dtrue \ + -smp 4 \ + -m 1024 \ + -serial stdio \ + -monitor none \ + -display none \ + -machine dumpdtb=3Dvirt.dtb + +dtc -I dtb -O dts virt.dtb > virt.dts + +cat >> virt.dts << EOF +/ { + chosen { + #address-cells =3D <0x2>; + #size-cells =3D <0x2>; + stdout-path =3D "/pl011@9000000"; + xen,xen-bootargs =3D "console=3Ddtuart dtuart=3D/pl011@9000000 dom= 0_mem=3D512M bootscrub=3D0"; + xen,dom0-bootargs =3D "console=3Dtty0 console=3Dhvc0 earlyprintk clk_ign= ore_unused root=3D/dev/ram0 rdinit=3D/bin/sh init=3D/bin/sh"; + dom0 { + compatible =3D "xen,linux-zimage", "xen,multiboot-module"; + reg =3D <0x0 0x1000000 0x0 $kernel>; + }; + dom0-ramdisk { + compatible =3D "xen,linux-initrd", "xen,multiboot-module"; + reg =3D <0x0 0x3200000 0x0 $initrd>; + }; + }; +}; +EOF +dtc -I dts -O dtb virt.dts > virt.dtb + +rm -f smoke.serial +set +e +timeout -k 1 240 \ +./qemu-system-arm \ + -machine virt-6.0 \ + -machine virtualization=3Dtrue \ + -smp 4 \ + -m 1024 \ + -serial stdio \ + -monitor none \ + -display none \ + -dtb virt.dtb \ + -no-reboot \ + -kernel ./xen \ + -device loader,file=3D./vmlinuz,addr=3D0x1000000 \ + -device loader,file=3D./initrd.gz,addr=3D0x3200000 |& tee smoke.serial + +set -e +(grep -q "^BusyBox" smoke.serial) || exit 1 +exit 0 --=20 2.25.1