[PATCH] ppc64: fix semtimedop compat syscall

David S. Miller davem at davemloft.net
Wed Mar 23 10:33:10 EST 2005


On Wed, 23 Mar 2005 09:58:22 +1100
Stephen Rothwell <sfr at canb.auug.org.au> wrote:

> I was just being pedantic as this is the case we care about.  It is quite
> possible that the compiler upon seeing "int x" as an function argument
> will assume that any value passed to the argument has been sign extended
> to the equivalent of long by any caller of the function (since ints as
> function arguments may actually be 64 bit registers).

That is actually the case on sparc64.  The ABI demands that all
signed function arguments are sign extended to 64-bits by the
caller.

So it would only work if the argument was declared as unsigned.



More information about the Linuxppc64-dev mailing list