From owner-freebsd-current@FreeBSD.ORG Mon Dec 14 11:27:59 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B0CE7106566C; Mon, 14 Dec 2009 11:27:59 +0000 (UTC) (envelope-from mavbsd@gmail.com) Received: from fg-out-1718.google.com (fg-out-1718.google.com [72.14.220.156]) by mx1.freebsd.org (Postfix) with ESMTP id 18DAD8FC08; Mon, 14 Dec 2009 11:27:58 +0000 (UTC) Received: by fg-out-1718.google.com with SMTP id 16so887079fgg.13 for ; Mon, 14 Dec 2009 03:27:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:message-id:date:from :user-agent:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=MqPDx+aCt7zkIcrnrFTHwRoPvseclwymxdF1r+c0W4A=; b=hhK1ReA58g0QL/QB7GntnH67QRXV+wGYDG0vY8ObMNydIQwjhc7IBvu1POqlZXoLka SjkjZ4+YPxXqoH6zbZjprH2OJI1ieuvyNz7+RLvutMLo23gyqYjggT6CrR7Ehf2sKC67 SPIsvVEUsP3/kATgfwBz5Fj3QZuHfTIVlJXrI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=LEH0WME9va30YuyHmHi1azOcWF+DTPhFEKViD9ar5iKctQTZDsjDVZ/TrlwfGMpN+i 6MbxpsMqYhjU808h8X/VgCt1QHrrvirnQ4H/Eco0nnaxwpQVyebxLeDbLpjsCwn5kUv3 c5tSns3vrz7SOgZJqv74LbUxLmm+/pbRIc9X4= Received: by 10.86.6.24 with SMTP id 24mr1976623fgf.67.1260790076937; Mon, 14 Dec 2009 03:27:56 -0800 (PST) Received: from mavbook.mavhome.dp.ua (pc.mavhome.dp.ua [212.86.226.226]) by mx.google.com with ESMTPS id 16sm1495332fxm.0.2009.12.14.03.27.55 (version=SSLv3 cipher=RC4-MD5); Mon, 14 Dec 2009 03:27:55 -0800 (PST) Sender: Alexander Motin Message-ID: <4B262119.6090904@FreeBSD.org> Date: Mon, 14 Dec 2009 13:27:21 +0200 From: Alexander Motin User-Agent: Thunderbird 2.0.0.23 (X11/20090901) MIME-Version: 1.0 To: Ivan Voras References: <1258575782.00184876.1258562404@10.7.7.3> <1258579386.00184908.1258567802@10.7.7.3> <1258590193.00184983.1258579804@10.7.7.3> In-Reply-To: <1258590193.00184983.1258579804@10.7.7.3> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: FreeBSD-Current Subject: Re: How do I use NCQ of Intel X25-E(SSD) on ahci(4)? 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: Mon, 14 Dec 2009 11:27:59 -0000 Ivan Voras wrote: > 2009/11/18 Alexander Motin : >> Ivan Voras wrote: > >>> I know next to nothing about AHCI and drivers so this might be obviously >>> wrong but wouldn't a quick (i.e. MFC-able) obvious temporary fix be to say >>> >>> numslots = min(get_minimum_tags_of_all_drives(), ...) >>> ? >> Problem is that SIM driver has no idea about devices capabilities, and >> also doesn't have method to resize queue after attach. In SCSI case, >> tags are random and only simultaneous number of request is limited, and >> this is handled fine by CAM. SATA NCQ is more restrictive, allowing to >> use only tags 0..(N-1). I am planning to make XPT inform SIM about >> supported tags for each device, to allow SIM to use that information >> while scheduling requests. I didn't do it yet, just because most of >> devices able to handle all 32 tags possible on SATA. This Intel SSD is >> one of rare exceptions. > > Ok, (still thinking about something that could be MFC-able in an > emergency), how about adding a loader tunable integer instead of "32"? Just for note, it is already fixed and merged. -- Alexander Motin