mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-23 10:15:57 +01:00
Allow passing options to gem5 itself instead of fs.py
This commit is contained in:
8
run
8
run
@@ -14,9 +14,10 @@ nographic=false
|
||||
extra_append='nokaslr norandmaps printk.devkmsg=on printk.time=y'
|
||||
extra_flags=''
|
||||
gem5=false
|
||||
gem5opts=''
|
||||
initrd=false
|
||||
root=''
|
||||
while getopts a:Dde:giknt:x OPT; do
|
||||
while getopts a:Dde:G:giknt:x OPT; do
|
||||
case "$OPT" in
|
||||
a)
|
||||
arch="$OPTARG"
|
||||
@@ -40,6 +41,9 @@ while getopts a:Dde:giknt:x OPT; do
|
||||
g)
|
||||
gem5=true
|
||||
;;
|
||||
G)
|
||||
gem5opts="$OPTARG"
|
||||
;;
|
||||
i)
|
||||
initrd=true
|
||||
;;
|
||||
@@ -60,6 +64,7 @@ if $gem5; then
|
||||
cmd="\
|
||||
M5_PATH='$(pwd)/gem5/gem5-system' \
|
||||
'${gem5_dir}/build/X86/gem5.opt' \
|
||||
${gem5opts} \
|
||||
'${gem5_dir}/configs/example/fs.py' \
|
||||
--disk-image='${outdir}/images/rootfs.ext2' \
|
||||
--kernel='${outdir}/build/linux-custom/vmlinux' \
|
||||
@@ -70,6 +75,7 @@ M5_PATH='$(pwd)/gem5/gem5-system' \
|
||||
M5_PATH='$(pwd)/gem5/gem5-system' \
|
||||
$debug_vm \
|
||||
'${gem5_dir}/build/ARM/gem5.opt' \
|
||||
${gem5opts} \
|
||||
'${gem5_dir}/configs/example/fs.py' \
|
||||
--command-line='earlyprintk=pl011,0x1c090000 console=ttyAMA0 lpj=19988480 rw loglevel=8 mem=512MB root=/dev/sda $extra_append' \
|
||||
--disk-image='${outdir}/images/rootfs.ext2' \
|
||||
|
||||
Reference in New Issue
Block a user