linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Geoff Levand <geoffrey.levand@am.sony.com>
Cc: linuxppc-dev@ozlabs.org, Paul Mackerras <paulus@samba.org>,
	Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH 13/16] ps3: get firmware version
Date: Tue, 30 Jan 2007 08:22:22 +1100	[thread overview]
Message-ID: <1170105742.26655.286.camel@localhost.localdomain> (raw)
In-Reply-To: <45BE476A.3010407@am.sony.com>


> 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.

      reply	other threads:[~2007-01-29 21:22 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-27  3:08 [PATCH 13/16] ps3: get firmware version Geoff Levand
2007-01-27 11:30 ` Arnd Bergmann
2007-01-29 19:13   ` Geoff Levand
2007-01-29 21:22     ` Benjamin Herrenschmidt [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1170105742.26655.286.camel@localhost.localdomain \
    --to=benh@kernel.crashing.org \
    --cc=arnd@arndb.de \
    --cc=geoffrey.levand@am.sony.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).