From owner-freebsd-current@FreeBSD.ORG Wed Mar 11 18:57:36 2009 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 79818106564A; Wed, 11 Mar 2009 18:57:36 +0000 (UTC) (envelope-from rnoland@FreeBSD.org) Received: from gizmo.2hip.net (gizmo.2hip.net [64.74.207.195]) by mx1.freebsd.org (Postfix) with ESMTP id 4AF448FC13; Wed, 11 Mar 2009 18:57:36 +0000 (UTC) (envelope-from rnoland@FreeBSD.org) Received: from [192.168.1.156] (adsl-241-168-218.bna.bellsouth.net [74.241.168.218]) (authenticated bits=0) by gizmo.2hip.net (8.14.3/8.14.3) with ESMTP id n2BIuCmc018456 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 11 Mar 2009 14:56:13 -0400 (EDT) (envelope-from rnoland@FreeBSD.org) From: Robert Noland To: "Arno J. Klaassen" In-Reply-To: References: <200903101425.28608.jhb@freebsd.org> <200903101637.31039.jhb@freebsd.org> <1236728841.2091.5.camel@balrog.2hip.net> <49B700AD.7010500@samsco.org> Content-Type: multipart/signed; micalg="pgp-sha1"; protocol="application/pgp-signature"; boundary="=-OMLtzr9t5krTccmb7S4K" Organization: FreeBSD Date: Wed, 11 Mar 2009 13:57:13 -0500 Message-Id: <1236797833.1679.14.camel@balrog.2hip.net> Mime-Version: 1.0 X-Mailer: Evolution 2.24.5 FreeBSD GNOME Team Port X-Spam-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00,RCVD_IN_PBL, RDNS_DYNAMIC autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on gizmo.2hip.net Cc: pyunyh@gmail.com, current@freebsd.org Subject: Re: msi broken? X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Mar 2009 18:57:36 -0000 --=-OMLtzr9t5krTccmb7S4K Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Wed, 2009-03-11 at 14:47 +0100, Arno J. Klaassen wrote: > Scott Long writes: >=20 > > Robert Noland wrote: > >> On Wed, 2009-03-11 at 00:36 +0100, Arno J. Klaassen wrote: > >>> John Baldwin writes: > >>> > >>>> On Tuesday 10 March 2009 3:00:00 pm Arno J. Klaassen wrote: > >>>>> John Baldwin writes: > >>>>> > >>>>>> On Tuesday 10 March 2009 10:08:59 am Arno J. Klaassen wrote: > >>>>>>> Hello, > >>>>>>> > >>>>>>> when upgrading this morning from a March 1 -current, if_bge > >>>>>>> stopped working (and irq256: bge0 not showing up in > >>>>>>> vmstat -i ). Setting hw.pci.enable_msi=3D"0" makes it work again. > >>>>>> Can you get a verbose dmesg (boot -v) with MSI enabled? > >>>> Ok, so you are getting MSI interrupts assigned and routed ok. Can > >>>> you try disabling the code that sets the INTx_MASK flag in the PCI > >>>> command register in sys/dev/pci/pci.c:pci_setup_intr()? > >>> grr : "rid" sure is 1 for the if_bge interrupt. Please tell me which > >>> lines of code set the INTx_MASK flag. Thanx, more tomorrow. > >> > >> if rid is 0, the chip should be using INTx. if rid > 0 then it should > >> be using MSI. > >> > >> > >> } > >> mte->mte_handlers++; > >> } > >> #if 0 /* Comment this out/* > >> /* Make sure that INTx is disabled if we are using MSI= /MSIX */ > >> pci_set_command_bit(dev, child, PCIM_CMD_INTxDIS); > >> #endif > >> bad: > >> if (error) { > >> (void)bus_generic_teardown_intr(dev, child, ir= q, > >> cookie); > >> return (error); > >> > >> robert. > >> > > > > If this turns out to help this particular gentleman, >=20 > yes it does ;) with otherwise clean sources >=20 > sorry I did not understand directly what you asked me to do >=20 > > then I'd like to > > suggest a further test of having the bge driver explicitly reset the > > the INTxDIS bit after calling bus_setup_intr(). If that works, then I > > strongly suggest that we treat this as a localized quirk that drivers > > will need to manage for themselves, and not something that the PCI laye= r > > should try to control. It might be possible to set up some sort of > > hint system for drivers to programatically tell the PCI layer to treat > > this bit special for a particular device instance. What I don't want > > to see is the PCI layer growing yet another hidden quirk table of > > PCI IDs. This kind of quirk knowledge belongs in the driver. >=20 Ok, well I agree with Scott, this needs to be addressed in the bge driver. robert. > iff you'd like I can test things on this board for a while ... >=20 > Thank you very much, Arno --=20 Robert Noland FreeBSD --=-OMLtzr9t5krTccmb7S4K Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.11 (FreeBSD) iEYEABECAAYFAkm4CYkACgkQM4TrQ4qfROMILwCfS5CoDPXQjaBHhc5H3NgYU7Yz YfsAoIedmsnkFqsS+Cx6J+bvbj3kJvCk =53lo -----END PGP SIGNATURE----- --=-OMLtzr9t5krTccmb7S4K--