In message <[EMAIL PROTECTED]> you wrote: > The call command tries to mimic a function call in that the 'arg's to > the command are passed in registers according to the PPC ABI. > > The prototype that call mimics is some variation of the following > depending on how many arguments are passed to the command: > > void func(void) > void func(unsigned long r3) > void func(unsigned long r3, unsigned long r4) > ... > void func(unsigned long r3, unsigned long r4, ... unsigned long r10) > > The maximum number of 'arg's is 8. There are no arguments passed on > a stack, no floating point or vector arguments.
This really makes zero sense to me. > + img = (int (*)(ulong, ulong, ulong, ulong, > + ulong, ulong, ulong, ulong)) addr; > + > + for (i = 2; i < argc; i++) > + r[i-2] = simple_strtoul(argv[i], NULL, 16); > + > + return (*img)(r[0], r[1], r[2], r[3], r[4], r[5], r[6], r[7]); This looks not clean. Either this is a function with exactly 8 arguments, or it isn't. And where is the code that makes sure that ``the 'arg's to the command are passed in registers'' ? I see no difference between this call and what "go" does. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: [EMAIL PROTECTED] "More software projects have gone awry for lack of calendar time than for all other causes combined." - Fred Brooks, Jr., _The Mythical Man Month_ ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ U-Boot-Users mailing list U-Boot-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/u-boot-users