Merge tag 'pull-11.1-testing-updates-230626-1' of https://gitlab.com/stsquad/qemu into staging

testing and gitlab updates:

  - present a dev friendly cmd line in functional test logs
  - tell pylint to skip c-modules
  - widen the capture of functional tests logs in gitlab
  - remove workaround for MacOS build targets
  - update the gitlab bug template for security process

# -----BEGIN PGP SIGNATURE-----
#
# iQEzBAABCgAdFiEEZoWumedRZ7yvyN81+9DbCVqeKkQFAmo6W8MACgkQ+9DbCVqe
# KkRwDwf+NiRSwHfbjVSPOWws8wVSZHcgzeArHPsXtYrebi+rX9+l+bdIeRNFTfDX
# +6FvA5lWMbIB+pNFAkPdtjvpzzmV+tjaer6lR//0riF4Ch3TufYHhDVIjuvJaI/d
# mvsVUAFCS6AMb9sdky2mGA8SHeO5dV7XqMquTOH/tfs/M3PuLFMj8qcVFzXlmC79
# pzbpahCSJsclFj8traFYiAR2ofGXUH2PkW5aEctD1LnyAbGEHdEO8vR3KKB7ysHA
# OySKG0IXTBmyH03rZ9WHskVlH/xVZjo+FPro0moduTVOLeCksNBnuxdmKJKvPVVy
# vSrF/TOjZbmgg9vVlGULFNKTu3VlAQ==
# =2LgM
# -----END PGP SIGNATURE-----
# gpg: Signature made Tue 23 Jun 2026 06:11:15 EDT
# gpg:                using RSA key 6685AE99E75167BCAFC8DF35FBD0DB095A9E2A44
# gpg: Good signature from "Alex Bennée (Master Work Key) <alex.bennee@linaro.org>" [unknown]
# gpg: WARNING: This key is not certified with a trusted signature!
# gpg:          There is no indication that the signature belongs to the owner.
# Primary key fingerprint: 6685 AE99 E751 67BC AFC8  DF35 FBD0 DB09 5A9E 2A44

* tag 'pull-11.1-testing-updates-230626-1' of https://gitlab.com/stsquad/qemu:
  gitlab: update bug template for sec issues & tool assistance
  gitlab: remove build target hacks
  gitlab: ensure "check-XXX' jobs capture functional test logs
  tests/functional: tell pylint not to check c-modules
  python/qemu: dump a developer friendly version of cmdline to logs
  python/qemu: split console from harness args
  python/qemu: split arg between base and harness lists

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
Stefan Hajnoczi
2026-06-25 19:25:44 -04:00
5 changed files with 48 additions and 21 deletions

View File

@@ -78,6 +78,15 @@
extends: .meson_job_template
stage: test
image: $CI_REGISTRY_IMAGE/qemu/$IMAGE:$QEMU_CI_CONTAINER_TAG
artifacts:
name: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG"
when: always
expire_in: 7 days
paths:
- build/meson-logs
- build/tests/functional/*/*/*.log
reports:
junit: build/meson-logs/*.junit.xml
script:
- source scripts/ci/gitlab-ci-section
- section_start buildenv "Setting up to run tests"
@@ -111,15 +120,6 @@
paths:
- ${CI_PROJECT_DIR}/functional-cache
policy: pull-push
artifacts:
name: "$CI_JOB_NAME-$CI_COMMIT_REF_SLUG"
when: always
expire_in: 7 days
paths:
- build/meson-logs
- build/tests/functional/*/*/*.log
reports:
junit: build/meson-logs/*.junit.xml
before_script:
- export QEMU_TEST_ALLOW_UNTRUSTED_CODE=1
- export QEMU_TEST_CACHE_DIR=${CI_PROJECT_DIR}/functional-cache

View File

@@ -29,7 +29,6 @@
- cd build
- ../configure --enable-werror $CONFIGURE_ARGS || { cat config.log meson-logs/meson-log.txt; exit 1; }
- $MAKE -j$(sysctl -n hw.ncpu)
- for TARGET in $TEST_BINARIES ; do $MAKE $TARGET ; done
- for TARGET in $TEST_TARGETS ; do $MAKE $TARGET ; done
aarch64-macos-15-build:
@@ -46,8 +45,7 @@ aarch64-macos-15-build:
--cross-prefix-i386=i686-elf-
--cross-prefix-x86_64=x86_64-elf-
--disable-plugins
TEST_BINARIES: qemu-system-aarch64 qemu-system-i386 qemu-system-x86_64
TEST_TARGETS: check-unit run-tcg-tests-aarch64-softmmu run-tcg-tests-i386-softmmu run-tcg-tests-x86_64-softmmu
TEST_TARGETS: check-unit check-tcg
aarch64-macos-26-build:
extends: .macos_job_template
@@ -64,5 +62,4 @@ aarch64-macos-26-build:
--cross-prefix-i386=i686-elf-
--cross-prefix-x86_64=x86_64-elf-
--disable-plugins
TEST_BINARIES: qemu-system-aarch64 qemu-system-i386 qemu-system-x86_64
TEST_TARGETS: check-unit run-tcg-tests-aarch64-softmmu run-tcg-tests-i386-softmmu run-tcg-tests-x86_64-softmmu
TEST_TARGETS: check-unit check-tcg

View File

@@ -13,8 +13,9 @@ older than this should be reported to the distribution instead.
See https://www.qemu.org/contribute/report-a-bug/ for additional
guidance.
If this is a security issue, please consult
https://www.qemu.org/contribute/security-process/
If this is a security issue, ensure this ticket is marked 'confidential'
before submission. See https://www.qemu.org/contribute/security-process/
for additional guidance
-->
## Host environment
@@ -49,6 +50,12 @@ https://www.qemu.org/contribute/security-process/
2.
3.
<!--
Note: if this issue was discovered with the assistance of automated
tooling LLM, static analysis, fuzzers), the reporter must disclose
that in the description. The steps to reproduce, and any other findings,
must be fully validated by the user of the tool prior to submission.
-->
## Additional information

View File

@@ -292,8 +292,8 @@ class QEMUMachine:
self._iolog = iolog.read()
@property
def _base_args(self) -> List[str]:
args = ['-display', 'none', '-vga', 'none']
def _harness_args(self) -> List[str]:
args: List[str] = []
if self._qmp_set:
if self._sock_pair:
@@ -306,12 +306,17 @@ class QEMUMachine:
moncdev = f"socket,id=mon,path={self._monitor_address}"
args.extend(['-chardev', moncdev, '-mon',
'chardev=mon,mode=control'])
return args
if self._machine is not None:
args.extend(['-machine', self._machine])
def _console_args(self, interactive: bool = False) -> List[str]:
args: List[str] = []
# redirect pre_console_index serials to null
for _ in range(self._console_index):
args.extend(['-serial', 'null'])
if self._console_set:
if interactive:
args.extend(['-serial', 'mon:stdio'])
elif self._console_set:
assert self._cons_sock_pair is not None
fd = self._cons_sock_pair[0].fileno()
chardev = f"socket,id=console,fd={fd}"
@@ -323,6 +328,13 @@ class QEMUMachine:
args.extend(['-device', device])
return args
@property
def _base_args(self) -> List[str]:
args: List[str] = ['-display', 'none', '-vga', 'none']
if self._machine is not None:
args.extend(['-machine', self._machine])
return args
@property
def args(self) -> List[str]:
"""Returns the list of arguments given to the QEMU binary."""
@@ -366,6 +378,8 @@ class QEMUMachine:
self._qemu_full_args = tuple(chain(
self._wrapper,
[self._binary],
self._harness_args,
self._console_args(),
self._base_args,
self._args
))
@@ -474,6 +488,14 @@ class QEMUMachine:
"""
self._pre_launch()
LOG.debug('VM launch command: %r', ' '.join(self._qemu_full_args))
# Log a simplified, developer-runnable command:
# Exclude harness-managed infrastructure args (harness_args)
# and wrapper.
debug_cmd = [self._binary]
debug_cmd.extend(self._console_args(interactive=True))
debug_cmd.extend(self._base_args)
debug_cmd.extend(self._args)
LOG.debug('Developer-runnable command: %r', ' '.join(debug_cmd))
# Cleaning up of this subprocess is guaranteed by _do_shutdown.
# pylint: disable=consider-using-with

View File

@@ -58,6 +58,7 @@ confidence=HIGH,
# no Warning level messages displayed, use "--disable=all --enable=classes
# --disable=W".
disable=bad-inline-option,
c-extension-no-member,
consider-using-f-string,
file-ignored,
fixme,