diff options
author | David S. Miller <davem@davemloft.net> | 2019-02-24 20:48:04 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-02-24 21:06:19 +0100 |
commit | 70f3522614e60b6125eff5f9dd7c887543812187 (patch) | |
tree | 5e08ed970fb035feb4a99ac8526c74da0d445d01 /net/compat.c | |
parent | trace: events: neigh_update: print new state in string format (diff) | |
parent | Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm (diff) | |
download | linux-70f3522614e60b6125eff5f9dd7c887543812187.tar.xz linux-70f3522614e60b6125eff5f9dd7c887543812187.zip |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Three conflicts, one of which, for marvell10g.c is non-trivial and
requires some follow-up from Heiner or someone else.
The issue is that Heiner converted the marvell10g driver over to
use the generic c45 code as much as possible.
However, in 'net' a bug fix appeared which makes sure that a new
local mask (MDIO_AN_10GBT_CTRL_ADV_NBT_MASK) with value 0x01e0
is cleared.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/compat.c')
-rw-r--r-- | net/compat.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/net/compat.c b/net/compat.c index 9629f053d4fa..319f30637a86 100644 --- a/net/compat.c +++ b/net/compat.c @@ -362,8 +362,12 @@ static int __compat_sys_setsockopt(int fd, int level, int optname, char __user *optval, unsigned int optlen) { int err; - struct socket *sock = sockfd_lookup(fd, &err); + struct socket *sock; + + if (optlen > INT_MAX) + return -EINVAL; + sock = sockfd_lookup(fd, &err); if (sock) { err = security_socket_setsockopt(sock, level, optname); if (err) { |