RE: move the SIOCDELRT and SIOCADDRT compat_ioctl handlers v2

From: David Laight
Date: Sat May 16 2020 - 11:05:06 EST


From: Christoph Hellwig
> Sent: 15 May 2020 14:19
>
> this series moves the compat_ioctl handlers into the protocol handlers,
> avoiding the need to override the address space limited as in the current
> handler.

Is it worth moving the user copies for the main ioctl buffer
into the sys_ioctl() entry code?
(As is done by the BSD kernels.)

This would allow the compat code to adjust the buffers and pass them on.
Most ioctls don't have indirect data buffers so wouldn't need to
do any further user copies.

This would be, of course, require far more changes (and require
more external modules be fixed) than the similar change I suggested
for [sg]et_sockopt().

David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)