ci: Fixes on the recent cross-binary test case
cover ci: Fixes on the recent cross-binary test case
From: Peter Xu <[email protected]>
Hi,
This small patchset updates the recent cross-binary test for migration on a few things.
Patch 1 modifies the aarch64 test GIC version to 3 rather than "max", paving way for enabling it, even if the CPU model is not yet ready.
Patch 2 removes the tag dependency of the new build-previous-qemu job, so that in personal CI pipelines the job won't fail if the tag is missing, as reported by Peter Maydell, and solution suggested by Dan.
Patch 3 updates the comment for aarch64 on the test to state the fact, and what is missing. Then we don't target it support for v9.0, but only until we have a stable CPU model for aarch64 (if ever possible to support both tcg and kvm).
Comments welcomed, thanks.
Peter Xu (3):
tests/migration-test: Stick with gicv3 in aarch64 test
ci: Remove tag dependency for build-previous-qemu
ci: Update comment for migration-compat-aarch64
tests/qtest/migration-test.c | 2 +- .gitlab-ci.d/buildtest.yml | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-)
Signature · 1 line
2.43.0
PATCH 2/3 ci: Remove tag dependency for build-previous-qemu
From: Peter Xu <[email protected]>
The new build-previous-qemu job relies on QEMU release tag being present, while that may not be always true for personal git repositories since by default tag is not pushed. The job can fail on those CI kicks, as reported by Peter Maydell.
Fix it by fetching the tags remotely from the official repository, as suggested by Dan.
[1] https://lore.kernel.org/r/[email protected]
--- .gitlab-ci.d/buildtest.yml | 2 ++ 1 file changed, 2 insertions(+)
.gitlab-ci.d/buildtest.yml +2 -0
@@ -189,6 +189,8 @@ build-previous-qemu: TARGETS: x86_64-softmmu aarch64-softmmu before_script: - export QEMU_PREV_VERSION="$(sed 's/\([0-9.]*\)\.[0-9]*/v\1.0/' VERSION)" + - git remote add upstream https://gitlab.com/qemu-project/qemu + - git fetch upstream $QEMU_PRRV_VERSION - git checkout $QEMU_PREV_VERSION after_script: - mv build build-previous
Signature · 1 line
2.43.0
PATCH 3/3 ci: Update comment for migration-compat-aarch64
In reply to [email protected]From: Peter Xu <[email protected]>
It turns out that we may not be able to enable this test even for the upcoming v9.0. Document what we're still missing.
--- .gitlab-ci.d/buildtest.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)
.gitlab-ci.d/buildtest.yml +4 -3
@@ -219,9 +219,10 @@ build-previous-qemu: - QTEST_QEMU_BINARY_DST=./qemu-system-${TARGET} QTEST_QEMU_BINARY=../build/qemu-system-${TARGET} ./tests/qtest/migration-test -# This job is disabled until we release 9.0. The existing -# migration-test in 8.2 is broken on aarch64. The fix was already -# commited, but it will only take effect once 9.0 is out. +# This job needs to be disabled until we can have an aarch64 CPU model that +# will both (1) support both KVM and TCG, and (2) provide a stable ABI. +# Currently only "-cpu max" can provide (1), however it doesn't guarantee +# (2). Mark this test skipped until later. migration-compat-aarch64: extends: .migration-compat-common variables:
Signature · 1 line
2.43.0
PATCH 1/3 tests/migration-test: Stick with gicv3 in aarch64 test
In reply to [email protected]From: Peter Xu <[email protected]>
Recently we introduced cross-binary migration test. It's always wanted that migration-test uses stable guest ABI for both QEMU binaries in this case, so that both QEMU binaries will be compatible on the migration stream with the cmdline specified.
Switch to a static gic version "3" rather than using version "max", so that GIC should be stable now across any future QEMU binaries for migration-test.
Here the version can actually be anything as long as the ABI is stable. We choose "3" because it's the majority of what we already use in QEMU while still new enough: "git grep gic-version=3" shows 6 hit, while version 4 has no direct user yet besides "max".
Note that even with this change, aarch64 won't be able to work yet with migration cross binary test, but then the only missing piece will be the stable CPU model.
--- tests/qtest/migration-test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tests/qtest/migration-test.c +1 -1
@@ -819,7 +819,7 @@ static int test_migrate_start(QTestState **from, QTestState **to, }else if (strcmp (arch,"aarch64" ) ==0 ) { memory_size ="150M" ; machine_alias ="virt" ; - machine_opts ="gic-version=max" ; + machine_opts ="gic-version=3" ; arch_opts =g_strdup_printf ("-cpu max -kernel %s" , bootpath); start_address =ARM_TEST_MEM_START ; end_address =ARM_TEST_MEM_END ;
Signature · 1 line
2.43.0
Re: [PATCH 2/3] ci: Remove tag dependency for build-previous-qemu
In reply to [email protected]Quoted 24 lines · On Tue, Feb 06, 2024 at 02:31:50PM +0800, [email protected] wrote:
From: Peter Xu <[email protected]>
The new build-previous-qemu job relies on QEMU release tag being present, while that may not be always true for personal git repositories since by default tag is not pushed. The job can fail on those CI kicks, as reported by Peter Maydell.
Fix it by fetching the tags remotely from the official repository, as suggested by Dan.
[1] https://lore.kernel.org/r/[email protected]
Reported-by Peter Maydell <[email protected]>Suggested-by Daniel P. Berrangé <[email protected]>Signed-off-by Peter Xu <[email protected]>--- .gitlab-ci.d/buildtest.yml | 2 ++ 1 file changed, 2 insertions(+).gitlab-ci.d/buildtest.yml +0
-0
.gitlab-ci.d/buildtest.yml build-previous-qemu: · line 193
Quoted 5 lines
.gitlab-ci.d/buildtest.yml +2
-0@@ -189,6 +189,8 @@ build-previous-qemu: TARGETS: x86_64-softmmu aarch64-softmmu before_script: - export QEMU_PREV_VERSION="$(sed 's/\([0-9.]*\)\.[0-9]*/v\1.0/' VERSION)" + - git remote add upstream https://gitlab.com/qemu-project/qemu + - git fetch upstream $QEMU_PRRV_VERSION
Typo^^^
.gitlab-ci.d/buildtest.yml build-previous-qemu: · line 196
Quoted 3 lines
.gitlab-ci.d/buildtest.yml +0
-0- git checkout $QEMU_PREV_VERSION after_script: - mv build build-previous
With that typo fixed, then
With regards,
Daniel
Signature · 3 lines
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
Re: [PATCH 3/3] ci: Update comment for migration-compat-aarch64
In reply to [email protected]Quoted 9 lines · On Tue, Feb 06, 2024 at 02:31:51PM +0800, [email protected] wrote:
From: Peter Xu <[email protected]>
It turns out that we may not be able to enable this test even for the upcoming v9.0. Document what we're still missing.
Signed-off-by Peter Xu <[email protected]>--- .gitlab-ci.d/buildtest.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)
With regards,
Daniel
Signature · 3 lines
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
Re: [PATCH 1/3] tests/migration-test: Stick with gicv3 in aarch64 test
In reply to [email protected]Quoted 15 lines · On Tue, Feb 06, 2024 at 02:31:49PM +0800, [email protected] wrote:
From: Peter Xu <[email protected]>
Recently we introduced cross-binary migration test. It's always wanted that migration-test uses stable guest ABI for both QEMU binaries in this case, so that both QEMU binaries will be compatible on the migration stream with the cmdline specified.
Switch to a static gic version "3" rather than using version "max", so that GIC should be stable now across any future QEMU binaries for migration-test.
Here the version can actually be anything as long as the ABI is stable. We choose "3" because it's the majority of what we already use in QEMU while still new enough: "git grep gic-version=3" shows 6 hit, while version 4 has no direct user yet besides "max".
Quoted 8 lines
Note that even with this change, aarch64 won't be able to work yet with migration cross binary test, but then the only missing piece will be the stable CPU model.
Signed-off-by Peter Xu <[email protected]>--- tests/qtest/migration-test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
With regards,
Daniel
Signature · 3 lines
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
Re: [PATCH 2/3] ci: Remove tag dependency for build-previous-qemu
In reply to Daniel P. BerrangéQuoted 20 lines · Daniel P. Berrangé
Quoted 19 lines · On Tue, Feb 06, 2024 at 02:31:50PM +0800, [email protected] wrote:
From: Peter Xu <[email protected]>
The new build-previous-qemu job relies on QEMU release tag being present, while that may not be always true for personal git repositories since by default tag is not pushed. The job can fail on those CI kicks, as reported by Peter Maydell.
Fix it by fetching the tags remotely from the official repository, as suggested by Dan.
[1] https://lore.kernel.org/r/[email protected]
Reported-by Peter Maydell <[email protected]>Suggested-by Daniel P. Berrangé <[email protected]>Signed-off-by Peter Xu <[email protected]>--- .gitlab-ci.d/buildtest.yml | 2 ++ 1 file changed, 2 insertions(+)
Quoted 12 lines
.gitlab-ci.d/buildtest.yml build-previous-qemu: · line 193
Quoted 10 lines
.gitlab-ci.d/buildtest.yml +2
-0@@ -189,6 +189,8 @@ build-previous-qemu: TARGETS: x86_64-softmmu aarch64-softmmu before_script: - export QEMU_PREV_VERSION="$(sed 's/\([0-9.]*\)\.[0-9]*/v\1.0/' VERSION)" + - git remote add upstream https://gitlab.com/qemu-project/qemu + - git fetch upstream $QEMU_PRRV_VERSIONTypo^^^
Interestingly, this typo won't affect the function, as QEMU_PRRV_VERSION will be an empty string, and this cmd will simply pull in all the tags..
After the fix, it should only fetch the tag that we need.
Quoted 8 lines
.gitlab-ci.d/buildtest.yml build-previous-qemu: · line 196
Quoted 4 lines
.gitlab-ci.d/buildtest.yml +0
-0- git checkout $QEMU_PREV_VERSION after_script: - mv build build-previousWith that typo fixed, then
Reviewed-by Daniel P. Berrangé <[email protected]>
Thanks.
Signature · 1 line
Peter Xu