1*52ec5f51SThomas Huth#!/usr/bin/env python3 2*52ec5f51SThomas Huth# 3*52ec5f51SThomas Huth# Replay test that boots a Linux kernel on an OpenRISC-1000 SIM machine 4*52ec5f51SThomas Huth# and checks the console 5*52ec5f51SThomas Huth# 6*52ec5f51SThomas Huth# SPDX-License-Identifier: GPL-2.0-or-later 7*52ec5f51SThomas Huth 8*52ec5f51SThomas Huthfrom qemu_test import Asset 9*52ec5f51SThomas Huthfrom replay_kernel import ReplayKernelBase 10*52ec5f51SThomas Huth 11*52ec5f51SThomas Huth 12*52ec5f51SThomas Huthclass Or1kReplay(ReplayKernelBase): 13*52ec5f51SThomas Huth 14*52ec5f51SThomas Huth ASSET_DAY20 = Asset( 15*52ec5f51SThomas Huth 'https://qemu-advcal.gitlab.io/qac-best-of-multiarch/download/day20.tar.xz', 16*52ec5f51SThomas Huth 'ff9d7dd7c6bdba325bd85ee85c02db61ff653e129558aeffe6aff55bffb6763a') 17*52ec5f51SThomas Huth 18*52ec5f51SThomas Huth def test_sim(self): 19*52ec5f51SThomas Huth self.set_machine('or1k-sim') 20*52ec5f51SThomas Huth kernel_path = self.archive_extract(self.ASSET_DAY20, 21*52ec5f51SThomas Huth member='day20/vmlinux') 22*52ec5f51SThomas Huth self.run_rr(kernel_path, self.REPLAY_KERNEL_COMMAND_LINE, 23*52ec5f51SThomas Huth 'QEMU advent calendar') 24*52ec5f51SThomas Huth 25*52ec5f51SThomas Huth 26*52ec5f51SThomas Huthif __name__ == '__main__': 27*52ec5f51SThomas Huth ReplayKernelBase.main() 28