From owner-svn-src-stable@freebsd.org Sun Dec 10 19:22:45 2017 Return-Path: Delivered-To: svn-src-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 53E43E97BCC; Sun, 10 Dec 2017 19:22:45 +0000 (UTC) (envelope-from bryanv@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1EB4C7DEF4; Sun, 10 Dec 2017 19:22:45 +0000 (UTC) (envelope-from bryanv@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBAJMim8089805; Sun, 10 Dec 2017 19:22:44 GMT (envelope-from bryanv@FreeBSD.org) Received: (from bryanv@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBAJMiGb089804; Sun, 10 Dec 2017 19:22:44 GMT (envelope-from bryanv@FreeBSD.org) Message-Id: <201712101922.vBAJMiGb089804@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bryanv set sender to bryanv@FreeBSD.org using -f From: Bryan Venteicher Date: Sun, 10 Dec 2017 19:22:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326751 - stable/11/sys/dev/vmware/vmxnet3 X-SVN-Group: stable-11 X-SVN-Commit-Author: bryanv X-SVN-Commit-Paths: stable/11/sys/dev/vmware/vmxnet3 X-SVN-Commit-Revision: 326751 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Dec 2017 19:22:45 -0000 Author: bryanv Date: Sun Dec 10 19:22:43 2017 New Revision: 326751 URL: https://svnweb.freebsd.org/changeset/base/326751 Log: MFC r326744: Correctly report the vmxnet3 link down media status Modified: stable/11/sys/dev/vmware/vmxnet3/if_vmx.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/vmware/vmxnet3/if_vmx.c ============================================================================== --- stable/11/sys/dev/vmware/vmxnet3/if_vmx.c Sun Dec 10 18:55:42 2017 (r326750) +++ stable/11/sys/dev/vmware/vmxnet3/if_vmx.c Sun Dec 10 19:22:43 2017 (r326751) @@ -3485,14 +3485,15 @@ vmxnet3_media_status(struct ifnet *ifp, struct ifmedia 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); }