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

be2net: change to show correct physical link status

link status is wrongly displayed under certain circumstances.
This change fixes it.

Signed-off-by: Somnath K <somnathk@serverengines.com>
Signed-off-by: Ajit Khaparde <ajitk@serverengines.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Ajit Khaparde and committed by
David S. Miller
48e9989e 7c185276

+2 -1
+2 -1
drivers/net/benet/be_ethtool.c
··· 322 322 int status; 323 323 u16 intf_type; 324 324 325 - if (adapter->link_speed < 0) { 325 + if ((adapter->link_speed < 0) || (!(netdev->flags & IFF_UP))) { 326 326 status = be_cmd_link_status_query(adapter, &link_up, 327 327 &mac_speed, &link_speed); 328 328 329 + be_link_status_update(adapter, link_up); 329 330 /* link_speed is in units of 10 Mbps */ 330 331 if (link_speed) { 331 332 ecmd->speed = link_speed*10;