From owner-freebsd-sparc64@FreeBSD.ORG Sun Apr 1 05:58:39 2012 Return-Path: Delivered-To: freebsd-sparc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A502A1065672 for ; Sun, 1 Apr 2012 05:58:39 +0000 (UTC) (envelope-from info2903@infofinweb.com) Received: from mail.angkorads.net (pacific.superdomainzone.com [199.168.191.104]) by mx1.freebsd.org (Postfix) with ESMTP id 42CE48FC0A for ; Sun, 1 Apr 2012 05:58:39 +0000 (UTC) Received: from dynamic-adsl-62-10-173-206.clienti.tiscali.it ([69.46.69.198]) by angkorads.net with MailEnable ESMTP; Sun, 1 Apr 2012 01:59:12 -0400 From: "Quasimodo" To: "freebsd-sparc" MIME-Version: 1.0 Organization: noreply_fineuropa03@tiscali.it Date: Sun, 1 Apr 2012 07:57:49 +0200 Message-ID: <0ECBD125F53B4EDC9BB7E9A3D75732D9.MAI@angkorads.net> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Subject: Servizi Moratoria PMI X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Apr 2012 05:58:39 -0000 L'accordo prevede la sospensione per 12 mesi della quota capitale dell= e rate di mutuo, e per 12 o 6 mesi della quota capitale prevista nei canoni di leasin= g "immobiliare" e "mobiliare".=20 Per informazioni Clicca qui Unsubscribe From owner-freebsd-sparc64@FreeBSD.ORG Sun Apr 1 07:40:14 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8E03C106564A for ; Sun, 1 Apr 2012 07:40: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 6EA178FC14 for ; Sun, 1 Apr 2012 07:40: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 q317eE27076454 for ; Sun, 1 Apr 2012 07:40:14 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q317eEfM076453; Sun, 1 Apr 2012 07:40:14 GMT (envelope-from gnats) Date: Sun, 1 Apr 2012 07:40:14 GMT Message-Id: <201204010740.q317eEfM076453@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Manuel Tobias Schiller Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Manuel Tobias Schiller List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Apr 2012 07:40:14 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Manuel Tobias Schiller To: Marius Strobl Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Sun, 1 Apr 2012 09:33:03 +0200 --Sig_/kyIP4yYpNDIXgcPafOsemRN Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Fri, 30 Mar 2012 16:04:13 +0200 Manuel Tobias Schiller wrote: > On Fri, 30 Mar 2012 15:50:19 +0200 > Marius Strobl wrote: >=20 > > On Fri, Mar 30, 2012 at 03:34:26PM +0200, Manuel Tobias Schiller > > wrote: > > > On Fri, 30 Mar 2012 15:30:26 +0200 > > > Marius Strobl wrote: > > >=20 > > > > On Fri, Mar 30, 2012 at 01:00:25PM +0000, Manuel Tobias Schiller > > > > wrote: > > > > > The following reply was made to PR sparc64/141918; it has been > > > > > noted by GNATS. > > > > >=20 > > > > > From: Manuel Tobias Schiller > > > > > To: bug-followup@FreeBSD.org, bel@orel.ru > > > > > Cc: =20 > > > > > Subject: Re: sparc64/141918: [ehci] ehci_interrupt: > > > > > unrecoverable error, controller halted (sparc64) > > > > > Date: Fri, 30 Mar 2012 14:58:07 +0200 > > > > >=20 > > > > > --Sig_/VHMCV0/0GzXjMMwv0Mf__N+ > > > > > Content-Type: text/plain; charset=3DUS-ASCII > > > > > Content-Transfer-Encoding: quoted-printable > > > > > =20 > > > > > Dear all, > > > > > =20 > > > > > has there been any progress on this one? I'm seeing basically > > > > > the same thing with FreeBSD 9, but in my case the problem turns > > > > > up when I try to mount one of my ZFS filesystems built in a > > > > > RAIDZ configuration on real hard disks connected over USB. The > > > > > disks are fine, and the ZFS filesystem was unexported cleanly > > > > > on a different machine. You can find the kernel messages from > > > > > dmesg below.=20 > > > > > I'm willing to test patches, but it might take a while, since > > > > > my machine (Netra T1 AC200 with a 500 MHz CPU) is not quite > > > > > that fast when recompiling kernels. > > > > > =20 > > > >=20 > > > > Have you given the two patches mentioned earlier in the > > > > audit-trail of this PR a try? It's probably a good idea to > > > > additionally put "options USB_HOST_ALIGN=3D64" into the kernel > > > > configuration file when testing the one for usb_transfer.c. > > > >=20 > > > > Marius > > >=20 > > > Hi Marius, > > >=20 > > > ok, so you did not get feedback on those patches. > >=20 > > No; so far I also couldn't reproduce this problem using the on-board > > EHCI controllers in sun4u machines or the add-on cards I have. What > > controller is this? If I'm not mistaken, the T1-AC200 don't have an > > on-board EHCI controller. > >=20 > > Marius >=20 > Correct. These are "no-name" VIA PCI USB 2.0 controllers. In the past, > I've swapped several of these (bought more than one year apart - this is > what you got at the time when buying a USB controller in the area where > I used to live) between the two Netra machines I administer, and it does > not seems to be specific to the machine or a specific controller card > (in the sense that these PCI cards run fine and without hiccups on > Linux/ppc and Linux/x86). >=20 > These are the kernel-messages: >=20 > uhci0: port 0xc00200-0xc0021f at device 5.0 > on pci2 usbus2: on uhci0 > uhci1: port 0xc00220-0xc0023f at device 5.1 > on pci2 usbus3: on uhci1 > ehci0: mem 0xa000-0xa0ff at device 5.2 > on pci2 ehci0: VIA-quirk applied > usbus4: EHCI version 1.0 > usbus4: on ehci0 >=20 > The relevant part of "pciconf -l" is: >=20 > uhci0@pci0:2:5:0: class=3D0x0c0300 card=3D0x30381106 chip=3D0x30381= 106 > rev=3D0x62 hdr=3D0x00 uhci1@pci0:2:5:1: class=3D0x0c0300 > card=3D0x30381106 chip=3D0x30381106 rev=3D0x62 hdr=3D0x00 > ehci0@pci0:2:5:2: class=3D0x0c0320 card=3D0x31041106 chip=3D0x31041= 106 > rev=3D0x65 hdr=3D0x00 >=20 > (World and kernel build for the latest 9-STABLE is on its way, first a > reference kernel without patches so I know what I compare to...) >=20 > Manuel Hi Marius, it seems that the first patch alone (http://people.freebsd.org/~kan/usb_rspro.diff) does not solve the issue. I'm currently compiling a kernel with the second patch on its own (with "options USB_HOST_ALIGN=3D64" in the kernel options as you suggested), and I'll let you know what comes out. Should I also build a kernel with both patches (assuming the one I'm currently building does not work either)? Manuel --=20 Homepage: http://www.hinterbergen.de/mala OpenPGP: 0xA330353E (DSA) or 0xD87D188C (RSA) --Sig_/kyIP4yYpNDIXgcPafOsemRN Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQGcBAEBAgAGBQJPeASvAAoJEEPbVOqHHK4gFp8L/0q5Jm7J0KhEPPcHJRE26T3w TgE+NCN7KoiwgNnajD6wPjZGqZzUGOQLnEu0iaL3yZIIpsxl8uVgORNBbpZ44EIE G5Ox1IN+zxy7X7enbT4tXS09LSbgiVagCYYcWKYb2dxVTvm4ps55ysOFCD8ASTUF E46RTPzB0K1zbwVH+MFVuAwIjc5wKkWyUrTjaTS52fef/hXjOkciY6ZJ+DqABSko 6GGsDrLQ3cXMhtWHKZrqdcBJJbdaxkkMkK+DkoftJjpZMmp7uH77f6/Ed/CCSpOS E8rubeMMv5zZ/eizjG2eViIePgqKOGLIwcChFgXMSfCVD6v5Zbh+t6owQ3I276U7 kDAtEqM4Gs15SCr6fmgHMGqp/eWDJyants0/mYJFM/7RSyns9o3zPsusFiiv7Bgc R6pAp8Qeyhhnzr3aLj+3q8FPB9aNK0Z8RefPiBykq0S/0o/Nnuujj+dAD/6zEYPx 8vLbqSGr6ti7f6jruyoJdDbSLv0gMOeal4nRs/XIuQ== =pVWu -----END PGP SIGNATURE----- --Sig_/kyIP4yYpNDIXgcPafOsemRN-- From owner-freebsd-sparc64@FreeBSD.ORG Sun Apr 1 10:50:16 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C22C6106566B for ; Sun, 1 Apr 2012 10:50:16 +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 A29EC8FC14 for ; Sun, 1 Apr 2012 10:50:16 +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 q31AoGPw057490 for ; Sun, 1 Apr 2012 10:50:16 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q31AoG2A057489; Sun, 1 Apr 2012 10:50:16 GMT (envelope-from gnats) Date: Sun, 1 Apr 2012 10:50:16 GMT Message-Id: <201204011050.q31AoG2A057489@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Marius Strobl Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Marius Strobl List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Apr 2012 10:50:16 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Marius Strobl To: Manuel Tobias Schiller Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Sun, 1 Apr 2012 12:41:24 +0200 On Sun, Apr 01, 2012 at 09:33:03AM +0200, Manuel Tobias Schiller wrote: > On Fri, 30 Mar 2012 16:04:13 +0200 > Manuel Tobias Schiller wrote: > > > On Fri, 30 Mar 2012 15:50:19 +0200 > > Marius Strobl wrote: > > > > > On Fri, Mar 30, 2012 at 03:34:26PM +0200, Manuel Tobias Schiller > > > wrote: > > > > On Fri, 30 Mar 2012 15:30:26 +0200 > > > > Marius Strobl wrote: > > > > > > > > > On Fri, Mar 30, 2012 at 01:00:25PM +0000, Manuel Tobias Schiller > > > > > wrote: > > > > > > The following reply was made to PR sparc64/141918; it has been > > > > > > noted by GNATS. > > > > > > > > > > > > From: Manuel Tobias Schiller > > > > > > To: bug-followup@FreeBSD.org, bel@orel.ru > > > > > > Cc: > > > > > > Subject: Re: sparc64/141918: [ehci] ehci_interrupt: > > > > > > unrecoverable error, controller halted (sparc64) > > > > > > Date: Fri, 30 Mar 2012 14:58:07 +0200 > > > > > > > > > > > > --Sig_/VHMCV0/0GzXjMMwv0Mf__N+ > > > > > > Content-Type: text/plain; charset=US-ASCII > > > > > > Content-Transfer-Encoding: quoted-printable > > > > > > > > > > > > Dear all, > > > > > > > > > > > > has there been any progress on this one? I'm seeing basically > > > > > > the same thing with FreeBSD 9, but in my case the problem turns > > > > > > up when I try to mount one of my ZFS filesystems built in a > > > > > > RAIDZ configuration on real hard disks connected over USB. The > > > > > > disks are fine, and the ZFS filesystem was unexported cleanly > > > > > > on a different machine. You can find the kernel messages from > > > > > > dmesg below. > > > > > > I'm willing to test patches, but it might take a while, since > > > > > > my machine (Netra T1 AC200 with a 500 MHz CPU) is not quite > > > > > > that fast when recompiling kernels. > > > > > > > > > > > > > > > > Have you given the two patches mentioned earlier in the > > > > > audit-trail of this PR a try? It's probably a good idea to > > > > > additionally put "options USB_HOST_ALIGN=64" into the kernel > > > > > configuration file when testing the one for usb_transfer.c. > > > > > > > > > > Marius > > > > > > > > Hi Marius, > > > > > > > > ok, so you did not get feedback on those patches. > > > > > > No; so far I also couldn't reproduce this problem using the on-board > > > EHCI controllers in sun4u machines or the add-on cards I have. What > > > controller is this? If I'm not mistaken, the T1-AC200 don't have an > > > on-board EHCI controller. > > > > > > Marius > > > > Correct. These are "no-name" VIA PCI USB 2.0 controllers. In the past, > > I've swapped several of these (bought more than one year apart - this is > > what you got at the time when buying a USB controller in the area where > > I used to live) between the two Netra machines I administer, and it does > > not seems to be specific to the machine or a specific controller card > > (in the sense that these PCI cards run fine and without hiccups on > > Linux/ppc and Linux/x86). > > > > These are the kernel-messages: > > > > uhci0: port 0xc00200-0xc0021f at device 5.0 > > on pci2 usbus2: on uhci0 > > uhci1: port 0xc00220-0xc0023f at device 5.1 > > on pci2 usbus3: on uhci1 > > ehci0: mem 0xa000-0xa0ff at device 5.2 > > on pci2 ehci0: VIA-quirk applied > > usbus4: EHCI version 1.0 > > usbus4: on ehci0 > > > > The relevant part of "pciconf -l" is: > > > > uhci0@pci0:2:5:0: class=0x0c0300 card=0x30381106 chip=0x30381106 > > rev=0x62 hdr=0x00 uhci1@pci0:2:5:1: class=0x0c0300 > > card=0x30381106 chip=0x30381106 rev=0x62 hdr=0x00 > > ehci0@pci0:2:5:2: class=0x0c0320 card=0x31041106 chip=0x31041106 > > rev=0x65 hdr=0x00 > > > > (World and kernel build for the latest 9-STABLE is on its way, first a > > reference kernel without patches so I know what I compare to...) > > > > Manuel > > Hi Marius, > > it seems that the first patch alone > (http://people.freebsd.org/~kan/usb_rspro.diff) > does not solve the issue. I'm currently compiling a kernel with the second > patch on its own (with "options USB_HOST_ALIGN=64" in the kernel options > as you suggested), and I'll let you know what comes out. > > Should I also build a kernel with both patches (assuming the one I'm > currently building does not work either)? > Well, the individual patches shouldn't make things worse except for the second one causing more memory to be used so I'd suggest to combine them. If in the end things actually work we still can check what changes are needed for that. Looking at the Linux USB code, the FreeBSD one doesn't some to honor some DMA constraints and at least for the alignment it's actually hard to follow what value eventually is used. One thing that stands out is that for EHCI, the boundary is 4096. This is most easily fixed by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. Marius From owner-freebsd-sparc64@FreeBSD.ORG Sun Apr 1 15:28:00 2012 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 86A49106564A for ; Sun, 1 Apr 2012 15:28:00 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id 04F9E8FC1A for ; Sun, 1 Apr 2012 15:27:59 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id q31FRwiK025701; Sun, 1 Apr 2012 17:27:58 +0200 (CEST) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id q31FRwN5025700; Sun, 1 Apr 2012 17:27:58 +0200 (CEST) (envelope-from marius) Date: Sun, 1 Apr 2012 17:27:58 +0200 From: Marius Strobl To: David Cross Message-ID: <20120401152758.GA25442@alchemy.franken.de> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: freebsd-sparc64@freebsd.org Subject: Re: 9.0-RELEASE, SPARC64, Ultra10, dummynet hard hang X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Apr 2012 15:28:00 -0000 On Fri, Mar 30, 2012 at 10:37:51PM -0400, David Cross wrote: > Ok.. to follow up on my own question, I have tracked it down! > > So, the problem is an unalligned memory access in the "burst" parameter of > dn_link. A printf of it on my system gives: > &(p->burst)=0x0xfffff80002c48f7c > > burst is an uint64_t.. that isn't 64bit aligned. > > This raises a few questions: > 1) Why isn't it being autoaligned, doesn't gcc do this (I am almost > positive it does (or it should) (I have no /etc/make.conf, completely stock > options) The compiler is free to assume native alignment of the struct members for optimization, i.e. use 64-bit accesses for 64-bit members instead of using 8 8-byte accesses. On architectures with strict alignment requirements, i.e. with FreeBSD everything but x86, requires that the memory address accessed also is 64-bit aligned though. The problem is that dummynet(4) consists of a lot of broken code that casts random chunks of memory to structs with the memory not necessarily fulfilling the alignment of these structs. There's nothing wrong with the compiler or its settings in this regard; it's the code that only has a chance of working on x86. > 2) Why is this causing a _deadlock_? (note kernel debugger _does_ work.. > which was a boon in getting to "close" to where the problem was in the > first place) > 3) Since it does cause a deadlock, it means that a bus-fault handler is > being called that _doesn't_ panic.. and doesn't return correctly? > 4) since its not tripping a RED error, its not looping the handler. > and Turns out that I once broke panicing on certain fatal exceptions while in the kernel, which is fixed in r233747. Now dummynet(4) triggers a panic again as it should. > 5) given all of the above.. what's the fix? I am modifying dn_link to be > 64 bit aligned (manually).. but this feels like the wrong approach (though > it will hopefully get me what I want for 'now'. > The correct fix is to copy the random memory byte-wise into instances with the expected alignment and to use the latter instead like in the following patch: http://people.freebsd.org/~marius/dummynet_unfuck_dn_link.diff This only fixes the tip of the iceberg though, potentially all of these types of erroneous casts in dummynet(4) potentially blow on !x86. An acceptable band-aid actually allowing these casts would be to declare the structs as packed, which forces byte-accesses as a side-effect. Given that the layout of struct dn_link isn't thought out well this would break the ABI though. Marius From owner-freebsd-sparc64@FreeBSD.ORG Sun Apr 1 23:10:14 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 37C6A106564A for ; Sun, 1 Apr 2012 23:10: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 08D1D8FC08 for ; Sun, 1 Apr 2012 23:10: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 q31NADQ9041989 for ; Sun, 1 Apr 2012 23:10:13 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q31NADwm041988; Sun, 1 Apr 2012 23:10:13 GMT (envelope-from gnats) Date: Sun, 1 Apr 2012 23:10:13 GMT Message-Id: <201204012310.q31NADwm041988@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Manuel Tobias Schiller Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Manuel Tobias Schiller List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Apr 2012 23:10:14 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Manuel Tobias Schiller To: Marius Strobl Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Mon, 2 Apr 2012 01:00:56 +0200 --Sig_/FD.bT1F1mdRCMwfDMJiTH.3 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Sun, 1 Apr 2012 12:41:24 +0200 Marius Strobl wrote: > Well, the individual patches shouldn't make things worse except for > the second one causing more memory to be used so I'd suggest to > combine them. If in the end things actually work we still can check > what changes are needed for that. > Looking at the Linux USB code, the FreeBSD one doesn't some to honor > some DMA constraints and at least for the alignment it's actually > hard to follow what value eventually is used. One thing that stands > out is that for EHCI, the boundary is 4096. This is most easily fixed > by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. >=20 > Marius Ok, the second patch on its own doesn't appear to work either, so I'm trying the combination of patches now. By the way: defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h is a bad idea - the kernel panics with a backtrace pointing into the mmu-related code. Probably has to do with sparc64 mmu only supporting 8k pages, so I'm not terribly surprised... Ok, I'm waiting for the next make buildkernel to finish, and I'll let you know what comes out. Manuel --=20 Homepage: http://www.hinterbergen.de/mala OpenPGP: 0xA330353E (DSA) or 0xD87D188C (RSA) --Sig_/FD.bT1F1mdRCMwfDMJiTH.3 Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQGcBAEBAgAGBQJPeN4oAAoJEEPbVOqHHK4gWQgL/1DH2YRTlCceXnvwiI13o90X BAd40TZ6llECh91m9TlJpyWK/2KL9HTBGbCMVlEb0+effYNfzkCuFL01FnbemY6x PniTe9y7QWiffaiwbrAQ9WpYRpWajh/R4UhydWTmiyu6XAybDF7Ast1TY0ZuBZMK WOkdUccGxnnsOo033PnHx5NbvNfqLJfTjafjgQ5TlnnSZCqKbaCOZD5ru3Wlex/I lGqCwbHlR1lw/VbmWdaVW4J7UjtDrZI7B6YRYEck5jtooo673heJ17NU/R/Dgkt2 sNkNlEa+xOVrKhBHct9x1UO2fkkwSmv3Zo0doURI8JvSVyuMNTw46d+4YKSfFzJ+ rWajSnjxa2yebMkaOnnhTbS/xx3lWy1x2Uqk5yl6mDjKox1vKwX6HuI8hVOw7qq6 O6vjJ0HqGraMiv+1IYUhx+FbbLSh811uAKck2JVRDL6n/xSdvb858ae7f7HjQHyt DIK/DcXqdyRVf7l2msOBWNeugHjQZO//BQkxTQW5SA== =5gLy -----END PGP SIGNATURE----- --Sig_/FD.bT1F1mdRCMwfDMJiTH.3-- From owner-freebsd-sparc64@FreeBSD.ORG Sun Apr 1 23:21:13 2012 Return-Path: Delivered-To: sparc64@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6BBFF106566B for ; Sun, 1 Apr 2012 23:21:13 +0000 (UTC) (envelope-from training@bdtrinity.com) Received: from mail.prothom-alojobs.com (mail.prothom-alojobs.com [203.76.159.21]) by mx1.freebsd.org (Postfix) with ESMTP id E34908FC0A for ; Sun, 1 Apr 2012 23:21:05 +0000 (UTC) Received: from PAJMES01 (unknown [192.168.110.19]) by mail.prothom-alojobs.com (Postfix) with SMTP id 486B9261096 for ; Mon, 2 Apr 2012 02:55:00 +0600 (BDT) From: Trinity Training Division To: Message-Id: <20120402025217.385920826@bdtrinity.com> Date: Mon, 2 Apr 2012 02:52:17 +0600 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Subject: Daylong Workshop on Dynamics of Marketing and Sales X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: training@bdtrinity.com List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Apr 2012 23:21:13 -0000 From owner-freebsd-sparc64@FreeBSD.ORG Mon Apr 2 08:50:20 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8B5FF106564A for ; Mon, 2 Apr 2012 08:50:20 +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 5B8E98FC14 for ; Mon, 2 Apr 2012 08:50:20 +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 q328oKOH016300 for ; Mon, 2 Apr 2012 08:50:20 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q328oJZL016299; Mon, 2 Apr 2012 08:50:19 GMT (envelope-from gnats) Date: Mon, 2 Apr 2012 08:50:19 GMT Message-Id: <201204020850.q328oJZL016299@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Manuel Tobias Schiller Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Manuel Tobias Schiller List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Apr 2012 08:50:20 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Manuel Tobias Schiller To: Marius Strobl Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Mon, 2 Apr 2012 10:43:14 +0200 --Sig_/D0usoAWksOR_ye8KrLvETot Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Mon, 2 Apr 2012 01:00:56 +0200 Manuel Tobias Schiller wrote: > On Sun, 1 Apr 2012 12:41:24 +0200 > Marius Strobl wrote: >=20 > > Well, the individual patches shouldn't make things worse except for > > the second one causing more memory to be used so I'd suggest to > > combine them. If in the end things actually work we still can check > > what changes are needed for that. > > Looking at the Linux USB code, the FreeBSD one doesn't some to honor > > some DMA constraints and at least for the alignment it's actually > > hard to follow what value eventually is used. One thing that stands > > out is that for EHCI, the boundary is 4096. This is most easily fixed > > by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. > >=20 > > Marius >=20 > Ok, the second patch on its own doesn't appear to work either, so I'm > trying the combination of patches now. By the way: defining > USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h is a bad idea - the > kernel panics with a backtrace pointing into the mmu-related code. > Probably has to do with sparc64 mmu only supporting 8k pages, so I'm > not terribly surprised... Ok, I'm waiting for the next make buildkernel > to finish, and I'll let you know what comes out. >=20 > Manuel Ok, I also tested a kernel with both patches, and the issue persists. Do you have something else to try? Manuel --=20 Homepage: http://www.hinterbergen.de/mala OpenPGP: 0xA330353E (DSA) or 0xD87D188C (RSA) --Sig_/D0usoAWksOR_ye8KrLvETot Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQGcBAEBAgAGBQJPeWaiAAoJEEPbVOqHHK4gc80MAKMomwW9ArAwWkdl4lI79K5a pJLkWtwYWD+YaXPg4s+af552Gra6/cZlvMqEbSu8MK1FiwCvMdnqvfratc1h0mVJ k7J010SBYaXNTw1+udOxFDlmQcgQedFVOgmiOrS3BxvJ60bLAq4HhfLg48jikBMI P9kVDW+BQKIQWSImaU3yDtEBdQ3SVN0QHHiHxBdyKqhF6KNif7nnLYU+yUu1kmzk 8ocX2kxTvA5zZRInWf8VRwnGOi2+ARPsDS6e2I/BUf++nGrdeehcLndEEGWvD2DN am+3mmnhMnBeUhR6QMuxaYDX/K3LNZS95MUYZuagaPJII75ZhjgcU1SNFClAKYn/ QP6BIQ7GHGaE7VNIfDPp0852jVoi85QwSJzcSmPOX5+QCAXSkKQtNoheB8HtKgMC 2aEWy9hPNMzJr0DA0xs3X+1CltAdDj5GMzqyGk9YuKLKk/hLCwUCk6wLgRUCu4HN xwoWyiSShcYZ6qeh3dPDja1bWqkmCZGjvwYBlbdKrQ== =uxqD -----END PGP SIGNATURE----- --Sig_/D0usoAWksOR_ye8KrLvETot-- From owner-freebsd-sparc64@FreeBSD.ORG Mon Apr 2 11:07:17 2012 Return-Path: Delivered-To: freebsd-sparc64@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AD9F010656D3 for ; Mon, 2 Apr 2012 11:07:17 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 985FE8FC12 for ; Mon, 2 Apr 2012 11:07:17 +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 q32B7Hpn046918 for ; Mon, 2 Apr 2012 11:07:17 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q32B7GqH046916 for freebsd-sparc64@FreeBSD.org; Mon, 2 Apr 2012 11:07:16 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 2 Apr 2012 11:07:16 GMT Message-Id: <201204021107.q32B7GqH046916@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-sparc64@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-sparc64@FreeBSD.org X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Apr 2012 11:07:17 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o sparc/165025 sparc64 [PATCH] zfsboot support for sparc64 o sparc/164227 sparc64 [boot] Can't boot 9.0-RELEASE/sparc64 on Blade 1500 o sparc/164226 sparc64 [cd] Data corruption on 9.0-RELEASE when reading from o sparc/162513 sparc64 mpt(4), mptutil(8) reports variable, erroneous drive i o sparc/141918 sparc64 [ehci] ehci_interrupt: unrecoverable error, controller s sparc/139134 sparc64 kernel output corruption s sparc/107087 sparc64 [hang] system is hung during boot from CD o sparc/105048 sparc64 [trm] trm(4) panics on sparc64 o sparc/104428 sparc64 [nullfs] nullfs panics on E4500 (but not E420) o sparc/71729 sparc64 printf in kernel thread causes panic on SPARC 10 problems total. From owner-freebsd-sparc64@FreeBSD.ORG Tue Apr 3 08:40:03 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 339A8106566C for ; Tue, 3 Apr 2012 08:40:03 +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 175F48FC14 for ; Tue, 3 Apr 2012 08:40:03 +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 q338e2Lp076998 for ; Tue, 3 Apr 2012 08:40:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q338e2fN076997; Tue, 3 Apr 2012 08:40:02 GMT (envelope-from gnats) Date: Tue, 3 Apr 2012 08:40:02 GMT Message-Id: <201204030840.q338e2fN076997@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Manuel Tobias Schiller Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Manuel Tobias Schiller List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Apr 2012 08:40:03 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Manuel Tobias Schiller To: Marius Strobl Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Tue, 3 Apr 2012 10:37:14 +0200 --Sig_/LIPyAG/wO3sJYsP6CnQl2.= Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Mon, 2 Apr 2012 10:43:14 +0200 Manuel Tobias Schiller wrote: > On Mon, 2 Apr 2012 01:00:56 +0200 > Manuel Tobias Schiller wrote: >=20 > > On Sun, 1 Apr 2012 12:41:24 +0200 > > Marius Strobl wrote: > >=20 > > > Well, the individual patches shouldn't make things worse except for > > > the second one causing more memory to be used so I'd suggest to > > > combine them. If in the end things actually work we still can check > > > what changes are needed for that. > > > Looking at the Linux USB code, the FreeBSD one doesn't some to honor > > > some DMA constraints and at least for the alignment it's actually > > > hard to follow what value eventually is used. One thing that stands > > > out is that for EHCI, the boundary is 4096. This is most easily > > > fixed by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. > > >=20 > > > Marius > >=20 > > Ok, the second patch on its own doesn't appear to work either, so I'm > > trying the combination of patches now. By the way: defining > > USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h is a bad idea - the > > kernel panics with a backtrace pointing into the mmu-related code. > > Probably has to do with sparc64 mmu only supporting 8k pages, so I'm > > not terribly surprised... Ok, I'm waiting for the next make > > buildkernel to finish, and I'll let you know what comes out. > >=20 > > Manuel >=20 > Ok, I also tested a kernel with both patches, and the issue persists. Do > you have something else to try? >=20 > Manuel > Hi Marius, I did a bit of code reading (/usr/src/sys/dev/usb/controller/ehci.c near line 1494), and I realised that the "unrecoverable error" message should only be triggered if the EHCI status register has the EHCI_STS_HCH bit set - according to the status word dump in my log, it is not set (just after the "unrecoverable error" message). The register dump re-reads the status register from the hardware. Could it be that some controllers have a glitch or something on that particular bit, and we better re-read the status register before we conclude that the controller "really wanted to set that bit"? I can also see that the bit is set in the original bug report. I don't know if that machine is just faster (and the bit has not had the time to clear yet), or if we're talking about two different problems here... (This observation might also indicate that small delay loop has to put in before I re-read the status register - we'll have to see...) I'm building a kernel with that modification, but I'd be interested in a second opinion nevertheless... Cheers, Manuel --=20 Homepage: http://www.hinterbergen.de/mala OpenPGP: 0xA330353E (DSA) or 0xD87D188C (RSA) --Sig_/LIPyAG/wO3sJYsP6CnQl2.= Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQGcBAEBAgAGBQJPera6AAoJEEPbVOqHHK4gOjkL/iKagzBm/KtB2K/lY882sK8L vkEnj4Ch5OjiauR/vWFIby23RSLJLqDGi15HCS7Ke7hEDDQjc6PhkbKfbHszIgQB MCaNbIWh+AAwGb0MXuMyCy2s9eDPwf7QULEyzg9Ib1RaXa2Ty5kSQny3qsxKRC8y ab+e+qFjKuqx+etzZQAc+qdYHZ/CgdoyXzrdr92CG1sjsywrcRYKzJIiBYoPbEfv kDhRpu0w2OuSD0Z5CMH8LAZsGWnOGwJHKotOUcp4kaat7CwqjamLfuKRjnqzEcK7 mDvuUYLuq9LwrgqfhwgLltjhQ0Zogs61AizRtyw3MeAQ6OjalbcNnBGhOzEVakZm tSGYgEulLySN/U4VCF5Dc01rMQ1nFUov1SsENhyfPkHpwHwqURGZC2W0NYbM/13/ wyK1waHulwFXk2XSyjpOlY5n8IrwYRp+SGKGM4mzWjwSfiFGmM0r8IOmpCVxbTPL ZE1fECnn7sjehI+GSuYbQgtgTawr+r0VF9Mr8hbyzg== =6AsC -----END PGP SIGNATURE----- --Sig_/LIPyAG/wO3sJYsP6CnQl2.=-- From owner-freebsd-sparc64@FreeBSD.ORG Tue Apr 3 15:10:04 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 67384106564A for ; Tue, 3 Apr 2012 15:10:04 +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 420068FC0C for ; Tue, 3 Apr 2012 15:10:04 +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 q33FA45c040960 for ; Tue, 3 Apr 2012 15:10:04 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q33FA4ro040959; Tue, 3 Apr 2012 15:10:04 GMT (envelope-from gnats) Date: Tue, 3 Apr 2012 15:10:04 GMT Message-Id: <201204031510.q33FA4ro040959@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Marius Strobl Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Marius Strobl List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Apr 2012 15:10:04 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Marius Strobl To: Manuel Tobias Schiller Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Tue, 3 Apr 2012 17:00:43 +0200 On Tue, Apr 03, 2012 at 10:37:14AM +0200, Manuel Tobias Schiller wrote: > On Mon, 2 Apr 2012 10:43:14 +0200 > Manuel Tobias Schiller wrote: > > > On Mon, 2 Apr 2012 01:00:56 +0200 > > Manuel Tobias Schiller wrote: > > > > > On Sun, 1 Apr 2012 12:41:24 +0200 > > > Marius Strobl wrote: > > > > > > > Well, the individual patches shouldn't make things worse except for > > > > the second one causing more memory to be used so I'd suggest to > > > > combine them. If in the end things actually work we still can check > > > > what changes are needed for that. > > > > Looking at the Linux USB code, the FreeBSD one doesn't some to honor > > > > some DMA constraints and at least for the alignment it's actually > > > > hard to follow what value eventually is used. One thing that stands > > > > out is that for EHCI, the boundary is 4096. This is most easily > > > > fixed by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. > > > > > > > > Marius > > > > > > Ok, the second patch on its own doesn't appear to work either, so I'm > > > trying the combination of patches now. By the way: defining > > > USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h is a bad idea - the > > > kernel panics with a backtrace pointing into the mmu-related code. > > > Probably has to do with sparc64 mmu only supporting 8k pages, so I'm > > > not terribly surprised... Ok, I'm waiting for the next make > > > buildkernel to finish, and I'll let you know what comes out. > > > > > > Manuel > > > > Ok, I also tested a kernel with both patches, and the issue persists. Do > > you have something else to try? > > > > Manuel > > > > Hi Marius, > > I did a bit of code reading (/usr/src/sys/dev/usb/controller/ehci.c near > line 1494), and I realised that the "unrecoverable error" message should > only be triggered if the EHCI status register has the EHCI_STS_HCH bit > set - according to the status word dump in my log, it is not set (just > after the "unrecoverable error" message). The register dump re-reads the > status register from the hardware. Could it be that some controllers have > a glitch or something on that particular bit, and we better re-read the > status register before we conclude that the controller "really wanted to > set that bit"? You mean EHCI_STS_HSE? This is expected, ehci_interrupt() clears the pending interrupt status bits before dumping the register content: EOWRITE4(sc, EHCI_USBSTS, status); /* acknowledge */ > I can also see that the bit is set in the original bug report. I don't > know if that machine is just faster (and the bit has not had the time to > clear yet), or if we're talking about two different problems here... Probably, the other controller just sets it again after the bit is cleared. Marius From owner-freebsd-sparc64@FreeBSD.ORG Tue Apr 3 21:20:06 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C56D61065674 for ; Tue, 3 Apr 2012 21:20:06 +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 A8C828FC1A for ; Tue, 3 Apr 2012 21:20:06 +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 q33LK6c4082758 for ; Tue, 3 Apr 2012 21:20:06 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q33LK6cF082757; Tue, 3 Apr 2012 21:20:06 GMT (envelope-from gnats) Date: Tue, 3 Apr 2012 21:20:06 GMT Message-Id: <201204032120.q33LK6cF082757@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Marius Strobl Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Marius Strobl List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Apr 2012 21:20:06 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Marius Strobl To: Manuel Tobias Schiller Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Tue, 3 Apr 2012 23:19:52 +0200 On Mon, Apr 02, 2012 at 01:00:56AM +0200, Manuel Tobias Schiller wrote: > On Sun, 1 Apr 2012 12:41:24 +0200 > Marius Strobl wrote: > > > Well, the individual patches shouldn't make things worse except for > > the second one causing more memory to be used so I'd suggest to > > combine them. If in the end things actually work we still can check > > what changes are needed for that. > > Looking at the Linux USB code, the FreeBSD one doesn't some to honor > > some DMA constraints and at least for the alignment it's actually > > hard to follow what value eventually is used. One thing that stands > > out is that for EHCI, the boundary is 4096. This is most easily fixed > > by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. > > > > Marius > > Ok, the second patch on its own doesn't appear to work either, so I'm > trying the combination of patches now. By the way: defining USB_PAGE_SIZE > to 4096 in sys/dev/usb/usb_busdma.h is a bad idea - the kernel panics with > a backtrace pointing into the mmu-related code. Probably has to do with > sparc64 mmu only supporting 8k pages, so I'm not terribly surprised... Okay, could you please give the following patch a try? http://people.freebsd.org/~marius/usb_busdma.diff Marius From owner-freebsd-sparc64@FreeBSD.ORG Wed Apr 4 12:40:04 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 86937106566B for ; Wed, 4 Apr 2012 12:40:04 +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 5FAC38FC18 for ; Wed, 4 Apr 2012 12:40:04 +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 q34Ce3GG070242 for ; Wed, 4 Apr 2012 12:40:03 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q34Ce3BG070241; Wed, 4 Apr 2012 12:40:03 GMT (envelope-from gnats) Date: Wed, 4 Apr 2012 12:40:03 GMT Message-Id: <201204041240.q34Ce3BG070241@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Manuel Tobias Schiller Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Manuel Tobias Schiller List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Apr 2012 12:40:04 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Manuel Tobias Schiller To: Marius Strobl Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Wed, 4 Apr 2012 14:38:25 +0200 --Sig_/XcvQd6ZGZTkVfcTQkvdtpVl Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Tue, 3 Apr 2012 23:19:52 +0200 Marius Strobl wrote: > On Mon, Apr 02, 2012 at 01:00:56AM +0200, Manuel Tobias Schiller wrote: > > On Sun, 1 Apr 2012 12:41:24 +0200 > > Marius Strobl wrote: > >=20 > > > Well, the individual patches shouldn't make things worse except for > > > the second one causing more memory to be used so I'd suggest to > > > combine them. If in the end things actually work we still can check > > > what changes are needed for that. > > > Looking at the Linux USB code, the FreeBSD one doesn't some to honor > > > some DMA constraints and at least for the alignment it's actually > > > hard to follow what value eventually is used. One thing that stands > > > out is that for EHCI, the boundary is 4096. This is most easily > > > fixed by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. > > >=20 > > > Marius > >=20 > > Ok, the second patch on its own doesn't appear to work either, so I'm > > trying the combination of patches now. By the way: defining > > USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h is a bad idea - the > > kernel panics with a backtrace pointing into the mmu-related code. > > Probably has to do with sparc64 mmu only supporting 8k pages, so I'm > > not terribly surprised... >=20 > Okay, could you please give the following patch a try? > http://people.freebsd.org/~marius/usb_busdma.diff >=20 > Marius Okay, I tried both my idea (which naturally did not work ;) and your patch (without my patch, so I don't screw up the results). Unfortunately, your patch does not seem to work either. From what I can tell from here at work, the machine is stuck in a reboot loop (I guess after trying to access the USB disks), but I'd like to be sure and watch the disk's LEDs for a bit when I get home tonight (to make sure that the reboot loop is really related to USB disk access). Manuel --=20 Homepage: http://www.hinterbergen.de/mala OpenPGP: 0xA330353E (DSA) or 0xD87D188C (RSA) --Sig_/XcvQd6ZGZTkVfcTQkvdtpVl Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQGcBAEBAgAGBQJPfEDBAAoJEEPbVOqHHK4gOfgL/3AvlvRfF/zVo4mg5LEa3Bl5 DoEaam/vElALUkBEWDcxaxxzjo42HaCSWYuUtDuCN1Z9vzU7lbZ3L157F/1Y1gI9 uWnWrINOauPGgwQ3dRam3ts59xGBp9IS44X5Md/2kZW5oa3qcctZ5FZy5/9zZLmd A3U4mPYiH2RXyhO3+qMGu2ZEXbSSxpiqskazQBHOYrQO1UJGuYqfqQYGuBRH3epW 8N3+/ssZTZQwqSGEzjtP8bk2JbKRAZCJ5xnQstrLPFl/ECzZ0byGRwPsZKtvqBTc bypA6vo5faiGt2S+n+ED1MBzaP2Nt9r5cQ4LH492Ch1Sl+7FLSC8xn0KCWB1DMJc ck6zigHfmcTDag5PjAyWYkt497pYOGy3TWl0C+xYrn0KtP/A83cv6LPGXEjh3M0F Nz9ELhhAXrkQh/sJRv2gubevAH+mNLipc7efExpFPwcGXTwmM/Np9vCnJb0Rh8dB C6A2V7IHHHyhiPTSsu+/wAI9gWZPnU19ubWsJcdetA== =lTLR -----END PGP SIGNATURE----- --Sig_/XcvQd6ZGZTkVfcTQkvdtpVl-- From owner-freebsd-sparc64@FreeBSD.ORG Wed Apr 4 13:00:19 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E8E3E106564A for ; Wed, 4 Apr 2012 13:00:17 +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 A1D5D8FC15 for ; Wed, 4 Apr 2012 13:00:17 +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 q34D0Hhp087509 for ; Wed, 4 Apr 2012 13:00:17 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q34D0HmH087508; Wed, 4 Apr 2012 13:00:17 GMT (envelope-from gnats) Date: Wed, 4 Apr 2012 13:00:17 GMT Message-Id: <201204041300.q34D0HmH087508@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Marius Strobl Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Marius Strobl List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Apr 2012 13:00:20 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Marius Strobl To: Manuel Tobias Schiller Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Wed, 4 Apr 2012 14:59:46 +0200 On Wed, Apr 04, 2012 at 02:38:25PM +0200, Manuel Tobias Schiller wrote: > On Tue, 3 Apr 2012 23:19:52 +0200 > Marius Strobl wrote: > > > On Mon, Apr 02, 2012 at 01:00:56AM +0200, Manuel Tobias Schiller wrote: > > > On Sun, 1 Apr 2012 12:41:24 +0200 > > > Marius Strobl wrote: > > > > > > > Well, the individual patches shouldn't make things worse except for > > > > the second one causing more memory to be used so I'd suggest to > > > > combine them. If in the end things actually work we still can check > > > > what changes are needed for that. > > > > Looking at the Linux USB code, the FreeBSD one doesn't some to honor > > > > some DMA constraints and at least for the alignment it's actually > > > > hard to follow what value eventually is used. One thing that stands > > > > out is that for EHCI, the boundary is 4096. This is most easily > > > > fixed by defining USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h. > > > > > > > > Marius > > > > > > Ok, the second patch on its own doesn't appear to work either, so I'm > > > trying the combination of patches now. By the way: defining > > > USB_PAGE_SIZE to 4096 in sys/dev/usb/usb_busdma.h is a bad idea - the > > > kernel panics with a backtrace pointing into the mmu-related code. > > > Probably has to do with sparc64 mmu only supporting 8k pages, so I'm > > > not terribly surprised... > > > > Okay, could you please give the following patch a try? > > http://people.freebsd.org/~marius/usb_busdma.diff > > > > Marius > > Okay, I tried both my idea (which naturally did not work ;) and your patch > (without my patch, so I don't screw up the results). Unfortunately, your > patch does not seem to work either. From what I can tell from here at > work, the machine is stuck in a reboot loop (I guess after trying to > access the USB disks), but I'd like to be sure and watch the disk's LEDs > for a bit when I get home tonight (to make sure that the reboot loop is > really related to USB disk access). > Hrm, okay, would be interesting to know what the machine actually does. Looking at the code I found another bug; the VIA-workaround currently doesn't do anything: http://people.freebsd.org/~marius/ehci_pci_fix_via_quirk.diff This might apply for the insane I/O you've reported but I'm unsure whether it makes a difference for the HSE interrupt. Marius From owner-freebsd-sparc64@FreeBSD.ORG Thu Apr 5 16:30:15 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8FDA11065674 for ; Thu, 5 Apr 2012 16:30:15 +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 2952A8FC22 for ; Thu, 5 Apr 2012 16:30: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 q35GUDWX051644 for ; Thu, 5 Apr 2012 16:30:13 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q35GUD87051639; Thu, 5 Apr 2012 16:30:13 GMT (envelope-from gnats) Date: Thu, 5 Apr 2012 16:30:13 GMT Message-Id: <201204051630.q35GUD87051639@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Manuel Tobias Schiller Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Manuel Tobias Schiller List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Apr 2012 16:30:15 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Manuel Tobias Schiller To: Marius Strobl Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Thu, 5 Apr 2012 18:21:24 +0200 --Sig_/=Vc_O6YUHnG+76EC7ZTtxX= Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Wed, 4 Apr 2012 14:59:46 +0200 Marius Strobl wrote: > Hrm, okay, would be interesting to know what the machine actually does. > Looking at the code I found another bug; the VIA-workaround currently > doesn't do anything: > http://people.freebsd.org/~marius/ehci_pci_fix_via_quirk.diff > This might apply for the insane I/O you've reported but I'm unsure > whether it makes a difference for the HSE interrupt. >=20 > Marius =46rom the looks of it (with your patch at http://people.freebsd.org/~marius/usb_busdma.diff), the machine starts booting, then tries to mount the filesystems residing on the USB disks, apparently does some I/O (while still processing interrupts), and after less than a minute locks up solid without any indication on the serial console as to what went wrong... I've started another build with your "VIA quirk fix" but without the patch in the last paragraph (the machine locking up is a lot worse than just USB not working after some heavy I/O, so I left it out for now), but since I started the build without being properly awake this morning, I typed "make buildworld" where I wanted to type "make buildkernel", so it's going to take some time. Also, I'll be leaving CERN over easter, so I won't be running tests on that machine from tomorrow morning until Monday evening (I can compile kernels, though). Anyhow, I'll let you know what comes out. Cheers, thanks a lot for your effort, and, of course, a Happy Easter! Manuel --=20 Homepage: http://www.hinterbergen.de/mala OpenPGP: 0xA330353E (DSA) or 0xD87D188C (RSA) --Sig_/=Vc_O6YUHnG+76EC7ZTtxX= Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQGcBAEBAgAGBQJPfcaEAAoJEEPbVOqHHK4go4oL/0xk69R8GeC3DHYSMJNEcav7 azM1/gU8YSfM1Kf8/xPsYgz2tangg8jzYMoheWThUYq6CwClL6xxQmgv++VHUqV1 BUAiHye/L2M1HmCZAD93AwyrPEPQpQ23TktVWY9y7X4cVDnmm0yqQTYvwsxJ8vMf cGtlVLdhcMc5JBjk0MvDQWQ5Doc+MsepBIStsxSxk1jtliYwGOiJCNgLOA9JVr43 9IMan1VZKD6ENbkDjoPxS0rxX5qJazCqYLBnHsQScEN/9Zqqd1UXXQhe2pLIxgPp ZOXRFyM+ctvR3dHe2FtAf70YYD6GBLa3ZY2+a7k0LPAn8X1LIlll6XiBalxrBcRE u+Ej86dAXIHZxxpdVqObAOa4gMtdpP+RGiBX3n4+jj/z9W8gvgG/AgWGnt4DGXLR Mt8LZK0sB3e5fwhs2niF1vAJR3YnO2aR0ZT+dTWYIDmSZxWo1wGkJw+Lhs/0VA5e jpmZqtu7DzDWo8170pZHbw5bpbTrXS8KlDmQMRYTMg== =zrQM -----END PGP SIGNATURE----- --Sig_/=Vc_O6YUHnG+76EC7ZTtxX=-- From owner-freebsd-sparc64@FreeBSD.ORG Fri Apr 6 08:00:32 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9CD8E106573E for ; Fri, 6 Apr 2012 08:00:28 +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 910008FC15 for ; Fri, 6 Apr 2012 08:00:28 +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 q3680SEQ040913 for ; Fri, 6 Apr 2012 08:00:28 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q3680SR8040911; Fri, 6 Apr 2012 08:00:28 GMT (envelope-from gnats) Date: Fri, 6 Apr 2012 08:00:28 GMT Message-Id: <201204060800.q3680SR8040911@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Manuel Tobias Schiller Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Manuel Tobias Schiller List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Apr 2012 08:00:32 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Manuel Tobias Schiller To: Marius Strobl Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Fri, 6 Apr 2012 09:58:42 +0200 --Sig_/USyVBnU_skI+EPlIK+Klizu Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Thu, 5 Apr 2012 18:21:24 +0200 Manuel Tobias Schiller wrote: > On Wed, 4 Apr 2012 14:59:46 +0200 > Marius Strobl wrote: >=20 > > Hrm, okay, would be interesting to know what the machine actually > > does. Looking at the code I found another bug; the VIA-workaround > > currently doesn't do anything: > > http://people.freebsd.org/~marius/ehci_pci_fix_via_quirk.diff > > This might apply for the insane I/O you've reported but I'm unsure > > whether it makes a difference for the HSE interrupt. > >=20 > > Marius >=20 > From the looks of it (with your patch at > http://people.freebsd.org/~marius/usb_busdma.diff), the machine starts > booting, then tries to mount the filesystems residing on the USB disks, > apparently does some I/O (while still processing interrupts), and after > less than a minute locks up solid without any indication on the serial > console as to what went wrong... >=20 > I've started another build with your "VIA quirk fix" but without the > patch in the last paragraph (the machine locking up is a lot worse than > just USB not working after some heavy I/O, so I left it out for now), > but since I started the build without being properly awake this > morning, I typed "make buildworld" where I wanted to type "make > buildkernel", so it's going to take some time. Also, I'll be leaving > CERN over easter, so I won't be running tests on that machine from > tomorrow morning until Monday evening (I can compile kernels, though). > Anyhow, I'll let you know what comes out. >=20 > Cheers, thanks a lot for your effort, and, of course, a Happy Easter! >=20 > Manuel Hi, the "VIA quirk fix" on its own gives the familiar message in dmesg (unrecoverable error, controller halted), so I'm compiling a kernel which combines this fix with your latest busdma fix to try them both together; as I said in my last e-mail, I'll probably not be testing this until Monday night... Manuel --=20 Homepage: http://www.hinterbergen.de/mala OpenPGP: 0xA330353E (DSA) or 0xD87D188C (RSA) --Sig_/USyVBnU_skI+EPlIK+Klizu Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQGcBAEBAgAGBQJPfqIyAAoJEEPbVOqHHK4gxKUL/3/SyPncSmzBrGgDghdAtra5 hqTTm6dtd9Pe9/6JcZWD9IhOFsrDjZzPsb0UfiZvkdXGwfyFPlo/Hygu31TyYioH tLig0DDxk5NZ3/dntGnR4o2lA58mLRSh/u9x4WqcBNkdJj/PVfE8KLi6haFsUt1b afW8UWzlP5qLszF4L7qKG+OOFjLyK5Nw9gm/U2u0jDTOxalkigT2ISdCUL9QJ8Yi +8Q+/yXxcM0/d9ZaLV8OTl52X8yDZKFSpxHePNh2jnC6xY+H40su8yZXFEbqGFcl ixClgqEu9Gk19WBI3stCPeW3jZ59aeqXM2m2Nw2BvOIant6CvsDbV+dSH5BdxKNE czDYaO2BgWYJOz5O4/9Hy6NhLv0/LPEQQyOy0S8Ind8bmNbEzXc2OYuFwbhxT7Pl g3nXNGmS/Rm6oE+IkYRb6kl7Sq9kbXukh7uzoB1vOq2OEEHY3FrQaB+DyQgz8uQN 9nVd/Xc7cn5d2MUaEtT09WQbHEZY2YTbs8TN1BvTZQ== =HeMr -----END PGP SIGNATURE----- --Sig_/USyVBnU_skI+EPlIK+Klizu-- From owner-freebsd-sparc64@FreeBSD.ORG Fri Apr 6 14:04:36 2012 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DE0041065670; Fri, 6 Apr 2012 14:04:36 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id A5AAA8FC08; Fri, 6 Apr 2012 14:04:36 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.5/8.14.5) with ESMTP id q36E4af3022097; Fri, 6 Apr 2012 10:04:36 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.5/8.14.5/Submit) id q36E4aYk022090; Fri, 6 Apr 2012 14:04:36 GMT (envelope-from tinderbox@freebsd.org) Date: Fri, 6 Apr 2012 14:04:36 GMT Message-Id: <201204061404.q36E4aYk022090@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Apr 2012 14:04:37 -0000 TB --- 2012-04-06 12:55:13 - tinderbox 2.9 running on freebsd-current.sentex.ca TB --- 2012-04-06 12:55:13 - FreeBSD freebsd-current.sentex.ca 8.3-PRERELEASE FreeBSD 8.3-PRERELEASE #0: Mon Mar 26 13:54:12 EDT 2012 des@freebsd-current.sentex.ca:/usr/obj/usr/src/sys/GENERIC amd64 TB --- 2012-04-06 12:55:13 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2012-04-06 12:55:13 - cleaning the object tree TB --- 2012-04-06 12:55:13 - cvsupping the source tree TB --- 2012-04-06 12:55:13 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2012-04-06 12:56:16 - building world TB --- 2012-04-06 12:56:16 - CROSS_BUILD_TESTING=YES TB --- 2012-04-06 12:56:16 - MAKEOBJDIRPREFIX=/obj TB --- 2012-04-06 12:56:16 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2012-04-06 12:56:16 - SRCCONF=/dev/null TB --- 2012-04-06 12:56:16 - TARGET=sparc64 TB --- 2012-04-06 12:56:16 - TARGET_ARCH=sparc64 TB --- 2012-04-06 12:56:16 - TZ=UTC TB --- 2012-04-06 12:56:16 - __MAKE_CONF=/dev/null TB --- 2012-04-06 12:56:16 - cd /src TB --- 2012-04-06 12:56:16 - /usr/bin/make -B buildworld >>> World build started on Fri Apr 6 12:56:17 UTC 2012 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries >>> stage 4.3: make dependencies >>> stage 4.4: building everything >>> World build completed on Fri Apr 6 13:54:35 UTC 2012 TB --- 2012-04-06 13:54:35 - generating LINT kernel config TB --- 2012-04-06 13:54:35 - cd /src/sys/sparc64/conf TB --- 2012-04-06 13:54:35 - /usr/bin/make -B LINT TB --- 2012-04-06 13:54:35 - cd /src/sys/sparc64/conf TB --- 2012-04-06 13:54:35 - /usr/sbin/config -m LINT TB --- 2012-04-06 13:54:35 - building LINT kernel TB --- 2012-04-06 13:54:35 - CROSS_BUILD_TESTING=YES TB --- 2012-04-06 13:54:35 - MAKEOBJDIRPREFIX=/obj TB --- 2012-04-06 13:54:35 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2012-04-06 13:54:35 - SRCCONF=/dev/null TB --- 2012-04-06 13:54:35 - TARGET=sparc64 TB --- 2012-04-06 13:54:35 - TARGET_ARCH=sparc64 TB --- 2012-04-06 13:54:35 - TZ=UTC TB --- 2012-04-06 13:54:35 - __MAKE_CONF=/dev/null TB --- 2012-04-06 13:54:35 - cd /src TB --- 2012-04-06 13:54:35 - /usr/bin/make -B buildkernel KERNCONF=LINT >>> Kernel build for LINT started on Fri Apr 6 13:54:36 UTC 2012 >>> stage 1: configuring the kernel >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3.1: making dependencies >>> stage 3.2: building everything [...] cc -c -O2 -pipe -fno-strict-aliasing -std=c99 -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc -I. -I/src/sys -I/src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=15000 --param inline-unit-growth=100 --param large-function-growth=1000 -fno-builtin -mcmodel=medany -msoft-float -ffreestanding -fstack-protector -Werror /src/sys/libkern/strtoul.c cc -c -O2 -pipe -fno-strict-aliasing -std=c99 -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc -I. -I/src/sys -I/src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=15000 --param inline-unit-growth=100 --param large-function-growth=1000 -fno-builtin -mcmodel=medany -msoft-float -ffreestanding -fstack-protector -Werror /src/sys/libkern/strtouq.c cc -c -O2 -pipe -fno-strict-aliasing -std=c99 -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc -I. -I/src/sys -I/src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=15000 --param inline-unit-growth=100 --param large-function-growth=1000 -fno-builtin -mcmodel=medany -msoft-float -ffreestanding -fstack-protector -Werror /src/sys/libkern/strvalid.c cc -c -O2 -pipe -fno-strict-aliasing -std=c99 -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc -I. -I/src/sys -I/src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=15000 --param inline-unit-growth=100 --param large-function-growth=1000 -fno-builtin -mcmodel=medany -msoft-float -ffreestanding -fstack-protector -Werror /src/sys/net/bpf.c /src/sys/net/bpf.c: In function 'bpf_setf': /src/sys/net/bpf.c:1683: error: 'need_upgrade' undeclared (first use in this function) /src/sys/net/bpf.c:1683: error: (Each undeclared identifier is reported only once /src/sys/net/bpf.c:1683: error: for each function it appears in.) *** Error code 1 Stop in /obj/sparc64.sparc64/src/sys/LINT. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2012-04-06 14:04:35 - WARNING: /usr/bin/make returned exit code 1 TB --- 2012-04-06 14:04:35 - ERROR: failed to build LINT kernel TB --- 2012-04-06 14:04:35 - 3412.92 user 536.10 system 4162.59 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Fri Apr 6 18:40:13 2012 Return-Path: Delivered-To: freebsd-sparc64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4D4D7106566B for ; Fri, 6 Apr 2012 18:40:13 +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 997FE8FC0C for ; Fri, 6 Apr 2012 18:40:12 +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 q36IeCTP042550 for ; Fri, 6 Apr 2012 18:40:12 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q36IeC2s042548; Fri, 6 Apr 2012 18:40:12 GMT (envelope-from gnats) Date: Fri, 6 Apr 2012 18:40:12 GMT Message-Id: <201204061840.q36IeC2s042548@freefall.freebsd.org> To: freebsd-sparc64@FreeBSD.org From: Marius Strobl Cc: Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Marius Strobl List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Apr 2012 18:40:13 -0000 The following reply was made to PR sparc64/141918; it has been noted by GNATS. From: Marius Strobl To: Manuel Tobias Schiller Cc: bug-followup@FreeBSD.org Subject: Re: sparc64/141918: [ehci] ehci_interrupt: unrecoverable error, controller halted (sparc64) Date: Fri, 6 Apr 2012 20:37:26 +0200 --TRYliJ5NKNqkz5bu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Apr 06, 2012 at 09:58:42AM +0200, Manuel Tobias Schiller wrote: > On Thu, 5 Apr 2012 18:21:24 +0200 > Manuel Tobias Schiller wrote: > > > On Wed, 4 Apr 2012 14:59:46 +0200 > > Marius Strobl wrote: > > > > > Hrm, okay, would be interesting to know what the machine actually > > > does. Looking at the code I found another bug; the VIA-workaround > > > currently doesn't do anything: > > > http://people.freebsd.org/~marius/ehci_pci_fix_via_quirk.diff > > > This might apply for the insane I/O you've reported but I'm unsure > > > whether it makes a difference for the HSE interrupt. > > > > > > Marius > > > > From the looks of it (with your patch at > > http://people.freebsd.org/~marius/usb_busdma.diff), the machine starts > > booting, then tries to mount the filesystems residing on the USB disks, > > apparently does some I/O (while still processing interrupts), and after > > less than a minute locks up solid without any indication on the serial > > console as to what went wrong... > > > > I've started another build with your "VIA quirk fix" but without the > > patch in the last paragraph (the machine locking up is a lot worse than > > just USB not working after some heavy I/O, so I left it out for now), > > but since I started the build without being properly awake this > > morning, I typed "make buildworld" where I wanted to type "make > > buildkernel", so it's going to take some time. Also, I'll be leaving > > CERN over easter, so I won't be running tests on that machine from > > tomorrow morning until Monday evening (I can compile kernels, though). > > Anyhow, I'll let you know what comes out. > > > > Cheers, thanks a lot for your effort, and, of course, a Happy Easter! > > > > Manuel > > Hi, > > the "VIA quirk fix" on its own gives the familiar message in dmesg > (unrecoverable error, controller halted), so I'm compiling a kernel which Oof, this likely means there's a more basic problem with this device. Have you already tried to re-seat the card in case there's an electrical problem? Please also provide the output of `pciconf -rb ehci0@pci0:2:5:2 0:255' from a booting kernel. FYI, after some digging I've found the following card ehci0@pci0:2:5:2: class=0x0c0320 card=0x31041106 chip=0x31041106 rev=0x6h0 which is a newer revision of your device and works just fine in a T1-200 including with the usb(4) fixes. The publicly available datasheets for the VIA USB controllers are minimal and exclude errata and Linux also doesn't seem to use any additional work arounds, so I'm starting to run out of ideas what could be wrong with your revision. The only remaining thing to give a try I currently can think of is to test whether it chokes on the generic initialization done by the sparc64 PCI code using the attached patch. > combines this fix with your latest busdma fix to try them both together; This combination is unlikely to make a difference. Marius --TRYliJ5NKNqkz5bu Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="skip_via.diff" Index: ofw_pcibus.c =================================================================== --- ofw_pcibus.c (revision 233234) +++ ofw_pcibus.c (working copy) @@ -133,6 +133,13 @@ ofw_pcibus_setup_device(device_t bridge, uint32_t #ifndef SUN4V uint32_t reg; + if ((CS_READ(PCIR_VENDOR, 2) == 0x1106 && + CS_READ(PCIR_DEVICE, 2) == 0x3104)) { + device_printf(bridge, "skipping %d/%d/%d\n", busno, slot, + func); + goto skip; + } + /* * Initialize the latency timer register for busmaster devices to * work properly. This is another task which the firmware doesn't @@ -210,6 +217,7 @@ ofw_pcibus_setup_device(device_t bridge, uint32_t CS_READ(PCIR_DEVICE, 2) == 0x5229)) CS_WRITE(0x50, CS_READ(0x50, 1) | 0x3, 1); + skip: /* * The preset in the intline register is usually wrong. Reset * it to 255, so that the PCI code will reroute the interrupt if --TRYliJ5NKNqkz5bu--