Skip to content

Commit

Permalink
Kernel: Fix run script to enable networking on Q35 machines
Browse files Browse the repository at this point in the history
Also, we enable KVM to accelerate the execution when booting with
q35_cmd or qcmd options in the run script.
  • Loading branch information
supercomputer7 authored and awesomekling committed Jan 14, 2020
1 parent 2da8aba commit bd3b64e
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions Kernel/run
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ cd "$script_path"
$SERENITY_EXTRA_QEMU_ARGS
-s -m $SERENITY_RAM_SIZE
-cpu max
-d cpu_reset,guest_errors
-d cpu_reset,guest_errors
-device VGA,vgamem_mb=64
-hda _disk_image
-device ich9-ahci
Expand Down Expand Up @@ -84,7 +84,9 @@ elif [ "$1" = "q35_cmd" ]; then
# ./run: qemu with SerenityOS with custom commandline
$SERENITY_QEMU_BIN \
$SERENITY_COMMON_QEMU_Q35_ARGS \
-device e1000 \
$SERENITY_KVM_ARG \
-netdev user,id=breh,hostfwd=tcp:127.0.0.1:8888-10.0.2.15:8888,hostfwd=tcp:127.0.0.1:8823-10.0.2.15:23 \
-device e1000,netdev=breh \
-kernel kernel \
-append "${SERENITY_KERNEL_CMDLINE}"
elif [ "$1" = "qcmd" ]; then
Expand All @@ -98,7 +100,9 @@ elif [ "$1" = "qcmd" ]; then
# ./run: qemu with SerenityOS with custom commandline
$SERENITY_QEMU_BIN \
$SERENITY_COMMON_QEMU_ARGS \
-device e1000 \
$SERENITY_KVM_ARG \
-netdev user,id=breh,hostfwd=tcp:127.0.0.1:8888-10.0.2.15:8888,hostfwd=tcp:127.0.0.1:8823-10.0.2.15:23 \
-device e1000,netdev=breh \
-kernel kernel \
-append "${SERENITY_KERNEL_CMDLINE}"
else
Expand Down

0 comments on commit bd3b64e

Please sign in to comment.