linux/drivers/net/dsa
Florian Fainelli 4ab7f91381 net: dsa: bcm_sf2: properly propagate carrier down state for MoCA
MoCA interfaces require the use of an user-space daemon (mocad) which
will typically use cmd->autoneg to force the link. This is causing other
network manager applications not to get proper carrier down
notifications because of the following sequence of events:

- link down interrupt is received, link is set to 0 by the interrupt
  handler
- fixed_link update callback runs and updates the BMSR register
  accordingly
- PHY library polls the PHY for link status, sees the link is down,
  proceeds with reporting that
- mocad gets notified of the link state and call phy_ethtool_sset()
  with cmd->autoneg set to the link status (0)
- phy_start_aneg() is called at the end of phy_ethtool_sset() and sets
  the PHY state to PHY_FORCING

Just make sure we notify the interface carrier appropriately when we
detect that the link is down in our fixed_link update callback. This is
made local to the bcm_sf2 driver as the PHY library does the right thing
in any case. This is similar to the GENET change introduced in
54d7c01d3e ("net: bcmgenet: enable MoCA
link state change detection").

Fixes: 246d7f773c ("net: dsa: add Broadcom SF2 switch driver")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-05-17 23:40:24 -04:00
..
bcm_sf2_regs.h net: dsa: bcm_sf2: add HW bridging support 2015-02-25 17:03:38 -05:00
bcm_sf2.c net: dsa: bcm_sf2: properly propagate carrier down state for MoCA 2015-05-17 23:40:24 -04:00
bcm_sf2.h Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2015-03-03 21:16:48 -05:00
Kconfig net: dsa: mv88e6171: Add other members of the family 2015-05-09 16:05:53 -04:00
Makefile net: dsa: Add support for Marvell 88E6352 2014-10-30 14:54:10 -04:00
mv88e6xxx.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2015-05-13 14:31:43 -04:00
mv88e6xxx.h net: dsa: mv88e6xxx: Replace PHY mutex by SMI mutex 2015-05-09 16:05:53 -04:00
mv88e6060.c net: dsa: Report known silicon revisions for Marvell 88E6060 2014-10-30 14:54:10 -04:00
mv88e6123_61_65.c net: dsa: Converting remaining registers to mnemonics 2015-05-09 16:05:53 -04:00
mv88e6131.c net: dsa: mv88e6131: Add support for mv88e6185 2015-05-09 16:05:53 -04:00
mv88e6171.c net: dsa: mv88e6171: Add other members of the family 2015-05-09 16:05:53 -04:00
mv88e6352.c net: dsa: Move mv88e6172 support into mv88e6352 family driver 2015-05-09 16:05:53 -04:00