Skip to content

Commit

Permalink
boot-qemu.py: Add support for mips
Browse files Browse the repository at this point in the history
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
  • Loading branch information
nathanchance committed Feb 27, 2023
1 parent 81286a4 commit 7d28e84
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions boot-qemu.py
Expand Up @@ -22,6 +22,8 @@
'arm32_v7',
'arm64',
'arm64be',
'mips',
'mipsel',
'x86',
'x86_64',
]
Expand Down Expand Up @@ -476,6 +478,24 @@ def supports_efi(self):
return False


class MIPSQEMURunner(QEMURunner):

def __init__(self):
super().__init__()

self._default_kernel_path = Path('vmlinux')
self._initrd_arch = self._qemu_arch = 'mips'
self._qemu_args += ['-cpu', '24Kf', '-machine', 'malta']


class MIPSELQEMURunner(MIPSQEMURunner):

def __init__(self):
super().__init__()

self._initrd_arch = self._qemu_arch = 'mipsel'


class X86QEMURunner(QEMURunner):

def __init__(self):
Expand Down Expand Up @@ -600,6 +620,8 @@ def parse_arguments():
'arm32_v7': ARMV7QEMURunner,
'arm64': ARM64QEMURunner,
'arm64be': ARM64BEQEMURunner,
'mips': MIPSQEMURunner,
'mipsel': MIPSELQEMURunner,
'x86': X86QEMURunner,
'x86_64': X8664QEMURunner,
}
Expand Down

0 comments on commit 7d28e84

Please sign in to comment.