summaryrefslogtreecommitdiffstats
path: root/drivers/net/dsa/mv88e6060.c
diff options
context:
space:
mode:
authorVivien Didelot2016-09-01 00:06:13 +0200
committerDavid S. Miller2016-09-02 07:51:12 +0200
commit04bed1434df256b07e78fa5deae848bba18a90f3 (patch)
treecc9b37d3c59dd7cab8d5a63e8bdd04fa1ac9506c /drivers/net/dsa/mv88e6060.c
parentMerge branch 'br-next' (diff)
downloadkernel-qcow2-linux-04bed1434df256b07e78fa5deae848bba18a90f3.tar.gz
kernel-qcow2-linux-04bed1434df256b07e78fa5deae848bba18a90f3.tar.xz
kernel-qcow2-linux-04bed1434df256b07e78fa5deae848bba18a90f3.zip
net: dsa: remove ds_to_priv
Access the priv member of the dsa_switch structure directly, instead of having an unnecessary helper. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa/mv88e6060.c')
-rw-r--r--drivers/net/dsa/mv88e6060.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/dsa/mv88e6060.c b/drivers/net/dsa/mv88e6060.c
index 7ff9d373a9ee..7ce36dbd9b62 100644
--- a/drivers/net/dsa/mv88e6060.c
+++ b/drivers/net/dsa/mv88e6060.c
@@ -19,7 +19,7 @@
static int reg_read(struct dsa_switch *ds, int addr, int reg)
{
- struct mv88e6060_priv *priv = ds_to_priv(ds);
+ struct mv88e6060_priv *priv = ds->priv;
return mdiobus_read_nested(priv->bus, priv->sw_addr + addr, reg);
}
@@ -37,7 +37,7 @@ static int reg_read(struct dsa_switch *ds, int addr, int reg)
static int reg_write(struct dsa_switch *ds, int addr, int reg, u16 val)
{
- struct mv88e6060_priv *priv = ds_to_priv(ds);
+ struct mv88e6060_priv *priv = ds->priv;
return mdiobus_write_nested(priv->bus, priv->sw_addr + addr, reg, val);
}