Jun Sun wrote:
> I compiled an image for DDB5074. I got a TLB fault immediately after
> the control enters prom_init() function. A further probe shows that the
> caller are passing differents arguments to prom_init than what the
> callee expected. See code excerpt below.
Most of the ports have the same mismatch. Usually, bios/prom/bootloader
calls the box independend routine, kernel_netry (head.S) with some
arguments. kernel_enry prepares C environment and calls init_arch w/ the
same arguments. The number of the arguments and their types are box
dependent. kernel_entry and init_arch never try to access the arguments
to be passed by prom, but just pass the arguments to prom_init.
Moreover, the arguments declared in init_arch don't match any mips box,
they are mix of calling conventions of ARC console and DECstation prom
(the last one).
Fortunately, sizeof(int) == sizeof(long) == sizeof(pointer) in mips32,
so we may happy live with that.
> Does this mean the code of DDB5074 is outdated? In any case, can
> someone give me a hint on how to fix this? It does not look obvious at
> the first sight...
I think, you shouldn't fix the argument list, continue bug searching in