Commit Graph

199 Commits

Author SHA1 Message Date
Henry Wang
eed0c927fd scripts: AArch64: Add missing tests in sequential mod
Signed-off-by: Henry Wang <Henry.Wang@arm.com>
2021-09-07 09:35:06 +01:00
Henry Wang
fb5cbd966e scripts: AArch64: Run test cases for split modules
Signed-off-by: Henry Wang <Henry.Wang@arm.com>
2021-09-07 09:35:06 +01:00
Jianyong Wu
a2e72774a9 bump kernel version to 5.14 for arm
Bump kernel version and update kernel config file accordingly.
Especially, enable virtio-mem and MEMORY_HOTPLUG_DEFAULT_ONLINE here.

Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
2021-09-07 09:34:22 +01:00
Henry Wang
5d53648762 scripts: Enable the live-migration test on AArch64
Signed-off-by: Henry Wang <Henry.Wang@arm.com>
2021-09-03 06:36:17 +01:00
Bo Chen
a1a0bc8592 scripts: Add entry for live-migration integration tests
Signed-off-by: Bo Chen <chen.bo@intel.com>
2021-09-02 14:57:31 +01:00
Sebastien Boeuf
f3793c08b5 resources: Update to guest kernel 5.14
Moving to the latest kernel 5.14 simplifies greatly the list of patches
that we need to carry. Since virtio-iommu has been merged as part of the
5.14 release, the only remaining patches are virtio-watchdog and the EFI
reboot.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-08-30 10:23:57 -07:00
Henry Wang
e1f35628e2 dev_cli: Enable pulling latest dev container on Arm
Currently the latest cloudhypervisor/dev docker container is the
multi-arch image. We can pull the arm image directly.

Signed-off-by: Henry Wang <Henry.Wang@arm.com>
2021-08-26 14:45:19 +01:00
Wei Liu
972e96ea68 scripts: honour --volumes in cmd_shell
It is useful to mount custom volumes sometimes.

Signed-off-by: Wei Liu <liuwe@microsoft.com>
2021-07-19 09:52:51 +02:00
Henry Wang
ea0918e5e8 docs, scripts: Use upstream edk2 for AArch64
The edk2 upstream has already suppoorted AArch64 Cloud Hypervisor,
and hence we can use upstream edk2 in CI and doc.

Signed-off-by: Henry Wang <Henry.Wang@arm.com>
2021-07-09 15:36:37 +02:00
Michael Zhao
d330d91e1a tests: Optimize integration test on AArch64
AArch64 tests were divided into 2 steps:
- Build and test with 'acpi' feature
- Build and test without 'acpi'

This can be optimized. We need only to build and test once with default
features ('acpi' is enabled).

On AArch64, ACPI only works with UEFI. If UEFI is not available, guest
kernel fall back to use FDT. Most AArch64 test cases boot from direct
kernel, the guest will keep using FDT even if ACPI is enabled. So
nothing is broken.

Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2021-06-24 13:13:27 +01:00
Rob Bradford
4c22592c6f scripts: Use CDN to download images
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-06-16 16:25:24 +01:00
Sebastien Boeuf
a6fe4aa7e9 virtio-devices, vmm: Update virtio-iommu to rely on VIOT
Since using the VIRTIO configuration to expose the virtual IOMMU
topology has been deprecated, the virtio-iommu implementation must be
updated.

In order to follow the latest patchset that is about to be merged in the
upstream Linux kernel, it must rely on ACPI, and in particular the newly
introduced VIOT table to expose the information about the list of PCI
devices attached to the virtual IOMMU.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-06-15 17:05:59 +02:00
Sebastien Boeuf
9dba097224 ci: Update guest cloud image by installing "stress" utility
Some new integration tests will require the "stress" binary to be
present in the guest in order to run correctly.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-06-09 14:34:55 +01:00
Michael Zhao
ce5c5833cb tests: Add a simple test case for ACPI on AArch64
In the test case, the guest boots from EDK2.

Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2021-06-09 18:36:59 +08:00
Henry Wang
3cb2b72e92 tests: Build EDK2 for AArch64 integration test
This commit added support for building the edk2 binary dedicated
for the Cloud Hypervisor (CLOUDHV_EFI.fd).

Signed-off-by: Henry Wang <Henry.Wang@arm.com>
2021-06-09 18:36:59 +08:00
Sebastien Boeuf
bb68e0bc3b tests: Re-enable virtiofsd tests
Re-enable virtiofsd testing now that issues with capstone repository
have been resolved.

This reverts commit a14c70019a.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-06-08 20:13:41 +02:00
Rob Bradford
a14c70019a tests: Don't test virtiofsd
The CI is failing due the git server that the submodules required for
this fork of QEMU need to build from is unavailable.

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
(cherry picked from commit 2aec0a92a5)
2021-06-02 16:12:30 +02:00
Sebastien Boeuf
4db7530f28 ci: Add OVS-DPDK integration test
In order to avoid regression regarding OVS-DPDK support, a new
integration test is added. This test consists of running two VMs, both
attached to a distinct OVS port, where both ports are connected to an
OVS bridge. Once the VM are running, the test validates the connection
between the two VMs works correctly.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-06-01 12:17:23 +02:00
Michael Zhao
e1c9a956da scripts: Fix an obsolete sha1sam
Updated the sha1sum of bionic-server-cloudimg-arm64.qcow2.

Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2021-05-20 13:42:34 +08:00
Michael Zhao
aca6fdbd0e scripts: Test ACPI build on AArch64
Added a step to verify ACPI build.

Signed-off-by: Michael Zhao <michael.zhao@arm.com>
2021-05-18 23:24:09 +02:00
Sebastien Boeuf
5268bf5a8c tests: Re-enable virtiofsd tests
Re-enable virtiofsd testing now that issues with capstone repository
have been resolved.

This reverts commit 2aec0a92a5.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-05-07 11:16:36 +02:00
Sebastien Boeuf
0a00df2e7e tests: Dynamically assign IPs for Windows integration tests
Relying on dnsmasq running on the host, the Windows guest are now
getting allocated with the expected IP addresses. This allows for
multiple VMs, therefore multiple tests to run in parallel.

The end goal is to reduce the time spent running Windows integration
tests.

Fixes #1891

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-05-06 17:27:33 +02:00
Sebastien Boeuf
b5be62a167 tests: Extend VFIO baremetal integration tests
Relying on guest Ubuntu image 21.04, including a 5.11 kernel, this patch
adds some additional tests to the VFIO baremetal integration tests. It
adds a test for ACPI memory hotplug, another one for virtio-mem memory
hotplug, and finally a test for hotplugging the NVIDIA card.

The existing test already taking care of the reboot has been renamed.

The script running "cargo test" has been modified to run only one thread
at a time, so that each test run sequentially. This is mandatory since
the card can't be shared across multiple VMs.

Fixes #2404

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-05-04 15:01:29 +02:00
Rob Bradford
2aec0a92a5 tests: Don't test virtiofsd
The CI is failing due the git server that the submodules required for
this fork of QEMU need to build from is unavailable.

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-05-04 12:14:37 +01:00
Rob Bradford
1f4a34ffc8 tests: Remove last tests using bzImage
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-04-30 16:16:48 +02:00
Rob Bradford
7367ca70c2 tests: Don't build separate pvh/non-pvh vmlinux binary
Use the PVH vmlinux for all tests (with the exception of the specific
bzImage test.)

See: #2231

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-04-28 10:40:31 +02:00
Rob Bradford
b5cf1f5a9e resources, scripts: Update x86_64 kernel to 5.12
The 5.12 kernel contains a fix for issues observed with nested snapshot
& restore.

Fixes: #2535

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-04-28 09:02:01 +02:00
Rob Bradford
5d1abec565 resources, scripts: Update aarch64 kernel to 5.12
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-04-27 11:31:17 +02:00
Sebastien Boeuf
e5211a6e1d ci: Update Ubuntu Focal custom image
Update the Ubuntu Focal image used as the guest image. It's based on the
latest Focal image released on April 1st 2021, and customized to include
all the utilities we need. As usual, snapd and pollinate services have
been removed.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-04-07 10:26:15 +01:00
Sebastien Boeuf
04dc496808 ci: Enable baremetal VFIO integration tests
Relying on a NVIDIA Tesla T4 card present in the SGX machine, this patch
enables baremetal VFIO testing, validated by running several NVIDIA
tools in the guest. The guest image has been prepared to include all the
software needed to run these tests.

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-03-16 18:59:46 +00:00
Muminul Islam
8739f6cccb scripts: Fix windows test script for running on MSHV
In order to run Windows test on MSHV we need to build and test using
MSHV feature.

Signed-off-by: Muminul Islam <muislam@microsoft.com>
2021-03-10 10:08:12 +00:00
Rob Bradford
99baee8d37 tests: Move Windows integration test to updated OVMF
Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-03-01 22:11:19 +00:00
Muminul Islam
29f924405a scripts: Check if windows image is in the host
Currently script does not exit early if the image/firmware not present
in the host. We should not progress further if the images are not pre
downloaded.

Signed-off-by: Muminul Islam <muislam@microsoft.com>
2021-02-19 10:09:23 +00:00
Muminul Islam
282134a490 scripts: Use variable for with windows image file
Signed-off-by: Muminul Islam <muislam@microsoft.com>
2021-02-19 10:09:23 +00:00
Bo Chen
a838d0bde1 scripts, tests: Rustify the network setup commands for tests
Fixes: #2218

Signed-off-by: Bo Chen <chen.bo@intel.com>
2021-02-15 08:34:23 +00:00
Muminul Islam
024675d1d8 scripts: error exit if aarch64 test is run on MSHV
Signed-off-by: Muminul Islam <muislam@microsoft.com>
2021-02-05 09:22:58 +00:00
Muminul Islam
c4fb0f36bd scripts: Use hypervisor variable instead of kvm
Signed-off-by: Muminul Islam <muislam@microsoft.com>
2021-01-28 09:11:02 +00:00
Muminul Islam
9cdcbb5121 script: Modify unit tests to support mshv
Signed-off-by: Muminul Islam <muislam@microsoft.com>
2021-01-28 09:11:02 +00:00
Muminul Islam
b339aa6b88 scripts: Export devices(/dev/kvm or /dev/mshv) based on hypervisor
Signed-off-by: Muminul Islam <muislam@microsoft.com>
2021-01-28 09:11:02 +00:00
Rob Bradford
b8342ebeb4 scripts: Don't download container on help invocations
Delay downloading the container until it is being used.

Fixes: #2065

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-01-26 13:29:05 +01:00
Rob Bradford
c2acea5156 tests: Support filtering integration tests
e.g.

scripts/dev_cli.sh tests --integration -- --test-filter test_watchdog

This used to be supported by passing "$@" but was broken when multiple
hypervisor support was added.

Fixes: #2182

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-01-25 17:34:10 +00:00
Sebastien Boeuf
3b43551d98 ci: Use device mapper to avoid copying Windows image
The Windows image is quite large (about 20GiB), hence it takes some time
to copy it for every test in order to avoid potential corruption.

One way to mitigate that without compromising on safety between each
test is by using device mapper. By creating a read-only base, we ensure
the image won't be modified by any of the tests, and by creating one
snapshot for each test, we avoid copying the entire image each time.
A dedicated Copy On Write disk image is created to handle any change
that might be performed on the base image, letting the tests behave as
expected.

Fixes #2155

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-01-13 10:48:06 +00:00
Rob Bradford
5881809126 tests: Update integration tests to use new image without pollinate
This image does not have the pollinate service which can sometimes fail
and prevent SSH from starting as it marks itself as a prerequisite. This
service will never fully succeed as it tries to make a network
connection which will fail inside our test VMs.

Fixes: #2113

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-01-11 16:38:07 +00:00
Rob Bradford
852bf0b2ce scripts, resources: aarch64: Update to Linux kernel v5.10 base
This allows the removal of most of the custom patches in particular all
the virtio-fs ones have been integrated.

Fixes: #2070

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-01-11 12:56:05 +01:00
Rob Bradford
642a1a610f scripts: Update to Linux fork using latest virtio-iommu patches
The ch-5.10.6 branch is rebased on top of Linux stable and includes the
latest virtio-iommu support patches.

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-01-11 12:56:05 +01:00
Sebastien Boeuf
7889fc9207 scripts: Run test container with the default bridge network
Using --net=host is not necessary for any of the integration tests, so
let's use the default network option called "bridge".

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
2021-01-11 11:18:48 +00:00
Rob Bradford
539708e45e scripts, resources: x86_64: Update to Linux kernel v5.10 base
This allows the removal of most of the custom patches in particular all
the virtio-fs ones have been integrated.

Partially fixes: #2070

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2021-01-04 22:44:40 +00:00
Muminul Islam
d79594aa3f scripts: dev_cli: Remove unnecessary spaces
Signed-off-by: Muminul Islam <muislam@microsoft.com>
2020-12-05 00:01:41 +01:00
Muminul Islam
27b5f8d7e3 scripts: Add an option to accept hypervisor argument
Signed-off-by: Muminul Islam <muislam@microsoft.com>
2020-12-05 00:01:41 +01:00
Rob Bradford
1908f488c3 tests: Move tests from vhost_user_fs to virtiofsd-rs
Download and build virtiofsd-rs and then use that in the integration
test suite.

Fixes: #2013

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
2020-12-01 11:13:21 +01:00