Skip to content

Commit

Permalink
net: dsa: mv88e6xxx: Set STP disable state in port_disable
Browse files Browse the repository at this point in the history
When requested to disable a port, set the port STP state to disabled.
This fully disables the port and should save some power.

Signed-off-by: Andrew Lunn <[email protected]>
Reviewed-by: Vivien Didelot <[email protected]>
Reviewed-by: Florian Fainelli <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
lunn authored and davem330 committed May 4, 2019
1 parent 2ce1aef commit 4a0eb73
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/net/dsa/mv88e6xxx/chip.c
Original file line number Diff line number Diff line change
Expand Up @@ -2428,6 +2428,9 @@ static void mv88e6xxx_port_disable(struct dsa_switch *ds, int port)

mutex_lock(&chip->reg_lock);

if (mv88e6xxx_port_set_state(chip, port, BR_STATE_DISABLED))
dev_err(chip->dev, "failed to disable port\n");

if (chip->info->ops->serdes_irq_free)
chip->info->ops->serdes_irq_free(chip, port);

Expand Down

0 comments on commit 4a0eb73

Please sign in to comment.