Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

be2net: Ignore physical link async event for Lancer

The ability of driver to transmit packets depends on logical state
of the link. Ignore physical link status.

Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Padmanabh Ratnakar and committed by
David S. Miller
2e177a5c 0b13fb45

+6
+5
drivers/net/ethernet/emulex/benet/be_cmds.c
··· 141 141 /* When link status changes, link speed must be re-queried from FW */ 142 142 adapter->phy.link_speed = -1; 143 143 144 + /* Ignore physical link event */ 145 + if (lancer_chip(adapter) && 146 + !(evt->port_link_status & LOGICAL_LINK_STATUS_MASK)) 147 + return; 148 + 144 149 /* For the initial link status do not rely on the ASYNC event as 145 150 * it may not be received in some cases. 146 151 */
+1
drivers/net/ethernet/emulex/benet/be_cmds.h
··· 93 93 LINK_UP = 0x1 94 94 }; 95 95 #define LINK_STATUS_MASK 0x1 96 + #define LOGICAL_LINK_STATUS_MASK 0x2 96 97 97 98 /* When the event code of an async trailer is link-state, the mcc_compl 98 99 * must be interpreted as follows