net/packet: fix missing net_device reference release
authorDouglas Caetano dos Santos <douglascs@taghos.com.br>
Fri, 12 May 2017 18:19:15 +0000 (15:19 -0300)
committerRaspbian kernel package updater <root@raspbian.org>
Sun, 23 Jul 2017 02:51:56 +0000 (02:51 +0000)
commit3fc300a4fc7d67aa4aea4b20d8b12e8c47ef3125
treed46f16087aac38f8d5439efc8660f30101026877
parent61526aee0faaca3ace634f0402b6600fb4c4e0e1
net/packet: fix missing net_device reference release

[ Upstream commit d19b183cdc1fa3d70d6abe2a4c369e748cd7ebb8 ]

When using a TX ring buffer, if an error occurs processing a control
message (e.g. invalid message), the net_device reference is not
released.

Fixes c14ac9451c348 ("sock: enable timestamping using control messages")
Signed-off-by: Douglas Caetano dos Santos <douglascs@taghos.com.br>
Acked-by: Soheil Hassas Yeganeh <soheil@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/packet/af_packet.c