From owner-svn-src-all@FreeBSD.ORG Fri Jul 19 05:28:48 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5C78BFF3; Fri, 19 Jul 2013 05:28:48 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 40583FA6; Fri, 19 Jul 2013 05:28:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r6J5Sm1E023224; Fri, 19 Jul 2013 05:28:48 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r6J5Sluv023223; Fri, 19 Jul 2013 05:28:47 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201307190528.r6J5Sluv023223@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 19 Jul 2013 05:28:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r253464 - stable/9/sys/dev/usb/controller X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2013 05:28:48 -0000 Author: kib Date: Fri Jul 19 05:28:47 2013 New Revision: 253464 URL: http://svnweb.freebsd.org/changeset/base/253464 Log: MFC r253398: Add a tunable to force disable MSI use for xhci(4). Approved by: re (delphij) Modified: stable/9/sys/dev/usb/controller/xhci_pci.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/controller/xhci_pci.c ============================================================================== --- stable/9/sys/dev/usb/controller/xhci_pci.c Fri Jul 19 03:27:04 2013 (r253463) +++ stable/9/sys/dev/usb/controller/xhci_pci.c Fri Jul 19 05:28:47 2013 (r253464) @@ -132,6 +132,9 @@ xhci_pci_probe(device_t self) } } +static int xhci_use_msi = 1; +TUNABLE_INT("hw.usb.xhci.msi", &xhci_use_msi); + static int xhci_pci_attach(device_t self) { @@ -159,13 +162,15 @@ xhci_pci_attach(device_t self) sc->sc_io_size = rman_get_size(sc->sc_io_res); sc->sc_irq_rid = 0; - count = pci_msi_count(self); - if (count >= 1) { - count = 1; - if (pci_alloc_msi(self, &count) == 0) { - if (bootverbose) - device_printf(self, "MSI enabled\n"); - sc->sc_irq_rid = 1; + if (xhci_use_msi) { + count = pci_msi_count(self); + if (count >= 1) { + count = 1; + if (pci_alloc_msi(self, &count) == 0) { + if (bootverbose) + device_printf(self, "MSI enabled\n"); + sc->sc_irq_rid = 1; + } } } sc->sc_irq_res = bus_alloc_resource_any(self, SYS_RES_IRQ,