[U-Boot] Mips: start.S Questions
Detlev Zundel
dzu at denx.de
Fri Aug 21 15:02:20 CEST 2009
Hi Peter,
> This is not quite correct. "romReserved" is only used for the, well,
> reserved entries. There are other parameters passed, these two are
> pretty important for example:
>
>
> The thing I don't get is if you expand the RVECENT macro into the code wouldn't
> you get this:
>
> _start:
> b reset; nop /* U-boot entry point */
> b reset; nop /* software reboot */
>
> b romReserved
> b romReserved
>
> ....
>
> romReserved:
> b romReserved
>
> So wouldn't it get stuck in an infinite loop straight away, calling romReserved
> recursively? I'm obviously overlooking something I think.
Why should it? I presume the CPU starts at _start, so it will "b
reset", i.e. branch (jump) to "reset" and be happy. Its only if the CPU
jumps to one the reserved vectors that it will loop. And well, as they
are reserved, this is a legal thing to do, no? As the purple port
works, I'm pretty sure they do not usually get jumped to there ;)
> And what's the point of passing the second parameter (0-127) to RVECENT when
> it's not used?
This is only making life easier in the "create table" part of the code
not to miss one of the defined vectors. So it really serves only
documentary functions.
Cheers
Detlev
--
Lobbing insults is not a useful technique for reaching understanding.
-- Thomas Bushnell, BSG
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de
More information about the U-Boot
mailing list