diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index d92bc3eb7afcb33f398dbf35a3e4bc8f2c0c5393..65643def31825d99fa7df8399871fd4e2d8b4144 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -3566,10 +3566,13 @@ asmlinkage long compat_sys_ioctl(unsigned int fd, unsigned int cmd, goto found_handler; } +#ifdef CONFIG_NET if (S_ISSOCK(filp->f_path.dentry->d_inode->i_mode) && cmd >= SIOCDEVPRIVATE && cmd <= (SIOCDEVPRIVATE + 15)) { error = siocdevprivate_ioctl(fd, cmd, arg); - } else { + } else +#endif + { static int count; if (++count <= 50)