[OpenBIOS] [PATCH] sparc64: clear unused registers when calling client image

Igor Kovalenko igor.v.kovalenko at gmail.com
Tue May 19 22:47:45 CEST 2009

This change seems to fix the problem here with silo not being able
to deal with bss data. The problem is that silo does access to an address
which is calculated from %i3 + bss offset, so %i3 must be somehow initialized.

To do this I created start_client_image() helper which initializes
clear context,
fills it with stack pointer and client interface handler pointer then
switches to it.
According to docs all registers not used to convey data to client code must be

Since my sparc64-elf-gcc cross compiler managed to discard stores
to __context in switch_to() I had to make __context a volatile pointer.

Signed-off-by: Igor Kovalenko <igor.v.kovalenko at gmail.com>

Kind regards,
Igor V. Kovalenko
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sparc64-aout-start-client.patch
Type: application/octet-stream
Size: 4474 bytes
Desc: not available
URL: <http://lists.openbios.org/pipermail/openbios/attachments/20090520/f71dc662/attachment-0001.dmg>

More information about the OpenBIOS mailing list