Virtual channel scheduling system for RDMA transmission
Through the design of the virtual channel scheduling system, the SQE of the virtual channel corresponding to QP is coordinated with each module to process the SQE of the virtual channel, which solves the problem of delay surge, performance attenuation and head blocking of QP scheduling processing in RDMA transmission, and realizes efficient virtual channel scheduling.
Patent Information
- Application Number
- CN202510477259.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-16
- Publication Date
- 2025-05-16
- Estimated Expiration
- 2045-04-16
AI Technical Summary
In RDMA transmission, the order of magnitude of QP scheduling processing is difficult to implement, and simple scheduling methods lead to delay surges, performance attenuation and head blocking problems.
A virtual channel scheduling system is designed to achieve the SQE processing flow of the QP of the streamlined virtual channel without mutual interference and blocking through the coordinated work of the relationship establishment module, the first virtual channel scheduling module, the second virtual channel scheduling module, the third virtual channel scheduling module and the message construction module.
It effectively solves the problems of delay surge, performance attenuation and head blocking caused by simple scheduling methods, and realizes efficient QP scheduling processing.
Smart Images

Figure CN120017602A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of remote direct memory access, and in particular to a virtual channel scheduling system for RDMA transmission. Background Art
[0002] In recent years, with the rapid development of technologies such as artificial intelligence and cloud computing, RoCEv2 (RDMA over ConvergedEthernet) technology has been widely used in data centers. Its high bandwidth, low latency, multiple links, and zero copy characteristics enable it to have better performance in multi-node distributed computing. The number of links required to be supported in its application scenarios in data centers is often more than 10K, and the link bandwidth is mostly at the level of hundreds of Gbps.
[0003] However, on the one hand, the total amount of on-chip RAM (Random Access Memory) storage resources of RDMA network cards implemented based on FPGA (Field Programmable Gate Array) or ASIC (Application Specific Integrated Circuit) is generally at the level of ten MB. However, based on the requirements of RDMA protocol technology implementation, RDMA network cards need to cache information such as QPC (Queue Pair Context), CQC (Completion Queue Context), MRC (Memory Region Context), SQE (Send Queue Element), RQE (Receive Queue Element), OR (Outstanding Request), etc., with QP (Queue Pair Context) as the core. The number of queue pairs is 10K, and each QPC is 128B. The space required for QPC alone is 1.28MB. Obviously, it is unreasonable to use on-chip storage resources to cache the relevant information of all links. On the other hand, such a large number of links requires a corresponding number of QPs to support RDMA transmission. For RDMA network cards, it is difficult to implement the scheduling between such a large number of QPs by simple polling. Simple polling operations for 10K QPs will bring huge delays, and in actual applications, only a small number of QPs need to be processed in parallel by the network card. Such polling will also cause serious performance degradation when the network card processes these QPs in parallel. Finally, affected by the RoCEv2 network congestion control algorithm and PFC (Priority-based Flow Control), it is necessary to implement fine-grained scheduling based on QPs, and to solve the problem of head blocking that all QPs cannot send data when a certain QP cannot continue to send data due to congestion control or PFC restrictions.
[0004] In view of this, how to implement a large number of QP scheduling processes while solving the delay surge, performance degradation and head blocking caused by simple scheduling methods is a technical problem that needs to be solved urgently by technical personnel in this field. Summary of the invention
[0005] In order to solve the above technical problems, the purpose of the present invention is to provide a virtual channel scheduling system for RDMA transmission, which can complete the entire SQE processing flow of the QP corresponding to each virtual channel in a pipeline manner without mutual interference and blocking through the collaborative work of various modules, thereby solving the problems of delay surge, performance degradation and head blocking brought about by simple scheduling methods.
[0006] The first object of the present invention is to provide a virtual channel scheduling system for RDMA transmission; The technical solution provided by the present invention is as follows: A virtual channel scheduling system for RDMA transmission, comprising: a relationship establishment module, a first virtual channel scheduling module, a second virtual channel scheduling module, a third virtual channel scheduling module and a message construction module; the first virtual channel scheduling module is respectively connected to the relationship establishment module and the second virtual channel scheduling module; the third virtual channel scheduling module is respectively connected to the second virtual channel scheduling module and the message construction module; the relationship establishment module, the first virtual channel scheduling module, the second virtual channel scheduling module, the third virtual channel scheduling module and the message construction module are all connected to a host; The relationship establishment module is used to obtain the active QP according to the Doorbell of each QP, and establish a mapping relationship between the active QP and the network card virtual channel; The first virtual channel scheduling module is used to poll and schedule the active QP obtained by the relationship establishment module to obtain the SQE from the host and write the SQE into the SQE cache space; The second virtual channel scheduling module is used to poll and read the SQE in the first virtual channel scheduling module to obtain a physical page address from the host and write the physical page address into a page address cache space; The third virtual channel scheduling module is used to poll and read the physical page address and the SQE in the second virtual channel scheduling module to obtain the message data cached in the corresponding MR (Memory Region) from the host; The message construction module is used to construct and forward the RoCEv2 message according to the QPC of the active QP, the SQE and the message data.
[0007] Preferably, the relationship establishing module is specifically used for: According to the WQE (Work Queue Element) type, PI (Producer Index) and CI (Consumer Index) maintained by the hardware in Doorbell, it is determined whether the corresponding QP is the active QP; if so, then: Check whether the active QP has a virtual channel mapping; if the active QP has a mapped virtual channel, there is no need to establish a new mapping relationship, only the PI value of the hardware cache needs to be updated; if the active QP has no mapped virtual channel, then: Check whether there is an idle virtual channel. If there is an idle virtual channel, establish a mapping relationship between the active QP and the idle virtual channel. If there is no idle virtual channel, do not perform any operation.
[0008] Preferably, the relationship establishing module is further used to delete the mapping relationship between the virtual channel and the active QP when it is detected that the QP corresponding to the virtual channel is destroyed or when the network card has processed the existing SQE of the virtual channel and no new SQE needs to be processed within a preset time.
[0009] Preferably, the first virtual channel scheduling module is specifically used to: The remaining SQE cache space of the virtual channel and the number of SQEs remaining in the host memory of the QP corresponding to the virtual channel are obtained by polling the virtual channel to calculate the number of SQEs; A specified number of SQEs are read from the host according to the number of SQEs, and the SQEs are written into the SQE cache space.
[0010] Preferably, the second virtual channel scheduling module is specifically used to: Reading the SQE cache space of the virtual channel by polling the virtual channel to obtain the remaining page address cache space and the remaining length of the SQE message of the virtual channel; Calculate the number of page addresses according to the remaining page address cache space and the remaining length of the SQE message; The physical page address of the MR corresponding to the message data in the SQE is obtained from the host according to the number of page addresses, and the physical page address is written into the page address cache space corresponding to the virtual channel.
[0011] Preferably, the third virtual channel scheduling module is specifically used to: Read the physical page address and the SQE of the virtual channel by polling the virtual channel, and simultaneously obtain the PMTU (Path Maximum Transmission Unit) of the QP corresponding to the virtual channel, the number of remaining tokens, the hardware status, the ORT (Outstanding Request Table) available space, the remaining length of the SQE message, the PFC back pressure status and the number of page addresses; Calculate the number of messages according to the PMTU of the QP corresponding to the virtual channel, the number of remaining tokens, the hardware status, the ORT available space, the remaining length of the SQE message, the PFC back pressure status and the number of page addresses; The corresponding MR message data is obtained from the host memory according to the number of messages.
[0012] Preferably, the message construction module is specifically used to: Cache the MR message data of the corresponding MR cache into the shared message payload cache, and cache the fields required for constructing the message in the corresponding SQE into the shared message descriptor cache in sequence; wherein the fields include: the operation type, immediate value, remote access address, remote access keyword and remote access memory size of the corresponding SQE; A RoCEv2 message is constructed according to the MR message data in the shared message payload cache, the fields in the shared message descriptor cache, and the QPC in the corresponding QP, and the RoCEv2 message is sent to the Ethernet interface for forwarding.
[0013] The present invention provides a virtual channel scheduling system for RDMA transmission, comprising: a relationship establishment module, a first virtual channel scheduling module, a second virtual channel scheduling module, a third virtual channel scheduling module and a message construction module; the first virtual channel scheduling module is respectively connected to the relationship establishment module and the second virtual channel scheduling module; the third virtual channel scheduling module is respectively connected to the second virtual channel scheduling module and the message construction module; the relationship establishment module, the first virtual channel scheduling module, the second virtual channel scheduling module, the third virtual channel scheduling module and the message construction module are all connected to a host; through the coordinated work of each module, the entire SQE processing flow of the QP corresponding to each virtual channel can be completed in a pipelined manner without mutual interference and blocking, thereby solving the problems of delay surge, performance degradation and head blocking caused by a simple scheduling method. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0015] Figure 1 The figure is a schematic diagram of the structure of a virtual channel scheduling system for RDMA transmission in an embodiment of the present invention. DETAILED DESCRIPTION
[0016] In order to enable those skilled in the art to better understand the technical solutions in this application, the technical solutions in the embodiments of this application will be clearly and completely described below. Obviously, the described embodiments are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0017] It should be noted that when an element is referred to as being "fixed on" or "set on" another element, it can be directly on the other element or indirectly set on the other element; when an element is referred to as being "connected to" another element, it can be directly connected to the other element or indirectly connected to the other element.
[0018] It should be understood that the terms "length", "width", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc., indicating the orientation or position relationship, are based on the orientation or position relationship shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0019] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, "multiple" and "several" mean two or more, unless otherwise clearly and specifically defined.
[0020] It should be noted that the structures, proportions, sizes, etc. illustrated in the drawings of this specification are only used to match the contents disclosed in the specification for people familiar with this technology to understand and read, and are not used to limit the conditions under which this application can be implemented. Therefore, they have no substantive technical significance. Any structural modification, change in proportional relationship or adjustment of size should still fall within the scope of the technical content disclosed in this application without affecting the effects and purposes that can be achieved by this application.
[0021] like Figure 1As shown, an embodiment of the present invention provides a virtual channel scheduling system for RDMA transmission, comprising: a relationship establishment module 101, a first virtual channel scheduling module 102, a second virtual channel scheduling module 103, a third virtual channel scheduling module 104 and a message construction module 105; the first virtual channel scheduling module 102 is connected to the relationship establishment module 101 and the second virtual channel scheduling module 103 respectively; the third virtual channel scheduling module 104 is connected to the second virtual channel scheduling module 103 and the message construction module 105 respectively; the relationship establishment module 101, the first virtual channel scheduling module 102, the second virtual channel scheduling module 103, the third virtual channel scheduling module 104 and the message construction module 105 are all connected to the host 11; The relationship establishing module 101 is used to obtain the active QP according to the Doorbell of each QP, and establish a mapping relationship between the active QP and the network card virtual channel; The first virtual channel scheduling module 102 is used for polling and scheduling the active QP obtained by the relationship establishment module 101 to obtain the SQE from the host and write the SQE into the SQE cache space; The second virtual channel scheduling module 103 is used to poll and read the SQE in the first virtual channel scheduling module 102 to obtain a physical page address from the host and write the physical page address into a page address cache space; The third virtual channel scheduling module 104 is used to poll and read the physical page address and the SQE in the second virtual channel scheduling module 103 to obtain the MR message data corresponding to the MR cache from the host; The message construction module 105 is used to construct and forward a RoCEv2 message according to the QPC of the active QP, the SQE and the MR message data.
[0022] In actual application, a virtual channel scheduling system for RDMA transmission is provided, which can implement the processing flow of SQE in a pipelined and parallel manner on the RDMA network card 10. The system includes: a relationship establishment module 101, which is used to screen active QPs according to the Doorbell of each QP, and establish a mapping relationship between the active QP and the network card virtual channel; a first virtual channel scheduling module 102, which is used to poll and schedule the corresponding QP of each virtual channel, obtain SQE from the host and write it into the SQE cache space of the corresponding virtual channel; a second virtual channel scheduling module 103, which is used to poll and read the SQE of each virtual channel, obtain the physical page address of the MR corresponding to the message data in the SQE from the host, and write it into the page address cache space of the corresponding virtual channel; a third virtual channel scheduling module 104, which is used to poll and read the page address and SQE of each virtual channel, and calculate the number of messages that can be sent , so as to read the message data in the MR according to the page address; the message construction module 105 is used to construct and forward the RoCEv2 message based on the read MR message data, SQE and QPC related information; through the first virtual channel scheduling module 102, it is respectively connected with the relationship establishment module 101 and the second virtual channel scheduling module 103; the third virtual channel scheduling module 104 is respectively connected with the second virtual channel scheduling module 103 and the message construction module 105 so that each module can work together to complete the entire SQE processing flow of each virtual channel corresponding to the QP in a pipelined manner without mutual interference and blocking, thereby solving the problems of delay surge, performance degradation and head blocking caused by the simple scheduling method; moreover, each virtual channel only needs to independently cache a small amount of information such as SQE and physical page address, and the data load is shared by all QPs, which can be achieved by using the on-chip storage resources of the network card.
[0023] Preferably, the relationship establishing module 101 is specifically used for: According to the WQE type in Doorbell, the PI producer index, and the CI consumer index maintained by the hardware, it is determined whether the corresponding QP is the active QP; if so, then: Check whether the active QP has a virtual channel mapping; if the active QP has a mapped virtual channel, there is no need to establish a new mapping relationship, only the PI value of the hardware cache needs to be updated; if the active QP has no mapped virtual channel, then: Check whether there is an idle virtual channel. If there is an idle virtual channel, establish a mapping relationship between the active QP and the idle virtual channel. If there is no idle virtual channel, do not perform any operation.
[0024] In actual application, in the relationship establishment module 101, the virtual channel is a logical channel composed of the network card based on the above three scheduling modules. Each virtual channel can process SQE in parallel without blocking or interfering with each other. When the virtual channel and QP establish a mapping relationship, only the SQE corresponding to the QP will be processed. The virtual channel mapping relationship is to establish a mapping table based on the binding relationship between the virtual channel and QP. The mapping table also records the status information such as whether each virtual channel is idle. The relationship establishment module 101 uses a mapping table to record the corresponding relationship between QP and the virtual channel. The mapping table specifically includes the number of each virtual channel, the QPN (Queue Pair Number) of the corresponding QP, whether it is idle, and other status information. As for the number of virtual channels, it can be based on the specific implementation of the network card, and the resources and design requirements of the network card need to be balanced. At the same time, the relationship establishment module is also used to release the virtual channel, that is, when it is detected that the QP corresponding to the virtual channel is destroyed or when the network card has processed the existing SQE of the virtual channel and there is no new SQE to be processed within a preset time, the mapping relationship between the virtual channel and the active QP is deleted.
[0025] Preferably, the first virtual channel scheduling module 102 is specifically used for: The remaining SQE cache space of the virtual channel and the number of SQEs remaining in the host memory of the QP corresponding to the virtual channel are obtained by polling the virtual channel to calculate the number of SQEs; The SQE is read from the host according to the number of SQEs, and the SQE is written into the SQE cache space.
[0026] In actual use, the first virtual channel scheduling module 102 polls each virtual channel to obtain information such as the remaining SQE cache space of the corresponding virtual channel and the number of SQEs remaining in the host memory of the QP corresponding to the virtual channel, and calculates and decides the number of SQEs that can be read based on this information, and then reads the host QP to obtain a specified number of SQEs from the host memory and writes them into the SQE cache space of the corresponding virtual channel; the specified number in this embodiment needs to be less than or equal to the above-mentioned number of SQEs that can be read, and can be set according to actual conditions such as the SQE size and memory access method.
[0027] Preferably, the second virtual channel scheduling module 103 is specifically used for: Reading the SQE cache space of the virtual channel by polling the virtual channel to obtain the remaining page address cache space and the remaining length of the SQE message of the virtual channel; Calculate the number of page addresses according to the remaining page address cache space and the remaining length of the SQE message; The physical page address of the MR corresponding to the message data in the SQE is obtained from the host according to the number of page addresses, and the physical page address is written into the page address cache space corresponding to the virtual channel.
[0028] In actual use, the second virtual channel scheduling module 103 schedules each virtual channel through polling, reads its SQE cache space, calculates and decides the number of page addresses that can be read according to the remaining page address cache space of the corresponding virtual channel, the remaining length of the SQE message and other information, and then reads the host MTR (Memory Translate Region) to obtain the physical page addresses of the MR corresponding to the message data in the specified number of SQEs from the host, and writes the physical page addresses into the page address cache space of the corresponding virtual channel; the specified number in this embodiment needs to be less than or equal to the above-mentioned number of readable page addresses, and can be set according to actual conditions such as the memory access method.
[0029] Preferably, the third virtual channel scheduling module 104 is specifically used for: Read the physical page address and the SQE of the virtual channel by polling the virtual channel, and simultaneously obtain the PMTU, the number of remaining tokens, the hardware status, the ORT available space, the remaining length of the SQE message, the PFC back pressure status and the number of page addresses of the QP corresponding to the virtual channel; Calculate the number of messages according to the PMTU of the QP corresponding to the virtual channel, the number of remaining tokens, the hardware status, the ORT available space, the remaining length of the SQE message, the PFC back pressure status and the number of page addresses; The corresponding MR message data is obtained from the host memory according to the number of messages.
[0030] In actual use, the third virtual channel scheduling module 104 schedules each virtual channel through polling, reads its page address and SQE, obtains the PMTU of the QP corresponding to the virtual channel, the number of remaining tokens in the token bucket, the hardware status, the ORT available space, the remaining length of the SQE message, the PFC back pressure status and the number of page addresses and other information, calculates and decides the number of messages that can be sent based on this information, and then reads the host MR to obtain the corresponding MR message data of the specified number from the host memory; the specified number in this embodiment is the amount of MR message data corresponding to the above-mentioned messages that can be sent.
[0031] Among them, the number of remaining tokens in the token bucket is used to control the message sending rate of the QP corresponding to each virtual channel, thereby supporting the QP-based congestion control algorithm required by the RoCEv2 network; the token bucket is activated when the mapping relationship between the virtual channel and the QP is established, and the rate limit value of the token bucket is calculated by the congestion control algorithm implemented by the network card; the hardware status is used to maintain the status of the QP corresponding to each virtual channel on the network card, and is used to decide whether the corresponding QP can continue to process SQE normally; the ORT available space is used to determine whether an OR cache can be constructed into the ORT when processing the SQE of the QP corresponding to the virtual channel; The remaining length of the SQE message is the size of the message data that has not yet been read from the MR for constructing the message, and is used to calculate the amount of data that the SQE still needs to read, the number of corresponding page addresses, and other information; the PFC back pressure state is used to determine whether the QP corresponding to the virtual channel can continue to send messages. When the PFC queue mapped by the corresponding QP is in a paused state, the message cannot be sent, and the corresponding virtual channel of the third virtual channel scheduling module 104 also needs to suspend reading MR message data; the number of page addresses is the number of page addresses in the page address cache space corresponding to the virtual channel in the second virtual channel scheduling module 103.
[0032] It should be noted that in order to support the QP-based congestion control required by the RoCEv2 network, such as DCQCN (Data Center Quantized Congestion Notification), the third virtual channel scheduling module 104 maintains an independent token bucket for each virtual channel. The token bucket is activated when the mapping relationship between the virtual channel and the QP is established, and starts to accumulate tokens. The rate of accumulating tokens is calculated by the congestion control algorithm implemented by the network card.
[0033] Preferably, the message construction module 105 is specifically used for: Cache the MR message data of the corresponding MR cache into the shared message payload cache, and cache the fields required for constructing the message in the corresponding SQE into the shared message descriptor cache in sequence; wherein the fields include: the operation type, immediate value, remote access address, remote access keyword and remote access memory size in the corresponding SQE; A RoCEv2 message is constructed according to the MR message data in the shared message payload cache, the fields in the shared message descriptor cache, and the QPC in the corresponding QP, and the RoCEv2 message is sent to the Ethernet interface for forwarding.
[0034] In actual use, the message construction module 105 caches the MR message data read by all virtual channels into the shared message load cache, and at the same time caches the message construction related fields such as the operation type, immediate value, remote access address, remote access keyword and remote access memory size in the corresponding SQE into the shared message descriptor cache in sequence; then the message construction module 105 constructs the header of the RoCEv2 message according to the message construction related fields in the above SQE and the corresponding QPC, including the Ethernet layer 2, layer 3, layer 4 header and the IB (InfiniBand, infinite bandwidth) protocol header, etc., and then fills the MR message data into the IB load interval of the RoCEv2 message; finally, the constructed RoCEv2 message is forwarded.
[0035] It should be understood that the use of "method", "device", "unit" and / or "module" in this application is only a method for distinguishing different components, elements, parts, portions or assemblies at different levels. However, if other words can achieve the same purpose, the word can be replaced by other expressions.
[0036] As shown in this application and claims, unless the context clearly indicates an exception, the words "a", "an", "a kind" and / or "the" do not refer to the singular, but also include the plural. Generally speaking, the terms "include" and "comprise" only indicate the inclusion of clearly identified steps and elements, and these steps and elements do not constitute an exclusive list. The method or device may also include other steps or elements. The elements defined by the sentence "includes a..." do not exclude the existence of other identical elements in the process, method, commodity or device that includes the elements.
[0037] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features.
[0038] If a flow chart is used in the present application, the flow chart is used to illustrate the operations performed by the system according to the embodiment of the present application. It should be understood that the preceding or following operations are not necessarily performed accurately in order. On the contrary, each step can be processed in reverse order or simultaneously. At the same time, other operations can also be added to these processes, or a certain step or several steps of operations can be removed from these processes.
[0039] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A virtual channel scheduling system for RDMA transmission, characterized in that: include: A relationship establishing module, a first virtual channel scheduling module, a second virtual channel scheduling module, a third virtual channel scheduling module and a message constructing module; The first virtual channel scheduling module is connected to the relationship establishment module and the second virtual channel scheduling module respectively; the third virtual channel scheduling module is connected to the second virtual channel scheduling module and the message construction module respectively; the relationship establishment module, the first virtual channel scheduling module, the second virtual channel scheduling module, the third virtual channel scheduling module and the message construction module are all connected to the host; The relationship establishment module is used to obtain the active QP according to the Doorbell of each QP, and establish a mapping relationship between the active QP and the network card virtual channel; The first virtual channel scheduling module is used to poll and schedule the active QP obtained by the relationship establishment module to obtain the SQE from the host and write the SQE into the SQE cache space; The second virtual channel scheduling module is used to poll and read the SQE in the first virtual channel scheduling module to obtain a physical page address from the host and write the physical page address into a page address cache space; The third virtual channel scheduling module is used to poll and read the physical page address and the SQE in the second virtual channel scheduling module to obtain the MR message data corresponding to the MR cache from the host; The message construction module is used to construct and forward the RoCEv2 message according to the QPC of the active QP, the SQE and the MR message data.
2. The virtual channel scheduling system for RDMA transmission according to claim 1, characterized in that: The relationship establishment module is specifically used for: According to the WQE type in Doorbell, the PI producer index, and the CI consumer index maintained by the hardware, it is determined whether the corresponding QP is the active QP; if so, then: Check whether the active QP has a virtual channel mapping; if the active QP has a mapped virtual channel, there is no need to establish a new mapping relationship, only the PI value of the hardware cache needs to be updated; if the active QP has no virtual channel mapping, then: Check whether there is an idle virtual channel. If there is an idle virtual channel, establish a mapping relationship between the active QP and the idle virtual channel. If there is no idle virtual channel, do not perform any operation.
3. The virtual channel scheduling system for RDMA transmission according to claim 2, characterized in that: The relationship establishing module is further used to delete the mapping relationship between the virtual channel and the active QP when it is detected that the QP corresponding to the virtual channel is destroyed or when the network card has processed the existing SQE of the virtual channel and there is no new SQE to be processed within a preset time.
4. The virtual channel scheduling system for RDMA transmission according to claim 1, characterized in that: The first virtual channel scheduling module is specifically used to: The remaining SQE cache space of the virtual channel and the number of SQEs remaining in the host memory of the QP corresponding to the virtual channel are obtained by polling the virtual channel to calculate the number of SQEs; A specified number of SQEs are read from the host according to the number of SQEs, and the SQEs are written into the SQE cache space.
5. The virtual channel scheduling system for RDMA transmission according to claim 1, characterized in that: The second virtual channel scheduling module is specifically used to: Reading the SQE cache space of the virtual channel by polling the virtual channel to obtain the remaining page address cache space and the remaining length of the SQE message of the virtual channel; Calculate the number of page addresses according to the remaining page address cache space and the remaining length of the SQE message; The physical page address of the MR corresponding to the message data in the SQE is obtained from the host according to the number of page addresses, and the physical page address is written into the page address cache space corresponding to the virtual channel.
6. The virtual channel scheduling system for RDMA transmission according to claim 5, characterized in that: The third virtual channel scheduling module is specifically used for: Read the physical page address and the SQE of the virtual channel by polling the virtual channel, and simultaneously obtain the PMTU, the number of remaining tokens, the hardware status, the ORT available space, the remaining length of the SQE message, the PFC back pressure status and the number of page addresses of the QP corresponding to the virtual channel; Calculate the number of messages according to the PMTU of the QP corresponding to the virtual channel, the number of remaining tokens, the hardware status, the ORT available space, the remaining length of the SQE message, the PFC back pressure status and the number of page addresses; The corresponding MR message data is obtained from the host memory according to the number of messages.
7. The virtual channel scheduling system for RDMA transmission according to claim 6, characterized in that: The message construction module is specifically used for: Cache the MR message data of the corresponding MR cache into the shared message payload cache, and cache the fields required for constructing the message in the corresponding SQE into the shared message descriptor cache in sequence; wherein the fields include: the operation type, immediate value, remote access address, remote access keyword and remote access memory size in the corresponding SQE; A RoCEv2 message is constructed according to the MR message data in the shared message payload cache, the fields in the shared message descriptor cache, and the QPC corresponding to the QP, and the RoCEv2 message is sent to the Ethernet interface for forwarding.
Citation Information
Patent Citations
Communication method for reducing high-speed bus delay
CN109491809A
Network interface card, controller, storage device and message sending method
CN114490462A
Implementation method of MHAL on FPGA based on virtual channel technology
CN117675731A
Lossless and efficient data processing method based on RMDA and network interface card
CN117931391A
Establishing connections in a computer network supporting a remote direct memory access (RDMA) protocol
US20250112872A1
Cited By
Rate control device and method
CN120614312A
A rate control device and method
CN120614312B