
2013/1/10 Gabor Juhos juhosg@openwrt.org:
2013.01.08. 20:14 keltezéssel, Gabor Juhos írta:
The linux starting code of the qemu specific bootm implementation is very similar to the one which is used for regular boards. The preparation code is different but it makes no sense to keep that in a separate file.
The pach moves the qemu specific code into bootm.c, and removes the custom file. This allows to get rid of some duplicated code, and it collects bootm specific code into a single file. Additionaly, this allows to use the prep,go subcommands in qemu as well.
Signed-off-by: Gabor Juhos juhosg@openwrt.org Cc: Daniel Schwierzeck daniel.schwierzeck@googlemail.com
This is compile tested only. I don't have suitable kernel images for mips,mipsel,mips64,mipsel64 systems to try it yet.
Ok, I have tried this with the sample vmlinux image provided here: ftp://ftp.denx.de/pub/contrib/Jean-Christophe_Plagniol-Villard/qemu_mips/
It works as expected:
Additionally, I wanted to compile a Linux kernel for mips64/mipsel/mipsel64 to test these patches on those as well. However when I have tried to configure a recent kernel I noticed that it has no MIPS QEMU platform. That has been completely removed from Linux five years ago by:
commit 302922e5f6901eb6f29c58539631f71b3d9746b8 Author: Ralf Baechle <ralf@linux-mips.org> Date: Tue Jan 29 10:15:02 2008 +0000 [MIPS] Qemu: Remove platform. The Qemu platform was originally implemented to have an easily supportable platform until Qemu reaches a state where it emulates a real world system. Since the latest release Qemu is capable of emulating the MIPSsim and Malta platforms, so this goal has been reached. The Qemu plaform is also rather underfeatured so less useful than a Malta emulation.
yes, I figured that too yesterday while testing.
Maybe the qemu_mips specific bootm stuff should be removed completely from U-Boot?
-Gabor
I agree. Maybe we should convert the current MIPS Qemu port to MTI Malta. I have seen that BareBox already supports Qemu Malta. For supporting real MTI Malta hardware there is AFAIK some work in progress [1].
[1] http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/140428/focus=140541