diff options
author | Andrew Lunn <andrew@lunn.ch> | 2015-04-02 04:06:36 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-04-01 22:55:40 -0400 |
commit | fd3a0ee4063e4f44d915df8f117d9e0d8b05950a (patch) | |
tree | 4852b462842e2e06bfccd0f16b817affb48f6d91 /drivers/net/dsa/mv88e6xxx.h | |
parent | 4914358567d81d6f1d95f7809c77658c55555f1c (diff) | |
download | op-kernel-dev-fd3a0ee4063e4f44d915df8f117d9e0d8b05950a.zip op-kernel-dev-fd3a0ee4063e4f44d915df8f117d9e0d8b05950a.tar.gz |
net: dsa: Consolidate phy read and write functions
Move the common code for reading and writing phy registers into the
shared mv88e6xxx.
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Tested-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa/mv88e6xxx.h')
-rw-r--r-- | drivers/net/dsa/mv88e6xxx.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/net/dsa/mv88e6xxx.h b/drivers/net/dsa/mv88e6xxx.h index 4961476..44b0ec7 100644 --- a/drivers/net/dsa/mv88e6xxx.h +++ b/drivers/net/dsa/mv88e6xxx.h @@ -140,8 +140,11 @@ int mv88e6xxx_reg_write(struct dsa_switch *ds, int addr, int reg, u16 val); int mv88e6xxx_config_prio(struct dsa_switch *ds); int mv88e6xxx_set_addr_direct(struct dsa_switch *ds, u8 *addr); int mv88e6xxx_set_addr_indirect(struct dsa_switch *ds, u8 *addr); -int mv88e6xxx_phy_read(struct dsa_switch *ds, int addr, int regnum); -int mv88e6xxx_phy_write(struct dsa_switch *ds, int addr, int regnum, u16 val); +int mv88e6xxx_phy_read(struct dsa_switch *ds, int port, int regnum); +int mv88e6xxx_phy_write(struct dsa_switch *ds, int port, int regnum, u16 val); +int mv88e6xxx_phy_read_indirect(struct dsa_switch *ds, int port, int regnum); +int mv88e6xxx_phy_write_indirect(struct dsa_switch *ds, int port, int regnum, + u16 val); void mv88e6xxx_ppu_state_init(struct dsa_switch *ds); int mv88e6xxx_phy_read_ppu(struct dsa_switch *ds, int addr, int regnum); int mv88e6xxx_phy_write_ppu(struct dsa_switch *ds, int addr, |