Date: Wed, 15 Feb 2012 17:50:49 +0100 From: Victor Balada Diaz <victor@bsdes.net> To: Scott Long <scottl@samsco.org> Cc: Harald Schmalzbauer <h.schmalzbauer@omnilan.de>, Alexander Motin <mav@freebsd.org>, freebsd-stable@freebsd.org, Jeremy Chadwick <freebsd@jdc.parodius.com>, Claudius Herder <claudius@ambtec.de> Subject: Re: problems with AHCI on FreeBSD 8.2 Message-ID: <20120215165049.GW2010@equilibrium.bsdes.net> In-Reply-To: <6D5E973B-6D98-41D7-B5E9-64A497F0F9F5@samsco.org> References: <20120214100513.GA94501@icarus.home.lan> <20120214135435.GQ2010@equilibrium.bsdes.net> <20120214141601.GA98986@icarus.home.lan> <4F3A83DE.3000200@ambtec.de> <20120214165029.GA1852@icarus.home.lan> <4F3A971F.9040407@omnilan.de> <20120214221527.GT2010@equilibrium.bsdes.net> <20120214230958.GA8434@icarus.home.lan> <20120214233420.GU2010@equilibrium.bsdes.net> <6D5E973B-6D98-41D7-B5E9-64A497F0F9F5@samsco.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Feb 14, 2012 at 04:42:47PM -0700, Scott Long wrote: > On Feb 14, 2012, at 4:34 PM, Victor Balada Diaz wrote: > > On Tue, Feb 14, 2012 at 03:09:58PM -0800, Jeremy Chadwick wrote: > >> I took a stab at this, but I don't feel confident this is the proper > >> solution/method. I worry there's some sort of chicken-or-the-egg > >> condition here (quirk setup/matching comes *after* SATA capabilities > >> detection), or that it makes the code messier. Need mav@'s > >> recommendations on this. > >> > >> Below is for RELENG_8. I should note I haven't tested if this works, or > >> even compiles -- normally I don't provide such patches without testing > >> so I apologise in advance / user beware. > > > > You're amazingly fast. Thanks for all your help :) > > > > You start applying the quirks before > > > > snprintf(announce_buf, sizeof(announce_buf), > > "kern.cam.ada.%d.quirks", periph->unit_number); > > quirks = softc->quirks; > > TUNABLE_INT_FETCH(announce_buf, &quirks); > > > > So you're breaking quirk setting at boot time. > > > > See my attached patch. I can confirm it works for me. > > > > Regards. > > > > I don't think that disabling NCQ entirely is the right solution. It's a tag starvation issue in the firmware, not a complete failure, and it can be dealt with in the CAM XPT scheduler fairly efficiently. Alexander and I talked about this recently, and though we differ on the details, a tag hack is not in order, IMHO. In the short term, try just using "cam control tags ada0 -N 1" to limit the concurrent commands to 1. > > Scott Seems changing tags on both disks doesn't fix the issue: (ada0:ahcich0:0:0:0): Request requeued (ada0:ahcich0:0:0:0): Retrying command ahcich1: Timeout on slot 0 ahcich1: is 00000000 cs 00000001 ss 00000000 rs 00000001 tfd c0 serr 00000000 ahcich1: AHCI reset... ahcich1: SATA connect time=0ms status=00000123 ahcich1: ready wait time=18ms ahcich1: AHCI reset done: device found (ada1:ahcich1:0:0:0): Request requeued (ada1:ahcich1:0:0:0): Retrying command (ada1:ahcich1:0:0:0): Command timed out (ada1:ahcich1:0:0:0): Retrying command ahcich0: Timeout on slot 30 ahcich0: is 00000000 cs c0000000 ss 00000000 rs c0000000 tfd c0 serr 00000000 ahcich0: AHCI reset... ahcich0: SATA connect time=0ms status=00000123 ahcich0: ready wait time=18ms ahcich0: AHCI reset done: device found The only difference is that now i get "Request requeued" message. -- La prueba más fehaciente de que existe vida inteligente en otros planetas, es que no han intentado contactar con nosotros.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120215165049.GW2010>