mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2025-08-15 22:36:35 +00:00
gem5: minimally test VExpress_GEM5_V2
This commit is contained in:
15
README.adoc
15
README.adoc
@ -1328,6 +1328,8 @@ The reason for that is that on baremetal we don't parse the <<device-tree,device
|
||||
./run --arch aarch64 --baremetal userland/c/hello.c --emulator gem5 --machine RealViewPBX
|
||||
....
|
||||
|
||||
see also: xref:gem5-arm-platforms[xrefstyle=full].
|
||||
|
||||
This generates yet new separate images with new magic constants:
|
||||
|
||||
....
|
||||
@ -12187,6 +12189,19 @@ xdg-open "$(./getvar --arch aarch64 --gem5-build-id ruby gem5_build_build_dir)/A
|
||||
|
||||
A minimized ruby config which was not merged upstream can be found for study at: https://gem5-review.googlesource.com/c/public/gem5/+/13599/1
|
||||
|
||||
=== gem5 ARM platforms
|
||||
|
||||
The gem5 platform is selectable with the `--machine` option, which is named after the analogous QEMU `-machine` option, and which sets the `--machine-type`.
|
||||
|
||||
Each platform represents a different system with different devices, memory and interrupt setup.
|
||||
|
||||
TODO: describe the main characteristics of each platform, as of gem5 5e83d703522a71ec4f3eb61a01acd8c53f6f3860:
|
||||
|
||||
* `VExpress_GEM5_V1`: good sane base platform
|
||||
* `VExpress_GEM5_V1_DPU`: `VExpress_GEM5_V1` with DP650 instead of HDLCD, selected automatically by `./run --dp650`, see also: <<gem5-graphic-mode-dp650>>
|
||||
* `VExpress_GEM5_V2`: VExpress_GEM5_V1 with GICv3, uses a different bootloader `arm/aarch64_bootloader/boot_emm_v2.arm64` TODO is it because of GICv3?
|
||||
* anything that does not start with: `VExpress_GEM5_`: old and bad, don't use them
|
||||
|
||||
=== gem5 internals
|
||||
|
||||
==== gem5 Python C++ interaction
|
||||
|
@ -110,6 +110,7 @@ https://github.com/cirosantilli/linux-kernel-module-cheat-regression#gem5-unit-t
|
||||
# TODO cross_compile is ignored because the make does not use CC...
|
||||
self.sh.run_cmd(['make', '-C', bootloader64_dir, LF])
|
||||
self.sh.cp(os.path.join(bootloader64_dir, 'boot_emm.arm64'), binaries_dir)
|
||||
self.sh.cp(os.path.join(bootloader64_dir, 'boot_emm_v2.arm64'), binaries_dir)
|
||||
term_source_dir = os.path.join(self.env['gem5_source_dir'], 'util/term')
|
||||
m5term_build = os.path.join(term_source_dir, 'm5term')
|
||||
self.sh.run_cmd(['make', '-C', term_source_dir, LF])
|
||||
|
@ -459,8 +459,12 @@ Which qemu binaries to use: qemu-system-, qemu-, qemu-img, etc.:
|
||||
'--machine',
|
||||
help='''\
|
||||
Machine type:
|
||||
* QEMU default: virt
|
||||
* gem5 default: VExpress_GEM5_V1
|
||||
|
||||
* QEMU default: -machine virt
|
||||
* gem5 default: --machine-type VExpress_GEM5_V1
|
||||
|
||||
More infor on platforms at:
|
||||
https://cirosantilli.com/linux-kernel-module-cheat#gem5-arm-platforms
|
||||
'''
|
||||
)
|
||||
|
||||
|
@ -215,6 +215,11 @@ class ShellHelpers:
|
||||
else:
|
||||
shutil.copy2(src, dest)
|
||||
|
||||
def mv(self, src, dest, **kwargs):
|
||||
self.print_cmd(['mv', src, dest])
|
||||
if not self.dry_run:
|
||||
shutil.move(src, dest)
|
||||
|
||||
def print_cmd(
|
||||
self,
|
||||
cmd,
|
||||
|
Reference in New Issue
Block a user