From owner-freebsd-current@FreeBSD.ORG Fri Jun 5 16:01:02 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 64B47106566B; Fri, 5 Jun 2009 16:01:02 +0000 (UTC) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.freebsd.org (Postfix) with ESMTP id 35CC68FC12; Fri, 5 Jun 2009 16:01:02 +0000 (UTC) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.14.2/8.14.1) with ESMTP id n55G11dq075737; Fri, 5 Jun 2009 09:01:01 -0700 (PDT) Received: (from dillon@localhost) by apollo.backplane.com (8.14.2/8.13.4/Submit) id n55G10Mi075734; Fri, 5 Jun 2009 09:01:00 -0700 (PDT) Date: Fri, 5 Jun 2009 09:01:00 -0700 (PDT) From: Matthew Dillon Message-Id: <200906051601.n55G10Mi075734@apollo.backplane.com> To: Alexander Motin , FreeBSD-Current , freebsd-arch@freebsd.org References: <4A254B45.8050800@mavhome.dp.ua> <200906050703.n5573x5Q071765@apollo.backplane.com> Cc: Subject: Re: WIP: ATA to CAM integration 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: Fri, 05 Jun 2009 16:01:02 -0000 More on the port multiplier spec. It turns out that the port-multiplier port selector is in the command table, so it is per command-tag. There is confusion in the spec though: section 9.1: In this mode of operation, a communication path is opened between the HBA and a device through the Port Multiplier. Since Port Multipliers are meant to be simple, the burden of making a connection is on the AHCI software, to ensure that multiple commands are not outstanding to different devices behind the Port Multiplier. section 9.1.2: "Since queued commands result in two different operations (command issue, clear of BSY, then data transfer), if commands were sent to different ports, the Port Multiplier may issue FISes back to the HBA in an interleaved manner from different ports. This will break an HBA that only supports command-based switching. Therefore, when executing native command queueing commands, system software must only add commands to the command list that target a single port behind the Port Multiplier, wait for the commands to finish (PxSACT bits all cleared), then add commands for a different port. Additionally, the tags used must match the command slot entries." -- It's unclear to me what this means. Can we use NCQ to queue multiple commands to multiple ports behind a single port multiplier in parallel or can't we? It's very confusing. -Matt