diff options
author | Florian Fainelli <f.fainelli@gmail.com> | 2017-06-02 15:31:21 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-06-04 20:05:15 -0400 |
commit | 937c7df85ce7ce6b2319894f6ad3376f15dff186 (patch) | |
tree | c98f81eae0f9a8e42ff136eb81ba188dad586400 /net/dsa/legacy.c | |
parent | 1820dd0633b9972028e377ee76e5d40873491d25 (diff) |
net: dsa: Pass dsa_port reference to ethtool setup/restore
We do not need to have a reference to a dsa_switch, instead we should
pass a reference to a CPU dsa_port, change that. This is a preliminary
change to better support multiple CPU ports.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa/legacy.c')
-rw-r--r-- | net/dsa/legacy.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/dsa/legacy.c b/net/dsa/legacy.c index d70a1a788d17..d534d8f4b9cf 100644 --- a/net/dsa/legacy.c +++ b/net/dsa/legacy.c | |||
@@ -205,7 +205,7 @@ static int dsa_switch_setup_one(struct dsa_switch *ds, struct device *parent) | |||
205 | netdev_err(dst->master_netdev, "[%d] : can't configure CPU and DSA ports\n", | 205 | netdev_err(dst->master_netdev, "[%d] : can't configure CPU and DSA ports\n", |
206 | index); | 206 | index); |
207 | 207 | ||
208 | ret = dsa_cpu_port_ethtool_setup(ds); | 208 | ret = dsa_cpu_port_ethtool_setup(ds->dst->cpu_dp); |
209 | if (ret) | 209 | if (ret) |
210 | return ret; | 210 | return ret; |
211 | 211 | ||
@@ -733,7 +733,7 @@ static void dsa_remove_dst(struct dsa_switch_tree *dst) | |||
733 | dsa_switch_destroy(ds); | 733 | dsa_switch_destroy(ds); |
734 | } | 734 | } |
735 | 735 | ||
736 | dsa_cpu_port_ethtool_restore(dst->cpu_dp->ds); | 736 | dsa_cpu_port_ethtool_restore(dst->cpu_dp); |
737 | 737 | ||
738 | dev_put(dst->master_netdev); | 738 | dev_put(dst->master_netdev); |
739 | } | 739 | } |