feat: added debug traces and added support for booting using grub and

tftp
This commit is contained in:
2021-03-08 22:00:07 +01:00
parent 945b18b2b2
commit cefdb8ed90
12 changed files with 253 additions and 380 deletions

View File

@@ -13,6 +13,7 @@ Options:
-i [disk], --ide [disk] Use [disk] as a hda on an IDE bus
-n, --nohup Run QEMU using nohup and output to /dev/null
-m, --max-cpu Run qemu with -m max
--net Launch the kernel using TFTP. (Requires GRUB to be set up)
EOF
}
@@ -23,6 +24,11 @@ while [[ "$#" -gt 0 ]]; do
ARGS="${ARGS} -S -s -d guest_errors,int"
shift
;;
--net)
cp cmake-build-debug/my-kernel.bin netdir/my-kernel.bin
KERNEL="-netdev user,id=n0,tftp=netdir,bootfile=/boot/grub/i386-pc/core.0 -device e1000,netdev=n0"
shift
;;
-i | --ide)
ARGS="${ARGS} -hda $2"
shift 2