Use of the go command
Herburger
Hello,
i use the go command from the hush shell to execute a function from environment. That function has been initially compiled in U-Boot and was first called in board_late_init().
I call the function by using
go #address
on my Arm Cortex A-7 machine the do_go_exec becomes:
e1a03000 mov r3, r0 e1a00001 mov r0, r1 e1a01002 mov r1, r2 e12fff13 bx r3
so instruction set is exchanged. This seems to work the function returns and returns back to the hush-shell. My question is now: Is it safe to use the go command to execute U-boot functions or do I miss something here? Does the exchange of the instruction set have some influence on the further execution of U-boot.?
Mit freundlichen Grüßen / Best regards
i.A. Gregor Herburger
Entwicklung Software Delling
Tel. +49 8153 9308-809, Fax +49 8153 9308-7809
gregor.herburger at tq-group.com
TQ-Systems GmbH
Mühlstraße 2, Gut Delling, 82229 Seefeld
Amtsgericht München, HRB 105018
Sitz der Gesellschaft: Seefeld
Geschäftsführer: Detlef Schneider, Rüdiger Stahl, Stefan Schneider www.tq-group.com
Dear Gregor,
Quoted 4 lines · In message <[email protected]> you wrote:
i use the go command from the hush shell to execute a function from environment. That function has been initially compiled in U-Boot and was first called in
board_late_init().
Urg...
Quoted 2 lines
I call the function by using
go #address
Go is supposed to be used with standalone programs only.
Quoted 2 lines
My question is now: Is it safe to use the go command to execute U-boot functions or do I miss something here?
You are invoking undefined behaviour.
Best regards,
Wolfgang Denk
Signature · 8 lines
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de "No proper program contains an indication which as an operator- applied occurrence identifies an operator-defining occurrence which as an indication-applied occurrence identifies an indication-defining occurrence different from the one identified by the given indication as an indication-applied occurrence." - ALGOL 68 Report