Skip to contentSkip to conversation

tests/avocado: Prefer max cpu type when using AArch64 virt machine

PATCH Superseded Andrew Jones 3 participants 7 messages Jun 3, 2022

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tests/avocado: Prefer max cpu type when using AArch64 virt machine

The max cpu type is the best default cpu type for tests to use when specifying the cpu type for AArch64 mach-virt. Switch all tests to it.

---
 tests/avocado/replay_kernel.py     | 2 +-
 tests/avocado/reverse_debugging.py | 2 +-
 tests/avocado/tcg_plugins.py       | 6 +++---
 3 files changed, 5 insertions(+), 5 deletions(-)
tests/avocado/replay_kernel.py +1 -1
index 0b2b0dc692b1..c19022ea977d 100644
@@ -147,7 +147,7 @@ def test_aarch64_virt(self):
         """
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
                       '/linux/releases/29/Everything/aarch64/os/images/pxeboot'
tests/avocado/reverse_debugging.py +1 -1
index d2921e70c3b4..d6a6d7277235 100644
@@ -198,7 +198,7 @@ def test_aarch64_virt(self):
         """
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
                       '/linux/releases/29/Everything/aarch64/os/images/pxeboot'
tests/avocado/tcg_plugins.py +3 -3
index 642d2e49e305..2bbf62f5036e 100644
@@ -68,7 +68,7 @@ def test_aarch64_virt_insn(self):
         :avocado: tags=accel:tcg
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_path = self._grab_aarch64_kernel()
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
@@ -94,7 +94,7 @@ def test_aarch64_virt_insn_icount(self):
         :avocado: tags=accel:tcg
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_path = self._grab_aarch64_kernel()
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
@@ -120,7 +120,7 @@ def test_aarch64_virt_mem_icount(self):
         :avocado: tags=accel:tcg
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_path = self._grab_aarch64_kernel()
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
Signature · 1 line
2.34.3
#1 lore raw
Quoted 3 lines · Andrew Jones

The max cpu type is the best default cpu type for tests to use when specifying the cpu type for AArch64 mach-virt. Switch all tests to it.

Hmm, looking at tests in tests/qtest and tests/vm I see cortex-a57 is still used for a default choice. I should probably post another patch changing those to max as well.

Thanks,
drew

Quoted 69 lines
---
 tests/avocado/replay_kernel.py     | 2 +-
 tests/avocado/reverse_debugging.py | 2 +-
 tests/avocado/tcg_plugins.py       | 6 +++---
 3 files changed, 5 insertions(+), 5 deletions(-)
tests/avocado/replay_kernel.py +1 -1
index 0b2b0dc692b1..c19022ea977d 100644
@@ -147,7 +147,7 @@ def test_aarch64_virt(self):
         """
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
                       '/linux/releases/29/Everything/aarch64/os/images/pxeboot'
tests/avocado/reverse_debugging.py +1 -1
index d2921e70c3b4..d6a6d7277235 100644
@@ -198,7 +198,7 @@ def test_aarch64_virt(self):
         """
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
                       '/linux/releases/29/Everything/aarch64/os/images/pxeboot'
tests/avocado/tcg_plugins.py +3 -3
index 642d2e49e305..2bbf62f5036e 100644
@@ -68,7 +68,7 @@ def test_aarch64_virt_insn(self):
         :avocado: tags=accel:tcg
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_path = self._grab_aarch64_kernel()
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
@@ -94,7 +94,7 @@ def test_aarch64_virt_insn_icount(self):
         :avocado: tags=accel:tcg
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_path = self._grab_aarch64_kernel()
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
@@ -120,7 +120,7 @@ def test_aarch64_virt_mem_icount(self):
         :avocado: tags=accel:tcg
         :avocado: tags=arch:aarch64
         :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
         """
         kernel_path = self._grab_aarch64_kernel()
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
Signature · 1 line
2.34.3
#2 lore raw
In reply to Andrew Jones
Quoted 11 lines · Andrew Jones

The max cpu type is the best default cpu type for tests to use when specifying the cpu type for AArch64 mach-virt. Switch all tests to it.

---
 tests/avocado/replay_kernel.py     | 2 +-
 tests/avocado/reverse_debugging.py | 2 +-
 tests/avocado/tcg_plugins.py       | 6 +++---
 3 files changed, 5 insertions(+), 5 deletions(-)

Is there anything in the boot_xen tests that requires cortex-a57, or should they be switched to max as well?

#3 lore raw
Quoted 14 lines · Cornelia Huck
Quoted 11 lines · Andrew Jones

The max cpu type is the best default cpu type for tests to use when specifying the cpu type for AArch64 mach-virt. Switch all tests to it.

---
 tests/avocado/replay_kernel.py     | 2 +-
 tests/avocado/reverse_debugging.py | 2 +-
 tests/avocado/tcg_plugins.py       | 6 +++---
 3 files changed, 5 insertions(+), 5 deletions(-)
Quoted 3 lines

Is there anything in the boot_xen tests that requires cortex-a57, or should they be switched to max as well?

You're right. I was ignoring xen tests for no good reason. They're simply using TCG mach-virt with a "default" cpu type too.

I'll spin a v2 that changes everything in tests/ which uses mach- virt and appears to be want a default cpu type.

Thanks,
drew

#4 lore raw
In reply to Andrew Jones
Quoted 3 lines · Andrew Jones

The max cpu type is the best default cpu type for tests to use when specifying the cpu type for AArch64 mach-virt. Switch all tests to it.

This won't work without further changes.

tests/avocado/replay_kernel.py def test_aarch64_virt(self): · line 153

Quoted 9 lines
tests/avocado/replay_kernel.py +1 -1
@@ -147,7 +147,7 @@ def test_aarch64_virt(self):
          """
          :avocado: tags=arch:aarch64
          :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
          """
          kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
                        '/linux/releases/29/Everything/aarch64/os/images/pxeboot'

For a release this old, we'll see the kernel bugs wrt FEAT_LPA/FEAT_LPA2. See 11593544df6f ("tests/avocado: update aarch64_virt test to exercise -cpu max")

r~

#5 lore raw
Quoted 7 lines · Richard Henderson
Quoted 3 lines · Andrew Jones

The max cpu type is the best default cpu type for tests to use when specifying the cpu type for AArch64 mach-virt. Switch all tests to it.

This won't work without further changes.

Quoted 12 lines

tests/avocado/replay_kernel.py def test_aarch64_virt(self): · line 153

Quoted 9 lines
tests/avocado/replay_kernel.py +1 -1
@@ -147,7 +147,7 @@ def test_aarch64_virt(self):
          """
          :avocado: tags=arch:aarch64
          :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
          """
          kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
                        '/linux/releases/29/Everything/aarch64/os/images/pxeboot'

For a release this old, we'll see the kernel bugs wrt FEAT_LPA/FEAT_LPA2. See 11593544df6f ("tests/avocado: update aarch64_virt test to exercise -cpu max")

Thanks Richard. How about for each test with guest kernels which don't work, I add a comment about LPA2 and use '-cpu max,lpa2=off' instead?

drew

#6 lore raw
Quoted 21 lines · Andrew Jones
Quoted 7 lines · Richard Henderson
Quoted 3 lines · Andrew Jones

The max cpu type is the best default cpu type for tests to use when specifying the cpu type for AArch64 mach-virt. Switch all tests to it.

This won't work without further changes.

Quoted 12 lines

tests/avocado/replay_kernel.py def test_aarch64_virt(self): · line 153

Quoted 9 lines
tests/avocado/replay_kernel.py +1 -1
@@ -147,7 +147,7 @@ def test_aarch64_virt(self):
           """
           :avocado: tags=arch:aarch64
           :avocado: tags=machine:virt
-        :avocado: tags=cpu:cortex-a53
+        :avocado: tags=cpu:max
           """
           kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
                         '/linux/releases/29/Everything/aarch64/os/images/pxeboot'

For a release this old, we'll see the kernel bugs wrt FEAT_LPA/FEAT_LPA2. See 11593544df6f ("tests/avocado: update aarch64_virt test to exercise -cpu max")

Quoted 2 lines

Thanks Richard. How about for each test with guest kernels which don't work, I add a comment about LPA2 and use '-cpu max,lpa2=off' instead?

I would prefer to test new kernels with max, where we might actually test the newer features. Perhaps keep one older kernel test around, to make sure we don't regress, but don't pretend that it can test more than what it was built for.

r~