1、ANSI INCITS 366-2003for Information Technology SCSI Architecture Model - 2 (SAM-2)ANSIINCITS 366-2003ANSIINCITS 366-2003American National Standardfor Information Technology SCSI Architecture Model - 2 (SAM-2)SecretariatInformation Technology Industry Council (ITI)Approved April 2, 2003American Natio
2、nal Standards Institute, Inc.AbstractThis standard specifies the SCSI Architecture Model. The purpose of the architecture is to provide a com-mon basis for the coordination of SCSI standards and to specify those aspects of SCSI I/O system behav-ior that are independent of a particular technology and
3、 common to all implementations.Approval of an American National Standard requires review by ANSI that therequirements for due process, consensus, and other criteria for approval havebeen met by the standards developer.Consensus is established when, in the judgement of the ANSI Board ofStandards Revi
4、ew, substantial agreement has been reached by directly andmaterially affected interests. Substantial agreement means much more thana simple majority, but not necessarily unanimity. Consensus requires that allviews and objections be considered, and that a concerted effort be madetowards their resolut
5、ion.The use of American National Standards is completely voluntary; theirexistence does not in any respect preclude anyone, whether he has approvedthe standards or not, from manufacturing, marketing, purchasing, or usingproducts, processes, or procedures not conforming to the standards.The American
6、National Standards Institute does not develop standards andwill in no circumstances give an interpretation of any American NationalStandard. Moreover, no person shall have the right or authority to issue aninterpretation of an American National Standard in the name of the AmericanNational Standards
7、Institute. Requests for interpretations should beaddressed to the secretariat or sponsor whose name appears on the titlepage of this standard.CAUTION NOTICE: This American National Standard may be revised orwithdrawn at any time. The procedures of the American National StandardsInstitute require tha
8、t action be taken periodically to reaffirm, revise, orwithdraw this standard. Purchasers of American National Standards mayreceive current information on all standards by calling or writing the AmericanNational Standards Institute.American National StandardPublished byAmerican National Standards Ins
9、titute, Inc.25 West 43rd Street, New York, NY 10036Copyright 2003 by Information Technology Industry Council (ITI)All rights reserved.No part of this publication may be reproduced in anyform, in an electronic retrieval system or otherwise,without prior written permission of ITI, 1250 Eye Street NW,
10、Washington, DC 20005. Printed in the United States of AmericaCAUTION: The developers of this standard have requested that holders of patents that may berequired for the implementation of the standard disclose such patents to the publisher. However,neither the developers nor the publisher have undert
11、aken a patent search in order to identifywhich, if any, patents may apply to this standard. As of the date of publication of this standardand following calls for the identification of patents that may be required for the implementation ofthe standard, no such claims have been made. No further patent
12、 search is conducted by the de-veloper or publisher in respect to any standard it processes. No representation is made or impliedthat licenses are not required to avoid infringement in the use of this standard.iContentsPageForeword.vi1 Scope. 11.1 Introduction. 11.2 Requirements precedence . 11.3 SC
13、SI standards family 22 Normative references. 52.1 Normative references . 52.2 Approved references 52.3 References under development . 53 Definitions, symbols, abbreviations, and conventions . 63.1 Definitions. 63.2 Acronyms 133.3 Keywords 133.4 Editorial conventions 143.5 Numeric conventions 143.6 N
14、otation conventions 153.6.1 Hierarchy diagram conventions . 153.6.2 Notation for procedures and functions. 153.6.3 Notation for state diagrams . 164 SCSI Architecture Model 184.1 Introduction. 184.2 The SCSI distributed service model . 194.3 The SCSI client-server model. 204.4 The SCSI structural mo
15、del . 214.5 SCSI domain 234.6 The service delivery subsystem . 234.6.1 The service delivery subsystem object 234.6.2 Synchronizing client and server states 244.6.3 Request/Response ordering 244.7 SCSI devices 254.7.1 SCSI initiator device 254.7.2 SCSI target device. 264.7.3 SCSI target/initiator dev
16、ice 274.7.4 SCSI port identifier 274.7.5 SCSI task router 284.7.6 SCSI device name. 284.7.7 SCSI port name. 284.8 Logical units 294.9 Logical unit numbers 304.9.1 Logical unit numbers overview 304.9.2 LUN 0 address. 304.9.3 Single level logical unit number structure 304.9.4 Eight byte logical unit n
17、umber structure 324.9.5 Logical unit addressing method. 344.9.6 Peripheral device addressing method . 344.9.7 Flat space addressing method 354.9.8 Extended logical unit addressing. 36ii4.9.9 Well known logical unit addressing 384.10 Tasks 394.10.1 The task object 394.10.2 Task tags. 394.11 The nexus
18、 object 404.12 SCSI ports 414.12.1 SCSI port configurations 414.12.2 SCSI devices with multiple ports . 414.12.3 Multiple port target SCSI device structure . 424.12.4 Multiple port initiator SCSI device structure. 434.12.5 Multiple port target/initiator SCSI device structure 444.12.6 SCSI initiator
19、device view of a multiple port SCSI target device . 454.12.7 SCSI target device view of a multiple port SCSI initiator device . 474.13 Model for dependent logical units. 484.14 The SCSI model for distributed communications . 505 SCSI Command Model 535.1 The Execute Command remote procedure 535.2 Com
20、mand descriptor block (CDB) 555.2.1 CDB format 555.2.2 OPERATION CODE byte. 555.2.3 CONTROL byte. 565.3 Status . 575.3.1 Status codes 575.3.2 Status precedence. 595.4 SCSI transport protocol services in support of Execute Command 605.4.1 Overview 605.4.2 Execute Command request/confirmation SCSI tra
21、nsport protocol services 605.4.3 Data transfer SCSI transport protocol services . 625.4.3.1 Introduction. 625.4.3.2 Data-In delivery service 635.4.3.3 Data-Out delivery service . 645.5 Task and command lifetimes 645.6 Task management function lifetime 655.7 Aborting tasks. 655.7.1 Mechanisms that ca
22、use tasks to be aborted . 655.7.2 When a SCSI initiator port aborts its own tasks 665.7.3 When a SCSI initiator port aborts tasks from other SCSI initiator ports 665.8 Command processing examples 675.8.1 Unlinked command example . 675.8.2 Linked command example. 685.9 Command processing consideratio
23、ns and exception conditions 695.9.1 Contingent allegiance (CA) and auto contingent allegiance (ACA) . 695.9.1.1 Overview. 695.9.1.2 Establishing a CA or ACA. 705.9.1.3 Handling tasks when neither CA or ACA is in effect. 715.9.1.4 Handling new tasks from the faulted initiator port when CA or ACA is i
24、n effect . 715.9.1.5 Handling new tasks from non-faulted initiator ports when CA or ACA is in effect 725.9.1.5.1 Commands permitted from non-faulted initiator ports during CA or ACA 725.9.1.5.2 Handling new tasks from non-faulted initiator ports when CA or ACA is in effect . 735.9.1.6 Clearing a CA
25、condition 755.9.1.7 Clearing an ACA condition . 755.9.2 Overlapped commands . 755.9.3 Incorrect logical unit selection . 76iii5.9.4 Sense data 775.9.4.1 Sense data introduction 775.9.4.2 Asynchronous event reporting 775.9.4.3 Autosense. 785.9.5 Unit Attention condition 795.9.6 Hard reset 805.9.7 Log
26、ical unit reset . 806 Task management functions 816.1 Introduction. 816.2 ABORT TASK. 826.3 ABORT TASK SET. 826.4 CLEAR ACA . 836.5 CLEAR TASK SET . 836.6 LOGICAL UNIT RESET 846.7 TARGET RESET 846.8 WAKEUP 856.9 Task management SCSI transport protocol services . 856.10 Task management function examp
27、le 877 Task Set Management. 887.1 Introduction to task set management . 887.2 Controlling task set management . 887.3 Task management events 897.4 Task states . 897.4.1 Overview 897.4.1.1 Task state nomenclature 897.4.1.2 Suspended information. 897.4.2 Enabled task state . 907.4.3 Blocked task state
28、 . 907.4.4 Dormant task state 907.4.5 Ended task state 907.4.6 Task states and task lifetimes . 917.5 Task attributes 917.5.1 Simple task 917.5.2 Ordered task 917.5.3 Head of queue task . 917.5.4 ACA task 927.6 Task state transitions 927.7 Task set management examples 937.7.1 Introduction 937.7.2 He
29、ad of queue tasks 947.7.3 Ordered tasks 967.7.4 ACA task 97AnnexesA Identifiers and names for objects 98B Terminology mapping . 102ivTablesPage1 Single level logical unit number structure for 256 or fewer logical units. 302 Single level logical unit number structure for 257 to 16 384 logical units.
30、313 Eight byte logical unit number structure adjustments. 324 Eight Byte logical unit number structure. 335 Format of addressing fields 336 ADDRESS METHOD field values. 347 Logical unit addressing. 348 Peripheral device addressing. 359 Flat space addressing 3610 Extended logical unit addressing 3611
31、 LENGTH field values. 3612 Two byte extended logical unit addressing format . 3713 Four byte extended logical unit addressing format. 3714 Six byte extended logical unit addressing format. 3715 Eight byte extended logical unit addressing format 3716 Logical unit extended address methods. 3717 Well k
32、nown logical unit extended address format 3818 Mapping nexus to SAM-2 identifiers. 4019 Command Descriptor Block (CDB) Format 5520 OPERATION CODE byte . 5521 Group Code values 5622 CONTROL byte . 5623 Status codes. 5724 Autosense, CA, and ACA Interactions . 6925 Blocking and aborting tasks when a CA
33、 or ACA is established . 7026 Task handling when neither CA nor ACA is in effect 7127 Handling for new tasks from a faulted initiator port during CA . 7128 Handling for new tasks from a faulted initiator port during ACA. 7229 Handling for new tasks from non-faulted initiator ports during CA . 7330 H
34、andling for new tasks from non-faulted initiator ports during ACA. 7431 Task Management Functions. 8132 Task State Nomenclature. 8933 Task attribute and state indications in examples 9434 Dormant task blocking boundary requirements 96vFiguresPage1 Requirements precedence . 12 SCSI document structure
35、 . 23 Example hierarchy diagram154 Example state diagram.165 Client-Server model196 SCSI client-server model207 SCSI I/O system and domain model 218 Overall SCSI domain model .229 SCSI domain model2310 Service delivery subsystem model .2311 SCSI initiator device model 2512 SCSI target device model.2
36、613 SCSI target/initiator device model 2714 Logical unit model.2915 Eight Byte logical unit number structure adjustments.3216 SCSI device functional models.4117 Multiple port target SCSI device structure model .4218 Multiple port SCSI initiator device structure model.4319 Multiple port target/initia
37、tor SCSI device structure model.4420 SCSI target device configured in a single SCSI domain 4521 SCSI target device configured in multiple SCSI domains.4622 SCSI target device and SCSI initiator device configured in a single SCSI domain 4623 Dependent logical unit model .4824 Example of hierarchical
38、system diagram4925 Protocol service reference model .5026 Protocol service model .5127 Request-Response ULP transaction and related LLP services5228 Model for Data-In and Data-Out data transfers 6229 Command processing events .6730 Linked command processing events 6831 Task management processing eve
39、nts8732 Example of Dormant state task behavior9133 Task states .9234 Head of queue tasks and blocking boundaries (example 1).94vi35 Head of queue tasks and blocking boundaries (example 2) .9536 Ordered tasks and blocking boundaries .9637 ACA task example 97viiForeword (This foreword is not part of A
40、NSI INCITS 366-2003.)The purpose of this standard is to provide a basis for the coordination of SCSIstandards development and to define requirements, common to all SCSI technol-ogies and implementations that are essential for compatibility with host SCSI appli-cation software and device-resident fir
41、mware across all SCSI transport protocols.These requirements are defined through a reference model that specifies thebehavior and abstract structure that is generic to all SCSI I/O system implementa-tions.With any technical document there may arise questions of interpretation as newproducts are impl
42、emented. INCITS has established procedures to issue technicalopinions concerning the standards developed by INCITS These procedures mayresult in SCSI Technical Information Bulletins being published by INCITS. These Bulletins, while reflecting the opinion of the Technical Committee thatdeveloped the
43、standard, are intended solely as supplementary information to otherusers of the standard. This standard, ANSI INCITS 366-2003, as approved throughthe publication and voting procedures of the American National Standards Institute,is not altered by these bulletins. Any subsequent revision to this stan
44、dard may or maynot reflect the contents of these Technical Information Bulletins.Current INCITS practice is to make Technical Information Bulletins available through:INCITS Online Store http:/ htmlmanaged by Techstreet Telephone: 1-734-302-7801 or1327 Jones Drive 1-800-699-9277Ann Arbor, MI 48105 Fa
45、csimile: 1-734-302-7811orGlobal Engineering http:/ Inverness Way East Telephone: 1-303-792-2181 orEnglewood, CO 80112-5704 1-800-854-7179Facsimile: 1-303-792-2192Requests for interpretation, suggestions for improvement and addenda, or defectreports are welcome. They should be sent to the INCITS Secr
46、etariat, NationalCommittee for Information Technology Standards, Information Technology Institute,1250 Eye Street, NW, Suite 200, Washington, DC 20005-3922. This standard was processed and approved for submittal to ANSI by the InterNa-tional Committee for Information Technology Standards (INCITS). C
47、ommitteeapproval of the standard does not necessarily imply that all committee membersvoted for approval. At the time of it approved this standard, INCITS had the followingmembers:Karen Higginbottom, ChairRuss Richards, Vice-ChairJennifer Garner, SecretaryOrganization Represented Name of Representat
48、iveApple Computer, Inc. David MichaelWanda Cox (Alt.)viiiOrganization Represented Name of RepresentativeHewlett-Packard Company. Karen HigginbottomScott Jameson (Alt.)Steve Mills (Alt.)IBM Corporation Ronald F. SillettiChuck Adams (Alt.)Institute for Certification of Computer Professionals. Kenneth
49、M. ZemrowskiThomas Kurihara (Alt.)Intel Corporation . Gregory KisorMichelle Stamnes (Alt.)Philip Wennblom (Alt.)Microsoft Corporation . Mike KsarJoseph Zajaczkowski (Alt.)National Institute of Standards equivalent to thephrase “it is strongly recommended“.3.3.11 vendor specific: Specification of the referenced item is determined by the SCSI device vendor.3.4 Editorial conventionsCertain words and terms used in this standard have a specific meaning beyond the normal English meaning.These words and terms are defined either in the glossary or in t