readme: a chain of qemu improvements

This commit is contained in:
Ciro Santilli 六四事件 法轮功
2019-10-20 00:00:00 +00:00
parent fd6062a38c
commit d1f16390d0

View File

@@ -4784,7 +4784,9 @@ hangs after printing the header:
PING google.com (216.58.204.46): 56 data bytes
....
https://unix.stackexchange.com/questions/473448/how-to-ping-from-the-qemu-guest-to-an-external-url
Here Ciro describes how to get it working: https://unix.stackexchange.com/questions/473448/how-to-ping-from-the-qemu-guest-to-an-external-url
Further bibliography: https://superuser.com/questions/787400/qemu-user-mode-networking-doesnt-work
=== Guest host networking
@@ -4878,7 +4880,10 @@ so we use in the guest:
wget 10.0.2.2:8000
....
Bibliography: https://serverfault.com/questions/769874/how-to-forward-a-port-from-guest-to-host-in-qemu-kvm/951835#951835
Bibliography:
* https://serverfault.com/questions/769874/how-to-forward-a-port-from-guest-to-host-in-qemu-kvm/951835#951835
* https://unix.stackexchange.com/questions/78953/qemu-how-to-ping-host-network/547698#547698
=== 9P
@@ -13002,17 +13007,7 @@ https://en.wikipedia.org/wiki/Buildroot[Buildroot] is a set of Make scripts that
It therefore produces a pristine, blob-less, debuggable setup, where all moving parts are configured to work perfectly together.
Perhaps the awesomeness of Buildroot only sinks in once you notice that all it takes is 4 commands as explained at https://stackoverflow.com/questions/47557262/how-to-download-the-torvalds-linux-kernel-master-recompile-it-and-boot-it-wi/49349237#49349237
....
git clone https://github.com/buildroot/buildroot
cd buildroot
git checkout 2018.02
make qemu_aarch64_virt_defconfig
make olddefconfig
time make BR2_JLEVEL="$(nproc)"
qemu-system-aarch64 -M virt -cpu cortex-a57 -nographic -smp 1 -kernel output/images/Image -append "root=/dev/vda console=ttyAMA0" -netdev user,id=eth0 -device virtio-net-device,netdev=eth0 -drive file=output/images/rootfs.ext4,if=none,format=raw,id=hd0 -device virtio-blk-device,drive=hd0
....
Perhaps the awesomeness of Buildroot only sinks in once you notice that all it takes is 4 commands as explained at xref:buildroot-hello-world[xrefstyle=full].
This repo basically wraps around that, and tries to make everything even more awesome for kernel developers.
@@ -13336,7 +13331,11 @@ One "downside" of glibc is that it exercises much more kernel functionality on i
=== Buildroot hello world
This repo doesn't do much more other than setting a bunch of Buildroot configurations and building it, and the minimal work you have to do to get QEMU to boot Buildroot from scratch is tiny if you want to quickly test Buildroot specifics, for example:
This repo doesn't do much more other than setting a bunch of Buildroot configurations and building it.
The minimal work you have to do to get QEMU to boot Buildroot from scratch is tiny if, about 4 commands!
Here are some good working commands for several ISAs:
* x86_64 https://unix.stackexchange.com/questions/44062/how-to-use-qemu-to-run-build-root-linux-images/543075#543075
** x86_64 X11 https://unix.stackexchange.com/questions/70931/how-to-install-x11-on-my-own-linux-buildroot-system/306116#306116 Also mentioned at: xref:x11[xrefstyle=full].
@@ -13345,6 +13344,8 @@ This repo doesn't do much more other than setting a bunch of Buildroot configura
* arm https://stackoverflow.com/questions/38320066/how-to-run-linux-on-a-qemu-arm-versatile-machine/44099299#44099299
* PPC <https://stackoverflow.com/questions/48021127/build-powerpc-kernel-and-boot-powerpc-kernel-on-qemu/49349262#49349262> just work commands for PPC, comment on how to replace kernel
These can come in handy if you want to debug something in Buildroot itself and possibly report an upstream bug.
== Userland content
This section contains userland content, such as <<c>>, <<cpp>> and <<posix>> examples.