mike upton has submitted this change. (
https://gem5-review.googlesource.com/c/public/gem5/+/34855 )
Change subject: arch-x86, cpu-kvm: add x86 kvm test to long regression
......................................................................
arch-x86, cpu-kvm: add x86 kvm test to long regression
revised patch based on reviews
Change-Id: I18d219080ff8ab1c42c9e1a12aadd89606802b25
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/34855
Maintainer: Bobby R. Bruce <bbr...@ucdavis.edu>
Tested-by: kokoro <noreply+kok...@google.com>
Reviewed-by: mike upton <michaelup...@gmail.com>
---
M tests/gem5/x86-boot-tests/test_linux_boot.py
1 file changed, 13 insertions(+), 4 deletions(-)
Approvals:
mike upton: Looks good to me, approved
Bobby R. Bruce: Looks good to me, approved
kokoro: Regressions pass
diff --git a/tests/gem5/x86-boot-tests/test_linux_boot.py
b/tests/gem5/x86-boot-tests/test_linux_boot.py
index d73f3a1..94b6e7e 100644
--- a/tests/gem5/x86-boot-tests/test_linux_boot.py
+++ b/tests/gem5/x86-boot-tests/test_linux_boot.py
@@ -25,7 +25,9 @@
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import os
+import subprocess
from testlib import *
+import platform
if config.bin_path:
@@ -43,8 +45,10 @@
image = DownloadedProgram(image_url, base_path, image_name, True)
kernel = DownloadedProgram(kernel_url, base_path, kernel_name)
+def support_kvm():
+ return os.access("/dev/kvm", os.R_OK | os.W_OK)
-def test_boot(cpu_type, num_cpus, boot_type):
+def test_boot(cpu_type, num_cpus, boot_type, host):
gem5_verify_config(
name = 'test-ubuntu_boot-' + cpu_type + '_cpu-' + num_cpus
+ '_cpus-'
+ boot_type + '_boot',
@@ -59,14 +63,19 @@
'--boot-type', boot_type,
],
valid_isas = ('X86',),
- valid_hosts = constants.supported_hosts,
+ valid_hosts = host,
length = constants.long_tag,
)
# Test every CPU type
cpu_types = ('atomic', 'simple',)
for cpu_type in cpu_types:
- test_boot(cpu_type, '1', 'init')
+ test_boot(cpu_type, '1', 'init', constants.supported_hosts)
# Test a multicore system
-test_boot('atomic', '4', 'systemd')
+test_boot('atomic', '4', 'systemd', constants.supported_hosts)
+
+#KVM
+if(support_kvm() and (platform.machine() == constants.host_x86_64_tag)):
+ test_boot('kvm', '1', 'init', (constants.host_x86_64_tag,))
+ test_boot('kvm', '4', 'systemd', (constants.host_x86_64_tag,))
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/34855
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I18d219080ff8ab1c42c9e1a12aadd89606802b25
Gerrit-Change-Number: 34855
Gerrit-PatchSet: 4
Gerrit-Owner: mike upton <michaelup...@gmail.com>
Gerrit-Reviewer: Bobby R. Bruce <bbr...@ucdavis.edu>
Gerrit-Reviewer: Gabe Black <gabebl...@google.com>
Gerrit-Reviewer: Giacomo Travaglini <giacomo.travagl...@arm.com>
Gerrit-Reviewer: kokoro <noreply+kok...@google.com>
Gerrit-Reviewer: mike upton <michaelup...@gmail.com>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list -- gem5-dev@gem5.org
To unsubscribe send an email to gem5-dev-le...@gem5.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s