linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* sign extension for 32bit syscalls on ppc64
@ 2006-04-28 13:12 Christoph Hellwig
  2006-04-28 23:32 ` Paul Mackerras
  0 siblings, 1 reply; 9+ messages in thread
From: Christoph Hellwig @ 2006-04-28 13:12 UTC (permalink / raw)
  To: linuxppc-dev

For 32bit syscalls implemented in arch/powerpc/ we're doing our own
sign-extension where an int argument is passed as u32 in the prototype
and then casted to int later on:

asmlinkage long compat_sys_sendfile(u32 out_fd, u32 in_fd, compat_off_t
__user * offset, u32 count)

{
	...
	ret = sys_sendfile((int)out_fd, (int)in_fd, up, count);
	..
}

OTOH various syscalls in the generic code don't do that and it seems to
still work fine.  I have patches for various new generic compat
routines, and they all seem to work fine without this sign extension.

What's the exact sign extention rules for ppc64?

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2006-05-01  3:44 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-04-28 13:12 sign extension for 32bit syscalls on ppc64 Christoph Hellwig
2006-04-28 23:32 ` Paul Mackerras
2006-04-29  1:30   ` Stephen Rothwell
2006-04-29  2:33     ` Paul Mackerras
2006-04-29  3:16       ` Stephen Rothwell
2006-04-29  3:42         ` Stephen Rothwell
2006-04-29 13:46         ` Andreas Schwab
2006-05-01  0:05           ` Stephen Rothwell
2006-05-01  3:44             ` Stephen Rothwell

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