IB(3)
π NAME π
packet.transport.ib β the InfiniBand module π¦
(also hi, you're reading IB(3) from the ib 1.2 manual, welcome to the group chat π
)
π DESCRIPTION π
Decode the InfiniBand layer. Reference: IB Specification Vol 1-Release-1.3-2015-03-03.pdf π
π CLASSES π
okay bestie, buckle up, there's a whole squad of classes in here and every single one of them is a header. iconic behavior, honestly.
π class AETH(baseobj.BaseObj) π
ACK EXTENDED TRANSPORT HEADER (AETH) β 4 BYTES
The ACK Extended Transport Header carries the extra transport fields for ACK packets. The AETH only shows up in Acknowledge, RDMA READ Response First, RDMA READ Response Last, and RDMA READ Response Only packets β and you know it's there because the Base Transport Header OpCode field says so. no cap.
AETH(
syndrome = int, # Syndrome indicates if this is an ACK or NAK
# packet plus additional information about the
# ACK or NAK
msn = int, # Message Sequence Number indicates the sequence
# number of the last message completed at the
# responder
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
π¦ class AtomicAckETH(baseobj.BaseObj) π¦
ATOMIC ACKNOWLEDGE EXTENDED TRANSPORT HEADER (ATOMICACKETH) β 8 BYTES
The Atomic ACK Extended Transport Header holds the extra transport fields for AtomicACK packets. The AtomicAckETH is only in Atomic Acknowledge packets, as indicated by the Base Transport Header OpCode field. she's specific, she's exclusive π
AtomicAckETH(
orig_rem_dt = int, # Original Remote Data is the return operand
# in atomic operations and contains the data
# in the remote memory location before the
# atomic operation
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
πΈ class AtomicETH(baseobj.BaseObj) πΈ
ATOMIC EXTENDED TRANSPORT HEADER (ATOMICETH) β 28 BYTES
The Atomic Extended Transport Header carries the extra transport fields for Atomic packets. The AtomicETH is only in Atomic packets, as indicated by the Base Transport Header OpCode field.
AtomicETH(
va = int, # Virtual Address: the remote virtual address
r_key = int, # Remote Key that authorizes access to the remote
# virtual address
swap_dt = int, # Swap/Add Data is an operand in atomic operations
cmp_dt = int, # Compare Data is an operand in CmpSwap atomic
# operation
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
π₯ class BTH(baseobj.BaseObj) π₯
BASE TRANSPORT HEADER (BTH) β 12 BYTES
The Base Transport Header contains the fields for IBA transports. You know the BTH is present because the Next Header field of the last previous header tells you β that's either LRH:lnh or GRH:nxthdr, depending on which one was the last previous header. iykyk π
BTH(
opcode = int, # OpCode indicates the IBA packet type. It also
# specifies which extension headers follow the BTH
se = int, # Solicited Event, this bit indicates that an event
# should be generated by the responder
migreq = int, # This bit is used to communicate migration state
padcnt = int, # Pad Count indicates how many extra bytes are added
# to the payload to align to a 4 byte boundary
tver = int, # Transport Header Version indicates the version of
# the IBA Transport Headers
pkey = int, # Partition Key indicates which logical Partition is
# associated with this packet
destqp = int, # Destination QP indicates the Work Queue Pair Number
# (QP) at the destination
ackreq = int, # Acknowledge Request, this bit is used to indicate
# that an acknowledge (for this packet) should be
# scheduled by the responder
psn = int, # Packet Sequence Number is used to detect a missing
# or duplicate Packet
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
π class DETH(baseobj.BaseObj) π
DATAGRAM EXTENDED TRANSPORT HEADER (DETH) β 8 BYTES
The Datagram Extended Transport Header carries the extra transport fields for datagram service. The DETH is only in datagram packets, when the Base Transport Header OpCode field indicates it. periodt.
DETH(
q_key = int, # Queue Key is required to authorize access to the
# receive queue
src_qp = int, # Source QP indicates the Work Queue Pair Number (QP)
# at the source.
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
π class GRH(baseobj.BaseObj) π
GLOBAL ROUTE HEADER (GRH) β 40 BYTES
The Global Route Header contains fields for routing the packet between subnets. The GRH is present when the Link Next Header (LNH) field in the LRH says so. The layout of the GRH is the same as the IPv6 Header defined in RFC 2460. but bestie, note this: IBA does not define a relationship between a device GID and an IPv6 address β i.e., there is no defined mapping between GID and IPv6 address for any IB device or port. π
GRH(
ipver = int, # IP Version indicates version of the GRH
tclass = int, # Traffic Class is used by IBA to communicate
# global service level
flabel = int, # Flow Label identifies sequences of packets
# requiring special handling
paylen = int, # Payload length specifies the number of bytes
# starting from the first byte after the GRH,
# up to and including the last byte of the ICRC
nxthdr = int, # Next Header identifies the header following the
# GRH. This field is included for compatibility with
# IPV6 headers. It should indicate IBA transport
hoplmt = int, # Hop Limit sets a strict bound on the number of
# hops between subnets a packet can make before
# being discarded. This is enforced only by routers
sgid = IPv6Addr, # Source GID identifies the Global Identifier
# (GID) for the port which injected the packet
# into the network
dgid = IPv6Addr, # Destination GID identifies the GID for the port
# which will consume the packet from the network
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
π class IB(baseobj.BaseObj) π
InfiniBand (IB) object β the main character, obviously π
Usage:
from packet.transport.ib import IB
x = IB(pktt)
Object definition:
IB(
lrh = LRH, # Local Route Header
grh = GRH, # Global Route Header
bth = BTH, # Base Transport Header
rdeth = RDETH, # Reliable Datagram Extended Transport Header
deth = DETH, # Datagram Extended Transport Header
xrceth = XRCETH, # XRC Extended Transport Header
reth = RETH, # RDMA Extended Transport Header
atomiceth = AtomicETH, # Atomic Extended Transport Header
aeth = AETH, # ACK Extended Transport Header
atomicacketh = AtomicAckETH, # Atomic Acknowledge Extended Transport Header
immdt = ImmDt, # Immediate Extended Transport Header
ieth = IETH, # Invalidate Extended Transport Header
psize = int, # Payload data size
icrc = int, # Invariant CRC
vcrc = int, # Variant CRC
)
β¨ Methods defined here β¨
__bool__(self)β Truth value testing for the built-in operationbool()__init__(self, pktt)β Constructor
Initialize object's private data.
pktt: Packet trace object (packet.pktt.Pktt) so this layer has access to the parent layers.
π§ class IETH(baseobj.BaseObj) π§
INVALIDATE EXTENDED TRANSPORT HEADER (IETH) β 4 BYTES
The Invalidate Extended Transport Header contains an R_Key field, which the responder uses to invalidate a memory region or memory window once it receives and executes the SEND with Invalidate request. go off, responder π
IETH(
r_key = int, # The SEND with Invalidate operation carries with it
# an R_Key field. This R_Key is used by the responder
# to invalidate a memory region or memory window once
# it receives and executes the SEND with Invalidate
# request
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
π class ImmDt(baseobj.BaseObj) π
IMMEDIATE DATA EXTENDED TRANSPORT HEADER (IMMDT) β 4 BYTES
The Immediate Data Extended Transport Header contains the additional data that gets placed in the receive Completion Queue Element (CQE). The ImmDt is only in Send or RDMA-Write packets with Immediate Data, when the Base Transport Header OpCode indicates it.
psst β note this: the terms Immediate Data Extended Transport Header and Immediate Data Header are used synonymously in the specification. two names, one legend π
ImmDt(
imm_dt = int, # Immediate Data contains data that is placed in the
# receive Completion Queue Element (CQE). The ImmDt is
# only allowed in SEND or RDMA WRITE packets with
# Immediate Data
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor
Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. π«Ά
β class LRH(baseobj.BaseObj) β
LOCAL ROUTE HEADER (LRH) β 8 BYTES
Okay so the Local Routing Header? It contains fields used for local routing by switches within a IBA subnet. <em>Slay.</em>
LRH(
vl = int, # Virtual Lane that the packet is using
lver = int, # Link Version of LRH
sl = int, # Service Level the packet is requesting within the subnet
lnh = int, # Link Next Header identifies the headers following the LRH
dlid = int, # Destination Local ID identifies the destination port
# and path (data sink) on the local subnet
plen = int, # Packet Length identifies the size of the packet in
# four-byte words. This field includes the first byte of
# LRH to the last byte before the variant CRC
slid = int, # Source Local ID identifies the source port
# (injection point) on the local subnet
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor. Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both.
class OpCode(builtins.int) π§
OpCode object, this is an integer in which its informal string representation is given as the OpCode name.
β¨ Methods defined here β¨
__str__(self)β Returnstr(self).
class RDETH(baseobj.BaseObj) π¦
RELIABLE DATAGRAM EXTENDED TRANSPORT HEADER (RDETH) - 4 BYTES
Reliable Datagram Extended Transport Header contains the additional transport fields for reliable datagram service. The RDETH is only in Reliable Datagram packets as indicated by the Base Transport Header OpCode field.
RDETH(
ee_context = int, # EE-Context indicates which End-to-End Context
# should be used for this Reliable Datagram packet
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor. Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both.
class RETH(baseobj.BaseObj) π
RDMA EXTENDED TRANSPORT HEADER (RETH) - 16 BYTES
RDMA Extended Transport Header contains the additional transport fields for RDMA operations. The RETH is present in only the first (or only) packet of an RDMA Request as indicated by the Base Transport Header OpCode field.
RETH(
va = int, # Virtual Address of the RDMA operation
r_key = int, # Remote Key that authorizes access for the RDMA
# operation
dma_len = int, # DMA Length indicates the length (in Bytes) of
# the DMA operation.
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor. Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both.
class XRCETH(baseobj.BaseObj) πΈ
XRC EXTENDED TRANSPORT HEADER (XRCETH)
XRC Extended Transport Header contains the Destination XRC SRQ identifier.
XRCETH(
xrcsrq = int, # XRC Shared Receive Queue indicates the XRC Shared
# Receive Queue number to be used by the responder
# for this packet
)
β¨ Methods defined here β¨
__init__(self, unpack)β Constructor. Initialize object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both.
SEE ALSO π
baseobj(3)packet.application.rpc(3)packet.application.rpcordma(3)packet.application.rpcordma_const(3)packet.internet.ipv6addr(3)packet.unpack(3)packet.utils(3)
BUGS π
No known bugs. <em>Iconic.</em>
AUTHOR π
Jorge Mora (mora@netapp.com)
This page is from <strong>NFStest 3.2</strong>, dated <strong>21 March 2023</strong>, for <strong>IB(3)</strong>. Bye bestie! π β¨
π¦ where this page comes from
- debian trixie: nfstest 3.2-3
- fedora 43: NFStest 3.2-14.fc43 Β· GPL-2.0-or-later
- fedora 44: NFStest 3.2-16.fc44 Β· GPL-2.0-or-later
- ubuntu noble: nfstest 3.2-2
- ubuntu questing: nfstest 3.2-3
- ubuntu resolute: nfstest 3.2-3build1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms