From owner-svn-doc-all@FreeBSD.ORG Sun Apr 12 00:07:00 2015 Return-Path: Delivered-To: svn-doc-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 89A7B7FE; Sun, 12 Apr 2015 00:07:00 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 75591A70; Sun, 12 Apr 2015 00:07:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t3C070G7018236; Sun, 12 Apr 2015 00:07:00 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t3C070ws018235; Sun, 12 Apr 2015 00:07:00 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201504120007.t3C070ws018235@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Apr 2015 00:07:00 +0000 (UTC) To: doc-committers@freebsd.org, svn-doc-all@freebsd.org, svn-doc-head@freebsd.org Subject: svn commit: r46517 - head/en_US.ISO8859-1/books/arch-handbook/scsi X-SVN-Group: doc-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-doc-all@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: "SVN commit messages for the entire doc trees \(except for " user" , " projects" , and " translations" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Apr 2015 00:07:00 -0000 Author: imp Date: Sun Apr 12 00:06:59 2015 New Revision: 46517 URL: https://svnweb.freebsd.org/changeset/doc/46517 Log: Update some obsolete references in the CAM / SCSI stuff. Modified: head/en_US.ISO8859-1/books/arch-handbook/scsi/chapter.xml Modified: head/en_US.ISO8859-1/books/arch-handbook/scsi/chapter.xml ============================================================================== --- head/en_US.ISO8859-1/books/arch-handbook/scsi/chapter.xml Sun Apr 12 00:06:58 2015 (r46516) +++ head/en_US.ISO8859-1/books/arch-handbook/scsi/chapter.xml Sun Apr 12 00:06:59 2015 (r46517) @@ -147,7 +147,7 @@ struct cam_sim *sim; if(( sim = cam_sim_alloc(action_func, poll_func, driver_name, - softc, unit, max_dev_transactions, + softc, unit, mtx, max_dev_transactions, max_tagged_dev_transactions, devq) )==NULL) { cam_simq_free(devq); error; /* some code to handle the error */ @@ -217,11 +217,18 @@ unit - the controller unit number, for example - for controller wds0 this number will be + for controller mps0 this number will be 0 + mtx - Lock associated with this SIM. For SIMs that don't + know about locking, pass in Giant. For SIMs that do, pass in + the lock used to guard this SIM's data structures. This lock + will be held when xxx_action and xxx_poll are called. + + + max_dev_transactions - maximal number of simultaneous transactions per SCSI target in the non-tagged mode. This value will be almost universally equal to 1, with possible @@ -248,7 +255,7 @@ Finally we register the SCSI buses associated with our SCSI adapterSCSIadapter: - if(xpt_bus_register(sim, bus_number) != CAM_SUCCESS) { + if(xpt_bus_register(sim, softc, bus_number) != CAM_SUCCESS) { cam_sim_free(sim, /*free_devq*/ TRUE); error; /* some code to handle the error */ } @@ -505,6 +512,11 @@ back to CAM). This flag is not used anywhere in the CAM code now, so its purpose is purely diagnostic. + + + CAM_QOS_VALID - The QOS data + is now valid. + The function xxx_action() is not @@ -728,27 +740,14 @@ CCB or pointed to, in the latter case the pointer may be physical or virtual. Since the hardware commonly needs physical address we always convert the address to the - physical one. + physical one, typically using the busdma API. - A NOT-QUITE RELATED NOTE: Normally this is done by a - call to vtophys(), but for the PCI - device (which account for most of the SCSI controllers now) - drivers' portability to the Alpha architecture the - conversion must be done by vtobus() - instead due to special Alpha quirks. [IMHO it would be much - better to have two separate functions, - vtop() and - ptobus() then - vtobus() would be a simple - superposition of them.] In case if a physical address is + In case if a physical address is requested it is OK to return the CCB with the status CAM_REQ_INVALID, the current drivers - do that. But it is also possible to compile the - Alpha-specific piece of code, as in this example (there - should be a more direct way to do that, without conditional - compilation in the drivers). If necessary a physical - address can be also converted or mapped back to a virtual - address but with big pain, so we do not do that. + do that. If necessary a physical address can be also + converted or mapped back to a virtual address but with + big pain, so we do not do that. if(ccb_h->flags & CAM_CDB_POINTER) { /* CDB is a pointer */ @@ -757,11 +756,7 @@ hcb->cmd = vtobus(csio->cdb_io.cdb_ptr); } else { /* CDB pointer is physical */ -#if defined(__alpha__) - hcb->cmd = csio->cdb_io.cdb_ptr | alpha_XXX_dmamap_or ; -#else hcb->cmd = csio->cdb_io.cdb_ptr ; -#endif } } else { /* CDB is in the ccb (buffer) */