smsc75xx: use skb_cow_head() to deal with cloned skbs
commitbe48b6ee6d07beb68e115936855786f9d99dbe54
authorEric Dumazet <edumazet@google.com>
Wed, 19 Apr 2017 16:59:21 +0000 (19 09:59 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Jan 2018 08:35:28 +0000 (17 09:35 +0100)
tree70c63045dd8d93bb888e21ba7a70e0ea69ea966c
parent36a1c87f57f6e92673403324144271ca4d74ffad
smsc75xx: use skb_cow_head() to deal with cloned skbs

commit b7c6d2675899cfff0180412c63fc9cbd5bacdb4d upstream.

We need to ensure there is enough headroom to push extra header,
but we also need to check if we are allowed to change headers.

skb_cow_head() is the proper helper to deal with this.

Fixes: d0cad871703b ("smsc75xx: SMSC LAN75xx USB gigabit ethernet adapter driver")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: James Hughes <james.hughes@raspberrypi.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Oliver Neukum <oneukum@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/usb/smsc75xx.c