Date: Wed, 23 May 2007 21:28:21 -0400 (EDT) From: Andrew Gallatin <gallatin@cs.duke.edu> To: John Baldwin <jhb@freebsd.org> Cc: Rui Paulo <rpaulo@fnop.net>, cvs-src@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/dev/pci pci_pci.c Message-ID: <18004.59980.434113.379401@grasshopper.cs.duke.edu> In-Reply-To: <200705231547.38987.jhb@freebsd.org> References: <200705231531.l4NFV12H058289@repoman.freebsd.org> <86bqgbs8kt.wl%rpaulo@fnop.net> <18004.36709.708317.994071@grasshopper.cs.duke.edu> <200705231547.38987.jhb@freebsd.org>
index | next in thread | previous in thread | raw e-mail
John Baldwin writes:
> On Wednesday 23 May 2007 03:00:30 pm Andrew Gallatin wrote:
> >
> > Rui Paulo writes:
> > > At Wed, 23 May 2007 15:31:01 +0000 (UTC),
> > > Andrew Gallatin wrote:
> > > >
> > > > gallatin 2007-05-23 15:31:01 UTC
> > > >
> > > > FreeBSD src repository
> > > >
> > > > Modified files:
> > > > sys/dev/pci pci_pci.c
> > > > Log:
> > > > Fix a typo in pcib_alloc_msi{x} which resulted in the
> > > > device's, not the bridge's, softc to be used to check the
> > > > PCIB_DISABLE_MSI flag. This resulted in randomly allowing
> > > > or denying MSI interrupts based on whatever value the driver
> > > > happened to store at sizeof(device_t) bytes into its softc.
> > > >
> > > > I noticed this when I stopped getting MSI interrupts
> > > > after slighly re-arranging mxge's softc yesterday.
> > >
> > > Wow, I'll have to try this out on msk(4)..
> >
> > To be clear, pci_alloc_msi() was failing, so MSI was not
> > used at all. It didn't affect the actual generation
> > of interrupts once MSI is enabled..
>
> In some cases it gave you MSI when it shouldn't have, too. I do have at least
> one bug report on msk(4) that this might fix, as since it was checking the
> wrong softc, it could break on any system, not just ones with the broken
> bridges.
Indeed. In fact, mxge would always get MSI, even on blacklisted
bridges before I changed the layout of the softc.. Then it would
never get MSI, and I lost ~1Gb/s when my 10GbE NIC was sharing an IRQ
with USB, and I went bug hunting.
The temporary lack of MSI made me appreciate all your hard work in adding
support for it even more :)
Drew
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?18004.59980.434113.379401>
