Subject: Re: [PATCH 13/16] ps3: get firmware version

From: Benjamin Herrenschmidt <[email-masked]>
Date: Tue, 30 Jan 2007 08:22:22 +1100

> To make it work, I need to arrange to do 64 bit HV calls from the 32 bit
> wrapper.  I'm not yet entirely sure how to set that up.  Any suggestions
> would be welcome.

You can use the ld and std instructions in 32 bits mode to load / store
full 64 bits registers. So you can define wrappers for the few HV calls
you need that either put all args in an array of 64 bits entries that
your asm wrapper then loads in registers using "ld" (and stores back the
results using std) or you can define proper wrappers per functions that
"turn" the arguments into the right shape for the 64 bits call (a bit
harder since 32 bits will pass 64 bits values as 2 registers, so you'd
have to write them on the stack and load the combined value with ld...)

Ben.