Message ID | 20250317121616.40687-9-roger.pau@citrix.com (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | automation/cirrus-ci: add smoke tests of the FreeBSD builds | expand |
On 3/17/25 1:16 PM, Roger Pau Monne wrote: > Introduce a basic set of smoke tests using the XTF selftest image, and run > them on QEMU. Use the matrix keyword to create a different task for each > XTF flavor on each FreeBSD build. > > Signed-off-by: Roger Pau Monné<roger.pau@citrix.com> > --- > I've used the current version of FreeBSD to run the tests, but it might be > safer to use the latest production (release) version instead. > --- > .cirrus.yml | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++ > CHANGELOG.md | 1 + Acked-by: Oleksii Kurochko<oleksii.kurochko@gmail.com> ~ Oleksii > 2 files changed, 55 insertions(+) > > diff --git a/.cirrus.yml b/.cirrus.yml > index c74d5cf6eb9a..9c8b4b235cfd 100644 > --- a/.cirrus.yml > +++ b/.cirrus.yml > @@ -5,6 +5,8 @@ freebsd_versions: &FREEBSD_VERSIONS > FREEBSD_14: freebsd-14-2 > FREEBSD_15: freebsd-15-0-snap > > +# Build jobs > + > freebsd_template: &FREEBSD_ENV > environment: > APPEND_LIB: /usr/local/lib > @@ -118,3 +120,55 @@ task: > xtf_artifacts: > path: xtf/tests/selftest/test-*-selftest > type: application/octet-stream > + > +# Test jobs > + > +task: > + name: 'FreeBSD: XTF selftest' > + > + << : *FREEBSD_ENV_LATEST > + > + env: > + matrix: > + FREEBSD_BUILD: $FREEBSD_13 > + FREEBSD_BUILD: $FREEBSD_14 > + FREEBSD_BUILD: $FREEBSD_15 > + > + depends_on: > + - freebsd_full_$FREEBSD_BUILD > + - xtf > + > + install_script: pkg install -y qemu-nox11 expect > + > + env: > + matrix: > + XTF_ARCH: hvm32 > + XTF_ARCH: hvm32pae > + XTF_ARCH: hvm32pse > + XTF_ARCH: hvm64 > + XTF_ARCH: pv64 > + > + fetch_script: > + - fetchhttps://api.cirrus-ci.com/v1/artifact/build/$CIRRUS_BUILD_ID/xtf/xtf.zip > + - fetchhttps://api.cirrus-ci.com/v1/artifact/build/$CIRRUS_BUILD_ID/freebsd_full_$FREEBSD_BUILD/xen.zip > + - unzip xtf.zip > + - unzip xen.zip > + > + test_script: | > + case "$XTF_ARCH" in \ > + *hvm*) \ > + XEN_EXTRA_CMD="dom0=pvh dom0-iommu=none" \ > + ;; \ > + esac > + export TEST_CMD="qemu-system-x86_64 -kernel xen/xen -initrd xtf/tests/selftest/test-${XTF_ARCH}-selftest \ > + -append \"loglvl=all console=com1 noreboot console_timestamps=boot dom0=verbose ${XEN_EXTRA_CMD}\" \ > + -m 512 -nographic -monitor none -serial stdio" > + export TEST_LOG="serial-${FREEBSD_BUILD}-${XTF_ARCH}.txt" > + export PASSED="Test result: SUCCESS" > + export TEST_TIMEOUT=120 > + ./automation/scripts/console.exp | sed 's/\r\+$//' > + > + always: > + serial_artifacts: > + path: serial-*.txt > + type: text/plain > diff --git a/CHANGELOG.md b/CHANGELOG.md > index 7201c484f899..16c14e933c80 100644 > --- a/CHANGELOG.md > +++ b/CHANGELOG.md > @@ -12,6 +12,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) > - On x86: > - Option to attempt to fixup p2m page-faults on PVH dom0. > - Resizable BARs is supported for PVH dom0. > + - Smoke tests for the FreeBSD Xen builds in Cirrus CI. > > ### Removed >
On Mon, 17 Mar 2025, Roger Pau Monne wrote: > Introduce a basic set of smoke tests using the XTF selftest image, and run > them on QEMU. Use the matrix keyword to create a different task for each > XTF flavor on each FreeBSD build. > > Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> > --- > I've used the current version of FreeBSD to run the tests, but it might be > safer to use the latest production (release) version instead. It is better to avoid using "current" (I called it "latest" in my previous email) if it is rolling. Otherwise, it is OK. Other than that, it is great.
On Mon, Mar 17, 2025 at 05:09:25PM -0700, Stefano Stabellini wrote: > On Mon, 17 Mar 2025, Roger Pau Monne wrote: > > Introduce a basic set of smoke tests using the XTF selftest image, and run > > them on QEMU. Use the matrix keyword to create a different task for each > > XTF flavor on each FreeBSD build. > > > > Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> > > --- > > I've used the current version of FreeBSD to run the tests, but it might be > > safer to use the latest production (release) version instead. > > It is better to avoid using "current" (I called it "latest" in my > previous email) if it is rolling. Otherwise, it is OK. Yes, will adjust to use production instead of current and resend the tail of the series. > Other than that, it is great. Thanks. Afterwards I would like to add a specific UBSAN enabled build, and do some more testing with it. I found clang UBSAN more complete than gcc (specially with the UB pointer arithmetic checks). Roger.
diff --git a/.cirrus.yml b/.cirrus.yml index c74d5cf6eb9a..9c8b4b235cfd 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -5,6 +5,8 @@ freebsd_versions: &FREEBSD_VERSIONS FREEBSD_14: freebsd-14-2 FREEBSD_15: freebsd-15-0-snap +# Build jobs + freebsd_template: &FREEBSD_ENV environment: APPEND_LIB: /usr/local/lib @@ -118,3 +120,55 @@ task: xtf_artifacts: path: xtf/tests/selftest/test-*-selftest type: application/octet-stream + +# Test jobs + +task: + name: 'FreeBSD: XTF selftest' + + << : *FREEBSD_ENV_LATEST + + env: + matrix: + FREEBSD_BUILD: $FREEBSD_13 + FREEBSD_BUILD: $FREEBSD_14 + FREEBSD_BUILD: $FREEBSD_15 + + depends_on: + - freebsd_full_$FREEBSD_BUILD + - xtf + + install_script: pkg install -y qemu-nox11 expect + + env: + matrix: + XTF_ARCH: hvm32 + XTF_ARCH: hvm32pae + XTF_ARCH: hvm32pse + XTF_ARCH: hvm64 + XTF_ARCH: pv64 + + fetch_script: + - fetch https://api.cirrus-ci.com/v1/artifact/build/$CIRRUS_BUILD_ID/xtf/xtf.zip + - fetch https://api.cirrus-ci.com/v1/artifact/build/$CIRRUS_BUILD_ID/freebsd_full_$FREEBSD_BUILD/xen.zip + - unzip xtf.zip + - unzip xen.zip + + test_script: | + case "$XTF_ARCH" in \ + *hvm*) \ + XEN_EXTRA_CMD="dom0=pvh dom0-iommu=none" \ + ;; \ + esac + export TEST_CMD="qemu-system-x86_64 -kernel xen/xen -initrd xtf/tests/selftest/test-${XTF_ARCH}-selftest \ + -append \"loglvl=all console=com1 noreboot console_timestamps=boot dom0=verbose ${XEN_EXTRA_CMD}\" \ + -m 512 -nographic -monitor none -serial stdio" + export TEST_LOG="serial-${FREEBSD_BUILD}-${XTF_ARCH}.txt" + export PASSED="Test result: SUCCESS" + export TEST_TIMEOUT=120 + ./automation/scripts/console.exp | sed 's/\r\+$//' + + always: + serial_artifacts: + path: serial-*.txt + type: text/plain diff --git a/CHANGELOG.md b/CHANGELOG.md index 7201c484f899..16c14e933c80 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) - On x86: - Option to attempt to fixup p2m page-faults on PVH dom0. - Resizable BARs is supported for PVH dom0. + - Smoke tests for the FreeBSD Xen builds in Cirrus CI. ### Removed
Introduce a basic set of smoke tests using the XTF selftest image, and run them on QEMU. Use the matrix keyword to create a different task for each XTF flavor on each FreeBSD build. Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> --- I've used the current version of FreeBSD to run the tests, but it might be safer to use the latest production (release) version instead. --- .cirrus.yml | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++ CHANGELOG.md | 1 + 2 files changed, 55 insertions(+)