RDMAINFO(3)
π RDMAINFO(3) β packet.transport.rdmainfo, from rdmainfo 1.1 β¨
okay so sit down, hydrate, and let's talk about RDMA reassembly, because bestie this module is literally the glue holding your RDMA fragments together π«Ά
πΈ NAME πΈ
packet.transport.rdmainfo β the RDMA reassembly module. that's it, that's the name, it's giving "I put the pieces back together" energy π
π¦ DESCRIPTION π¦
It provides functionality to reassemble RDMA fragments. no cap, that's the whole job, and she does it flawlessly β¨
π CLASSES π
π class RDMAinfo(packet.utils.RDMAbase)
RDMA info object used for reassembly. the main character, honestly π
The reassembled message consists of one or multiple chunks and each chunk in turn could be composed of multiple segments. Also, each segment could be composed of multiple sub-segments and each sub-segment could be composed of multiple fragments. it's layers on layers on layers, like an onion but make it networking π§
The protocol only defines segments but if the segment length is large, it is split into multiple sub-segments in which each sub-segment is specified by RDMA_WRITE_First or RDMA_READ_Request packets. The handle is the same for each of these packets but with a shorter DMA length. iykyk π₯
Thus in order to reassemble all fragments for a single message, a list of segments is created where each segment is identified by its handle or RKey and the message is reassembled according to the chuck lists specified by the RPC-over-RDMA layer. (yes it says "chuck" in the original, we're keeping it, it's iconic, do not perceive it π)
π Methods defined here:
__del__ = reset(self)β destructor duties, delegated straight toresetπ§Ή__init__(self)β Constructor. Initializes object's private data according to the arguments given. Arguments can be given as positional, named arguments or a combination of both. flexible queen π__len__ = size(self)β length dunder, just callssizeπadd_iwarp_data(self, rdmap, unpack, isread=False)β Add iWarp fragment data πadd_iwarp_request(self, rdmap)β Add iWarp read request information π¨add_rdma_data(self, psn, unpack, reth=None, only=False, read=False)β Add Infiniband fragment data π«add_rdma_segment(self, rdma_seg, rpcrdma=None)β Add RDMA segment information and if the information already exists just update the length and return the segment πdel_rdma_segment(self, rsegment)β Delete RDMA segment information ποΈget_rdma_segment(self, handle)β Return RDMA segment identified by the given handle πprocess_rdma_segments(self, rpcrdma)β Process the RPC-over-RDMA chunks π§
When this method is called on an RPC call, it adds the information of all the segments to the list of segments. When this method is called on an RPC reply, the segments should already exist so just update the segment's DMA length as returned by the reply. two moods, one method π
RPCoRDMA reads attribute is a list of read segments. Read segment is a plain segment plus an XDR position. A read chunk is the collection of all read segments with the same XDR position.
RPCoRDMA writes attribute is a list of write chunks. A write chunk is a list of plain segments.
RPCoRDMA reply is just a single write chunk if it exists. Return the reply chunk data π€
reassemble_rdma_reads(self, unpack, psn=None, only=False, rdmap=None)β Reassemble RDMA read chunks. The RDMA read chunks are reassembled in the read last operation π§©reset(self)β Clear RDMA segments π§Όsize(self)β Return the number RDMA segments π’
πΈ class RDMArequest(builtins.object)
RDMA iWarp Request object π
π Methods defined here:
__contains__(self, offset)β Membership test operator. Return true if offset belongs to this request β__init__(self, rdmap, rsegment)β Initialize self. Seehelp(type(self))for accurate signature πget_offset(self, offset)β Return offset translated from sink to src π
π class RDMAseg(builtins.object)
RDMA sub-segment object β¨
The sub-segment is created for each RDMA_WRITE_First, RDMA_WRITE_Only or RDMA_READ_Request and each sub-segment belongs to a list in the RDMAsegment object so there is no segment identifier or handle. anonymous but thriving π
Reassembly for each sub-segment is done using the PSN or packet sequence number in each of the data fragments. Therefore, a range of PSN numbers define this object which is given by the spsn and epsn attributes (first and last PSN respectively). π¬
π Methods defined here:
__del__(self)β Destructor π__init__(self, spsn, epsn, dmalen)β Initialize self. Seehelp(type(self))for accurate signature πget_data(self, padding=True)β Return sub-segment data π¦get_size(self)β Return sub-segment data size πinsert_data(self, psn, data)β Insert data at correct position given by the psn π―
π¦ class RDMAsegment(builtins.object)
RDMA segment object π«Ά
Each segment is identified by its handle. The segment information comes from the RPC-over-RDMA protocol layer so the length attribute gives the total DMA length of the segment. π§΅
π Methods defined here:
__del__(self)β Destructor π__init__(self, rdma_seg, rpcrdma)β Initialize self. Seehelp(type(self))for accurate signature πadd_data(self, psn, data)β Add Infiniband fragment data π«add_fragment(self, offset, data)β Add iWarp fragment to segment πadd_sub_segment(self, psn, dmalen, only=False, iosize=0)β Add RDMA sub-segment PSN information π§±get_data(self, padding=True)β Return segment data π¦get_size(self)β Return segment data πvalid_psn(self, psn)β True if given psn is valid for this segment β
π SEE ALSO π
baseobj(3), packet.utils(3) β go read these too, bestie, they're the supporting cast π¬
π BUGS π
No known bugs. she's flawless, periodt π
βοΈ AUTHOR βοΈ
Jorge Mora (mora@netapp.com) β the icon, the legend, the moment π
and that's the whole page, bestie!! this came from NFStest 3.2, dated 21 March 2023 β so yeah, if you see her around, tell her she ate π β¨π
π¦ 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
- ubuntu stonking: nfstest 3.2-5
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms