aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/via/via-velocity.h
diff options
context:
space:
mode:
authorMichal Kubecek <mkubecek@suse.cz>2020-01-06 07:39:36 +0100
committerDavid S. Miller <davem@davemloft.net>2020-01-06 13:54:55 -0800
commit71f711a4f1dd1f6ebc26870ef17ae79581f37ae7 (patch)
tree332b30f367e5da1d56fade74257cc9f7030b25f5 /drivers/net/ethernet/via/via-velocity.h
parentwil6210: get rid of begin() and complete() ethtool_ops (diff)
downloadlinux-71f711a4f1dd1f6ebc26870ef17ae79581f37ae7.tar.xz
linux-71f711a4f1dd1f6ebc26870ef17ae79581f37ae7.zip
via-velocity: allow nesting of ethtool_ops begin() and complete()
Unlike most networking drivers using begin() and complete() ethtool_ops callbacks to resume a device which is down and suspend it again when done, via-velocity does not use standard refcounted infrastructure but sets device sleep state directly. With the introduction of netlink ethtool interface, we may have nested begin-complete blocks so that inner complete() would put the device back to sleep for the rest of the outer block. To avoid rewriting an old and not very actively developed driver, just add a nesting counter and only perform resume and suspend on the outermost level. Signed-off-by: Michal Kubecek <mkubecek@suse.cz> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/via/via-velocity.h')
-rw-r--r--drivers/net/ethernet/via/via-velocity.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/via/via-velocity.h b/drivers/net/ethernet/via/via-velocity.h
index cdfe7809e3c1..f196e71d2c04 100644
--- a/drivers/net/ethernet/via/via-velocity.h
+++ b/drivers/net/ethernet/via/via-velocity.h
@@ -1483,6 +1483,7 @@ struct velocity_info {
struct velocity_context context;
u32 ticks;
+ u32 ethtool_ops_nesting;
u8 rev_id;