1、American National StandardDeveloped byfor Information Technology Fibre Channel Protocol for SCSI,Third Version (FCP-3)ANSI INCITS 416-2006ANSIINCITS416-2006ANSIINCITS 416-2006American National Standardfor Information Technology Fibre Channel Protocol for SCSI,Third Version (FCP-3)SecretariatInformat
2、ion Technology Industry CouncilApproved June 22, 2006American National Standards Institute, Inc.AbstractThis standard describes the frame format and protocol definitions required to transfer commands and databetween a SCSI (Small Computer System Interface) initiator and target using the Fibre Channe
3、l family ofstandards. The second version (ANSI INCITS 350) added optional retransmission, task ordering, and con-firmation capabilities. This third version incorporates bi-directional commands, removes information thatis now contained in other standards, and describes additional error recovery capab
4、ilities for the FibreChannel Protocol.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 ofStandar
5、ds Review, 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
6、resolution.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 Am
7、erican 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 Sta
8、ndards 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 requ
9、ire that 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 Standa
10、rds Institute, Inc.25 West 43rd Street, New York, NY 10036Copyright 2006 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 Stre
11、et NW, Washington, DC 20005. Printed in the United States of AmericaCAUTION: The developers of this standard have requested that holders of patents that may be re-quired for the implementation of the standard disclose such patents to the publisher. However, nei-ther the developers nor the publisher
12、have undertaken a patent search in order to identify which, ifany, patents may apply to this standard. As of the date of publication of this standard, followingcalls for the identification of patents that may be required for the implementation of the standard,notice of one or more such claims has be
13、en received. By publication of this standard, no positionis taken with respect to the validity of this claim or of any rights in connection therewith. The knownpatent holder(s) has (have), however, filed a statement of willingness to grant a license underthese rights on reasonable and nondiscriminat
14、ory terms and conditions to applicants desiring to ob-tain such a license. Details may be obtained from the publisher. No further patent search is con-ducted by the developer or publisher in respect to any standard it processes. No representation ismade or implied that this is the only license that
15、may be required to avoid infringement in the use ofthis standard.iContentsPageForeword xIntroduction .xv1 Scope . 12 Normative references 12.1 Qualification and availability of references. 12.2 Published standard and technical report references 12.3 References under development . 12.4 Other referenc
16、es 23 Definitions, abbreviations and conventions 23.1 Definitions 23.2 Abbreviations . 53.3 Keywords . 73.4 Editorial conventions 74 General . 94.1 Structure and concepts 94.2 FCP I/O operations 104.3 Bidirectional and unidirectional commands and FCP_RSP IU format . 124.4 Precise delivery of SCSI co
17、mmands 124.5 Confirmed completion of FCP I/O operations 134.6 Retransmission of unsuccessfully transmitted IUs. 144.7 Task retry identification 144.8 Discovery of FCP capabilities 154.9 Task management . 154.10 Clearing effects of task management, FCP, FC-FS-2, FC-LS, and FC-AL-2 actions . 164.11 I_
18、T nexus loss notification events 194.12 Transport Reset notification events 194.13 Port Login/Logout. 194.14 Process Login and Process Logout . 204.15 Link management. 204.16 FCP addressing and Exchange identification 204.17 Use of World Wide Names. 205 FC-FS-2 frame header 215.1 FC-FS-2 frame heade
19、r overview 21iiPage5.2 FC-FS-2 frame header fields 215.2.1 r_ctl field 215.2.2 d_id field 215.2.3 cs_ctl field . 215.2.4 s_id field 215.2.5 type field 215.2.6 f_ctl field 225.2.7 seq_id field 225.2.8 df_ctl field 225.2.9 seq_cnt field 225.2.10 ox_id field 225.2.11 rx_id field . 225.2.12 parameter fi
20、eld 226 FCP link service definitions . 236.1 Overview of link service requirements . 236.2 Overview of Process Login and Process Logout . 236.3 PRLI . 246.3.1 Use of PRLI by the Fibre Channel Protocol 246.3.2 Process_Associator requirements 246.3.3 New or repeated Process Login 246.3.4 PRLI request
21、FCP Service Parameter page format 246.3.5 PRLI accept FCP Service Parameter page format . 286.4 PRLO . 296.5 Read Exchange Concise (REC). 297 FC-4 specific Name Server registration and objects . 307.1 Overview of FC-4 specific objects for the Fibre Channel Protocol. 307.2 FC-4 TYPEs object 307.3 FC-
22、4 Features object . 308 FC-4 Link Service definitions 318.1 FC-4 Link Services for the Fibre Channel Protocol 318.2 Sequence Retransmission Request (SRR) 318.3 FCP FC-4 Link Service Reject (FCP_RJT) 339 FCP Information Unit (IU) usage and formats . 359.1 FCP Information Unit (IU) usage 359.2 FCP_CMN
23、D IU. 369.2.1 Overview and format of FCP_CMND IU . 369.2.2 FCP_CMND IU field descriptions 379.2.2.1 fcp_lun field 379.2.2.2 COMMAND REFERENCE NUMBER field 389.2.2.3 priority field . 389.2.2.4 task attribute field . 389.2.2.5 TASK MANAGEMENT FLAGS FIELD 389.2.2.6 additional fcp_cdb length field 40iii
24、Page9.2.2.7 rddata and wrdata bits 419.2.2.8 fcp_cdb field . 419.2.2.9 additional_fcp_cdb field 419.2.2.10 fcp_dl field 419.2.2.11 fcp_bidirectional_read_dl field 429.3 FCP_XFER_RDY IU 429.3.1 Overview and format of FCP_XFER_RDY IU . 429.3.2 fcp_data_ro field 439.3.3 fcp_burst_len field . 439.4 FCP_
25、DATA IU 439.4.1 FCP_DATA IU overview 439.4.2 FCP_DATA IUs for read and write operations . 449.4.3 FCP_DATA IUs for bidirectional commands . 449.4.4 FCP_DATA IU use of fill bytes 459.5 FCP_RSP IU 459.5.1 Overview and format of FCP_RSP IU . 459.5.2 retry delay timer field . 479.5.3 fcp_bidi_rsp bit 47
26、9.5.4 fcp_bidi_read_resid_under bit . 489.5.5 fcp_bidi_read_resid_over bit . 489.5.6 FCP_CONF_REQ BIT . 489.5.7 fcp_resid_under bit 489.5.8 fcp_resid_over bit 489.5.9 fcp_sns_len_valid bit . 489.5.10 fcp_rsp_len_valid bit 489.5.11 SCSI status code field . 499.5.12 fcp_resid field 499.5.13 fcp_bidire
27、ctional_read_resid field 499.5.14 fcp_sns_len field 509.5.15 fcp_rsp_len field 509.5.16 fcp_rsp_info field . 509.5.17 fcp_sns_info field . 519.6 FCP_CONF IU . 5210 SCSI mode parameters for the Fibre Channel Protocol 5310.1 Overview of mode pages for the Fibre Channel Protocol. 5310.2 Disconnect-Reco
28、nnect mode page 5310.2.1 Overview and format of Disconnect-Reconnect mode page for FCP 5310.2.2 buffer full ratio field 5410.2.3 buffer empty ratio field . 5510.2.4 bus inactivity limit field . 5510.2.5 disconnect time limit field 5510.2.6 connect time limit field . 5510.2.7 maximum burst size field
29、 . 5510.2.8 emdp bit . 5610.2.9 FAA, FAB, FAC BITS 5610.2.10 first burst size field . 5610.3 Fibre Channel Logical Unit Control mode page 57ivPage10.4 Fibre Channel Port Control mode page . 5710.4.1 Overview and format of Fibre Channel Port Control mode page 5710.4.2 DISABLE TARGET ORIGINATED LOOP I
30、NITIALIZATION (DTOLI) bit . 5810.4.3 DISABLE TARGET INITIATED PORT ENABLE (DTIPE) bit 5810.4.4 ALLOW LOGIN WITHOUT LOOP INITIALIZATION (ALWLI) bit 5810.4.5 REQUIRE HARD ADDRESS (RHA) bit . 5910.4.6 disable loop master (dlm) bit . 5910.4.7 DISABLE DISCOVERY (DDIS) bit . 5910.4.8 PREVENT LOOP PORT BYP
31、ASS (PLPB) bit 5910.4.9 DISABLE TARGET FABRIC DISCOVERY (DTFD) bit 5910.4.10 sequence initiative resource recovery timeout value (rr_tovseq_init) field . 6011 Timers for FCP operation and recovery 6111.1 Summary of timers for the Fibre Channel Protocol 6111.2 Error_Detect Timeout (E_D_TOV). 6211.3 R
32、esource Allocation Timeout (R_A_TOV) . 6211.4 Resource Recovery Timeout (RR_TOV) 6211.5 Read Exchange Concise Timeout Value (REC_TOV). 6211.6 Upper Level Protocol Timeout (ULP_TOV) 6312 Link error detection and error recovery procedures 6412.1 Error detection and error recovery overview 6412.1.1 Exc
33、hange level 6412.1.2 Sequence level 6412.2 FCP error detection 6412.2.1 Overview of FCP-3 error detection 6412.2.2 FCP-3 error detection using protocol errors for all classes of service . 6412.2.3 Error detection mechanisms for acknowledged classes of service . 6512.3 Exchange level recovery using r
34、ecovery abort 6612.3.1 Recovery abort overview . 6612.3.2 Initiator FCP_Port invocation of recovery abort 6612.3.3 Target FCP_Port response to recovery abort . 6612.3.4 Additional error recovery by initiator FCP_Port . 6712.3.5 Additional error recovery by target FCP_Port . 6712.4 Sequence level err
35、or detection and recovery. 6712.4.1 Using information from REC to perform Sequence level recovery 6712.4.1.1 Polling Exchange state with REC . 6712.4.1.2 Detection of errors while polling with REC . 6812.4.1.3 FCP_CMND IU recovery 6812.4.1.4 FCP_XFER_RDY IU recovery . 6812.4.1.5 FCP_RSP IU recovery
36、. 6812.4.1.6 FCP_DATA IU recovery - write operations 6912.4.1.7 FCP_DATA IU recovery - read operations . 7012.4.1.8 FCP_CONF IU recovery 7012.4.2 Additional error recovery requirements . 7112.4.2.1 Error indicated in ACK 7112.4.2.2 Missing ACK . 71vPage12.4.2.3 Distinguishing Exchange to be aborted
37、7112.5 Second-level error recovery . 7112.5.1 ABTS error recovery 7112.5.2 REC error recovery . 7212.5.3 SRR error recovery . 7212.6 Responses to FCP type frames before PLOGI or PRLI . 72AnnexesA FCP-3 mapping to SAM-3 (Fibre Channel Protocol Service mapping to SCSI Architectural Model - 3 73A.1 Def
38、inition of procedure terms . 73B FCP Examples 75B.1 Examples of the use of FCP Information Units (IUs) . 75B.1.1 Overview of examples . 75B.1.2 SCSI FCP read operation . 75B.1.3 SCSI FCP write operation . 76B.1.4 SCSI FCP operation with no data transfer or with check condition . 76B.1.5 SCSI FCP rea
39、d operation with multiple FCP_DATA IUs 77B.1.6 SCSI FCP write operation with FCP_XFR_RDY disabled 77B.1.7 SCSI FCP bidirectional command with write before read . 78B.1.8 SCSI FCP bidirectional command with read before write . 78B.1.9 SCSI FCP bidirectional command, write first, write FCP_XFER_RDY di
40、sabled . 79B.1.10 SCSI FCP bidirectional command with intermixed writes and reads 80B.1.11 SCSI linked commands . 81B.1.12 SCSI WRITE command with confirmed completion 82B.1.13 SCSI FCP task management function 82B.2 FCP write example, frame level . 83B.3 FCP read example, frame level . 85C Error de
41、tection and recovery action examples 87C.1 Introduction 87D FCP device discovery procedure 121D.1 FCP Device Discovery Procedure . 121D.1.1 Initiator discovery of Fabric-attached target FCP_Ports . 121D.1.2 Initiator discovery of loop-attached target FCP_Ports 121D.2 Fabric and Device Authentication
42、 122D.3 Logical unit authentication . 122viPageE FCP-3 examples of link service usage . 123E.1 Formats for recovery link services . 123E.2 Abort Sequence (ABTS) Request 123E.2.1 Abort Sequence (ABTS) Request fields . 123E.2.2 Basic Accept (BA_ACC) Frame to ABTS . 124E.2.3 Basic Reject (BA_RJT) Frame
43、 to ABTS . 125E.3 Reinstate Recovery Qualifier (RRQ) 125E.3.1 RRQ request format 125Tables1 SCSI and Fibre Channel Protocol functions . 102 Discovery of FCP-3 capabilities 153 Task management functions, SAM-3 to FCP-3 164 Clearing effects of link related functions . 185 Clearing effects of initiator
44、 FCP_Port actions . 196 FCP frame header 217 FCP Service Parameter page, PRLI request 228 FCP Service Parameter page, PRLI accept . 289 FCP definition of FC-4 Feature bits 3010 FCP FC-4 Link Service Requests and Responses . 3111 SRR Payload 3212 SRR Accept Payload 3213 FCP_RJT Payload 3314 FCP_RJT r
45、eason codes . 3415 FCP_RJT reason code explanations 3416 FCP Information Units (IUs) sent to target FCP_Ports . 3517 FCP Information Units (IUs) sent to initiator FCP_Ports . 3618 FCP_CMND IU Payload . 3719 TASK ATTRIBUTE field values 3820 Task management flags field 3921 FCP_XFER_RDY IU payload . 4
46、222 FCP_RSP IU Payload . 4723 FCP_RSP_INFO field format 5124 RSP_CODE definitions 5125 Mode pages for FCP . 5326 Disconnect-Reconnect mode page (02h) . 54viiPage27 Fibre Channel Logical Unit Control mode page (18h) . 5728 Fibre Channel Port Control mode page (19h) . 5829 Values for RR_TOV UNITS . 60
47、30 Timer summary . 6131 Initiator FCP_Port REC_TOV Usage 6332 Target FCP_Port REC_TOV usage 63A.1 FCP-3 procedure terms mapped to terms from SAM-3 standard 73A.2 Procedure terms 74B.1 FCP read operation, example . 75B.2 FCP write operation, example . 76B.3 FCP operation without data transfer, exampl
48、e 76B.4 FCP read operation, example . 77B.5 FCP write operation with FCP_XFER_RDY disabled, example 77B.6 FCP bidirectional command with write before read, example . 78B.7 FCP bidirectional command with read before write, example . 78B.8 FCP bidirectional command, write FCP_XFER_RDY disabled, exampl
49、e 79B.9 FCP bidirectional command with intermixed writes and reads, example 80B.10 FCP linked commands, example 81B.11 FCP write command with confirmed completion . 82B.12 FCP task management function, example 82E.1 ABTS Frame 123E.2 BA_ACC Frame to ABTS 124E.3 BA_RJT Frame to ABTS . 125E.4 Reinstate Recovery Qualifier 125FiguresB.1 Example of class 2 FCP write operation . 83B.2 Example of class 2 FCP_DATA write 84B.3 Example of class 2 FCP read operation 85B.4 Example of class 2 FCP_DATA read 86C.1 Lengthy FCP_CMND or Lost ACK 88C.2 FCP_CMND Lost, Unacknowledged Classes .