Commit Graph
240 Commits
Author SHA1 Message Date
Javi Merino 4d8aa53ed1 CI: Refresh the Debian 12 arm64 container
Rework the container to user heredocs for readability, derive from
bookworm-slim and use apt-get --no-install-recommends to keep the size down.

Additionally:

 * Make it a non-root container.
 * Drop libext2fs-dev which is an x86-only dependency.
 * Add libncurses5-dev for xentop and zlib1g-dev which was missing from the
   libxenguest decompressors.
 * As there's no ninja, the container can no loger build QEMU so drop
   libglib2.0-dev and libpixman-1-dev too.
 * Swap libyajl-dev for libjson-c-dev given the deprecation of the former.

Rename the job to debian-12-arm64-* to follow the naming scheme of all the
other CI jobs.

This reduces the size of the debian:12-arm64v8 from 2.25GB down to 1.62GB.

Signed-off-by: Javi Merino <javi.merino@cloud.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Michal Orzel <michal.orzel@amd.com>
2026-05-29 23:13:02 +01:00
Javi Merino 81c9fa421d CI: Refresh the Debian 12 arm32 cross compile container
Rework the container to user heredocs for readability, derive from
bookworm-slim and use apt-get --no-install-recommends to keep the size down.

Convert it to being a non-root container.  Add checkpolicy as FLASK is an
available build option for arm32 under Randconfig testing.

Rename the CI jobs to debian-12-arm32-* to follow the naming scheme of all the
other CI jobs.

No functional change.

Signed-off-by: Javi Merino <javi.merino@cloud.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Michal Orzel <michal.orzel@amd.com>
2026-05-29 23:13:02 +01:00
Jan Beulich 2121f89503 CI: collect certain intermediate files as artifacts
When one of the linking passes fails, additional intermediate files are
still in place. Having them available for analysis of the underlying
problem can be pretty helpful. Collect some into a new intermediates/
directory. (Nothing new will be collected if linking succeeds.)

As the script is run with -e passed to bash, defer exit if the main
"make" (or substituent script thereof) failed. This way more artifacts
are collected, potentially making it easier to analyze the failure.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2026-05-11 18:40:58 -07:00
Jan Beulich 87dd994a3e CI: re-work Xen artifacts collection
There's no need to do this separately from three places. Once moved to the
bottom of the script, the need for this to be a function also disappears.

While there also make sure xen-syms is collected. This is rather more
useful for analysis of possible problems than its stripped counterpart.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2026-05-11 18:40:53 -07:00
Javi Merino e8c1feab33 CI: Refresh the Debian 12 cppcheck container
Rework the container to derive from bookworm-slim, and to build and run
cppcheck as a normal user.  User heredocs for readability and use apt-get
--no-install-recommends to keep the size down.

Changed the libpcre3-dev dependency to libpcre3, as the -dev package
is only needed for building, not for running.

Signed-off-by: Javi Merino <javi.merino@cloud.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2026-05-06 13:14:36 +01:00
Denis Mukhin f7173bff9d xtf: fix argo test parameters
The mac-permissive= option is currently ignored because Argo configuration
parameters are comma-separated.

Fix the missing comma in the XTF test arguments.

Fixes: 150c6ef459 ("CI: add argo x86 XTF test")
Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2026-02-14 01:01:33 +00:00
Denis Mukhin 032ac14b05 scripts/config: hook to automation build script
Use the new .config manipulation tool to toggle CONFIG_DEBUG in the
Xen automation build script.

Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2026-02-04 15:44:06 -08:00
Denis Mukhin 3a7b635365 automation: align XTF qemu parameters across achitectures
It is handy to have 2 CPUs and more RAM for smoke testing a hypervisor
change via XTF.

Align x86 QEMU configuration with Arm for XTF tests: 2 CPU and 2G of RAM.

Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2026-02-04 14:35:00 -08:00
Andrew Cooper 809bd86db6 CI: Update x86 to use Debian Trixie
With the exception of the custom IBT job, copy all Debian 12 jobs making
Debian 13 versions, then trim the Debian 12 ranconfig jobs.

Update the test jobs using Debian 12 to use 13.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Denis Mukhin <dmukhin@ford.com>
Reviewed-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-09-13 01:02:28 +01:00
Andrew Cooper fdc2023945 CI: Use pipefail in scripts/build
Marek noticed that some builds were failing with:

  + cd dist/install
  + find
  + cpio -R 0:0 -o -H newc
  ./automation/scripts/build: line 111: cpio: command not found
  + gzip

but succeeding overall, and producing a zero length xen-tools.cpio.gz as an
artefact.

In fact, it's all of:

  archlinux:current
  debian:12-x86_32
  fedora:41
  opensuse:tumbleweed
  ubuntu (all versions)

Add cpio into all of these containers, including opensuse leap for good
measure, and use pipefail in the build script.

Fixes: 4611ae6fb8 ("CI: save toolstack artifact as cpio.gz")
Reported-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Denis Mukhin <dmukhin@ford.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-09-13 01:02:28 +01:00
Andrew Cooper e2bff412e0 CI: Make qemu-smoke-x86-64-gcc-efi compatible with Debian Trixie
The OVMF package in Debian Trixie has _4M suffixes on the files.  Have
scripts/include/xtf-x86-64-efi check for this before falling back to no
suffix.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Denis Mukhin <dmukhin@ford.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-09-13 01:02:28 +01:00
Andrew Cooper 5ec86c3b83 CI: Update ppc64 to use Debian Trixie
Everything works fine with Debian 13.  Provide two new build jobs (for a total
of 6), and update the test jobs.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Denis Mukhin <dmukhin@ford.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-09-13 01:02:28 +01:00
Andrew Cooper aad6ebf059 CI: Update riscv64 to use Debian Trixie
Everything works fine with Debian 13.  Provide two new build jobs, and update
both the randconfig the test jobs.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
2025-09-10 17:30:22 +01:00
Andrew Cooper e3042c9fc2 CI: Create initrd fragments explicitly as root
We have a mix of root and non-root containers, and are trying to become
rootless.  This can cause the local CPIO fragements to end up being user:user
in the test environment.

Nothing seems to go wrong so far, but it's a trap waiting to happen.

Make everything consistently root for the initrds, irrespective of the
rootness of the container the test is running in.

No practical change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Denis Mukhin <dmukhin@ford.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-09-10 10:19:25 +01:00
Victor Lira 0dcc23db96 automation: edit expect script to separate error message lines
The errors can happen in the middle of a console line which causes the message
to appear at the end of the current line.

Prepend a newline to clearly separate the error line.

Signed-off-by: Victor Lira <victorm.lira@amd.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-09-03 17:20:05 -07:00
Victor Lira a406195c15 automation: call expect script with redirected standard error
In the console expect script, "send_error" will send a message to standard
error. Current use of this script redirects only standard output into a
pipeline. This causes the error messages to sometimes appear hidden in the
middle of the test logs.

Redirect also standard error to clearly show when a test has timed out or hit
EOF.

Signed-off-by: Victor Lira <victorm.lira@amd.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-09-03 17:20:05 -07:00
Andrew Cooper 011a9e2566 CI: Use 'watchdog' for x86 hardware
This detects various hangs and turns them into a crash with backtrace.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-08-22 23:34:07 +01:00
Denis Mukhin 150c6ef459 CI: add argo x86 XTF test
Introduce new CI job to run x86 XTF argo test under QEMU to smoke test argo
feature functionality in upstream CI.

The new job lead time is ~30s, limit max job duration to 60s.

Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-07-25 13:17:39 -07:00
Victor Lira 2f73ef4bd7 automation: disable terminal echo in xilinx test scripts
The default terminal settings in Linux will enable echo which interferes with
these tests. Set the value in the script to avoid failure caused by a settings
reset.

Signed-off-by: Victor Lira <victorm.lira@amd.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-06-17 10:59:52 -07:00
Anthony PERARD 321b74f29d CI: Add timing to junit
Signed-off-by: Anthony PERARD <anthony.perard@vates.tech>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
2025-06-06 12:07:26 +02:00
Anthony PERARD 1cdf180308 CI: Fix status check for tools/tests
Without "pipefail", $? have the exit value of `tee`, which should
always be 0. But instead of using "pipefail", do collect the value of
from the test with $PIPESTATUS.

Signed-off-by: Anthony PERARD <anthony.perard@vates.tech>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-06-06 12:06:34 +02:00
Anthony PERARD a6eb429d51 CI: Use CDATA avoid the need to escape tests outputs
This is easier than escaping individual characters, especially '&'
and '<' which are problematic if present.

We might still need to escape ']]>' if this string is present in the
test output, but hopefully not.

Signed-off-by: Anthony PERARD <anthony.perard@vates.tech>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-06-06 12:04:05 +02:00
Andrew Cooper 2c4a3d6889 CI: Adjust how domU is packaged in dom0
Package domU for dom0 and insert into the uncompressed part of dom0's rootfs,
rather than recompressing it as part of the overlay.

For Qubes, this avoids putting the domU kernel in dom0's rootfs for tests
which aren't going to boot a guest.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
Reviewed-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
2025-06-03 12:10:36 +01:00
Andrew Cooper 3905638437 CI: Use bash arrays to simplify dom0 rootfs construction
For Qubes, this requires switching from sh to bash.

This reduces the number of times the target filename needs to be written to 1.

Expand the comment to explain the concatenation constraints.

No functional change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
Reviewed-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
2025-06-03 12:10:36 +01:00
Oleksii Kurochko b3d5fad63a xen/riscv: introduce support of Svpbmt extension and make it mandatory
Svpbmt extension is necessary for chaning the memory type for a page contains
a combination of attributes that indicate the cacheability, idempotency,
and ordering properties for access to that page.

As a part of the patch the following is introduced:
- Svpbmt memory type defintions: PTE_PBMT_{NOCACHE,IO}.
- PAGE_HYPERVISOR_{NOCACHE,WC}.
- RISCV_ISA_EXT_svpbmt and add a check in runtime that Svpbmt is
  supported by platform.
- Update riscv/booting.txt with information about Svpbmt.
- Update logic of pt_update_entry() to take into account PBMT bits.

Use 'unsigned long' for pte_attr_t as PBMT bits are 61 and 62 and it doesn't
fit into 'unsigned int'. Also, update function prototypes which uses
'unsigned int' for flags/attibutes.

Enable Svpbmt for testing in QEMU as it is now mandatory for Xen work.

Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
2025-06-02 12:42:23 +02:00
Andrew Cooper 0e7f6c6098 CI: Drop custom handling of tools/tests
... and use them from their installed location.

The full reclusive copy of tools/tests brings in all build and intermediate
artefacts.  e.g. for test-tsx alone:

  ./tests/tsx
  ./tests/tsx/.test-tsx.o.d
  ./tests/tsx/test-tsx.o
  ./tests/tsx/.gitignore
  ./tests/tsx/test-tsx
  ./tests/tsx/Makefile
  ./tests/tsx/test-tsx.c

duplicating the test binary which is also in ./usr/lib/xen/tests

Rewrite run-tools-tests to run tests from their installed
location (/usr/lib/xen/tests in alpine), which effectively removes the outer
loop over $dir.

No practical change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
Reviewed-by: Denis Mukhin <dmukhin@ford.com>
2025-05-28 12:29:33 +01:00
Andrew Cooper 2e6bf63fb1 CI/qubes: Deduplicate the handling of ${dom0_check}
Make it clearer that ${dom0_check} is unconditional.

No functional change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-05-28 12:29:33 +01:00
Andrew Cooper 05ea324725 CI: Rename qubes-x86-64 parameter "" to "dom0pv"
This really is a legacy of not having parameters to start with.  Give PV dom0
with a PVH domU a real name.

Reformat the table to fix alignment.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
2025-05-27 12:21:38 +01:00
Anthony PERARD e43d9621d8 automation: Avoid changing source files for randconfig tests
We should avoid changing files from the source tree if we don't intend
to commit the result.

We don't really need to check if $EXTRA_FIXED_RANDCONFIG is empty so
add it to the temporary file in all cases.

Signed-off-by: Anthony PERARD <anthony.perard@vates.tech>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-25 11:26:29 +02:00
Denis Mukhin 934fcfb17d CI: switch arm64 XTF test runner to qemu-xtf.sh
Hook arm64 QEMU configuration to qemu-xtf.sh and use new script in arm64 CI
jobs.

Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-22 13:07:13 -07:00
Denis Mukhin 23041e72d9 CI: switch x86 EFI smoke test runner to qemu-xtf.sh
Use qemu-xtf.sh for qemu-smoke-x86-64-gcc-efi job.

Lead time is reduced a bit since not all XTF code base is built, just the
required test.

Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-22 13:07:12 -07:00
Denis Mukhin a22f80e758 CI: unify x86 XTF test runner
Add test runner script qemu-xtf.sh which is allows any XTF x86 test to be
easily executed. Test runner is invoked from the qemu-smoke* jobs with the
hardcoded parameters.

Each x86 XTF job lead time is reduced a bit since only the test-related code
is built, not the entire XTF project.

Add .gitignore to avoid committing test artifacts by mistake.

Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-22 13:07:12 -07:00
Andrew Cooper 7f8c2dd829 CI: Build with --prefix=/usr rather than setting LD_LIBRARY_PATH
This also moves executables too.

I'm not sure why xilinx-smoke-dom0-x86_64.sh was overriding PATH too, as
/usr/local is clearly in PATH given the other tests, but drop that too.

No practical change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-16 09:37:14 +01:00
Andrew Cooper 4a39780faa CI: Include microcode for x86 hardware jobs
All the x86 hardware runners are out of date, to varying degrees, in terms of
microcode.

Microcode must be uncompressed and prepended to the initrd in order for Xen to
be able to use it during early boot.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
2025-04-14 19:20:58 +01:00
Marek Marczykowski-Górecki 4611ae6fb8 CI: save toolstack artifact as cpio.gz
This avoids the need to re-compress it in every test job.  This saves minutes
of wallclock time.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
2025-04-14 19:20:58 +01:00
Andrew Cooper 464d4dd456 CI: Switch to new argo artefact
The argo artefact is now a cpio archive and can be appended to dom?-rootfs
directly, rather than being part of of the overlay.  Drop the
copy_dom?_files() functions.

xen-argo.ko has moved into the standard location, so update the insmod path.

No practical change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
2025-04-14 19:20:58 +01:00
Marek Marczykowski-Górecki 786f323809 CI: avoid repacking initrd as part of the test job
Use the new test-artifacts which provide rootfs.cpio.gz rather than
initrd.tar.gz.  rootfs.cpio.gz also has all the necessary top-level
directories, and includes the rc_verbose setting, so these modifications can
be dropped.

Having that, do not repack the whole initrd, but only pack modified
files and rely on Linux handling of concatenated archives.
This allows packing just test-related files (which includes the whole
toolstack), instead of the whole initrd.

For xilinx-smoke-dom0-x86_64.sh, this involves instructing grub not to unzip
the archive, as doing so corrupts it.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
2025-04-14 19:20:58 +01:00
Andrew Cooper 9caca83404 CI: Rename intermediate artefacts in qemu-* scripts
Right now, we have initrd.cpio.gz as domU, and initrd.tar.gz as the base for
dom0.

Rename initrd.cpio.gz to domU-rootfs.cpio.gz, and xen-rootfs.cpio.gz to
dom0-rootfs.cpio.gz to make it clearer which is which.  Rename the VM from
test to domU.

No functional change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
2025-04-14 19:20:58 +01:00
Marek Marczykowski-Górecki 79de6507c5 CI: fix waiting for final test message (again)
The previous attempt has correct diagnosis, but added -notransfer flag
in a wrong place - it should be used in the first (outer) match out of
two, not the second (inner) one.

Fixes: 1e12cbd6af ("CI: fix waiting for final test message")
Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
2025-04-14 12:16:43 +01:00
Marek Marczykowski-Górecki f401eae6ec CI: write whole etc/issue for domU initrd
Upcoming changes won't unpack original rootfs anymore, so sed on
existing file cannot be used. Override the whole file instead.

No functional change intended.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
2025-04-12 15:06:43 +01:00
Marek Marczykowski-Górecki d604d774a2 CI: switch qubes runners to use console.exp
It appears as sometimes it takes more time for Xen even start booting,
mostly due to firmware and fetching large boot files by grub. In some
jobs the current timeout is pretty close to the actual time needed, and
sometimes (rarely for now) test fails due to timeout expiring in the
middle of dom0 booting. This will be happening more often if the
initramfs will grow (and with more complex tests).
This has been observed on some dom0pvh-hvm jobs, at least on runners hw3
and hw11.

Switch to using expect (console.exp) for more robust test output
handling. This allows waiting separately for Xen starting to boot and
then for the test to complete. For now, set both of those to 120s, which
pessimistically bumps timeout for the whole test to 240s (from 120s).

Add S3 handling to console.exp via SUSPEND_MSG + WAKEUP_CMD.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
2025-04-11 22:07:57 +01:00
Marek Marczykowski-Górecki 1e12cbd6af CI: fix waiting for final test message
Expect normally discards initial part of its buffer after matching the
patter, before looking for the next one. If both PASSED and LOG_MSG
happen to be in the buffer at the same time, depending on their order,
only one will be matched and the waiting for the other will timeout.
Example expect -d output of this happening (parts eclipsed for brevity):

    expect: does "\r\r\r\nWelcome to Alpine Linux 3.18\r\r\r\n...\r\r\r\r\n(domU) + echo 'pci test passed'\r\r\r\r\n(domU) pci test passed\r\r\r\r..." (spawn_id exp4) match regular expression "pci test passed"? Gate "pci test passed"? gate=yes re=yes
    ...
    Gate keeper glob pattern for '\nWelcome to Alpine Linux' is '
    Welcome to Alpine Linux'. Activating booster.
    expect: does "'\r\r\r\r\n(domU) pci test passed\r\r\r\r\n(domU)  [ ok ]\r\r\r\r\n(domU)  [ ok ]\r\r\r\r\n(domU) \r\r\r\r\r\n(domU) domU Welcome to Alpine Linux 3.18\r\r\r\r\n(domU) \rKernel 6.6.56 on an x86_64 (/dev/hvc0)\r\r\r\r\n(domU) \r\r\r\r\r\n" (spawn_id exp4) match regular expression "\nWelcome to Alpine Linux"? Gate "\nWelcome to Alpine Linux"? gate=no

Fix this by using -notransfer flag to keep matched part in the buffer.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Acked-by: Andrew Cooper <andrew.cooper3@citix.com>
2025-04-11 22:07:57 +01:00
Marek Marczykowski-Górecki 7c96a27e37 CI: wait for Xen to start before waiting for test to complete
Add additional stage in console output parsing - wait for first message
from Xen. The message is defined via BOOT_MSG variable. This has two
effects:
- distinguishes failing Xen to load at all from later test failures
- resets timeout when Xen starts loading

The latter is especially relevant for hardware tests where firmware +
network boot may take some time before Xen starts booting. The two-stage
timeout is more robust solution than increasing the overall timeout.
The issue has been observed on some dom0pvh-hvm jobs, at least on
runners hw3 and hw11. This patch is a first stage before qubes-x86-64.sh
is switched to use expect in the next stage.

While at it, consistently use 'expect -re' for all matches. This
especially allows matching newlines ("\n"), which will become relevant
in the next patch. And document variables used in console.exp.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
2025-04-11 22:07:57 +01:00
Marek Marczykowski-Górecki 930279d96c CI: adjust resolving network interface into PCI device
Change how PCI device lookup is done to handle also USB devices, in
which case get the USB controller. Instead of taking basename of the
'device' symlink, resolve the full path (example:
/sys/devices/pci0000:00/0000:00:09.0/usb4/4-7/4-7:1.0) and take the
first part after pci0000:00. Theoretically it could be a bridge, but VM
has flat PCI topology.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-07 19:17:38 +01:00
Marek Marczykowski-Górecki 6e3fe711fb CI: wait for the network interface in PCI passthrough tests
The network driver initializes asynchronously, and it may not be ready
yet by the time the startup script is called. This is especially the
case for USB network adapter (where the PCI device is the USB
controller) in the upcoming runner.

Don't bother about separate timeout - test timeout will cover this part
too.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-07 19:17:38 +01:00
Marek Marczykowski-Górecki b8d41a9b22 CI: increase verbosity of starting a domain
And start collecting qemu log earlier, so it isn't lost in case of a
timeout during domain startup.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
2025-04-07 19:17:38 +01:00
Marek Marczykowski-Górecki 1804064f68 CI: include domU kernel messages in the console output log
Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Acked-by: Stefano Stabellini <sstabellini@kernel.org>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
2025-04-07 19:17:38 +01:00
Marek Marczykowski-Górecki 32e6d052c2 CI: prevent grub unpacking initramfs
It fails on larger initramfs (~250MB one) and sometimes even smaller
depending on memory size/memory map, let Linux do it.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-07 19:17:38 +01:00
Marek Marczykowski-Górecki 42beecae0b ci: create boot.ipxe for legacy boot
Hardware runners that use legacy boot use iPXE instead of grub2. Create
boot.ipxe for those too - with exact same options.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
2025-04-02 16:53:02 -07:00
Oleksii Kurochko 470310a41b automation/RISC-V: select APLIC and IMSIC to handle both wired interrupts and MSIs
By default, the `aia` option is set to "none" which selects the SiFive PLIC for
handling wired interrupts. However, since PLIC is now considered obsolete and
will not be supported by Xen now, APLIC and IMSIC are selected instead to manage
both wired interrupts and MSIs.

Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
2025-04-01 12:45:26 +02:00