[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070209220327.GB16158@flint.arm.linux.org.uk>
Date: Fri, 9 Feb 2007 22:03:27 +0000
From: Russell King <rmk+lkml@....linux.org.uk>
To: David Woodhouse <dwmw2@...radead.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Alexey Dobriyan <adobriyan@...nvz.org>,
linux-kernel@...r.kernel.org, drepper@...hat.com
Subject: Re: -mm merge plans for 2.6.21
On Fri, Feb 09, 2007 at 09:53:19PM +0000, David Woodhouse wrote:
> On Fri, 2007-02-09 at 21:49 +0000, Russell King wrote:
> > urgh, new system calls... wonder if they fit in the ARM ABI... Looks
> > fine.
>
> Can you elucidate on _what_ you just checked for?
>
> There was something about alignment of 64-bit arguments to syscalls
> which affects MIPS and/or ARM which I can't quite remember--
It's something like that.
> something
> about putting it them arguments in either an even-numbered or
> odd-numbered position to make it work nicely.
We have a maximum of 7 32-bit registers to pass system call arguments.
In EABI, 64-bit arguments must be aligned to an even-numbered register
(starting at zero). In OABI, 64-bit arguments do not have this
restriction.
So, for EABI:
sys_foo(int a, unsigned long long b, int c, unsigned long long d)
would allocate 'a' into r0, 'b' into r2,r3, 'c' into r4, and 'd' into
r6, and oops we're out of registers - so the above syscall prototype
can't be supported on ARM.
However:
sys_foo(int a, int c, unsigned long long b, unsigned long long d)
is entirely reasonable and leaves us with spare room for one additional
32-bit arg to be passed.
> Is that actually written anywhere, and does anyone bother to check?
Mostly mailing list archives I'd guess. As far as anyone bothering
to check, that's me when I'm aware of new syscalls... which typically
happens a long time after the syscalls have been introduced on x86
etc.
--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of:
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists