diff mbox series

[3/5] avocado/boot_linux_console.py: check for tcg in test_ppc_powernv8/9

Message ID 20220303153517.168943-4-danielhb413@gmail.com (mailing list archive)
State New, archived
Headers show
Series --disable-tcg qtest/avocado fixes for ppc64 | expand

Commit Message

Daniel Henrique Barboza March 3, 2022, 3:35 p.m. UTC
The PowerNV8/9 machines does not work with KVM acceleration, meaning
that boot_linux_console.py:BootLinuxConsole.test_ppc_powernv8/9 tests
will always fail when QEMU is compiled with --disable-tcg:

ERROR 1-tests/avocado/boot_linux_console.py:BootLinuxConsole.test_ppc_powernv8
-> VMLaunchFailure: ConnectError: Failed to establish session:
[Errno 104] Connection reset by peer
        Exit code: 1
        Command: ./qemu-system-ppc64 -display none -vga none -chardev socket,id=mon,path=/var/tmp/avo_qemu_sock_no19zg0m/qemu-1936936-7fffa77cff98-monitor.sock -mon chardev=mon,mode=control -machine powernv8 -chardev socket,id=console,path=/var/tmp/avo_qemu_sock_no19zg0m/qemu-1936936-7fffa77cff98-console.sock,server=on,wait=off -serial chardev:console -kernel /home/danielhb/avocado/data/cache/by_location/4514304e2c4ee84c5f0b5c8bacedda783891df68/zImage.epapr -append console=tty0 console=hvc0 -device pcie-pci-bridge,id=bridge1,bus=pcie.1,addr=0x0 -device nvme,bus=pcie.2,addr=0x0,serial=1234 -device e1000e,bus=bridge1,addr=0x3 -device nec-usb-xhci,bus=bridge1,addr=0x2
        Output: qemu-system-ppc64: The powernv machine does not work with KVM acceleration

Let's add the TCG accel requirement in both tests to skip them if we
don't have TCG support available.

Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
---
 tests/avocado/boot_linux_console.py | 3 +++
 1 file changed, 3 insertions(+)

Comments

Cédric Le Goater March 3, 2022, 4:08 p.m. UTC | #1
On 3/3/22 16:35, Daniel Henrique Barboza wrote:
> The PowerNV8/9 machines does not work with KVM acceleration, meaning
> that boot_linux_console.py:BootLinuxConsole.test_ppc_powernv8/9 tests
> will always fail when QEMU is compiled with --disable-tcg:
> 
> ERROR 1-tests/avocado/boot_linux_console.py:BootLinuxConsole.test_ppc_powernv8
> -> VMLaunchFailure: ConnectError: Failed to establish session:
> [Errno 104] Connection reset by peer
>          Exit code: 1
>          Command: ./qemu-system-ppc64 -display none -vga none -chardev socket,id=mon,path=/var/tmp/avo_qemu_sock_no19zg0m/qemu-1936936-7fffa77cff98-monitor.sock -mon chardev=mon,mode=control -machine powernv8 -chardev socket,id=console,path=/var/tmp/avo_qemu_sock_no19zg0m/qemu-1936936-7fffa77cff98-console.sock,server=on,wait=off -serial chardev:console -kernel /home/danielhb/avocado/data/cache/by_location/4514304e2c4ee84c5f0b5c8bacedda783891df68/zImage.epapr -append console=tty0 console=hvc0 -device pcie-pci-bridge,id=bridge1,bus=pcie.1,addr=0x0 -device nvme,bus=pcie.2,addr=0x0,serial=1234 -device e1000e,bus=bridge1,addr=0x3 -device nec-usb-xhci,bus=bridge1,addr=0x2
>          Output: qemu-system-ppc64: The powernv machine does not work with KVM acceleration
> 
> Let's add the TCG accel requirement in both tests to skip them if we
> don't have TCG support available.
> 
> Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>

Reviewed-by: Cédric Le Goater <clg@kaod.org>

Thanks,

C.

> ---
>   tests/avocado/boot_linux_console.py | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/tests/avocado/boot_linux_console.py b/tests/avocado/boot_linux_console.py
> index 9c618d4809..d7d9130329 100644
> --- a/tests/avocado/boot_linux_console.py
> +++ b/tests/avocado/boot_linux_console.py
> @@ -1170,6 +1170,7 @@ def test_ppc64_e500(self):
>           self.do_test_advcal_2018('19', tar_hash, 'uImage')
>   
>       def do_test_ppc64_powernv(self, proc):
> +        self.require_accelerator("tcg")
>           images_url = ('https://github.com/open-power/op-build/releases/download/v2.7/')
>   
>           kernel_url = images_url + 'zImage.epapr'
> @@ -1194,6 +1195,7 @@ def test_ppc_powernv8(self):
>           """
>           :avocado: tags=arch:ppc64
>           :avocado: tags=machine:powernv8
> +        :avocado: tags=accel:tcg
>           """
>           self.do_test_ppc64_powernv('P8')
>   
> @@ -1201,6 +1203,7 @@ def test_ppc_powernv9(self):
>           """
>           :avocado: tags=arch:ppc64
>           :avocado: tags=machine:powernv9
> +        :avocado: tags=accel:tcg
>           """
>           self.do_test_ppc64_powernv('P9')
>
Philippe Mathieu-Daudé March 4, 2022, 12:23 p.m. UTC | #2
On 3/3/22 16:35, Daniel Henrique Barboza wrote:
> The PowerNV8/9 machines does not work with KVM acceleration, meaning
> that boot_linux_console.py:BootLinuxConsole.test_ppc_powernv8/9 tests
> will always fail when QEMU is compiled with --disable-tcg:
> 
> ERROR 1-tests/avocado/boot_linux_console.py:BootLinuxConsole.test_ppc_powernv8
> -> VMLaunchFailure: ConnectError: Failed to establish session:
> [Errno 104] Connection reset by peer
>          Exit code: 1
>          Command: ./qemu-system-ppc64 -display none -vga none -chardev socket,id=mon,path=/var/tmp/avo_qemu_sock_no19zg0m/qemu-1936936-7fffa77cff98-monitor.sock -mon chardev=mon,mode=control -machine powernv8 -chardev socket,id=console,path=/var/tmp/avo_qemu_sock_no19zg0m/qemu-1936936-7fffa77cff98-console.sock,server=on,wait=off -serial chardev:console -kernel /home/danielhb/avocado/data/cache/by_location/4514304e2c4ee84c5f0b5c8bacedda783891df68/zImage.epapr -append console=tty0 console=hvc0 -device pcie-pci-bridge,id=bridge1,bus=pcie.1,addr=0x0 -device nvme,bus=pcie.2,addr=0x0,serial=1234 -device e1000e,bus=bridge1,addr=0x3 -device nec-usb-xhci,bus=bridge1,addr=0x2
>          Output: qemu-system-ppc64: The powernv machine does not work with KVM acceleration
> 
> Let's add the TCG accel requirement in both tests to skip them if we
> don't have TCG support available.
> 
> Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
> ---
>   tests/avocado/boot_linux_console.py | 3 +++
>   1 file changed, 3 insertions(+)

Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
diff mbox series

Patch

diff --git a/tests/avocado/boot_linux_console.py b/tests/avocado/boot_linux_console.py
index 9c618d4809..d7d9130329 100644
--- a/tests/avocado/boot_linux_console.py
+++ b/tests/avocado/boot_linux_console.py
@@ -1170,6 +1170,7 @@  def test_ppc64_e500(self):
         self.do_test_advcal_2018('19', tar_hash, 'uImage')
 
     def do_test_ppc64_powernv(self, proc):
+        self.require_accelerator("tcg")
         images_url = ('https://github.com/open-power/op-build/releases/download/v2.7/')
 
         kernel_url = images_url + 'zImage.epapr'
@@ -1194,6 +1195,7 @@  def test_ppc_powernv8(self):
         """
         :avocado: tags=arch:ppc64
         :avocado: tags=machine:powernv8
+        :avocado: tags=accel:tcg
         """
         self.do_test_ppc64_powernv('P8')
 
@@ -1201,6 +1203,7 @@  def test_ppc_powernv9(self):
         """
         :avocado: tags=arch:ppc64
         :avocado: tags=machine:powernv9
+        :avocado: tags=accel:tcg
         """
         self.do_test_ppc64_powernv('P9')