Re: RFD: x32 ABI system call numbers

From: Linus Torvalds
Date: Sun Sep 04 2011 - 13:10:13 EST


On Sun, Sep 4, 2011 at 8:17 AM, Arnd Bergmann <arnd@xxxxxxxx> wrote:
>
> For a lot of these cases, the best option is to change the
> kernel headers to use new definitions on x32 before someone
> tries to ship a distro, especially when the ioctl command code
> is fixed. In case of the XFS ioctls, I think the only sane
> way is define the x32 ABI to match the 64 bit ABI completely,
> while for RAW_GETBIND and VIDEO_GET_EVENT it's probably enough
> to make x32 match x86-32.

Ack, ack, ack.

If we make the x32 ioctl system call first do "regular" ioctl, and
then fall back to the compat ones if that fails, x32 can mix and
match. It's not pretty, but I think it's better than the alternative
(which would be to have to use one r the other and add lots of new
compat handling).

Of course, we could also just have "compat_ioctl()" fall back to
native mode in general, and not make a x32 special case.

Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/