Commit 7b898469 authored by Andrew Lunn's avatar Andrew Lunn Committed by David S. Miller

net: dsa: mv88e6xxx: link mv88e6xxx_port to mv88e6xxx_chip

An up coming change will register interrupts for individual switch
ports, using the mv88e6xxx_port as the interrupt context information.
Add members to the mv88e6xxx_port structure so we can link it back to
the mv88e6xxx_chip member the port belongs to and the port number of
the port.
Signed-off-by: default avatarAndrew Lunn <andrew@lunn.ch>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 364e9d77
...@@ -2173,6 +2173,9 @@ static int mv88e6xxx_setup_port(struct mv88e6xxx_chip *chip, int port) ...@@ -2173,6 +2173,9 @@ static int mv88e6xxx_setup_port(struct mv88e6xxx_chip *chip, int port)
int err; int err;
u16 reg; u16 reg;
chip->ports[port].chip = chip;
chip->ports[port].port = port;
/* MAC Forcing register: don't force link, speed, duplex or flow control /* MAC Forcing register: don't force link, speed, duplex or flow control
* state to any particular values on physical ports, but force the CPU * state to any particular values on physical ports, but force the CPU
* port and all DSA ports to their maximum bandwidth and full duplex. * port and all DSA ports to their maximum bandwidth and full duplex.
......
...@@ -191,6 +191,8 @@ struct mv88e6xxx_port_hwtstamp { ...@@ -191,6 +191,8 @@ struct mv88e6xxx_port_hwtstamp {
}; };
struct mv88e6xxx_port { struct mv88e6xxx_port {
struct mv88e6xxx_chip *chip;
int port;
u64 serdes_stats[2]; u64 serdes_stats[2];
u64 atu_member_violation; u64 atu_member_violation;
u64 atu_miss_violation; u64 atu_miss_violation;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment