]> asedeno.scripts.mit.edu Git - linux.git/commit
devlink: hold a reference to the netdevice around ethtool compat
authorJakub Kicinski <jakub.kicinski@netronome.com>
Tue, 26 Feb 2019 03:34:06 +0000 (19:34 -0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 26 Feb 2019 16:49:05 +0000 (08:49 -0800)
commit1b45ff6c17f1d07c496b08dd602a4aff8fe40848
tree8e7cc2289a7e48072dc3db8690e709828debb7d9
parent03969b941486b208e2e418acbcf7065c740e7a5e
devlink: hold a reference to the netdevice around ethtool compat

When ethtool is calling into devlink compat code make sure we have
a reference on the netdevice on which the operation was invoked.

v3: move the hold/lock logic into devlink_compat_* functions (Florian)

Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/devlink.c
net/core/ethtool.c