Are you an LLM? You can read better optimized documentation at /zh/docs/UB-Base-Specification-2.1.0/transaction-layer/transaction-headers/acknowledge-transaction-header-atah.md for this page in Markdown format
ATAH是所有事务响应必须包含的事务层包头。包括完整格式以及精简格式,和BTAH格式对应,即如果BTAH采用完整格式,ATAH也应采用完整格式,如果BTAH采用精简格式,ATAH也应采用精简格式。
完整ATAH格式如下:
Byte0 | Byte1 | Byte2 | Byte3 |
7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
TAOpcode | TAver | RSVD | SV | Poison | RSVD | INI_TASSN |
RSPST | RSPINFO | RSVD | INI_RC_Type | INI_RC_ID |
图 7-5 完整ATAH格式
精简ATAH格式如下:
Byte0 | Byte1 | Byte2 | Byte3 |
7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
TAOpcode | TAver | Status | RSVD | Poison | RSVD | INI_TASSN |
图 7-6 精简ATAH格式
各域段描述如下:
表 7-3 ATAH域段
域段名 | 位宽(bits) | 完整ATAH域段描述 | 精简ATAH域段描述 |
|---|
TAOpcode | 8 | 表示当前事务的响应类型,具体编码如下: - 0x11:Transaction ACK(TAACK)
- 0x12:Read_response
- 0x13:Atomic_response
| 同左 |
TAver | 2 | Transaction协议版本号,当前协议应设置为0。 | 同左 |
Status | 2 | Reserved | 用于表示远端鉴权结果,编码如下: - 2'b00:表示远端鉴权Pass,数据读写正确完成。
- 2'b01:表示远端鉴权Fail。
- Others:Reserved。
|
SV | 1 | SCID Valid。 ROT动态模式下是否申请到Target SCID。 - 1'b0:未申请到。
- 1'b1:申请到,SCID携带在INI_TASSN中。
| Reserved |
Poison | 1 | 带数据的包该bit有效,表示Payload是否存在poison: | 同左 |
INI_TASSN | 16 | Initiator Transaction Segment Sequence Number: - SV为0时,表示Initiator TASSN,应对应事务请求的TASSN。
- SV为1时,该域段代表ROT模式时申请到的Target SCID。
| Initiator Transaction Segment Sequence Number,表示Initiator TASSN,应对应事务请求的TASSN。 |
RSPST | 3 | Response Status,事务响应状态,和RSPINFO搭配使用,编码如下: - 3'b000:Successful Completion (SC)
- 3'b001:Receiver Not Ready(RNR),Target侧支持事务类型,但Target接收资源不足,此时RSPINFO表示RNR_Timer。
- 3'b010:Page Fault,Target出现Page Fault,此时RSPINFO表示RNR_Timer。当出现Page Fault时,有2种处理策略。
策略1:不等Page Fault处理完,回异常TAACK,告知发送端重传,此策略下RNR_Timer通常大于0。 策略2:Page Fault处理完,回异常TAACK,告知发送端重传,此策略下RNR_Timer为0。 - 3'b011:Target Error。
- 3'b101:包正确接收,但未写入介质。
当事务类型为Atomic_store_with_return_status时,表示事务到达Target侧,但Target侧不支持该类型,Target目标内存数据不会被更新。当为其他事务类型时,表示包正确接收,但未写入介质。 - Others: Reserved。
注:3'b000和3'b101的差异是3'b000表示Payload已经写入内存,而3'b101表示Payload已经交给介质控制器,如内存控制器,但并未保证已写入介质。 | 无此域段 |
RSPINFO | 5 | Response Information,事务响应信息,具体编码如下: - RSPST=3'b000或3'b101:该域段表示TAACK聚合个数,为0时表示此TAACK无聚合其它TAACK,非0时表示聚合其它TAACK的个数。
- RSPST=3'b001和3'b010:该域段表示RNR_Timer编码。RNR_Timeout = 2us * 2^RNR_Timer,RNR_Timer有效编码范围为[0,19],其它编码Reserved。
- RSPST=3'b011:该域段表示返回错误应答,错误类型为:
- 5'b00001表示Unsupported Request。
- 5'b00010表示Remote Abort。
- Others:Reserved。
| 无此域段 |
INI_RC_Type | 2 | Initiator Requester Context Type: - 2'b00和2'b01:Initiator使用Send Queue(SQ)。
- 2'b10:Initiator使用Target Sequence Context(SC)资源。
- 2'b11: Reserved。
| 无此域段 |
INI_RC_ID | 20 | Initiator Requester Context ID: - 若INI_RC_Type为2'b00或2'b01,此域段表示Requester Context ID(RCID),Target生成事务响应时,把此域段带回给Initiator,以便Initiator用来索引正确的SQ。
- 若INI_RC_Type为2'b10,此域段表示SCID,Target产生事务响应时,从SC中取出RCID,填到ATAH中,以便Initiator用来索引正确的SQ。
| 无此域段 |
不同事务响应使用的包格式如下:
表 7-4 事务响应包格式
TAOpcode | 事务操作 | 事务层包格式 |
|---|
0x11 | Transaction_ACK | ATAH |
0x12 | Read_response | ATAH,[TAIDETAH],[OFSTETAH],Payload |
0x13 | Atomic_response | ATAH,[TAIDETAH],[Payload] |
注:[*]为可选包头,是否携带见7.4节。