From owner-freebsd-scsi@FreeBSD.ORG Fri Feb 24 00:50:14 2012 Return-Path: Delivered-To: freebsd-scsi@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D49851065673 for ; Fri, 24 Feb 2012 00:50:14 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id C36238FC16 for ; Fri, 24 Feb 2012 00:50:14 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q1O0oEEt075485 for ; Fri, 24 Feb 2012 00:50:14 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q1O0oETM075484; Fri, 24 Feb 2012 00:50:14 GMT (envelope-from gnats) Date: Fri, 24 Feb 2012 00:50:14 GMT Message-Id: <201202240050.q1O0oETM075484@freefall.freebsd.org> To: freebsd-scsi@FreeBSD.org From: dfilter@FreeBSD.ORG (dfilter service) Cc: Subject: Re: kern/163812: commit references a PR X-BeenThere: freebsd-scsi@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: dfilter service List-Id: SCSI subsystem List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Feb 2012 00:50:14 -0000 The following reply was made to PR kern/163812; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: kern/163812: commit references a PR Date: Fri, 24 Feb 2012 00:48:40 +0000 (UTC) Author: marius Date: Fri Feb 24 00:48:27 2012 New Revision: 232093 URL: http://svn.freebsd.org/changeset/base/232093 Log: MFC: r231621 - As it turns out, MSI-X is broken for at least LSI SAS1068E when passed through by VMware so blacklist their PCI-PCI bridge for MSI/MSI-X here. Note that besides currently there not being a quirk type that disables MSI-X only and there's no evidence that MSI doesn't work with the VMware pass-through, it's really questionable whether MSI generally works in that setup as VMware only mention three know working devices [1, p. 4]. Also not that this quirk entry currently doesn't affect the devices emulated by VMware in any way as these don't claim support MSI/MSI-X to begin with. [2] While at it, make the PCI quirk table const and static. - Remove some duplicated empty lines. - Use DEVMETHOD_END. PR: 163812, http://forums.freebsd.org/showthread.php?t=27899 [2] Reviewed by: jhb Approved by: re (kib) [1]: http://www.vmware.com/pdf/vsp_4_vmdirectpath_host.pdf Modified: stable/8/sys/dev/pci/pci.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/e1000/ (props changed) Modified: stable/8/sys/dev/pci/pci.c ============================================================================== --- stable/8/sys/dev/pci/pci.c Fri Feb 24 00:47:14 2012 (r232092) +++ stable/8/sys/dev/pci/pci.c Fri Feb 24 00:48:27 2012 (r232093) @@ -170,7 +170,7 @@ static device_method_t pci_methods[] = { DEVMETHOD(pci_msi_count, pci_msi_count_method), DEVMETHOD(pci_msix_count, pci_msix_count_method), - { 0, 0 } + DEVMETHOD_END }; DEFINE_CLASS_0(pci, pci_driver, pci_methods, 0); @@ -182,7 +182,6 @@ MODULE_VERSION(pci, 1); static char *pci_vendordata; static size_t pci_vendordata_size; - struct pci_quirk { uint32_t devid; /* Vendor/device of the card */ int type; @@ -193,7 +192,7 @@ struct pci_quirk { int arg2; }; -struct pci_quirk pci_quirks[] = { +static const struct pci_quirk const pci_quirks[] = { /* The Intel 82371AB and 82443MX has a map register at offset 0x90. */ { 0x71138086, PCI_QUIRK_MAP_REG, 0x90, 0 }, { 0x719b8086, PCI_QUIRK_MAP_REG, 0x90, 0 }, @@ -226,6 +225,12 @@ struct pci_quirk pci_quirks[] = { { 0x74501022, PCI_QUIRK_DISABLE_MSI, 0, 0 }, /* + * MSI-X doesn't work with at least LSI SAS1068E passed through by + * VMware. + */ + { 0x079015ad, PCI_QUIRK_DISABLE_MSI, 0, 0 }, + + /* * Some virtualization environments emulate an older chipset * but support MSI just fine. QEMU uses the Intel 82440. */ @@ -1813,7 +1818,7 @@ pci_remap_intr_method(device_t bus, devi int pci_msi_device_blacklisted(device_t dev) { - struct pci_quirk *q; + const struct pci_quirk *q; if (!pci_honor_msi_blacklist) return (0); @@ -1833,7 +1838,7 @@ pci_msi_device_blacklisted(device_t dev) static int pci_msi_vm_chipset(device_t dev) { - struct pci_quirk *q; + const struct pci_quirk *q; for (q = &pci_quirks[0]; q->devid; q++) { if (q->devid == pci_get_devid(dev) && @@ -2788,7 +2793,7 @@ pci_add_resources(device_t bus, device_t struct pci_devinfo *dinfo = device_get_ivars(dev); pcicfgregs *cfg = &dinfo->cfg; struct resource_list *rl = &dinfo->resources; - struct pci_quirk *q; + const struct pci_quirk *q; int i; /* ATA devices needs special map treatment */ @@ -3593,7 +3598,6 @@ pci_write_ivar(device_t dev, device_t ch } } - #include "opt_ddb.h" #ifdef DDB #include @@ -3734,7 +3738,6 @@ out:; return (res); } - struct resource * pci_alloc_resource(device_t dev, device_t child, int type, int *rid, u_long start, u_long end, u_long count, u_int flags) _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"