From owner-svn-src-head@freebsd.org Thu Feb 2 17:29:17 2017 Return-Path: Delivered-To: svn-src-head@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 1F475CCD3F4; Thu, 2 Feb 2017 17:29:17 +0000 (UTC) (envelope-from jhb@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 E3439772; Thu, 2 Feb 2017 17:29:16 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v12HTGIk095210; Thu, 2 Feb 2017 17:29:16 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v12HTGuX095209; Thu, 2 Feb 2017 17:29:16 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201702021729.v12HTGuX095209@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Thu, 2 Feb 2017 17:29:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r313097 - head/sys/dev/pci X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Feb 2017 17:29:17 -0000 Author: jhb Date: Thu Feb 2 17:29:15 2017 New Revision: 313097 URL: https://svnweb.freebsd.org/changeset/base/313097 Log: Require Data Layer Active reporting for native PCI-e HotPlug. Some PCI-e bridges report that they support HotPlug in the slot capabilities but do not report support for Data Layer Active events in the link capabilities register. These bridges do not work correctly when HotPlug is used. Further, while the description of HotPlug in the spec does not mention that DL active events are required, the description of the link capabilities register says that DL active is required for HotPlug. Thanks to Dave Baukus for finding that language in the spec. PR: 211699 Submitted by: Dave Baukus Reviewed by: vangyzen MFC after: 3 days Modified: head/sys/dev/pci/pci_pci.c Modified: head/sys/dev/pci/pci_pci.c ============================================================================== --- head/sys/dev/pci/pci_pci.c Thu Feb 2 13:40:37 2017 (r313096) +++ head/sys/dev/pci/pci_pci.c Thu Feb 2 17:29:15 2017 (r313097) @@ -935,6 +935,8 @@ pcib_probe_hotplug(struct pcib_softc *sc if ((sc->pcie_slot_cap & PCIEM_SLOT_CAP_HPC) == 0) return; + if ((sc->pcie_link_cap & PCIEM_LINK_CAP_DL_ACTIVE) == 0) + return; /* * Some devices report that they have an MRL when they actually