mirror of
https://github.com/openvswitch/ovs
synced 2025-08-31 06:15:47 +00:00
netdev-linux: Use ethtool when miimon fails.
Some network drivers might return true to SIOCGMIIPHY and an error on SIOCGMIIREG when using MII to query phy state. Fall back to ethtool if this happens to allow failover to work when using such nics. Reported-at: http://openvswitch.org/pipermail/dev/2016-August/078800.html Signed-off-by: David Hill <dhill@redhat.com> Signed-off-by: Joe Stringer <joe@ovn.org>
This commit is contained in:
@@ -1486,10 +1486,9 @@ netdev_linux_get_miimon(const char *name, bool *miimon)
|
||||
|
||||
if (!error) {
|
||||
*miimon = !!(data.val_out & BMSR_LSTATUS);
|
||||
} else {
|
||||
VLOG_WARN_RL(&rl, "%s: failed to query MII", name);
|
||||
}
|
||||
} else {
|
||||
}
|
||||
if (error) {
|
||||
struct ethtool_cmd ecmd;
|
||||
|
||||
VLOG_DBG_RL(&rl, "%s: failed to query MII, falling back to ethtool",
|
||||
|
Reference in New Issue
Block a user