* [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container
[not found] <1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u>
@ 2026-11-03 14:08 ` Baptiste Le Duc
2026-11-03 14:15 ` Baptiste Le Duc
` (3 more replies)
2026-11-03 14:08 ` [PATCH v3 2/6] automation/qtb: add the QTB machine for riscv64 Baptiste Le Duc
` (4 subsequent siblings)
5 siblings, 4 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-03 14:08 UTC (permalink / raw)
To: xen-devel
Cc: Baptiste Le Duc, Doug Goldstein, Stefano Stabellini,
Anthony PERARD, Andrew Cooper, Alistair Francis, Connor Davis,
Oleksii Kurochko, Alejandro Vallejo, Zhang Zheng
The riscv64 QTB tests use QTB (QEMU Test Bench) Python package. QTB is part
of AMD's work on the 'safety' branch [1] of their QEMU fork and is not
upstream in QEMU yet. The tests also need pytest and qemu-system-riscv64.
Add debian:13-riscv64-qtb, a Debian Trixie container with those packages
and the QTB package installed from the python/ directory of AMD's QEMU
fork, at the commit pinned by QEMU_REPO/QEMU_COMMIT. Make it available to
containerize script as trixie-riscv64-qtb.
QTB depends on pexpect, ptyprocess, pygdbmi and qemu.qmp. Rather than
fetching them from PyPI, install them from the wheels vendored in the
python/wheels/ directory of the same fork commit, with pip --no-index.
[1] https://gitlab.com/xen-project/people/amd/qemu/-/tree/safety?ref_type=heads
Suggested-by: Stefano Stabellini <sstabellini@kernel.org>
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
---
The CI jobs running the tests in this container come in a later patch.
---
Changes in v3:
- Move the container from test-artifacts to xen.git (automation/build/),
renamed debian:13-riscv64-qtb.
- Install the QTB dependencies from the wheels vendored in the fork, with
pip --no-index.
- Add pytest, drop jinja2, yaml and device-tree-compiler.
- Comment that the pinned commit is the tip of the safety branch.
- Reword the commit title and message.
---
automation/build/debian/13-riscv64-qtb.dockerfile | 47 +++++++++++++++++++++++
automation/scripts/containerize | 1 +
2 files changed, 48 insertions(+)
diff --git a/automation/build/debian/13-riscv64-qtb.dockerfile b/automation/build/debian/13-riscv64-qtb.dockerfile
new file mode 100644
index 0000000000..34ca1f2b7d
--- /dev/null
+++ b/automation/build/debian/13-riscv64-qtb.dockerfile
@@ -0,0 +1,47 @@
+# syntax=docker/dockerfile:1
+FROM --platform=linux/amd64 debian:trixie-slim
+LABEL maintainer.name="The Xen Project"
+LABEL maintainer.email="xen-devel@lists.xenproject.org"
+
+ENV DEBIAN_FRONTEND=noninteractive
+
+ARG QEMU_REPO=https://gitlab.com/xen-project/people/amd/qemu.git
+# Tip of the safety branch
+ARG QEMU_COMMIT=24cd7e5c0d7e4db8e651f091d0b9da2e7c58dbab
+
+RUN <<EOF
+#!/bin/bash
+ set -eu
+
+ useradd --create-home user
+
+ apt-get update
+
+ DEPS=(# Base environment
+ ca-certificates
+ git
+ python3-minimal
+ python3-pip
+ python3-pytest
+ python3-setuptools
+
+ # QEMU for the tests
+ qemu-system-riscv64
+ )
+
+ apt-get -y --no-install-recommends install "${DEPS[@]}"
+
+ # QTB framework
+ git init /tmp/qemu
+ git -C /tmp/qemu fetch --depth 1 "$QEMU_REPO" "$QEMU_COMMIT"
+ git -C /tmp/qemu checkout FETCH_HEAD
+
+ pip install --break-system-packages --no-index --no-build-isolation \
+ --find-links /tmp/qemu/python/wheels "/tmp/qemu/python[qtb]"
+
+ rm -rf /tmp/qemu
+ rm -rf /var/lib/apt/lists/*
+EOF
+
+USER user
+WORKDIR /build
diff --git a/automation/scripts/containerize b/automation/scripts/containerize
index feadd9e82f..cd078d48d9 100755
--- a/automation/scripts/containerize
+++ b/automation/scripts/containerize
@@ -33,6 +33,7 @@ case "_${CONTAINER}" in
_trixie-ppc64le) CONTAINER="${BASE}/debian:13-ppc64le" ;;
_bookworm-riscv64) CONTAINER="${BASE}/debian:12-riscv64" ;;
_trixie-riscv64) CONTAINER="${BASE}/debian:13-riscv64" ;;
+ _trixie-riscv64-qtb) CONTAINER="${BASE}/debian:13-riscv64-qtb" ;;
_bookworm-x86_64-gcc-ibt) CONTAINER="${BASE}/debian:12-x86_64-gcc-ibt" ;;
_bookworm|_bookworm-x86_64) CONTAINER="${BASE}/debian:12-x86_64" ;;
_trixie-x86_64|_) CONTAINER="${BASE}/debian:13-x86_64" ;;
--
2.56.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH v3 2/6] automation/qtb: add the QTB machine for riscv64
[not found] <1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u>
2026-11-03 14:08 ` [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container Baptiste Le Duc
@ 2026-11-03 14:08 ` Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 3/6] automation/qtb: add the console-test type with a Xen boot test Baptiste Le Duc
` (3 subsequent siblings)
5 siblings, 0 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-03 14:08 UTC (permalink / raw)
To: xen-devel
Cc: Baptiste Le Duc, Doug Goldstein, Stefano Stabellini,
Anthony PERARD, Andrew Cooper, Alistair Francis, Connor Davis,
Oleksii Kurochko, Alejandro Vallejo, Zhang Zheng
The QTB (QEMU Test Bench) Python package drives a QEMU process over QMP and
qtest through QtbMachine, which leaves the QEMU binary (_resolve_binary())
and the machine part of its command line (_machine_args()) to a subclass.
Add RiscvTestMachine, the riscv64 implementation of QtbMachine, with:
- HostConfig, the test-agnostic description of the host (Xen) to boot:
for now, the pCPU count and the RAM size.
- The QEMU command line that boots Xen on the virt machine in
aia=aplic-imsic mode, using the distribution's qemu-system-riscv64,
found in PATH, and the OpenSBI it bundles. Xen is resolved from the
binaries directory before QEMU starts, so a missing one fails the
test without launching QEMU for nothing.
- expect_console() waits for a string on a console and turns a timeout or
a closed console into an AssertionError, which pytest reports as a test
failure.
- Xen's console is mirrored to stdout, so a failing test shows where Xen
stopped without fetching its log from the artifacts.
QtbEnv (qtb/env.py) holds the directories shared by every test, and
qtb/utils.py holds the generic path helpers.
Suggested-by: Stefano Stabellini <sstabellini@kernel.org>
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
---
The machine is unused on its own: the pytest fixture booting it and the
first test come in the next patch.
---
Changes in v3:
- New patch, split out of v2 "automation/qtb: add Python QTB framework
with the console-test type".
- Mirror Xen's console to stdout, so pytest shows it in the report of a
failing test.
- Map pexpect timeouts and EOF to AssertionError (a pytest failure)
instead of a dedicated TestFailure exception.
- Keep the host at 2GB.
- Drop the Jinja2 host device tree.
---
automation/scripts/qtb/__init__.py | 2 +
automation/scripts/qtb/env.py | 15 ++++++
automation/scripts/qtb/riscv/__init__.py | 2 +
automation/scripts/qtb/riscv/machine.py | 92 ++++++++++++++++++++++++++++++++
automation/scripts/qtb/utils.py | 15 ++++++
5 files changed, 126 insertions(+)
diff --git a/automation/scripts/qtb/__init__.py b/automation/scripts/qtb/__init__.py
new file mode 100644
index 0000000000..a0e6e76cb2
--- /dev/null
+++ b/automation/scripts/qtb/__init__.py
@@ -0,0 +1,2 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""QTB (QEMU Test Bench) test frameworks."""
diff --git a/automation/scripts/qtb/env.py b/automation/scripts/qtb/env.py
new file mode 100644
index 0000000000..7887d6af23
--- /dev/null
+++ b/automation/scripts/qtb/env.py
@@ -0,0 +1,15 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""Run environment prepared by the launcher and shared by every test."""
+
+from __future__ import annotations
+
+from dataclasses import dataclass
+from pathlib import Path
+
+
+@dataclass(frozen=True)
+class QtbEnv:
+ """Directories prepared by the launcher and shared by every test."""
+
+ binaries_dir: Path # Build artifacts (xen, ...) the hosts boot.
+ log_dir: Path | None = None # Logs, kept after the run.
diff --git a/automation/scripts/qtb/riscv/__init__.py b/automation/scripts/qtb/riscv/__init__.py
new file mode 100644
index 0000000000..7a0218c73c
--- /dev/null
+++ b/automation/scripts/qtb/riscv/__init__.py
@@ -0,0 +1,2 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""QTB riscv64 test framework package."""
diff --git a/automation/scripts/qtb/riscv/machine.py b/automation/scripts/qtb/riscv/machine.py
new file mode 100644
index 0000000000..1c5e3b0d9e
--- /dev/null
+++ b/automation/scripts/qtb/riscv/machine.py
@@ -0,0 +1,92 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""QtbMachine for riscv64."""
+
+from __future__ import annotations
+
+import shutil
+from collections.abc import Sequence
+from dataclasses import dataclass
+
+import pexpect
+from qemu.qtb import GuestConsoleSession
+from qemu.qtb import QtbMachine
+
+from qtb.env import QtbEnv
+from qtb.utils import resolve_under
+
+
+@dataclass(frozen=True)
+class HostConfig:
+ """The test-agnostic description of what to boot."""
+
+ pcpu: int
+ memory: int = 2048 # MB
+
+
+class RiscvTestMachine(QtbMachine):
+ arch_name = "riscv64"
+ gdb_arch = "riscv:rv64"
+
+ qemu_bin = "qemu-system-riscv64"
+
+ def __init__(
+ self,
+ host_config: HostConfig,
+ *,
+ env: QtbEnv,
+ ) -> None:
+ self.host = host_config
+ self.env = env
+ # Resolved before QEMU starts, so a missing binary fails early.
+ self.xen = resolve_under("xen", env.binaries_dir)
+ super().__init__(
+ memory=self.host.memory,
+ cpus=self.host.pcpu,
+ mirror_console=True,
+ # Default expect timeout
+ timeout=30,
+ log_dir=str(env.log_dir) if env.log_dir else None,
+ )
+
+ # Implements QtbMachine._machine_args()
+ def _machine_args(self, memory: int, cpus: int) -> Sequence[str]:
+ machine_opt = "virt,aia=aplic-imsic"
+ cpu_opt = "rv64,svpbmt=on"
+ return [
+ "-M",
+ machine_opt,
+ "-cpu",
+ cpu_opt,
+ "-smp",
+ str(cpus),
+ "-m",
+ str(memory),
+ "-kernel",
+ str(self.xen),
+ ]
+
+ # Implements QtbMachine._resolve_binary()
+ @classmethod
+ def _resolve_binary(cls) -> str:
+ qemu = shutil.which(cls.qemu_bin)
+ if qemu is None:
+ raise FileNotFoundError(f"{cls.qemu_bin} not found in PATH")
+ return qemu
+
+ def get_host_console(self) -> GuestConsoleSession | None:
+ return self.console
+
+ @staticmethod
+ def expect_console(
+ console: GuestConsoleSession, expected: str, timeout: int
+ ) -> None:
+ """Wait for `expected` on console and fail if it does not show up
+ within `timeout`, which overrides the default one from QtbMachine."""
+ if console is None:
+ raise RuntimeError("Xen console not wired up, host not launched?")
+ try:
+ console.expect_exact(expected, timeout=timeout)
+ except pexpect.TIMEOUT:
+ raise AssertionError(f"{expected!r} not seen within {timeout}s") from None
+ except pexpect.EOF:
+ raise AssertionError(f"console closed before {expected!r}") from None
diff --git a/automation/scripts/qtb/utils.py b/automation/scripts/qtb/utils.py
new file mode 100644
index 0000000000..cce5936acb
--- /dev/null
+++ b/automation/scripts/qtb/utils.py
@@ -0,0 +1,15 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""Generic helpers shared by the QTB test frameworks."""
+
+from __future__ import annotations
+
+from pathlib import Path
+
+
+def resolve_under(file_name: str, base: Path) -> Path:
+ """Resolve `file_name` against `base`, absolute paths pass through."""
+ p = Path(file_name)
+ path = p if p.is_absolute() else base / p
+ if not path.exists():
+ raise FileNotFoundError(f"cannot resolve {str(path)!r}: does not exist")
+ return path
--
2.56.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH v3 3/6] automation/qtb: add the console-test type with a Xen boot test
[not found] <1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u>
2026-11-03 14:08 ` [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 2/6] automation/qtb: add the QTB machine for riscv64 Baptiste Le Duc
@ 2026-11-03 14:08 ` Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 4/6] automation/qtb: add QTB framework README Baptiste Le Duc
` (2 subsequent siblings)
5 siblings, 0 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-03 14:08 UTC (permalink / raw)
To: xen-devel
Cc: Baptiste Le Duc, Doug Goldstein, Stefano Stabellini,
Anthony PERARD, Andrew Cooper, Alistair Francis, Connor Davis,
Oleksii Kurochko, Alejandro Vallejo, Zhang Zheng
Add a first console test, which boots Xen under QEMU and waits for "All set
up" on its console. It is the equivalent of qemu-smoke-riscv64.sh, with the
finer control QTB gives, and new configurations are added as test
parameters instead of new scripts.
The tests get their machine through the `machine` pytest fixture. A test
parametrizes the fixture indirectly with the pCPU count, and the fixture
builds the matching RiscvTestMachine from it, so a new configuration only
takes a pytest.param() above the test function. The fixture launches QEMU
before the test body and shuts it down after, so setup problems (missing
binary, QEMU not starting) are reported as pytest errors and only console
checks are reported as test failures.
--binaries-dir gives the directory holding the binaries to boot, and is
mandatory. --log-dir gives where to keep the QEMU and console logs, one
<module>/<test> subdirectory per test. The timeout of each expected string
is 1500 seconds, as in console.exp, overridden by TEST_TIMEOUT_OVERRIDE or
TEST_TIMEOUT.
Suggested-by: Stefano Stabellini <sstabellini@kernel.org>
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
---
Changes in v3:
- New patch, split out of v2 "automation/qtb: add Python QTB framework
with the console-test type".
- Rework on top of pytest: tests are pytest functions parametrizing the
`machine` fixture. The CLI, config.yaml, the per-type YAML files, the
test class hierarchy and the attempts/retry logic are gone.
- Take the binaries and logs directories from --binaries-dir and
--log-dir, no environment variable.
- Take the per-string timeout from TEST_TIMEOUT_OVERRIDE/TEST_TIMEOUT,
like console.exp.
---
automation/scripts/qtb/riscv/tests/__init__.py | 2 +
automation/scripts/qtb/riscv/tests/conftest.py | 65 ++++++++++++++++++++++
automation/scripts/qtb/riscv/tests/test_console.py | 35 ++++++++++++
3 files changed, 102 insertions(+)
diff --git a/automation/scripts/qtb/riscv/tests/__init__.py b/automation/scripts/qtb/riscv/tests/__init__.py
new file mode 100644
index 0000000000..24d34ae2d1
--- /dev/null
+++ b/automation/scripts/qtb/riscv/tests/__init__.py
@@ -0,0 +1,2 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""qtb riscv64 tests: boot Xen under QEMU and check what it does."""
diff --git a/automation/scripts/qtb/riscv/tests/conftest.py b/automation/scripts/qtb/riscv/tests/conftest.py
new file mode 100644
index 0000000000..be6c7223a3
--- /dev/null
+++ b/automation/scripts/qtb/riscv/tests/conftest.py
@@ -0,0 +1,65 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""Fixtures booting Xen under QEMU for the qtb riscv64 tests.
+
+A test takes the `machine` fixture and parametrizes it indirectly with its
+pCPU count.
+"""
+
+from __future__ import annotations
+
+from pathlib import Path
+
+import pytest
+
+from qtb.env import QtbEnv
+from qtb.riscv.machine import HostConfig, RiscvTestMachine
+
+def pytest_addoption(parser: pytest.Parser) -> None:
+ parser.addoption(
+ "--log-dir",
+ default=None,
+ metavar="DIR",
+ help="Directory for all logs (QEMU process log, qtest and the "
+ "consoles as con<N>.log), one subdirectory per test. When unset, "
+ "no logs are written.",
+ )
+
+ parser.addoption(
+ "--binaries-dir",
+ default=None,
+ metavar="DIR",
+ help="Directory holding the build artifacts (xen, ...) the tests boot.",
+ )
+
+
+@pytest.fixture
+def machine(request: pytest.FixtureRequest, qtb_env: QtbEnv):
+ """The test's machine: QEMU launched."""
+ if not hasattr(request, "param"):
+ pytest.fail("machine fixture needs indirect parametrization with the "
+ "pCPU count")
+ machine = RiscvTestMachine(
+ HostConfig(request.param),
+ env=qtb_env,
+ )
+ with machine:
+ machine.launch()
+ yield machine
+
+
+@pytest.fixture
+def qtb_env(request: pytest.FixtureRequest) -> QtbEnv:
+ log_dir = request.config.getoption("log_dir")
+ if log_dir:
+ # One <module>/<test> subdirectory per test
+ log_dir = Path(log_dir) / request.node.path.stem / request.node.name
+ log_dir.mkdir(parents=True, exist_ok=True)
+
+ binaries_dir = request.config.getoption("binaries_dir")
+ if binaries_dir is None:
+ pytest.fail("no binaries dir: pass --binaries-dir")
+
+ return QtbEnv(
+ binaries_dir=Path(binaries_dir),
+ log_dir=log_dir,
+ )
diff --git a/automation/scripts/qtb/riscv/tests/test_console.py b/automation/scripts/qtb/riscv/tests/test_console.py
new file mode 100644
index 0000000000..10169e03a8
--- /dev/null
+++ b/automation/scripts/qtb/riscv/tests/test_console.py
@@ -0,0 +1,35 @@
+# SPDX-License-Identifier: GPL-2.0-only
+"""Console string expectation tests (console-test).
+
+Boot Xen under QEMU and check its console, within the timeout.
+"""
+
+from __future__ import annotations
+
+import os
+
+import pytest
+from qemu.qtb import GuestConsoleSession
+
+from qtb.riscv.machine import RiscvTestMachine
+
+# Per expected string (seconds)
+TIMEOUT: int = int(
+ os.environ.get("TEST_TIMEOUT_OVERRIDE") or os.environ.get("TEST_TIMEOUT")
+ or 1500
+)
+
+
+def _check_console(console: GuestConsoleSession, expect: list[str]) -> None:
+ """Assert each string in `expect` is printed on console, in order."""
+ for s in expect:
+ RiscvTestMachine.expect_console(console, s, TIMEOUT)
+
+
+def _check_host_boot(machine: RiscvTestMachine) -> None:
+ _check_console(machine.get_host_console(), ["All set up"])
+
+
+@pytest.mark.parametrize("machine", [pytest.param(1, id="1pcpu")], indirect=True)
+def test_host_boot(machine):
+ _check_host_boot(machine)
--
2.56.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH v3 4/6] automation/qtb: add QTB framework README
[not found] <1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u>
` (2 preceding siblings ...)
2026-11-03 14:08 ` [PATCH v3 3/6] automation/qtb: add the console-test type with a Xen boot test Baptiste Le Duc
@ 2026-11-03 14:08 ` Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 5/6] CI: add a riscv64 smoke test job using the QTB console-test Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 6/6] CI: drop the riscv64 expect-based smoke test Baptiste Le Duc
5 siblings, 0 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-03 14:08 UTC (permalink / raw)
To: xen-devel
Cc: Baptiste Le Duc, Doug Goldstein, Stefano Stabellini,
Anthony PERARD, Andrew Cooper, Alistair Francis, Connor Davis,
Oleksii Kurochko, Alejandro Vallejo, Zhang Zheng
Document the qtb riscv64 test framework in a README.
It covers:
- the core concepts: a test type is a pytest module under tests/, a test
is a function parametrizing the `machine` fixture with what it boots
- the source files layout
- the prerequisites and how to run the tests with pytest, with logs and
a JUnit report as CI does
- how to run them in the CI container
- how to add a test and how to add a new test type.
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
---
Changes in v3:
- Rewrite for the pytest-based framework.
---
automation/scripts/qtb/riscv/README.md | 127 +++++++++++++++++++++++++++++++++
1 file changed, 127 insertions(+)
diff --git a/automation/scripts/qtb/riscv/README.md b/automation/scripts/qtb/riscv/README.md
new file mode 100644
index 0000000000..f074a70c4a
--- /dev/null
+++ b/automation/scripts/qtb/riscv/README.md
@@ -0,0 +1,127 @@
+qtb riscv64 test framework
+==========================
+
+A small pytest framework built on qtb (QEMU Test Bench), a Python package that
+controls a QEMU process over QMP and qtest and gives access to its consoles.
+Each test drives Xen and its guests through these interfaces and turns what
+it observes into a pass/fail verdict.
+
+Prerequisites
+-------------
+
+- `qemu.qtb`: the QEMU Test Bench Python package. It is not upstream yet, so
+ install it with its `[qtb]` extra (which pulls `pexpect`) from the `python/`
+ directory of the `QEMU_REPO` fork, at the `QEMU_COMMIT` pinned in
+ `automation/build/debian/13-riscv64-qtb.dockerfile`.
+- `pytest`.
+- `qemu-system-riscv64` in PATH, with its bundled OpenSBI.
+- A riscv64 `xen` binary, in the directory given with `--binaries-dir`.
+
+The simplest way to get the Python ones is to use the CI container, see
+"Running in the container" below.
+
+Running the tests
+-----------------
+
+Run from the top level of the source tree, as CI does. Here the binaries are
+in `binaries/`:
+
+```
+T=automation/scripts/qtb/riscv/tests
+
+# List every test:
+python3 -m pytest $T --collect-only -q
+
+# Run every test, one file, one test, or by name substring:
+python3 -m pytest $T --binaries-dir binaries
+python3 -m pytest $T/test_console.py --binaries-dir binaries
+python3 -m pytest $T/test_console.py::test_host_boot --binaries-dir binaries
+python3 -m pytest $T -k 1pcpu --binaries-dir binaries
+
+# With logs and per-test results as JUnit XML (what CI does):
+python3 -m pytest $T --binaries-dir binaries --log-dir qtb-logs \
+ --junitxml tests-junit.xml
+```
+
+pytest finds the `qtb` package on its own, as `automation/scripts/` is the
+first directory above the tests without an `__init__.py`.
+
+The `machine` fixture understands the following options.
+
+- `--binaries-dir DIR`: The directory holding the binaries. It is required to
+ boot a test.
+
+- `--log-dir DIR`: The directory collecting the logs, in one
+ `<module>/<test>/` subdirectory per test. It holds QEMU's stdout/stderr
+ (`riscv64-qtest-<pid>.log`, named after the host) and Xen's console as
+ `con0.log`. Without it, no logs are written.
+
+`--log-cli-level=DEBUG` shows the debug logs live.
+
+Running in the container
+------------------------
+
+Build the CI container once, then run the tests in it with `containerize`,
+which mounts the Xen tree as the working directory. In this example, we assume
+the binaries were copied to `binaries/` at the top of the tree.
+
+```
+make -C automation/build debian/13-riscv64-qtb
+CONTAINER=trixie-riscv64-qtb ./automation/scripts/containerize \
+ python3 -m pytest automation/scripts/qtb/riscv/tests --binaries-dir binaries
+```
+
+Layout
+------
+
+```
+qtb/env.py QtbEnv: directories handed to each host
+qtb/utils.py Generic helpers, not riscv specific
+
+qtb/riscv/ This framework
+ machine.py HostConfig: what a host boots; RiscvTestMachine:
+ QEMU command line, console helpers
+
+ tests/ The QEMU tests, one module per test type
+ conftest.py `machine` fixture and its options
+ test_console.py console-test
+```
+
+Test types and tests
+--------------------
+
+A test type is one module under `tests/`. Each test is a short function
+taking the `machine` fixture, which it parametrizes indirectly with the
+pCPU counts it runs on:
+
+```
+@pytest.mark.parametrize(
+ "machine",
+ [pytest.param(1, id="1pcpu")],
+ indirect=True,
+)
+def test_a(machine):
+ ...
+```
+
+Before the test body runs, the `machine` fixture launches QEMU with Xen. Once
+the test body returns, QEMU is shut down.
+
+An exception raised before the test body (a bad parameter, a missing binary,
+QEMU not starting) is reported by pytest and JUnit as an *error*. An
+exception raised in the test body (an `expect_console` timing out) is
+reported as a *failure*.
+
+Adding a test
+-------------
+
+Add a function to the module of the test type, parametrize `machine`
+indirectly with the machines it runs on, and check their consoles.
+
+Adding a test type
+------------------
+
+Add `tests/test_<type>.py`, holding the logic of the type in one function
+that takes the machine and the parameters of the type, and the tests that
+call it. Host-side helpers shared between types go to `RiscvTestMachine` or
+`machine.py`. State the requirements of the type in the module docstring.
--
2.56.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH v3 5/6] CI: add a riscv64 smoke test job using the QTB console-test
[not found] <1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u>
` (3 preceding siblings ...)
2026-11-03 14:08 ` [PATCH v3 4/6] automation/qtb: add QTB framework README Baptiste Le Duc
@ 2026-11-03 14:08 ` Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 6/6] CI: drop the riscv64 expect-based smoke test Baptiste Le Duc
5 siblings, 0 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-03 14:08 UTC (permalink / raw)
To: xen-devel
Cc: Baptiste Le Duc, Doug Goldstein, Stefano Stabellini,
Anthony PERARD, Andrew Cooper, Alistair Francis, Connor Davis,
Oleksii Kurochko, Alejandro Vallejo, Zhang Zheng
Add QTB console-test in CI next to the existing qemu-smoke-riscv64-gcc
job, which is left unchanged.
Add .qemu-qtb-riscv64, a template running the pytest module named by
QTB_TEST in the debian:13-riscv64-qtb container. --binaries-dir points
at the artifacts of the job, Xen from the build job. The per-test logs
are collected under qtb-logs, kept on failure and on success, and the
JUnit report is uploaded so GitLab shows per-test results.
Add qemu-smoke-qtb-riscv64-gcc job on top of it, running test_console.py:
its test boots Xen alone on one pCPU and waits for "All set up" on
Xen's console, the same string as the existing qemu-smoke-riscv64-gcc.
Both jobs use Debian's QEMU and its bundled OpenSBI.
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
---
Changes in v3:
- Add the QTB job next to qemu-smoke-riscv64-gcc instead of replacing it,
the drop moves to its own patch.
- Rename the template and job with "qtb".
- Run pytest and upload its JUnit report.
- Use the container from xen.git, drop ARTIFACTS_REGISTRY.
---
automation/gitlab-ci/test.yaml | 27 +++++++++++++++++++++++++++
1 file changed, 27 insertions(+)
diff --git a/automation/gitlab-ci/test.yaml b/automation/gitlab-ci/test.yaml
index 96127995d7..dcf75e4674 100644
--- a/automation/gitlab-ci/test.yaml
+++ b/automation/gitlab-ci/test.yaml
@@ -84,6 +84,26 @@
tags:
- x86_64
+.qemu-qtb-riscv64:
+ extends: .test-jobs-common
+ variables:
+ CONTAINER: debian:13-riscv64-qtb
+ script:
+ - python3 -m pytest
+ "automation/scripts/qtb/riscv/tests/${QTB_TEST}"
+ -p no:cacheprovider
+ --log-dir qtb-logs
+ --binaries-dir "${CI_PROJECT_DIR}/binaries"
+ --junitxml tests-junit.xml
+ artifacts:
+ paths:
+ - qtb-logs
+ reports:
+ junit: tests-junit.xml
+ when: always
+ tags:
+ - x86_64
+
.qemu-ppc64le:
extends: .test-jobs-common
variables:
@@ -792,6 +812,13 @@ qemu-smoke-riscv64-gcc:
needs:
- debian-13-riscv64-gcc-debug
+qemu-smoke-qtb-riscv64-gcc:
+ extends: .qemu-qtb-riscv64
+ variables:
+ QTB_TEST: test_console.py
+ needs:
+ - debian-13-riscv64-gcc-debug
+
qemu-smoke-ppc64le-powernv9-gcc:
extends: .qemu-ppc64le
script:
--
2.56.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH v3 6/6] CI: drop the riscv64 expect-based smoke test
[not found] <1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u>
` (4 preceding siblings ...)
2026-11-03 14:08 ` [PATCH v3 5/6] CI: add a riscv64 smoke test job using the QTB console-test Baptiste Le Duc
@ 2026-11-03 14:08 ` Baptiste Le Duc
5 siblings, 0 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-03 14:08 UTC (permalink / raw)
To: xen-devel
Cc: Baptiste Le Duc, Doug Goldstein, Stefano Stabellini,
Anthony PERARD, Andrew Cooper, Alistair Francis, Connor Davis,
Oleksii Kurochko, Alejandro Vallejo, Zhang Zheng
qemu-smoke-qtb-riscv64-gcc boots Xen alone and waits for the same
"All set up" string on Xen's console as qemu-smoke-riscv64-gcc, so the
latter is redundant.
Drop qemu-smoke-riscv64-gcc, its .qemu-riscv64 template and
automation/scripts/qemu-smoke-riscv64.sh, which has no caller left.
Kept as a separate patch so it can be deferred until the QTB job has
proven itself.
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
---
The debian:13-riscv64 container still installs qemu-system-riscv64 and
expect for the test phase, although nothing tests in it anymore. As it
needs a rebuild, dropping them is left to a follow-up if needed.
---
Changes in v3:
- New patch, split out of v2 "CI: run the riscv64 smoke test via QTB
framework console-test".
---
automation/gitlab-ci/test.yaml | 20 --------------------
automation/scripts/qemu-smoke-riscv64.sh | 19 -------------------
2 files changed, 39 deletions(-)
diff --git a/automation/gitlab-ci/test.yaml b/automation/gitlab-ci/test.yaml
index dcf75e4674..13f7ddfc7b 100644
--- a/automation/gitlab-ci/test.yaml
+++ b/automation/gitlab-ci/test.yaml
@@ -71,19 +71,6 @@
variables:
TEST_TIMEOUT_OVERRIDE: 120
-.qemu-riscv64:
- extends: .test-jobs-common
- variables:
- CONTAINER: debian:13-riscv64
- LOGFILE: qemu-smoke-riscv64.log
- artifacts:
- paths:
- - smoke.serial
- - '*.log'
- when: always
- tags:
- - x86_64
-
.qemu-qtb-riscv64:
extends: .test-jobs-common
variables:
@@ -805,13 +792,6 @@ qemu-xtf-argo-x86_64-gcc-debug:
needs:
- alpine-3.24-x86_64-gcc-debug
-qemu-smoke-riscv64-gcc:
- extends: .qemu-riscv64
- script:
- - ./automation/scripts/qemu-smoke-riscv64.sh 2>&1 | tee ${LOGFILE}
- needs:
- - debian-13-riscv64-gcc-debug
-
qemu-smoke-qtb-riscv64-gcc:
extends: .qemu-qtb-riscv64
variables:
diff --git a/automation/scripts/qemu-smoke-riscv64.sh b/automation/scripts/qemu-smoke-riscv64.sh
deleted file mode 100755
index c0b1082a08..0000000000
--- a/automation/scripts/qemu-smoke-riscv64.sh
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-set -ex -o pipefail
-
-# Run the test
-rm -f smoke.serial
-
-export TEST_CMD="qemu-system-riscv64 \
- -M virt,aia=aplic-imsic \
- -cpu rv64,svpbmt=on \
- -smp 1 \
- -nographic \
- -m 2g \
- -kernel binaries/xen"
-
-export TEST_LOG="smoke.serial"
-export PASSED="All set up"
-
-./automation/scripts/console.exp |& sed 's/\r\+$//'
--
2.56.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* Re: [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container
2026-11-03 14:08 ` [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container Baptiste Le Duc
@ 2026-11-03 14:15 ` Baptiste Le Duc
2026-11-19 11:09 ` Oleksii Kurochko
` (2 subsequent siblings)
3 siblings, 0 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-03 14:15 UTC (permalink / raw)
To: Baptiste Le Duc
Cc: xen-devel, Doug Goldstein, Stefano Stabellini, Anthony PERARD,
Andrew Cooper, Alistair Francis, Connor Davis, Oleksii Kurochko,
Alejandro Vallejo, Zhang Zheng
On 2026-11-03 15:08 +0100, Baptiste Le Duc wrote:
The cover letter did not get threaded with the patches, sorry for the
noise. It is here:
https://lore.kernel.org/xen-devel/1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u
--
Baptiste Le Duc <baptiste.le-duc@vates.tech>
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container
[not found] ` <k4hxivkhib6yi7onicgs4ws2earwcawmds3bmp5nefjrw525qo@w6wxrkpdhoru>
@ 2026-11-19 10:38 ` Oleksii Kurochko
2026-11-19 15:28 ` Baptiste Le Duc
1 sibling, 0 replies; 11+ messages in thread
From: Oleksii Kurochko @ 2026-11-19 10:38 UTC (permalink / raw)
To: Hiago De Franco, Baptiste Le Duc
Cc: xen-devel, Doug Goldstein, Stefano Stabellini, Anthony PERARD,
Andrew Cooper, Alistair Francis, Connor Davis, Alejandro Vallejo,
Zhang Zheng
On 11/18/26 10:49 PM, Hiago De Franco wrote:
> Hi Baptiste,
>
> On Tue, Nov 03, 2026 at 03:08:09PM +0100, Baptiste Le Duc wrote:
>> The riscv64 QTB tests use QTB (QEMU Test Bench) Python package. QTB is part
>> of AMD's work on the 'safety' branch [1] of their QEMU fork and is not
>> upstream in QEMU yet. The tests also need pytest and qemu-system-riscv64.
>>
>> Add debian:13-riscv64-qtb, a Debian Trixie container with those packages
>> and the QTB package installed from the python/ directory of AMD's QEMU
>> fork, at the commit pinned by QEMU_REPO/QEMU_COMMIT. Make it available to
>> containerize script as trixie-riscv64-qtb.
>>
>> QTB depends on pexpect, ptyprocess, pygdbmi and qemu.qmp. Rather than
>> fetching them from PyPI, install them from the wheels vendored in the
>> python/wheels/ directory of the same fork commit, with pip --no-index.
>>
>> [1] https://gitlab.com/xen-project/people/amd/qemu/-/tree/safety?ref_type=heads
>>
>> Suggested-by: Stefano Stabellini <sstabellini@kernel.org>
>> Assisted-by: Claude:claude-opus-5-5
>
> Not sure if the above tag is needed by Xen, since this is not needed
> anymore on Linux kernel, I was wondering if this is still needed here as
> well. If it is, please ignore this comment :)
>
According to docs/process/sending-patches.pandoc [1] "### Assisted-by:"
at least nice to (even it is mentioned should) be added.
[1]
https://xenbits.xen.org/docs/unstable/process/sending-patches.html#assisted-by
~ Oleksii
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container
2026-11-03 14:08 ` [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container Baptiste Le Duc
2026-11-03 14:15 ` Baptiste Le Duc
@ 2026-11-19 11:09 ` Oleksii Kurochko
[not found] ` <k4hxivkhib6yi7onicgs4ws2earwcawmds3bmp5nefjrw525qo@w6wxrkpdhoru>
2026-11-19 17:21 ` dmukhin
3 siblings, 0 replies; 11+ messages in thread
From: Oleksii Kurochko @ 2026-11-19 11:09 UTC (permalink / raw)
To: Baptiste Le Duc, xen-devel
Cc: Doug Goldstein, Stefano Stabellini, Anthony PERARD, Andrew Cooper,
Alistair Francis, Connor Davis, Alejandro Vallejo, Zhang Zheng
On 11/3/26 3:08 PM, Baptiste Le Duc wrote:
> The riscv64 QTB tests use QTB (QEMU Test Bench) Python package. QTB is part
> of AMD's work on the 'safety' branch [1] of their QEMU fork and is not
> upstream in QEMU yet. The tests also need pytest and qemu-system-riscv64.
>
> Add debian:13-riscv64-qtb, a Debian Trixie container with those packages
> and the QTB package installed from the python/ directory of AMD's QEMU
> fork, at the commit pinned by QEMU_REPO/QEMU_COMMIT. Make it available to
> containerize script as trixie-riscv64-qtb.
>
> QTB depends on pexpect, ptyprocess, pygdbmi and qemu.qmp. Rather than
> fetching them from PyPI, install them from the wheels vendored in the
> python/wheels/ directory of the same fork commit, with pip --no-index.
>
> [1] https://gitlab.com/xen-project/people/amd/qemu/-/tree/safety?ref_type=heads
>
> Suggested-by: Stefano Stabellini <sstabellini@kernel.org>
> Assisted-by: Claude:claude-opus-5-5
> Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
> ---
> The CI jobs running the tests in this container come in a later patch.
> ---
> Changes in v3:
> - Move the container from test-artifacts to xen.git (automation/build/),
> renamed debian:13-riscv64-qtb.
> - Install the QTB dependencies from the wheels vendored in the fork, with
> pip --no-index.
> - Add pytest, drop jinja2, yaml and device-tree-compiler.
> - Comment that the pinned commit is the tip of the safety branch.
> - Reword the commit title and message.
> ---
> automation/build/debian/13-riscv64-qtb.dockerfile | 47 +++++++++++++++++++++++
> automation/scripts/containerize | 1 +
> 2 files changed, 48 insertions(+)
>
> diff --git a/automation/build/debian/13-riscv64-qtb.dockerfile b/automation/build/debian/13-riscv64-qtb.dockerfile
> new file mode 100644
> index 0000000000..34ca1f2b7d
> --- /dev/null
> +++ b/automation/build/debian/13-riscv64-qtb.dockerfile
> @@ -0,0 +1,47 @@
> +# syntax=docker/dockerfile:1
> +FROM --platform=linux/amd64 debian:trixie-slim
> +LABEL maintainer.name="The Xen Project"
> +LABEL maintainer.email="xen-devel@lists.xenproject.org"
> +
> +ENV DEBIAN_FRONTEND=noninteractive
> +
> +ARG QEMU_REPO=https://gitlab.com/xen-project/people/amd/qemu.git
> +# Tip of the safety branch
> +ARG QEMU_COMMIT=24cd7e5c0d7e4db8e651f091d0b9da2e7c58dbab
> +
> +RUN <<EOF
> +#!/bin/bash
> + set -eu
> +
> + useradd --create-home user
> +
> + apt-get update
> +
> + DEPS=(# Base environment
> + ca-certificates
> + git
> + python3-minimal
> + python3-pip
Nit: the other dockerfiles put the comment on its own line after "DEPS=(".
Also, python3-pip already pulls in python3, so python3-minimal looks
redundant.
Other LGTM:
Reviewed-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
I've also tested it by:
$ podman build -t qtb-review -f
automation/build/debian/13-riscv64-qtb.dockerfile automation/build/debian
And it looks everything is on the place so:
Tested-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
~ Oleksii
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container
[not found] ` <k4hxivkhib6yi7onicgs4ws2earwcawmds3bmp5nefjrw525qo@w6wxrkpdhoru>
2026-11-19 10:38 ` Oleksii Kurochko
@ 2026-11-19 15:28 ` Baptiste Le Duc
1 sibling, 0 replies; 11+ messages in thread
From: Baptiste Le Duc @ 2026-11-19 15:28 UTC (permalink / raw)
To: Hiago De Franco
Cc: xen-devel, Doug Goldstein, Stefano Stabellini, Anthony PERARD,
Andrew Cooper, Alistair Francis, Connor Davis, Oleksii Kurochko,
Alejandro Vallejo, Zhang Zheng
Hi Hiago,
Thanks for reviewing this patch series!
Next time, could you please follow Xen's convention for sending emails:
the recipient (To:) should be xen-devel and the others in CC, as
specified in the "## Recipients of the patch" section of
sending-patches.adoc. If you are using b4 (it seems to be the case from
the formatting), there is a .b4-config at the root of the tree.
>> +ARG QEMU_REPO=https://gitlab.com/xen-project/people/amd/qemu.git
>> +# Tip of the safety branch
> Maybe add a TODO comment here to change this QEMU_COMMIT and switch to
> upstream QEMU once it gets merged? Just a suggestiong, not sure how
> others feel about it, so feel free to ignore as well.
I'm fine with that, something like:
# TODO: drop once QTB is merged into upstream QEMU
>
> Anyway I think the commit message should mention this, that the image
> has to be rebuilt and pushed before the job in patch 5 can run.
Yes, the image has to be rebuilt and pushed to xen-project's registry,
but as I'm not a maintainer I can't do it, and it wouldn't make sense
before the patch is acked anyway. Still, you're right, it's worth
mentioning below the --- of the commit message.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container
2026-11-03 14:08 ` [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container Baptiste Le Duc
` (2 preceding siblings ...)
[not found] ` <k4hxivkhib6yi7onicgs4ws2earwcawmds3bmp5nefjrw525qo@w6wxrkpdhoru>
@ 2026-11-19 17:21 ` dmukhin
3 siblings, 0 replies; 11+ messages in thread
From: dmukhin @ 2026-11-19 17:21 UTC (permalink / raw)
To: Baptiste Le Duc
Cc: xen-devel, Doug Goldstein, Stefano Stabellini, Anthony PERARD,
Andrew Cooper, Alistair Francis, Connor Davis, Oleksii Kurochko,
Alejandro Vallejo, Zhang Zheng
On Tue, Nov 03, 2026 at 03:08:09PM +0100, Baptiste Le Duc wrote:
> The riscv64 QTB tests use QTB (QEMU Test Bench) Python package. QTB is part
> of AMD's work on the 'safety' branch [1] of their QEMU fork and is not
> upstream in QEMU yet. The tests also need pytest and qemu-system-riscv64.
>
> Add debian:13-riscv64-qtb, a Debian Trixie container with those packages
> and the QTB package installed from the python/ directory of AMD's QEMU
> fork, at the commit pinned by QEMU_REPO/QEMU_COMMIT. Make it available to
> containerize script as trixie-riscv64-qtb.
>
> QTB depends on pexpect, ptyprocess, pygdbmi and qemu.qmp. Rather than
> fetching them from PyPI, install them from the wheels vendored in the
> python/wheels/ directory of the same fork commit, with pip --no-index.
>
> [1] https://gitlab.com/xen-project/people/amd/qemu/-/tree/safety?ref_type=heads
>
> Suggested-by: Stefano Stabellini <sstabellini@kernel.org>
> Assisted-by: Claude:claude-opus-5-5
> Signed-off-by: Baptiste Le Duc <baptiste.le-duc@vates.tech>
> ---
> The CI jobs running the tests in this container come in a later patch.
> ---
> Changes in v3:
> - Move the container from test-artifacts to xen.git (automation/build/),
> renamed debian:13-riscv64-qtb.
> - Install the QTB dependencies from the wheels vendored in the fork, with
> pip --no-index.
> - Add pytest, drop jinja2, yaml and device-tree-compiler.
> - Comment that the pinned commit is the tip of the safety branch.
> - Reword the commit title and message.
> ---
> automation/build/debian/13-riscv64-qtb.dockerfile | 47 +++++++++++++++++++++++
> automation/scripts/containerize | 1 +
> 2 files changed, 48 insertions(+)
>
> diff --git a/automation/build/debian/13-riscv64-qtb.dockerfile b/automation/build/debian/13-riscv64-qtb.dockerfile
> new file mode 100644
> index 0000000000..34ca1f2b7d
> --- /dev/null
> +++ b/automation/build/debian/13-riscv64-qtb.dockerfile
> @@ -0,0 +1,47 @@
> +# syntax=docker/dockerfile:1
> +FROM --platform=linux/amd64 debian:trixie-slim
> +LABEL maintainer.name="The Xen Project"
> +LABEL maintainer.email="xen-devel@lists.xenproject.org"
> +
> +ENV DEBIAN_FRONTEND=noninteractive
> +
> +ARG QEMU_REPO=https://gitlab.com/xen-project/people/amd/qemu.git
> +# Tip of the safety branch
> +ARG QEMU_COMMIT=24cd7e5c0d7e4db8e651f091d0b9da2e7c58dbab
> +
> +RUN <<EOF
> +#!/bin/bash
> + set -eu
> +
> + useradd --create-home user
> +
> + apt-get update
> +
> + DEPS=(# Base environment
Can you please move the comment to the new line?
DEPS=(
# Base environment
With or without that correction
Reviewed-by: Denis Mukhin <dmukhin@ford.com>
> + ca-certificates
> + git
> + python3-minimal
> + python3-pip
> + python3-pytest
> + python3-setuptools
> +
> + # QEMU for the tests
> + qemu-system-riscv64
> + )
> +
> + apt-get -y --no-install-recommends install "${DEPS[@]}"
> +
> + # QTB framework
> + git init /tmp/qemu
> + git -C /tmp/qemu fetch --depth 1 "$QEMU_REPO" "$QEMU_COMMIT"
> + git -C /tmp/qemu checkout FETCH_HEAD
> +
> + pip install --break-system-packages --no-index --no-build-isolation \
> + --find-links /tmp/qemu/python/wheels "/tmp/qemu/python[qtb]"
> +
> + rm -rf /tmp/qemu
> + rm -rf /var/lib/apt/lists/*
> +EOF
> +
> +USER user
> +WORKDIR /build
> diff --git a/automation/scripts/containerize b/automation/scripts/containerize
> index feadd9e82f..cd078d48d9 100755
> --- a/automation/scripts/containerize
> +++ b/automation/scripts/containerize
> @@ -33,6 +33,7 @@ case "_${CONTAINER}" in
> _trixie-ppc64le) CONTAINER="${BASE}/debian:13-ppc64le" ;;
> _bookworm-riscv64) CONTAINER="${BASE}/debian:12-riscv64" ;;
> _trixie-riscv64) CONTAINER="${BASE}/debian:13-riscv64" ;;
> + _trixie-riscv64-qtb) CONTAINER="${BASE}/debian:13-riscv64-qtb" ;;
> _bookworm-x86_64-gcc-ibt) CONTAINER="${BASE}/debian:12-x86_64-gcc-ibt" ;;
> _bookworm|_bookworm-x86_64) CONTAINER="${BASE}/debian:12-x86_64" ;;
> _trixie-x86_64|_) CONTAINER="${BASE}/debian:13-x86_64" ;;
>
> --
> 2.56.0
>
>
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2026-11-19 17:22 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1793714671.8631fc262581453bbf619ec5b2062170.1a1a1b9ce9c000403d@vates.tech/T/#u>
2026-11-03 14:08 ` [PATCH v3 1/6] CI: add a Debian 13 riscv64 QTB container Baptiste Le Duc
2026-11-03 14:15 ` Baptiste Le Duc
2026-11-19 11:09 ` Oleksii Kurochko
[not found] ` <k4hxivkhib6yi7onicgs4ws2earwcawmds3bmp5nefjrw525qo@w6wxrkpdhoru>
2026-11-19 10:38 ` Oleksii Kurochko
2026-11-19 15:28 ` Baptiste Le Duc
2026-11-19 17:21 ` dmukhin
2026-11-03 14:08 ` [PATCH v3 2/6] automation/qtb: add the QTB machine for riscv64 Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 3/6] automation/qtb: add the console-test type with a Xen boot test Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 4/6] automation/qtb: add QTB framework README Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 5/6] CI: add a riscv64 smoke test job using the QTB console-test Baptiste Le Duc
2026-11-03 14:08 ` [PATCH v3 6/6] CI: drop the riscv64 expect-based smoke test Baptiste Le Duc
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.