qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] U-Boot patch for qemu -M mips


From: Vlad Lungu
Subject: Re: [Qemu-devel] U-Boot patch for qemu -M mips
Date: Thu, 04 Oct 2007 13:52:28 +0300
User-agent: Thunderbird 2.0.0.6 (Windows/20070728)

Thiemo Seufer wrote:
Vlad Lungu wrote:
Thiemo Seufer wrote:
Vlad Lungu wrote:
[snip]
 +long int initdram(int board_type)
 +{
 +       /* Sdram is setup by assembler code */
+ /* If memory could be changed, we should return the true value here */
 +       return MEM_SIZE*1024*1024;
Qemu gets the amount of RAM passed via a command line switch, the
qemu-mips emulation sets up a Linux kernel like "command line" in
memory where u-boot could parse it from.

Does it, or just when you pass -kernel to it? I'll check.
Hm, you are right, it does that only for -kernel. Would it make sense
to change that in Qemu?
IDK. Maybe I can probe the RAM size in U-Boot , or if this does not work,

mips_r4k implements no probable memory controller, so this won't work.
I say let's stick it into a "DIP-switch", so nobody can overwrite it by mistake. And you don't have to parse it.
put some info somewhere (RAM, register,
emulated DIP-dwitch), like RAM size, endianness of the CPU.

Endianness is rather pointless. If your U-Boot binary doesn't explode
immediately you got the right endianness. :-)

It doesn't actually explode, it sort of almost hits the exception handler and freezes there. I don't have a mipsel gdb at hand
to watch it, but it should be fun.

pc=EPC   0xbfc00380
ds 0006

STATUS    0x00400006
CAUSE     0x00000428
CONFIG0 0x80000082
CONFIG1 0x9e190c8b






reply via email to

[Prev in Thread] Current Thread [Next in Thread]