aboutsummaryrefslogtreecommitdiff
path: root/virt
diff options
context:
space:
mode:
authorMichal Kubecek2020-03-28 00:01:03 +0100
committerDavid S. Miller2020-03-29 22:32:36 -0700
commitb51fb7711a6d0e325d0fdb299cf67c4ec4b88b4b (patch)
treebd9cd9d74a74ceafcc577577ca1178f2e7cac16e /virt
parent96376cad350873bdeb500d49817d749242f74068 (diff)
ethtool: fix reference leak in ethnl_set_privflags()
Andrew noticed that some handlers for *_SET commands leak a netdev reference if required ethtool_ops callbacks do not exist. One of them is ethnl_set_privflags(), a simple reproducer would be e.g. ip link add veth1 type veth peer name veth2 ethtool --set-priv-flags veth1 foo on ip link del veth1 Make sure dev_put() is called when ethtool_ops check fails. Fixes: f265d799596a ("ethtool: set device private flags with PRIVFLAGS_SET request") Reported-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Michal Kubecek <mkubecek@suse.cz> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'virt')
0 files changed, 0 insertions, 0 deletions