diff options
author | Bryan Venteicher <bryanv@FreeBSD.org> | 2017-11-28 06:21:37 +0000 |
---|---|---|
committer | Bryan Venteicher <bryanv@FreeBSD.org> | 2017-11-28 06:21:37 +0000 |
commit | 1b108b19eded2860f7691b4ec836b7b60b9a2888 (patch) | |
tree | 780d4b721c786921929c7e0255cc56963328862f /sys/dev/vmware | |
parent | 51de47e3f84c22ff87bf6e2a33df8a07ab9ac727 (diff) | |
download | src-1b108b19eded2860f7691b4ec836b7b60b9a2888.tar.gz src-1b108b19eded2860f7691b4ec836b7b60b9a2888.zip |
Correctly report the vmxnet3 link down media status
Reported by: lew@perftech.com
MFC after: 1 week
Notes
Notes:
svn path=/head/; revision=326309
Diffstat (limited to 'sys/dev/vmware')
-rw-r--r-- | sys/dev/vmware/vmxnet3/if_vmx.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/dev/vmware/vmxnet3/if_vmx.c b/sys/dev/vmware/vmxnet3/if_vmx.c index 017ccb0b94d6..a83e2de31661 100644 --- a/sys/dev/vmware/vmxnet3/if_vmx.c +++ b/sys/dev/vmware/vmxnet3/if_vmx.c @@ -3485,14 +3485,15 @@ vmxnet3_media_status(struct ifnet *ifp, struct ifmediareq *ifmr) sc = ifp->if_softc; - ifmr->ifm_active = IFM_ETHER | IFM_AUTO; ifmr->ifm_status = IFM_AVALID; + ifmr->ifm_active = IFM_ETHER; VMXNET3_CORE_LOCK(sc); - if (vmxnet3_link_is_up(sc) != 0) + if (vmxnet3_link_is_up(sc) != 0) { ifmr->ifm_status |= IFM_ACTIVE; - else - ifmr->ifm_status |= IFM_NONE; + ifmr->ifm_active |= IFM_AUTO; + } else + ifmr->ifm_active |= IFM_NONE; VMXNET3_CORE_UNLOCK(sc); } |