From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTP id 020C1DDFFA for ; Tue, 30 Jan 2007 08:22:50 +1100 (EST) Subject: Re: [PATCH 13/16] ps3: get firmware version From: Benjamin Herrenschmidt To: Geoff Levand In-Reply-To: <45BE476A.3010407@am.sony.com> References: <45BAC225.7020209@am.sony.com> <200701271230.06534.arnd@arndb.de> <45BE476A.3010407@am.sony.com> Content-Type: text/plain Date: Tue, 30 Jan 2007 08:22:22 +1100 Message-Id: <1170105742.26655.286.camel@localhost.localdomain> Mime-Version: 1.0 Cc: linuxppc-dev@ozlabs.org, Paul Mackerras , Arnd Bergmann List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , > 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.