1 # OpenSBI boot test for RISC-V machines
3 # Copyright (c) 2022, Ventana Micro
5 # This work is licensed under the terms of the GNU GPL, version 2 or
6 # later. See the COPYING file in the top-level directory.
8 from avocado_qemu
import QemuSystemTest
9 from avocado_qemu
import wait_for_console_pattern
11 class RiscvOpenSBI(QemuSystemTest
):
13 :avocado: tags=accel:tcg
17 def boot_opensbi(self
):
20 wait_for_console_pattern(self
, 'Platform Name')
21 wait_for_console_pattern(self
, 'Boot HART MEDELEG')
23 def test_riscv32_spike(self
):
25 :avocado: tags=arch:riscv32
26 :avocado: tags=machine:spike
30 def test_riscv64_spike(self
):
32 :avocado: tags=arch:riscv64
33 :avocado: tags=machine:spike
37 def test_riscv32_sifive_u(self
):
39 :avocado: tags=arch:riscv32
40 :avocado: tags=machine:sifive_u
44 def test_riscv64_sifive_u(self
):
46 :avocado: tags=arch:riscv64
47 :avocado: tags=machine:sifive_u
51 def test_riscv32_virt(self
):
53 :avocado: tags=arch:riscv32
54 :avocado: tags=machine:virt
58 def test_riscv64_virt(self
):
60 :avocado: tags=arch:riscv64
61 :avocado: tags=machine:virt