Re: is avoiding compat ioctls possible?

David Miller
2009-10-29T05:41:34Z

From: Arnd Bergmann <arndbergmann@googlemail.com>
Date: Wed, 28 Oct 2009 16:40:18 +0100

> I'm pretty sure it was ok when we started adding the compat_ioctl
> handlers years ago. I think most people just ignored these for
> the majority of drivers that can't possibly run on s390. Even
> on s390, gcc will always do the right thing if you call call ioctl
> with a pointer to a normal object in the .data section, heap or stack,
> but hand-written assembly or other compilers may not.

Arnd, even compat_sys_ioctl() itself has constructs like:

case FS_IOC_RESVSP:
case FS_IOC_RESVSP64:
error = ioctl_preallocate(filp, (void __user *)arg);
goto out_fput;

That's why I asked about the 'arg' argument to sys_ioctl
on s390 :-)