diff options
| author | 2017-09-20 12:28:05 -0400 | |
|---|---|---|
| committer | 2017-09-21 15:15:58 -0700 | |
| commit | 0abfd494deefdbab66ac03c1181a614285e7d90c (patch) | |
| tree | 303df476c86a75a7b3d7a162a681039a97014c8c /drivers/net/dsa/mt7530.c | |
| parent | net: avoid a full fib lookup when rp_filter is disabled. (diff) | |
| download | linux-rng-0abfd494deefdbab66ac03c1181a614285e7d90c.tar.xz linux-rng-0abfd494deefdbab66ac03c1181a614285e7d90c.zip | |
net: dsa: use dedicated CPU port
Each port in DSA has its own dedicated CPU port currently available in
its parent switch's ds->ports[port].cpu_dp. Use it instead of getting
the unique tree CPU port, which will be deprecated soon.
Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa/mt7530.c')
| -rw-r--r-- | drivers/net/dsa/mt7530.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/dsa/mt7530.c b/drivers/net/dsa/mt7530.c index c142b97add2c..faa3b88d2206 100644 --- a/drivers/net/dsa/mt7530.c +++ b/drivers/net/dsa/mt7530.c @@ -928,11 +928,11 @@ mt7530_setup(struct dsa_switch *ds) struct device_node *dn; struct mt7530_dummy_poll p; - /* The parent node of cpu_dp->netdev which holds the common system + /* The parent node of master netdev which holds the common system * controller also is the container for two GMACs nodes representing * as two netdev instances. */ - dn = ds->dst->cpu_dp->netdev->dev.of_node->parent; + dn = ds->ports[MT7530_CPU_PORT].netdev->dev.of_node->parent; priv->ethernet = syscon_node_to_regmap(dn); if (IS_ERR(priv->ethernet)) return PTR_ERR(priv->ethernet); |
