summaryrefslogtreecommitdiff
path: root/include/linux/inetdevice.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2017-06-26 20:19:16 +0300
committerAl Viro <viro@zeniv.linux.org.uk>2018-01-25 03:13:45 +0300
commit36fd633ec98acd2028585c22128fcaa3da6d5770 (patch)
tree1fa77e8bf1662dea936b52107a0d39485110edb1 /include/linux/inetdevice.h
parentbe1b6e8b5470e8311bfa1a3dfd7bd59e85a99759 (diff)
downloadlinux-36fd633ec98acd2028585c22128fcaa3da6d5770.tar.xz
net: separate SIOCGIFCONF handling from dev_ioctl()
Only two of dev_ioctl() callers may pass SIOCGIFCONF to it. Separating that codepath from the rest of dev_ioctl() allows both to simplify dev_ioctl() itself (all other cases work with struct ifreq *) *and* seriously simplify the compat side of that beast: all it takes is passing to inet_gifconf() an extra argument - the size of individual records (sizeof(struct ifreq) or sizeof(struct compat_ifreq)). With dev_ifconf() called directly from sock_do_ioctl()/compat_dev_ifconf() that's easy to arrange. As the result, compat side of SIOCGIFCONF doesn't need any allocations, copy_in_user() back and forth, etc. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'include/linux/inetdevice.h')
0 files changed, 0 insertions, 0 deletions