skge: restore device multicast membership after link down/up
Subsystems (2)
PATCH 1/1 skge: restore device multicast membership after link down/up
Yukon hardware will lose multicast membership data and promiscuous mode information if a link is disconnected and reconnected without taking the interface down. A call to yukon_reset in yukon_link_down will clear the hardware's multicast list, so it needs to be added back on link_up.
It does not appear that Genesis hardware needs a similar patch is needed since it does not seem to clear multicast membership when taking the link down.
---
skge.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/net/skge.c +4 -0
@@ -1922,6 +1922,10 @@ static void yukon_link_up(struct skge_pogma_write16 (hw, port,GM_GP_CTRL , reg);gm_phy_write (hw, port,PHY_MARV_INT_MASK ,PHY_M_IS_DEF_MSK ); + +/* reset multicast list */ +yukon_set_multicast (skge->netdev); +skge_link_up (skge); }
PATCH 1/1 skge: don't clear MC state on link down
I would rather fix Andy's problem by not clearing
multicast information on link down.
Also, add code to restore multicast state after ethtool phy reset.
--- drivers/net/skge.c | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-)
drivers/net/skge.c +2 -3
@@ -2154,8 +2154,6 @@ static void yukon_link_down(struct skge_int port = skge->port;u16 ctrl; -gm_phy_write (hw, port,PHY_MARV_INT_MASK ,0 ); - ctrl =gma_read16 (hw, port,GM_GP_CTRL ); ctrl &= ~(GM_GPCR_RX_ENA |GM_GPCR_TX_ENA );gma_write16 (hw, port,GM_GP_CTRL , ctrl);
@@ -2167,7 +2165,6 @@ static void yukon_link_down(struct skge_gm_phy_write (hw, port,PHY_MARV_AUNE_ADV , ctrl); } -yukon_reset (hw, port);skge_link_down (skge);yukon_init (hw, port);
@@ -2268,6 +2265,8 @@ static void skge_phy_reset(struct skge_pyukon_init (hw, port); }mutex_unlock (&hw->phy_mutex); + + dev->set_multicast_list (dev); }/* Basic MII support */
Signature · 1 line
1.4.1
Re: [PATCH] skge: don't clear MC state on link down
Quoted 5 lines · Stephen Hemminger
I would rather fix Andy's problem by not clearing
multicast information on link down.Also, add code to restore multicast state after ethtool phy reset.
Stephen,
I'll ACK that change instead as long as we can be sure that this isn't needed for hardware reasons.
-andy