Packet transmission method and apparatus
By setting header address information and dynamic configuration in RDMA message groups, the problem of inflexible RDMA operation is solved, and system performance is improved and transmission overhead is reduced under high packet loss rate.
Patent Information
- Application Number
- PCT/CN2025/105053
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-07-15
- Filing Date
- 2025-06-27
- Publication Date
- 2026-01-22
Smart Images

Figure CN2025105053_22012026_PF_FP_ABST
Abstract
Description
Message transmission method and apparatus
[0001] This application claims priority to Chinese Patent Application No. 202410949418.0, filed on July 15, 2024, entitled "Message Transmission Method and Apparatus", the entire contents of which are incorporated herein by reference. Technical Field
[0002] This application relates to the field of communication technology, and in particular to a message transmission method and apparatus. Background Technology
[0003] Remote direct memory access (RDMA) technology was developed to address the latency issues in server-side data processing during network transmission. RDMA allows direct access to memory data through the network interface, eliminating the need for data to be moved from the central processing unit (CPU) to the kernel and then from the kernel to the network card. It requires no intervention from the operating system kernel, making it suitable for use in large-scale parallel computer clusters. RDMA technology supports RDMA operations on messages, such as writing RDMA message packets.
[0004] However, RDMA operation is not flexible enough at present, and how to improve the flexibility of RDMA operation is a current research problem. Summary of the Invention
[0005] This application provides a message transmission method and apparatus to improve the flexibility of RDMA operation.
[0006] To achieve the above objectives, this application adopts the following technical solution:
[0007] A first aspect provides a message transmission method applied to a first device, the method comprising: the first device acquiring a first Remote Direct Memory Access (RDMA) message and sending the first RDMA message to a second device. The first RDMA message is any one of M RDMA messages, the M RDMA messages including... One RDMA message group, It is an integer greater than 1. Each RDMA message group contains an RDMA message header that includes address information, where M is an integer greater than 1 and N is a positive integer less than M. The address information is used to determine the address at which the RDMA message containing the address information is written to the memory of the second device.
[0008] Therefore, for M RDMA messages, taking the RDMA messages contained in each group (or RDMA message group) as a unit, an address information is set in the header of an RDMA message in each RDMA message group. This address information is used to determine the address of the RDMA message containing the address information to be written to the memory of the second device. The address of other RDMA messages in each group to be written to the memory of the second device can be determined based on this address information. That is, RDMA operation is performed at the group level to write to memory. For example, RDMA messages from different groups can be written to the same or different memory regions. These regions can be discrete or continuous, which can improve the flexibility of RDMA operation.
[0009] In one possible design scheme, The header of the first RDMA message in each RDMA message group can contain address information. That is, the header of the (a-1)*N+1th RDMA message in M RDMA messages can contain address information, such as the 1st RDMA message, the N+1th RDMA message, etc., where 'a' represents the number of RDMA messages from 1 to 1. integers, Less than or equal to M.
[0010] Optionally, the sequence number of the first RDMA message is X, and the sequence number of the first RDMA message among the M RDMA messages is Y. If (XY) modulo N is 0, and (XY)*MTU is less than the size of the M RDMA messages, or in other words, XY is less than M, then the header of the first RDMA message contains address information, and MTU is the maximum transmission unit of the first RDMA message. This ensures that the RDMA message carrying address information belongs to the M RDMA messages, and avoids other messages being mistakenly written into the memory space of the M RDMA messages.
[0011] For example, the address information is the address of the first RDMA message, which is the address where the first RDMA message is written to the memory of the second device. The address where the first RDMA message is written to the memory of the second device can be determined based on the address of the first RDMA message.
[0012] Furthermore, the offset of the address of the first RDMA message relative to the address of the first RDMA message is (XY)*MTU. The address of the first RDMA message is the address where the first RDMA message is written into the memory of the second device. This offset plus the address of the first RDMA message is the address of the first RDMA message. In other words, when the offset is determined, the second device only needs to obtain the address of the first RDMA message from RETH to determine the address of the first RDMA message, which is simple and efficient.
[0013] Furthermore, if the header of the first RDMA message carries address information, the header of the first RDMA message is RETH, and the BTH of the first RDMA message contains indication information indicating that the first RDMA message contains RETH, so as to avoid errors in unpacking by the second device.
[0014] For example, the address information is the packet identifier of the RDMA packet group to which the first RDMA packet belongs. In this case, the sequence number of the first RDMA packet is Y, and the packet identifier of the RDMA packet group to which the first RDMA packet belongs is... The address of the first RDMA message is offset from the address of the first RDMA message. MTU is the maximum transmission unit of the first RDMA message, and the address of the first RDMA message is the address where the first RDMA message is written to the memory of the second device.
[0015] In other words, the address of the first RDMA message in each RDMA message group can be determined based on the group identifier. The addresses of other RDMA messages in the same RDMA message group can be determined based on the address of the first RDMA message, thus ensuring that each RDMA message is written to the correct location.
[0016] Furthermore, the header of the first RDMA message is BTH, eliminating the need for an additional extended header and further reducing overhead.
[0017] In one possible design, M RDMA packets correspond to queue pairs QP. The packet loss rate of QP's RDMA packets is negatively correlated with the value of N; that is, the higher the packet loss rate, the smaller the value of N, and vice versa. This allows for dynamic packet grouping based on the packet loss rate, balancing system performance and transmission overhead. For example, when the packet loss rate is low, retransmissions are infrequent, so the value of N can be configured to be relatively large, resulting in a smaller proportion of overhead for address information and lower transmission overhead. When the packet loss rate is high, retransmissions occur frequently, so the value of N can be configured to be relatively small to reduce retransmission overhead and ensure system performance.
[0018] In one possible design, the method described in the first aspect may further include: a first device receiving configuration information, the configuration information being used to indicate... Each RDMA packet group contains an RDMA packet header with address information, allowing the RDMA packet packet transmission method to be dynamically configured according to actual conditions, providing flexibility in configuration.
[0019] Optionally, configuration information is used to indicate The header of the first RDMA message in each RDMA message group contains address information.
[0020] In one possible design, the method described in the first aspect further includes: a first device receiving feedback information from a second device, the feedback information indicating that the second RDMA message has been lost, and the second RDMA message belongs to M RDMA messages; the first device retransmitting Q RDMA messages from the M RDMA messages to the second device according to the feedback information, where Q is a positive integer, and the Q RDMA messages include: from the second RDMA message to the last RDMA message in the RDMA message group to which the second RDMA message belongs, that is, only a portion of the RDMA messages in the group to which the second RDMA message belongs needs to be retransmitted, and the RDMA messages in other groups do not need to be retransmitted, the retransmission overhead is relatively small, and the communication efficiency is improved.
[0021] Secondly, a message transmission method is provided, applied to a second device, the method comprising: the second device receiving a first Remote Direct Memory Access (RDMA) message, the first RDMA message belonging to M RDMA messages, and writing the first RDMA message into the first RDMA message. The M RDMA messages include... One RDMA message group, It is an integer greater than 1. Each RDMA packet in the RDMA packet group contains an RDMA packet header containing address information, where M is an integer greater than 1 and N is a positive integer less than M. The address information is used to determine the address where the RDMA packet containing the address information is written to the memory of the second device.
[0022] In one possible design scheme, The header of the first RDMA message in each RDMA message group can contain address information. That is, the header of the (a-1)*N+1th RDMA message in M RDMA messages can contain address information, where a is the number of RDMA messages traversed from 1 to N. integers, Less than or equal to M.
[0023] Optionally, the sequence number of the first RDMA message is X, and the sequence number of the first RDMA message among the M RDMA messages is Y. If (XY) modulo N is 0, and (XY)*MTU is less than the size of the M RDMA messages, then the header of the first RDMA message contains address information, and MTU is the maximum transmission unit of the first RDMA message.
[0024] For example, the address information is the address of the first RDMA message, and the address of the first RDMA message is the address where the first RDMA message is written to the memory of the second device.
[0025] Furthermore, the offset of the address of the first RDMA message relative to the address of the first RDMA message is (XY)*MTU. The address of the first RDMA message is the address where the first RDMA message is written to the memory of the second device. This offset plus the address of the first RDMA message is the address of the first RDMA message.
[0026] Furthermore, if the header of the first RDMA message carries address information, the header of the first RDMA message is RETH, and the BTH of the first RDMA message contains indication information indicating that the first RDMA message contains RETH.
[0027] For example, the address information is the packet identifier of the RDMA packet group to which the first RDMA packet belongs. In this case, the sequence number of the first RDMA packet is Y, and the packet identifier of the RDMA packet group to which the first RDMA packet belongs is... The address of the first RDMA message is offset from the address of the first RDMA message. MTU is the maximum transmission unit of the first RDMA message, and the address of the first RDMA message is the address where the first RDMA message is written to the memory of the second device.
[0028] Furthermore, the header of the first RDMA message is BTH.
[0029] In one possible design, M RDMA messages correspond to queue pairs QP, and the RDMA message loss rate of QP is negatively correlated with the value of N.
[0030] In one possible design, the second device writes the first RDMA message, including: the second device can determine the address of the first RDMA message based on the address information, and write the first RDMA message based on the address of the first RDMA message.
[0031] Optionally, the second device determines the address of the first RDMA message based on the address information, including: the second device determines the offset of the address of the first RDMA message relative to the address of the first RDMA message among the M RDMA messages, and determines the address of the first RDMA message based on the address of the first RDMA message and the offset. The address of the first RDMA message is the address where the first RDMA message is written to the memory of the second device.
[0032] In one possible design, the method described in the second aspect may further include: the second device sending feedback information and receiving Q RDMA messages from the M RDMA messages retransmitted by the first device. The feedback information indicates that the second RDMA message has been confirmed as lost, and the second RDMA message belongs to the M RDMA messages; Q is a positive integer, and the Q RDMA messages include: from the second RDMA message to the last RDMA message in the RDMA message group to which the second RDMA message belongs.
[0033] It is understandable that the technical effects of the method described in the second aspect can also refer to the relevant introduction of the method described in the first aspect above, and will not be repeated here.
[0034] Thirdly, a message transmission method is provided, applied to a third device. The method includes: the third device acquiring the packet loss rate of Remote Direct Memory Access (RDMA) messages for the queue to QP, and sending configuration information to the first device where QP is located based on the RDMA message packet loss rate. The configuration information indicates that one of the N RDMA message groups associated with QP has address information in its header, where N is a positive integer, the RDMA message packet loss rate is negatively correlated with the value of N, and the address information is used to determine the address at which the RDMA message containing address information is written to memory.
[0035] In one possible design, the third device is a network element for session management. The third device obtains the RDMA packet loss rate of the queue QP by: the network element for session management obtaining the RDMA packet loss rate from at least one of the following network elements associated with the QP: a network element for policy management, a network element for user plane transmission, or an access network device.
[0036] Optionally, the network element used for session management obtains the RDMA packet loss rate from the network element used for policy management associated with the QP. This includes: when establishing or modifying a session associated with the QP, the network element used for session management obtains the session's policy and charging rules (PCC rules) from the network element used for policy management; the network element used for session management obtains the upper limit of packet loss rate (PER) in the PCC rules, and PER is used as the RDMA packet loss rate. This means that the existing session establishment or modification process can be reused to obtain the RDMA packet loss rate without introducing a new process, making the implementation simple.
[0037] Optionally, the network element used for session management obtains the RDMA packet loss rate from the access network device associated with the QP, including: the network element used for session management obtains the packet loss rate of the data radio bearer (DRB) or quality of service (QoS) flow associated with the QP from the access network device, and the packet loss rate of the DRB or QoS flow is used as the RDMA packet loss rate. For example, the network element used for session management can obtain the RDMA packet loss rate from the access network device through existing subscription methods without introducing additional procedures, which is simple to implement.
[0038] Optionally, the network element used for session management obtains the RDMA packet loss rate from the network element associated with QP for user plane transmission. This includes: the network element used for session management obtaining the PER associated with QP from the network element associated with user plane transmission. The PER is the PER of the downlink data of the QP-associated session. The PER is used as the RDMA packet loss rate. In this case, the existing N4 session process can be reused to obtain the RDMA packet loss rate from the network element associated with user plane transmission. No additional process needs to be introduced, making the implementation simple.
[0039] Optionally, the third device is an access network device. The third device obtains the RDMA packet loss rate of the queue QP by: the access network device obtaining the packet loss rate of the DRB or QoS flow associated with the QP, and the packet loss rate of the DRB or QoS flow is used as the RDMA packet loss rate. That is, it obtains the data locally without signaling interaction, thus avoiding the communication overhead caused by interaction; or, in the case of establishing or modifying a session associated with QP, the access network device obtains the QoS configuration of the session from the network element used for policy management, and obtains the PER in the QoS configuration. The PER is used as the RDMA packet loss rate. That is, the existing session establishment or modification process can be reused to obtain the RDMA packet loss rate without introducing a new process, which is simple to implement.
[0040] In one possible design, the method described in the third aspect may further include: the third device obtaining the MTU, where MTU is the maximum transmission unit of the RDMA message associated with QP; the third device sending configuration information to the first device where QP resides based on the RDMA message packet loss rate, including: the third device sending configuration information to the first device based on the RDMA message packet loss rate and MTU. That is, the RDMA packet size also needs to consider the MTU factor to ensure that the packets are more reasonable.
[0041] Optionally, the third device sends configuration information to the first device based on the RDMA packet loss rate and the MTU. This includes: the third device determining multiple packet loss rates for the RDMA packets corresponding to the MTU, and determining a packet loss rate that matches the RDMA packet loss rate from among the multiple packet loss rates, where the matched packet loss rate corresponds to a value of N; thus, the third device sends the configuration information to the first device based on the matched packet loss rate. Different MTUs correspond to different packet loss rates; for example, a larger MTU generally results in lower overall packet loss rates to ensure system capacity.
[0042] Optionally, the third device acquires the MTU by: the third device acquiring the MTU from the first device and / or the network element associated with the QP for user plane transmission.
[0043] Furthermore, the third device is a network element used for session management. The third device obtains the MTU from the first device, including: the network element for session management receiving a session request message from the first device, the session request message being used to request the establishment or modification of a QP-associated session, and the session request message including the MTU; the network element for session management obtaining the MTU from the session request message; or; the third device is an access network device, and the third device obtains the MTU from the first device, including: the access network device receiving a Radio Resource Control (RRC) message from the first device, the RRC message being used to request the establishment / re-establishment of a QP-associated RRC connection, and the RRC message including the MTU; the access network device obtaining the MTU from the RRC message. That is, the existing establishment or modification process can be reused to obtain the MTU without introducing a new process, simplifying implementation.
[0044] Furthermore, the third device is a network element used for session management. This third device obtains the MTU from the network element used for user plane transmission, including: the network element used for session management receiving a session response message returned by the network element used for user plane transmission in response to a session request message. The session request message is used to request the establishment or modification of a QP-associated session, and the session response message includes the MTU; the network element used for session management obtains the MTU from the session response message. That is, the existing establishment or modification process can be reused to obtain the MTU without introducing a new process, simplifying implementation.
[0045] Fourthly, a communication apparatus is provided. This communication apparatus is used to perform the message transmission method described in any implementation of the first or third aspect.
[0046] In this application, the communication device described in the fourth aspect can be a terminal device or a network device, or a chip (system) or other component or assembly, or a device containing the terminal device or network device. The aforementioned chip (system) or other component or assembly can all be applied to the terminal device or network device.
[0047] It should be understood that the communication apparatus described in the fourth aspect includes modules, units, or means that implement the message transmission method described in either the first or third aspect. These modules, units, or means can be implemented in hardware, software, or by hardware executing corresponding software. The hardware or software includes one or more modules or units for performing the functions involved in the aforementioned message transmission method.
[0048] Fifthly, a communication apparatus is provided. The communication apparatus includes at least one processor configured to execute the message transmission method described in any possible implementation of the first or third aspect.
[0049] In one possible design, the communication device described in the fifth aspect may further include a transceiver. This transceiver may be a transceiver circuit or an interface circuit. The transceiver can be used for communication between the communication device described in the fifth aspect and other communication devices.
[0050] In one possible design, the communication device described in the fifth aspect may further include a memory. This memory may be integrated with at least one processor or may be disposed separately. The memory may be used to store computer programs and / or data related to the message transmission method described in either the first or third aspect.
[0051] In this application, the communication device described in the fifth aspect can be a terminal device or a network device, or a chip (system) or other component or assembly, or a device containing the terminal device or network device. The aforementioned chip (system) or other component or assembly can all be disposed within the terminal device or network device.
[0052] A sixth aspect provides a communication device. The communication device includes: at least one processor coupled to a memory, the at least one processor being configured to execute a computer program stored in the memory, such that the communication device performs the message transmission method described in any possible implementation of the first or third aspect.
[0053] In one possible design, the communication device described in the sixth aspect may further include a transceiver. This transceiver may be a transceiver circuit or an interface circuit. The transceiver can be used for communication between the communication device described in the sixth aspect and other communication devices.
[0054] In this application, the communication device described in the sixth aspect can be a terminal device or a network device, or a chip (system) or other component or assembly, or a device containing the terminal device or network device. The aforementioned chip (system) or other component or assembly can all be disposed within the terminal device or network device.
[0055] A seventh aspect provides a communication device, comprising: at least one processor and a memory; the memory being used to store a computer program, which, when executed by the at least one processor, causes the communication device to perform the message transmission method described in any implementation of the first or third aspect.
[0056] In one possible design, the communication device described in the seventh aspect may further include a transceiver. This transceiver may be a transceiver circuit or an interface circuit. The transceiver can be used for communication between the communication device described in the seventh aspect and other communication devices.
[0057] In this application, the communication device described in the seventh aspect can be a terminal device or a network device, or a chip (system) or other component or assembly, or a device containing the terminal device or network device. The aforementioned chip (system) or other component or assembly can all be disposed within the terminal device or network device.
[0058] Eighthly, a communication apparatus is provided, comprising: at least one processor; said at least one processor is configured to be coupled to a memory, and after reading a computer program from the memory, to execute a message transmission method as described in any implementation of the first or third aspect according to the computer program.
[0059] In one possible design, the communication device described in the eighth aspect may further include a transceiver. This transceiver may be a transceiver circuit or an interface circuit. The transceiver can be used for communication between the communication device described in the eighth aspect and other communication devices.
[0060] In this application, the communication device described in the eighth aspect can be a terminal device or a network device, or a chip (system) or other component or assembly, or a device containing the terminal device or network device. The aforementioned chip (system) or other component or assembly can all be disposed within the terminal device or network device.
[0061] A ninth aspect provides at least one processor. The at least one processor is configured to execute the message transmission method described in any possible implementation of the first or third aspect.
[0062] A tenth aspect provides a communication system. The communication system includes a first means for performing the method described in the first aspect, and a second means for performing the method described in the second aspect.
[0063] Optionally, the communication system further includes a third means for performing the method described in the third aspect above.
[0064] Eleventhly, a computer-readable storage medium is provided, comprising: a computer program or instructions; when the computer program or instructions are executed on a computer, the computer causes the computer to perform the message transmission method described in any possible implementation of the first or third aspect.
[0065] In a twelfth aspect, a computer program product is provided, comprising a computer program or instructions that, when executed on a computer, cause the computer to perform the message transmission method described in any possible implementation of the first or third aspect.
[0066] Furthermore, the technical effects of the communication devices described in the fourth to twelfth aspects above can be referred to the technical effects of the message transmission methods described in the first or third aspects above, and will not be repeated here. Attached Figure Description
[0067] Figure 1 is a schematic diagram of RDMA application scenarios;
[0068] Figure 2 is a schematic diagram of the IB architecture;
[0069] Figure 3 is a schematic diagram of the QP connection;
[0070] Figure 4 is a schematic diagram of the RDMA message format;
[0071] Figure 5 is a schematic diagram of the prior art;
[0072] Figure 6 is a schematic diagram of the prior art;
[0073] Figure 7 is a schematic diagram of the architecture of the communication system provided in an embodiment of this application;
[0074] Figure 8 is a flowchart illustrating the message transmission method provided in an embodiment of this application;
[0075] Figure 9 is a schematic diagram of an application scenario of the message transmission method provided in the embodiments of this application;
[0076] Figure 10 is a schematic diagram of the second application scenario of the message transmission method provided in the embodiment of this application;
[0077] Figure 11 is a schematic diagram of the third application scenario of the message transmission method provided in the embodiment of this application;
[0078] Figure 12 is a schematic diagram of an application scenario of the message transmission method provided in the embodiments of this application;
[0079] Figure 13 is a second structural schematic diagram of the communication device provided in an embodiment of this application;
[0080] Figure 14 is a schematic diagram of the structure of the communication device provided in the embodiment of this application. Detailed Implementation
[0081] The technical solutions of this application embodiment can be applied to various communication systems, such as Wi-Fi wireless network systems, vehicle-to-everything (V2X) communication systems, device-to-device (D2D) communication systems, vehicle-to-everything (V2X) communication systems, fourth-generation (4G) mobile communication systems, such as long-term evolution (LTE) systems, worldwide interoperability for microwave access (WiMAX) communication systems, fifth-generation (5G) mobile communication systems, such as new radio (NR) systems, and future communication systems.
[0082] The technical terms and related technical solutions in this application will be described below with reference to the accompanying drawings.
[0083] Remote direct memory access (RDMA):
[0084] For high-performance computing, big data analytics, and other applications requiring high concurrency and low latency input / output (IO), the existing TCP / IP hardware and software architecture cannot meet the application requirements. This is mainly because traditional TCP / IP network communication involves sending messages through the kernel, which incurs significant overhead from data movement and copying. RDMA technology was developed to address the latency in server-side data processing during network transmission. As shown in Figure 1, RDMA technology can directly access memory data through the network interface, eliminating the need for data to be moved from the central processing unit (CPU) to the kernel and then from the kernel to the network card. It also eliminates the need for operating system kernel intervention (the RDMA network card directly reads application (APP) data from memory, without CPU intervention for data movement). This allows for high-throughput, low-latency network communication, making it suitable for use in large-scale parallel computer clusters. When speeds reach 40 gigabits per second (Gbps), traditional TCP / IP transmission methods typically result in CPU utilization of up to 100%; while using an RDMA network card, CPU utilization is typically around 5%.
[0085] RDMA protocol stack:
[0086] InfiniBand (IB) is a Remote DMA (Remote Data Access) technology based on the IB architecture. It provides a channel-based point-to-point message queue forwarding model, allowing each application to directly access its own data messages through a created virtual channel without the need for other operating systems or protocol stacks. The application layer of the IB architecture utilizes RDMA technology to provide RDMA read / write access between remote nodes, offloading CPU workloads. Network transmission employs high-bandwidth transmission, and the link layer uses specific retransmission mechanisms to ensure quality of service, eliminating the need for data buffering.
[0087] The Ethernet-based RDMA (RDMA over converged Ethernet, RoCE) protocol has two versions: RoCE v1 and RoCE v2. RoCE v1: RDMA is carried over Ethernet and deployed in Layer 2 networks. Its message structure adds a Layer 2 Ethernet header to the existing IB architecture, identifying RoCE messages using the Ethernet type 0x8915. RoCE v2: RDMA is carried over the User Datagram Protocol (UDP) / IP protocol and can be deployed in Layer 3 networks. Its message structure adds a UDP header, an IP header, and a Layer 2 Ethernet header to the existing IB architecture, identifying RoCE messages using the UDP destination port number 4791.
[0088] The Internet Wide-Area RDMA protocol (iWARP) is an RDMA technology based on Ethernet and TCP / IP protocols, capable of running on standard Ethernet infrastructure. iWARP does not specify physical layer information, thus it can work on any network layer using the TCP / IP protocol. iWARP allows many transport types to share the same physical connection, such as network, I / O, file systems, block storage, and inter-processor message communication.
[0089] RDMA Basic Service Types:
[0090] The basic communication unit of RDMA is the queue pair (QP). There are many communication models based on QP, which are referred to as "service types" in the RDMA field. In the IB protocol, a service type is described through two dimensions: "reliability" and "connectivity".
[0091] Reliability: In communication, reliability refers to ensuring that all sent data packets are received correctly through mechanisms. That is, "a reliable service guarantees that information is delivered at most once between the sender and receiver, and that it is received completely in the order it was sent." RDMA can guarantee reliability through three mechanisms:
[0092] 1) Acknowledgment Mechanism: The sender sends a data packet to the receiver. Upon receiving it, the receiver replies with a "Received" message, thus informing the sender that the receiver has received the data packet. In the field of communications, this reply from the receiver is generally called an acknowledgment packet (ACK). In the IB protocol's reliable service type, an acknowledgment mechanism is used to ensure that data packets are received by the other party. In IB's reliable service type, the receiver does not necessarily reply to every packet; it can also reply with ACKs for multiple packets at once.
[0093] 2) Data verification mechanism: The sending end calculates a checksum for the header and payload using a specific algorithm and places it at the end of the data packet. The receiving end, upon receiving the data packet, also calculates its checksum using the same algorithm and compares it with the checksum in the data packet. If they do not match, it indicates an error in the data (usually caused by a link problem), and the receiving end will discard the data packet.
[0094] 3) Order Preservation Mechanism: The order preservation mechanism ensures that data packets sent to the physical link first are received by the receiver before data packets sent later. For example, some services require the order of data packets, such as voice or video. The IB protocol defines the concept of packet sequence number (PSN), which is an incrementing code for each data packet. This PSN is used to detect packet loss. For instance, if the receiver receives a data packet with PSN=1 but receives a data packet with PSN=3 before receiving a data packet with PSN=2, the receiver will consider an error to have occurred during transmission and send a negative acknowledge (NACK) to the sender, requesting the sender to retransmit the lost data packet.
[0095] Connection: In the IB protocol, a connection is usually a logical concept, distinct from a physical connection. A connection is a communication "pipeline." Once the pipeline is established, data packets sent from one end of the pipeline will travel along it to the other end. As shown in Figure 2, each QP maintains a connection with the QPs it establishes a connection with. The QP maintains this information. For example, if QPs of 5 nodes need to communicate with each other, then 20 QPs of 5*(5-1) need to be established. The context maintenance between QPs consumes network card resources, resulting in significant overhead.
[0096] In contrast to connections, datagrams do not require a "pipeline" between the sender and receiver, guaranteeing physical reachability. The sender can send data to any receiver from any path. Therefore, the IB protocol defines a datagram as follows: For datagram services, a QP (Queued Message) is not bound to a single remote node, but rather the destination node is specified through a work queue element (WQE). Similar to connection-type services, establishing communication requires exchanging information between the two ends; however, datagram services perform this exchange once for each destination node. As shown in Figure 2, communication between five nodes requires establishing five QPs. The QP context information for datagram services is less than that for connection-type services, resulting in lower overhead.
[0097] The aforementioned reliability and connection / datagram combinations include four types: Reliable and Connection (RC), Unreliable and Connection (UC), Reliable and Datagram (RD), and Unreliable and Datagram (UD). RDMA supports RC, UC, RD, and UD, with RC and UD being the most common service types. RC is the mainstream approach, with a one-to-one QP relationship. Its characteristics are similar to TCP, ensuring reliability through ACK, PSN, and cyclic redundancy check (CRC). It does not support selective retransmission or out-of-order delivery; in case of an error, the entire message is retransmitted. RC supports send, read, write, and atomic operations, making it suitable for scenarios with high reliability and small node scale, such as distributed artificial intelligence (AI) and storage systems. UC also has a one-to-one QP relationship, characterized by not retransmitting packets in case of loss or errors. UC supports send and read operations, making it suitable for scenarios with low reliability requirements, high upper-layer application load, small node scale, and large message volume. UD's QP relationship is one-to-many, and its characteristics are similar to UDP, not guaranteeing in-order delivery. UD supports sending, making it suitable for scenarios where reliability is not required, the number of nodes is large, there is multi-node interaction, and multicast requirements, such as storage with three replicas.
[0098] RDMA data packets:
[0099] RDMA data packets, also known as RDMA messages, have a base transport header (BTH) in the RDMA transport layer (IB transport layer). The BTH contains an opcode field indicating the service type of the transport layer message. For example, the high 3 bits (000) indicate RC service type, 001 indicate UC service type, 010 indicate RD service type, and 011 indicate UD service type. The QP indicator field (or QP number) in the BTH is 24 bits in size, and the QP number ranges from 0 to 2. 24-1 .
[0100] The RDMA message format is shown in Figure 3. It includes the RDMA link layer header (local routing header, LRH), the RDMA network layer header (global routing header, GRH), the RDMA transport layer basic header (BTH), the RDMA transport layer extended transport header (ETH), the message payload, the R_Key or immediate data, the invariant cyclic shift code (CRC), and the variant cyclic shift code (CRC). There are several different types of ETH, such as the reliable datagram extended transport header (RDETH), the datagram extended transport header (DETH), and the RDMA extended transport header (RETH).
[0101] The GRH header carries source and destination GID information. The BTH header carries destination QP information, and the opcode in the BTH header indicates the service type of the QP and the specific extended header type. The DETH header carries source QP information, while other extended headers do not carry source QP information.
[0102] For a detailed introduction to RDMA, please refer to: https: / / www.afs.enea.it / asantoro / V1r1_2_1.Release_12062007.pdf.
[0103] Currently, the retransmission method for existing RDMA is go-back-Q retransmission. The maximum message size for RDMA transmit / write / read primitives is related to the service type. For RC, UC, and RD services, the maximum message size is 2 gigabytes (GBytes). The payload of the transport layer message is negotiated during link establishment to one of 256 / 512 / 1024 / 2048 / 4096 bytes, i.e., the maximum transmission unit (MTU). Therefore, message transmission is split into N packets, as shown in Figure 4. If one packet is lost or encounters a parsing error, that packet and all subsequent packets need to be retransmitted, such as retransmitting a packet with a PSN of Q+2. This method leads to a significant performance loss in communication; with a packet loss rate of 0.1%, there will be nearly a 50% performance loss for RDMA transmit / write. For example, as shown in Figure 5, when the message written by RDMA is 1 kilobyte and the MTU is 1024 bytes, the normalized system throughput is only 0.349 when the packet loss rate is 0.1%, resulting in a significant loss in system performance.
[0104] In addition, some network interface cards (NICs) provide an out-of-order reception mechanism for RDMA writes, as shown in Figure 6. This is achieved by splitting the write first, write middle, and write last messages into messages larger than the MTU, and sending them as individual write-only messages. Each write-only message includes a Retrieval Token (RETH) to ensure that any lost message is retransmitted separately. However, carrying a RETH in every message can lead to significant transmission overhead.
[0105] Therefore, in RDMA scenarios, how to balance system performance and transmission overhead is a current research problem.
[0106] To address the aforementioned technical problems, this application proposes the following technical solutions. The technical solutions in this application will now be described in conjunction with the accompanying drawings.
[0107] This application will present various aspects, embodiments, or features relating to systems that may include multiple devices, components, modules, etc. It should be understood and appreciated that individual systems may include additional devices, components, modules, etc., and / or may not include all the devices, components, modules, etc. discussed in conjunction with the accompanying drawings. Furthermore, combinations of these approaches are also possible.
[0108] Furthermore, in the embodiments of this application, words such as "exemplarily" and "for example" are used to indicate that something is an example, illustration, or description. Any embodiment or design that is described as an "example" in this application should not be construed as being better or more advantageous than other embodiments or designs. Rather, the use of the word "example" is intended to present the concept in a specific manner.
[0109] First, in this application, "for indicating" can include both direct and indirect indication. When describing "information" for indicating A, it can include whether the information directly indicates A or indirectly indicates A, but does not necessarily mean that the information carries A.
[0110] The information indicated by a given piece of information is called the information to be indicated. In the specific implementation process, there are many ways to indicate the information to be indicated, such as, but not limited to, directly indicating the information to be indicated, such as the information to be indicated itself or its index. It can also be indirectly indicated by indicating other information, where there is a relationship between the other information and the information to be indicated. It can also indicate only a part of the information to be indicated, while the other parts are known or pre-agreed upon. For example, the indication of specific information can be achieved by using a pre-agreed (e.g., protocol-defined) arrangement of various pieces of information, thereby reducing the indication overhead to some extent. At the same time, common parts of various pieces of information can be identified and indicated uniformly to reduce the indication overhead caused by individually indicating the same information.
[0111] Furthermore, the specific indication method can also be any existing indication method, such as, but not limited to, the above-mentioned indication methods and their various combinations. Specific details of various indication methods can be found in existing technologies, and will not be repeated here. As described above, for example, when multiple pieces of information of the same type need to be indicated, the indication methods for different pieces of information may differ. In the specific implementation process, the required indication method can be selected according to specific needs. This application embodiment does not limit the selected indication method; therefore, the indication methods involved in this application embodiment should be understood to cover various methods that enable the party to be indicated to obtain the information to be indicated.
[0112] The information to be instructed can be sent as a whole or divided into multiple sub-information messages, and the sending period and / or timing of these sub-information messages can be the same or different. This application does not limit the specific sending method. The sending period and / or timing of these sub-information messages can be predefined, for example, according to a protocol, or configured by the transmitting device by sending configuration information to the receiving device. This configuration information can include, for example, but not limited to, one or a combination of at least two of radio resource control (RRC) signaling, medium access control (MAC) layer signaling, and physical layer signaling. MAC layer signaling includes, for example, a MAC control element (CE); physical (PHY) layer signaling includes, for example, downlink control information (DCI).
[0113] Second, in the embodiments shown below, the first, second, and various numerical designations are merely distinctions for descriptive convenience and are not intended to limit the scope of the embodiments of this application. For example, to distinguish different indication information.
[0114] Third, "pre-defined," "pre-configured," or "pre-specified" can be achieved by pre-saving corresponding codes, tables, or other means of indicating relevant information in the device (e.g., including terminal devices and network devices), or by pre-defining them in a protocol. This application does not limit the specific implementation method. "Saving" can refer to saving in one or more memories. These memories can be separate installations or integrated into the encoder, decoder, processor, or communication device. Alternatively, some memories can be separately installed, while others are integrated into the decoder, processor, or communication device. The type of memory can be any form of storage medium, and this application does not limit this.
[0115] Fourth, the “protocol” involved in the embodiments of this application may refer to standard protocols in the field of communication, such as 3GPP’s LTE protocols (such as technical specification (TS) 36, i.e., the TS36 series of technical specifications), NR protocols (such as the TS38 series of technical specifications), and related protocols applied to future communication systems. This application does not limit this.
[0116] The network architecture and business scenarios described in the embodiments of this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided in the embodiments of this application. As those skilled in the art will know, with the evolution of network architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of this application are also applicable to similar technical problems.
[0117] The network architecture and business scenarios described in the embodiments of this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided in the embodiments of this application. As those skilled in the art will know, with the evolution of network architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of this application are also applicable to similar technical problems.
[0118] To facilitate understanding of the embodiments of this application, the communication system applicable to the embodiments of this application will be described in detail first using the communication system shown in FIG7 as an example. Exemplarily, FIG7 is a schematic diagram of the architecture of a communication system to which the method provided in the embodiments of this application is applicable.
[0119] As shown in Figure 7(a), the communication system may include a first device and a second device, and optionally, may also include a third device.
[0120] The first device can be a terminal device or a network device, and the second device can also be a terminal device or a network device. The third device can be a network device. If the second device is a network device, the third device and the second device can be the same network device or different network devices, subject to specific limitations.
[0121] For example, as shown in FIG7(b), the network devices may include network devices 201a to 201c, and the terminal devices may include terminal devices 202a to 202f. The terminal devices may be connected to the network devices wirelessly, and the network may be connected to the core network via wired or wireless means.
[0122] Among them, network devices and terminal devices can exchange information.
[0123] Terminal equipment can be a terminal with transceiver capabilities, or it can be a chip or chip system installed in the terminal equipment. This terminal equipment can also be referred to as user equipment (UE), access terminal, subscriber unit, user station, mobile station (MS), mobile station, remote station, remote terminal, mobile device, user terminal, terminal, wireless communication equipment, user agent, or user device. The terminal devices in the embodiments of this application may be mobile phones, cellular phones, smartphones, tablets, wireless data cards, personal digital assistants (PDAs), wireless modems, handsets, laptop computers, machine-type communication (MTC) terminals, computers with wireless transceiver capabilities, virtual reality (VR) terminals, augmented reality (AR) terminals, smart home devices (e.g., refrigerators, televisions, air conditioners, electricity meters, etc.), intelligent robots, robotic arms, workshop equipment, wireless terminals in autonomous driving, wireless terminals in industrial control, wireless terminals in self-driving, wireless terminals in telemedicine, wireless terminals in smart grids, wireless terminals in transportation safety, wireless terminals in smart cities, wireless terminals in smart homes, vehicle-mounted terminals, and roadside units with terminal functions. The terminal device in this application can also be an onboard module, onboard unit, onboard component, onboard chip, or onboard unit built into a vehicle as one or more components or units. The terminal device can also be other devices with terminal functions; for example, it can be a device that performs terminal functions in D2D communication. The embodiments of this application do not limit the device form of the terminal device. The device used to implement the terminal function can be a terminal device; it can also be a device that supports the terminal in implementing the function, such as a chip system. This device can be installed in the terminal or used in conjunction with the terminal. In the embodiments of this application, the chip system can be composed of chips or include chips and other discrete devices.
[0124] Network devices can be devices with wireless transceiver capabilities, or they can be chips or chip systems located in the access network (AN) of a communication system to provide access services to terminals. For example, network devices can be called radio access network (RAN) devices, specifically future mobile communication systems, or network devices can have other naming conventions in future mobile communication systems, all of which are covered within the protection scope of the embodiments of this application, and this application does not impose any limitations on them. Alternatively, network equipment can also include 5G, such as a gNB in a New Radio (NR) system, or one or a group of antenna panels (including multiple antenna panels) of a 5G base station. It can also be network nodes constituting a gNB, transmission and reception point (TRP) or transmission point (TP), or transmission measurement function (TMF), such as a central unit (CU), distributed unit (DU), CU-control plane (CP), CU-user plane (UP), or radio unit (RU), RSU with base station functionality, or wired access gateway, or core network elements of 5G. Alternatively, network equipment can also include: access points (APs) in WiFi systems, wireless relay nodes, wireless backhaul nodes, various forms of macro base stations, micro base stations (also called small cells), relay stations, access points, wearable devices, vehicle-mounted equipment, etc.
[0125] CU and DU can be separate entities or included in the same network element, such as a baseband unit (BBU). RU can be included in radio frequency equipment or radio frequency units, such as remote radio units (RRUs), active antenna units (AAUs), or remote radio heads (RRHs). It is understood that network equipment can be CU nodes, DU nodes, or a combination of CU and DU nodes. Furthermore, CUs can be classified as network equipment in the access network (RAN) or the core network (CN), without limitation. In different systems, CUs (or CU-CPs and CU-UPs), DUs, or RUs may have different names, but their meanings will be understood by those skilled in the art. For example, in an ORAN system, a CU can also be called an O-CU (open CU), a DU can also be called an O-DU, a CU-CP can also be called an O-CU-CP, a CU-UP can also be called an O-CU-UP, and a RU can also be called an O-RU. For ease of description, this application uses CU, CU-CP, CU-UP, DU, and RU as examples. Any of the units among CU (or CU-CP, CU-UP), DU, and RU in this application can be implemented through software modules, hardware modules, or a combination of software and hardware modules. In the embodiments of this application, the form of the network device is not limited; the device used to implement the function of the network device can be the network device itself; it can also be a device capable of supporting the network device in implementing that function, such as a chip system. This device can be installed in the network device or used in conjunction with the network device.
[0126] Alternatively, network devices can also be core network elements, such as user plane function (UPF), authentication server function (AUSF), access and mobility management function (AMF), session management function (SMF), network slice selection function (NSSF), network exposure function (NEF), network repository function (NRF), policy control function (PCF), unified data management (UDM), unified data repository (UDR), and application function (AF), etc. In future communication systems, network devices can also be other network elements, or the above-mentioned network function elements can be combined or split, or their deployment locations can be adjusted, without any specific restrictions.
[0127] In a communication system, the first device can group / segment M RDMA messages, either automatically or according to the configuration of the third device. Each RDMA message group includes an address information header. This address information determines the address at which the RDMA message containing the address information is written to the memory of the second device. The addresses at which other RDMA messages within each group are written to the memory of the second device can then be determined based on this address information. On one hand, performing RDMA operations at the group level allows for writing to memory. RDMA messages from different groups can be written to the same or different memory regions, which can be discrete or contiguous, increasing the flexibility of RDMA operations. On the other hand, if an RDMA message in a group / segment is lost, the first device can retransmit only the RDMA messages following the lost message in that group / segment; messages from other groups do not need to be retransmitted. This reduces RDMA retransmission overhead and improves communication efficiency.
[0128] It should be understood that the message transmission method provided in this application embodiment can be applied to the devices shown in Figures 6-7, such as between the first device and the second device. Specific implementations can be found in the following method embodiments, which will not be repeated here. The solutions in this application embodiment can also be applied to other communication systems, and the corresponding names can be replaced with the names of the corresponding functions in other communication systems.
[0129] It should also be understood that Figures 6 and 7 are simplified schematic diagrams for ease of understanding only, and the communication system may also include other network devices and / or other terminal devices, which are not shown in Figures 6 and 7.
[0130] The interaction process between devices in the above-described communication system will be specifically described below with reference to Figure 8 and through method embodiments. The message transmission method provided in this application embodiment can be applied to the above-described communication system, such as the interaction between the first device and the second device, which will be described in detail below.
[0131] As shown in Figure 8, the process of this message transmission method is as follows:
[0132] S801, the first device acquires the first RDMA message.
[0133] The first RDMA message belongs to M RDMA messages, or any one of the M RDMA messages, where M is an integer greater than 1.
[0134] M RDMA messages belong to one RDMA message. For example, the M RDMA messages are part / all of the RDMA messages obtained by processing this RDMA message. For instance, this RDMA message is processed by the QP of the first device to obtain M RDMA messages. It can also be said that the M RDMA messages correspond to this QP, or that the QP contains M RDMA messages. An RDMA message can be an RDMA write message, or a message indicating an RDMA write operation, or any other possible name. It can also be an RDMA send message, or a message indicating an RDMA send operation, or any other possible name; there is no specific limitation. If the RDMA message is an RDMA write message, then the M RDMA messages can be RDMA write messages, that is, the first RDMA message can also be an RDMA write message. If the RDMA message is an RDMA send message, then the M RDMA messages can be RDMA send messages, that is, the first RDMA message can also be an RDMA send message.
[0135] M RDMA messages include One RDMA message group, To round up, let K is an integer greater than 1. Each of the K RDMA packet groups contains one RDMA packet whose header includes address information. N is a positive integer less than M. For example, if M = 100 and N = 10, then K = 10, meaning 10 RDMA packet groups, each containing 10 RDMA packets. Alternatively, if M = 53 and N = 7, then K = 8, meaning 8 RDMA packet groups. The first to seventh RDMA packet groups each contain 7 RDMA packets, and the eighth RDMA packet group each contains 4 RDMA packets. The group containing 4 RDMA packets can also be any packet group, and its position or index within the 8 RDMA packet groups is not restricted. The number of RDMA packets contained in each RDMA packet group is the packet length of that RDMA packet group. The packet lengths can be the same or different. For ease of understanding, this application uses the example of a packet length of N.
[0136] Address information can be used to determine the address of the RDMA message containing address information to be written into the memory of the second device, such as the address of the first RDMA message or the group identifier, as detailed below. It is used to determine the address of the remaining N-1 RDMA messages that belong to the same RDMA message group as the first RDMA message.
[0137] The value of N can be dynamic. For example, M RDMA packets correspond to a certain QP. The packet loss rate of the RDMA packets of the QP is negatively correlated with the value of N. For example, the higher the packet loss rate, the smaller the value of N, and vice versa. In other words, the packet loss rate of the RDMA packets of the QP can determine the packet length N of the RDMA packets processed by the QP, so as to realize dynamic packetization according to the packet loss rate, taking into account system performance and transmission overhead. For example, when the RDMA packet loss rate is >2.6*10e-2, each RDMA packet is a group of RDMA packets, i.e., N=1; when the RDMA packet loss rate is >3.5*10e-3, each group of 5 RDMA packets is a group of RDMA packets, i.e., N=5; when the RDMA packet loss rate is >4.5*10e-3, each group of 10 RDMA packets is a group of RDMA packets, i.e., N=10; when the RDMA packet loss rate is <4.5*10e-3, each group of 50 RDMA packets is a group of RDMA packets, i.e., N=50.
[0138] It can be seen that when the packet loss rate is low, retransmissions are infrequent, so the value of N can be configured to be relatively large, resulting in a smaller proportion of overhead for address information and lower transmission overhead. When the packet loss rate is high, retransmissions occur frequently. The first device performs retransmissions at the packet level, such as retransmitting up to N RDMA packets. Therefore, the value of N can be configured to be relatively small to reduce retransmission overhead and thus ensure system performance.
[0139] Specifically, the header of the first RDMA message in each of the K RDMA message groups can contain address information. That is, the header of the (a-1)*N+1th RDMA message in the M RDMA messages can contain address information, such as the 1st RDMA message, the N+1th RDMA message, the 2N+1th RDMA message, etc., where a is an integer from 1 to K, K is an integer greater than 1, and (K-1)*N+1 is less than or equal to M. This means that the last RDMA message containing address information also belongs to the M RDMA messages. This ensures that the RDMA message carrying address information belongs to the M RDMA messages and avoids writing other RDMA messages into the memory space of the M RDMA messages by mistake.
[0140] It is understood that the header of the first RDMA message in each RDMA message group mentioned above containing address information is only one example. It could also be the 1+xth RDMA message in each RDMA message group. For example, the header of the (a-1)*N+1+xth RDMA message in M RDMA messages can contain address information, where x is a positive integer and (K-1)*N+1+x is less than or equal to M. The specific implementation is similar to the above, and can be understood by referring to it.
[0141] For ease of understanding, let's take the first RDMA message as an example:
[0142] Each RDMA message has its own sequence number (e.g., PSN) to uniquely identify it. If 1000 RDMA messages need to be transmitted, their sequence numbers can range from 1 to 1000. Let X be the sequence number of the first RDMA message and Y be the sequence number of the first RDMA message among M RDMA messages. If (XY) modulo N is 0, and (XY)*MTU is less than the size of the M RDMA messages, or in other words, XY is less than M, then the first RDMA message belongs to the M RDMA messages and is the (a-1)*N+1th RDMA message. In this case, the header of the first RDMA message can contain the address information mentioned above. It should be understood that if XY = 0, the first RDMA message is the first RDMA message; if XY ≠ 0, the first RDMA message is not the first RDMA message, such as an intermediate RDMA message.
[0143] MTU is the maximum transmission unit of the first RDMA message, which can be negotiated between the first device and the second device.
[0144] Method 1:
[0145] When the header of the first RDMA message carries address information, the header of the first RDMA message can be a RETH, and the aforementioned address information is carried in the RETH, specifically the address of the first RDMA message. The address of the first RDMA message can be the address where the first RDMA message is written to the memory of the second device, such as a virtual address (VA). The address used to write the first RDMA message to the memory of the second device can be determined based on the address of the first RDMA message. For specific implementation details, please refer to the relevant introduction of S803 below, which will not be repeated here.
[0146] Optionally, if the first RDMA message contains RETH, the BTH of the first RDMA message may also contain indication information. This indication information can indicate that the first RDMA message contains RETH to avoid errors in unpacking by the second device. For example, the BTH of the first RDMA message contains 15 reserved bits, of which 1 bit can be used. A value of 1 indicates indication information, a value of 0 indicates no indication information is contained, or it is a blank bit. Other implementation methods are also possible, and there are no specific limitations. Example 1 illustrates this below.
[0147] Example 1:
[0148] The first device (e.g., the application layer) can generate corresponding RDMA messages based on the RDMA service, such as generating an RDMA write message for an RDMA write operation and an RDMA send message for an RDMA send operation, and obtain the message size and packet MTU of the RDMA message. The first device can process the RDMA messages to obtain RDMA packets (such as the M RDMA packets mentioned above). For the first RDMA packet, the first device can record the sequence number of the first RDMA packet, such as PSN_first, and the address carried by the RETH of the first RDMA packet, such as the virtual address (VA_First) of the first RDMA packet. For any intermediate RDMA packet, i.e., neither the first nor the last RDMA packet, the first device can obtain the sequence number of the intermediate RDMA packet, such as PSN_middle, and determine PSN_middle - PSN_first, denoted as the PSN offset. The first device can determine whether the PSN offset modulo N is 0, or whether the value of the PSN offset modulo N is 0, and whether the PSN offset * MTU is less than the message size of the RDMA message. If the PSN offset modulo N is 0 and the PSN offset * MTU is less than the message size of the RDMA message, it indicates that the intermediate RDMA message is the (a-1)*N+1th RDMA message. The first device uses the newly defined processing method of this application to add RETH to the intermediate RDMA message, set the address carried by the RETH to VA_First, and add indication information to the BTH of the intermediate RDMA message to indicate that the intermediate RDMA message carries RETH. For example, as shown in Figure 9, when N=3, the intermediate RDMA message with PSN=4 adds RETH and carries VA_First. If the PSN offset modulo N is not 0, or the PSN offset * MTU is greater than the message size of the RDMA message, the first device uses the existing method for processing, which will not be elaborated further.
[0149] It should be understood that in the above examples, the processing of RDMA messages / packets by the first device can be implemented by the QP of the first device, such as the QP associated with the RDMA service, or it can be implemented by other software / functions / entities of the first device. In some scenarios, such as distributed scenarios, it can also be replaced by devices other than the first device. The embodiments of this application do not impose specific limitations, and the relevant content involved below is also the same and will not be repeated.
[0150] Method 2:
[0151] When address information is carried in the header of the first RDMA message, the header of the first RDMA message is BTH. The aforementioned address information can be carried in the BTH, eliminating the need for an additional extended header and further reducing overhead. For example, the address information can specifically be the packet identifier of the RDMA message group to which the first RDMA message belongs, specifically the packet number, packet sequence number, or packet index, such as the packet identifier. The address used to write the first RDMA message to the memory of the second device, indicating rounding down, can be determined based on the address of the first RDMA message and the group identifier. For specific implementation details, please refer to the relevant description in S803 below, which will not be repeated here. The group identifier can be carried by a portion of the 15 bits reserved in BTH. For example, 4 bits: 0000 represents N0=0, i.e., the 0th RDMA message group; 0001 represents N0=1, i.e., the 1st RDMA message group; 0010 represents N0=2, i.e., the 2nd RDMA message group; and so on, with 1111 representing N0=15, i.e., the 15th RDMA message group. This will be illustrated in Example 2 below.
[0152] Example 2:
[0153] The first device can generate a corresponding RDMA message according to the RDMA service and obtain the message size and MTU of the RDMA packet. The first device can process the RDMA message to obtain the RDMA packet. For the first RDMA packet, the first device can record the packet sequence number of the first RDMA packet, such as PSN_first. For any intermediate RDMA packet, the first device can obtain the packet sequence number of the intermediate RDMA packet, such as PSN_middle, and determine PSN_middle - PSN_first, denoted as the PSN offset. The first device can determine whether the PSN offset modulo N is 0. If the PSN offset modulo N is 0, the first device adopts the newly defined processing method of this application to add a group identifier to the BTH of the intermediate RDMA packet, such as... For example, as shown in Figure 10, when N=3, a packet identifier is added to the BTH of the intermediate RDMA message with PSN=4. If the PSN offset modulus N is not 0, the first device will process it in the existing way, which will not be elaborated on in detail.
[0154] S802, the first device sends a first RDMA message to the second device. The second device receives the first RDMA message.
[0155] The first device and the second device can establish a transmission path. For example, the first device may be a terminal device and the second device may be an access network device, or the first device may be an access network device and the second device may be a terminal device. An air interface connection can be established between the terminal device and the access network device. Alternatively, the first device may be a terminal device and the second device may be a network element used for user plane transmission, such as a UPF network element or any other possible designation. Or, the first device may be a user plane network element and the second device may be a terminal device. A user plane tunnel can be established between the terminal device and the network element used for user plane transmission. Therefore, the first device can send a first RDMA message to the second device through this transmission path, and correspondingly, the second device can receive the first RDMA message through this transmission path.
[0156] S803, the second device writes the first RDMA message.
[0157] When the header of the first RDMA message carries address information, the second device can determine the address of the first RDMA message based on this address information. For example, if the first RDMA message is the first RDMA message, the second device can obtain the address of the first RDMA message from the address information; the address of the first RDMA message is the address of the first RDMA message. If the first RDMA message is not the first RDMA message, the second device can determine the offset of the address of the first RDMA message relative to the address of the first RDMA message among the M RDMA messages based on the address information, and determine the address of the first RDMA message based on the address of the first RDMA message and the offset. The address of the first RDMA message can be the address where the first RDMA message is written to the memory of the second device, such as a virtual address, or any other possible form of address. The following sections will further describe these two methods.
[0158] Method 1:
[0159] The second device can determine the offset of the address of the first RDMA message relative to the address of the first RDMA message based on the sequence number of the first RDMA message, the sequence number of the first RDMA message, and the MTU. For example, this offset could be (XY)*MTU. Based on this, the second device can determine the address of the first RDMA message using this offset and the address of the first RDMA message. For instance, the offset plus the address of the first RDMA message equals the address of the first RDMA message. In other words, given a determined offset, the second device only needs the address of the first RDMA message obtained from the RETH to determine the address of the first RDMA message, which is simple and efficient.
[0160] Method 2:
[0161] The second device can determine the offset of the address of the first RDMA message relative to the address of the first RDMA message based on the address information carried in the BTH of the first RDMA message and the packet length N. For example, if the offset is... The packet length N can be pre-configured for the second device or determined by the second device itself, such as by the difference between the sequence number of the first RDMA message and the sequence number of the first RDMA message, i.e., XY = N. The MTU can be negotiated in advance. Therefore, the second device only needs the sequence number obtained from the BTH to determine the offset, which is simple and efficient. Based on this, the second device can determine the address of the first RDMA message according to the offset and the address of the first RDMA message.
[0162] Having obtained the address of the first RDMA packet, since this address is a virtual address, the second device can translate it into a physical address and then write the first RDMA packet into the memory of the second device at the location pointed to by that physical address. With the address of the first RDMA packet determined, subsequent RDMA packets in the RDMA packet group containing the first RDMA packet can be written sequentially according to the address of the first RDMA packet. The two examples will be further described below.
[0163] It is understandable that when address information is carried in the header of a non-first RDMA message, this address information can be not only the address or packet identifier of the first RDMA message, but also the address of the non-first RDMA message, or the offset of the address of the non-first RDMA message relative to the address of the first RDMA message.
[0164] Example 1:
[0165] When the second device receives the first RDMA packet, the first device can record the packet sequence number of the first RDMA packet, such as PSN_first, and the address of the first RDMA packet, such as the virtual address (VA_First) carried in the RETH of the first RDMA packet. The second device can convert the address of the first RDMA packet to a physical address and write the first RDMA packet into the memory location pointed to by that physical address. When the second device receives any intermediate RDMA packet, it can obtain the packet sequence number of the intermediate RDMA packet, such as PSN_middle. The second device can determine whether the intermediate RDMA packet carries a RETH. If the intermediate RDMA packet does not carry a RETH, the second device processes it using existing technology, which will not be elaborated further. If the intermediate RDMA packet carries a RETH, the second device processes it using the method newly defined in this application. For example, the second device can determine whether the RETH of the intermediate RDMA packet is the same as that of the first RDMA packet, i.e., whether they contain the same address. If the addresses are different, no processing is done; if the addresses are the same, the second device can determine the offset, i.e., (PSN_middle - PSN_first) * MTU, and determine the address of the intermediate RDMA packet, i.e., the offset + the address of the first RDMA packet. The second device can convert the address of the intermediate RDMA packet to a physical address and write the intermediate RDMA packet into the memory location pointed to by that physical address. For the next RDMA packet after the intermediate RDMA packet, the second device writes sequentially after the physical address of the intermediate RDMA packet until it receives another intermediate RDMA packet carrying RETH, or receives the last RDMA packet.
[0166] Example 2:
[0167] The second device receives the first RDMA message, such as the first RDMA write / transmit message. For the first RDMA write message, the first device can record the packet sequence number of the first RDMA write message, such as PSN_first, and the address of the first RDMA write message, such as the virtual address (VA_First) carried in the RETH of the first RDMA write message. For the first RDMA transmit message, the first device can record the packet sequence number of the first RDMA write message and obtain the virtual address in the WQE associated with the RDMA transmit operation, and record it as the address of the first RDMA write message. The second device can convert the address of the first RDMA message into a physical address and write the first RDMA message into the memory location pointed to by that physical address. When the second device receives any intermediate RDMA message, the second device can determine whether the BTH of the intermediate RDMA message carries a packet identifier. If the BTH of the intermediate RDMA message does not carry a packet identifier, the second device will process it using existing technology, which will not be elaborated further. If the BTH of the intermediate RDMA message carries a packet identifier, the second device will process it using the method newly defined in this application. For example, the second device can determine the offset, i.e. The second device determines the address of the intermediate RDMA message, such as offset plus the address of the first RDMA message. The second device can translate the address of the intermediate RDMA message into a physical address and write the intermediate RDMA message into the memory location pointed to by that physical address. For the next RDMA message following this intermediate RDMA message, the second device sequentially writes after the physical address of the intermediate RDMA message until it receives another intermediate RDMA message carrying RETH, or receives the last RDMA message.
[0168] In summary, for M RDMA messages, each group (or RDMA message group) / segment containing RDMA messages is used as a unit. In each RDMA message group, an RDMA message header containing address information is set. This address information is used to determine the address of the RDMA message containing the address information to be written to the memory of the second device. The address of other RDMA messages in each group to be written to the memory of the second device can be determined based on this address information. That is, RDMA operation is performed at the group level to write to memory. For example, RDMA messages from different groups can be written to the same or different memory regions. These regions can be discrete or continuous, which can improve the flexibility of RDMA operation.
[0169] Optionally, in conjunction with the process shown in Figure 8 above, the method may further include:
[0170] S804a, the second device sends feedback information. Correspondingly, the first device receives the feedback information from the second device.
[0171] Feedback information can be carried in the NACK message. The feedback information indicates that the second RDMA message has been lost. The second RDMA message belongs to M RDMA messages. The feedback information can include the sequence number of the second RDMA message. Optionally, it can also include information about the QP corresponding to the M RDMA messages, such as the QP identifier.
[0172] S804b, based on the feedback information, the first device retransmits Q RDMA messages out of the M RDMA messages to the second device. Correspondingly, the second device receives Q RDMA messages out of the M RDMA messages retransmitted by the first device.
[0173] Q is a positive integer. The Q RDMA messages can include: from the second RDMA message to the last RDMA message in the RDMA message group containing the second RDMA message. That is, only a portion of the RDMA messages in the group containing the second RDMA message needs to be retransmitted, and the RDMA messages in other groups do not need to be retransmitted, resulting in low retransmission overhead. For example, the first device can determine the group in which the second RDMA message is located within the M RDMA messages based on the packet sequence number of the second RDMA message, or optionally based on the identifier of QP, and thus determine that all messages in that group from the second RDMA message to the end of the group need to be retransmitted. For example, if N=10, and the second RDMA message is the 4th RDMA message, the first device will retransmit the 4th RDMA message to the 10th RDMA message.
[0174] Optionally, in conjunction with the process shown in Figure 8 above, the method may further include:
[0175] S800a, the third device obtains the RDMA packet loss rate of QP.
[0176] In one possible design, the third device can be a core network element, such as a network element used for session management, specifically an SMF network element, or any other possible name, without limitation. The network element used for session management can obtain the RDMA packet loss rate from at least one of the following network elements associated with QP: a network element used for policy management, a network element used for user plane transmission, or an access network device, which will be described below.
[0177] 1) When establishing or modifying a QP-associated session, the network element used for session management obtains the session's policy and charging control (PCC) rules from the network element used for policy management.
[0178] The session associated with a QP can be a session established or modified for that QP, such as a Protocol Data Unit (PDU) session. This session can be used to carry / transmit the services associated with that QP, such as the RDMA service mentioned above. When establishing or modifying a session, the terminal device (such as the first device / second device) can send the QP's identifier to the network side, such as by including it in a PDU session establishment or modification request message, to trigger the network side to establish or modify the session associated with the QP. For details, please refer to the existing session establishment or modification procedures, which will not be elaborated here.
[0179] The network element used for policy management can be a PCF network element, or any other possible name, without any restrictions.
[0180] The aforementioned PCC rules can be initial or updated. For example, in the session establishment process, the network element used for session management can obtain the initial PCC rules from the network element used for policy management and subscribe to PCC rule update events. In the session modification process, the network element used for policy management can update the PCC rules according to the application function requirements and respond to the update event by sending the updated PCC rules to the network element used for session management. At this time, the network element used for session management can obtain the updated PCC rules.
[0181] Therefore, the network element used for session management can obtain the packet error rate (PER) in the PCC rules. This PER can be used as the RDMA packet loss rate. That is, the existing session establishment or modification process can be reused to obtain the RDMA packet loss rate without introducing a new process, which is simple to implement. Of course, the RDMA packet loss rate can also be obtained from the network element used for policy management through a newly defined process. The specific implementation is not limited.
[0182] 2) The network element used for session management obtains the packet loss rate of the data radio bearer (DRB) or quality of service (QoS stream) associated with the QP from the access network equipment.
[0183] The packet loss rate of the DRB or QoS flow associated with QP can be used as the packet loss rate of RDMA packets. For example, if there is only one DRB or QoS flow associated with QP, the packet loss rate of that DRB or QoS flow can be used as the packet loss rate of RDMA packets. If there are multiple DRB or QoS flows associated with QP, the average, maximum / minimum value of the packet loss rates of these multiple DRB or QoS flows can be used as the packet loss rate of RDMA packets.
[0184] Network elements used for session management can obtain RDMA packet loss rates from access network devices through existing subscription methods, without introducing additional procedures, making implementation simple. Specifically, during the establishment or modification of QP-associated sessions, the access network device can map the QP-associated session to QoS flows and DRBs based on the QoS configuration of the network element used for session management. This allows the access network device to know which QoS flows and DRBs the QP is associated with. Subsequently, the network element used for session management can (e.g., during the paging phase of the terminal device, or at any other possible time) send a subscription request to the access network device. This subscription request may include the QP's identifier and one or more threshold information to subscribe to packet loss rate change events of the QoS flows or DRBs associated with the QP. The access network device can determine whether the packet loss rate of the QoS flows or DRBs associated with the QP has changed above / below a certain threshold based on the subscription request. If so, the access network device can respond to the subscription request by sending a subscription response to the network element used for session management, which indicates the packet loss rate of the QoS flows or DRBs associated with the QP. Otherwise, the access network device may not respond to the subscription request.
[0185] It is understandable that the above methods are just some examples. For instance, network elements used for session management can also periodically obtain RDMA packet loss rates from access network devices.
[0186] 3) The network element used for session management obtains the PER associated with QP from the network element used for user plane transmission, such as the PER in the downlink data of the QP-associated session. This PER is used as the RDMA packet loss rate. At this time, the existing N4 session process can be reused to obtain the RDMA packet loss rate from the network element used for user plane transmission without introducing additional processes, which is simple to implement.
[0187] The network element used for user plane transmission can be a UPF network element, or any other possible name, without specific restrictions. The network element used for session management can configure the session for user plane transmission during the establishment or modification of the QP-associated session, such as including the QoS flow identifier (QFI) for the session. Subsequently, the network element used for session management can (e.g., periodically, or at any possible time) send an N4 message to the network element used for user plane transmission, such as a session request message carrying the session identifier, to instruct the network element used for user plane transmission to provide the QFI information for the QP-associated session. Correspondingly, the network element used for user plane transmission can respond to the N4 message by returning QFI information, such as a session response message carrying the QFI information, which may include the PER of the downlink data for the session.
[0188] In another possible design, the third device is an access network device. The access network device obtains the packet loss rate of the DRB or QoS flow associated with the QP. The access network device can periodically calculate the packet loss rate of the DRB or QoS flow associated with the QP locally, or at any possible time. This packet loss rate is used as the RDMA packet loss rate, meaning it obtains the data locally without signaling interaction, thus avoiding the communication overhead associated with interaction. Alternatively, when establishing or modifying a QP-associated session, the access network device obtains the session's QoS configuration from the network element used for policy management (specifically, this configuration can be passed to the access network device by the network element used for session management), and obtains the PER from the QoS configuration. The PER is used as the RDMA packet loss rate. This allows reuse of existing session establishment or modification procedures to obtain the RDMA packet loss rate, without introducing new procedures, simplifying implementation.
[0189] In S800b, the third device sends configuration information to the first device where QP is located based on the RDMA message packet loss rate. Correspondingly, the first device receives the configuration information.
[0190] Configuration information can instruct that one RDMA packet in each RDMA packet group includes address information in its header, enabling dynamic configuration of the RDMA packet packet transmission method based on actual conditions, providing flexibility. For example, the configuration information can include the QP identifier and the packet length N, which together indicate that one of every N RDMA packets associated with the QP includes address information in its header.
[0191] It is understandable that the configuration information indicating a packet length of N does not mean that the first device has a packet length of N for each RDMA message group when grouping. As mentioned above, if M / N is not divisible, there may be an RDMA message group whose packet length is not N.
[0192] Optionally, the configuration information may also indicate grouping rules, such as the first RDMA message in each RDMA message group, such as the header of the (a-1)*N+1th RDMA message containing address information. For example, the configuration information may contain grouping rule information elements to indicate the grouping rule, such as 00 indicating that the header of the (a-1)*N+1th RDMA message contains address information, and 01 indicating that the header of the (a-1)*N+1+xth RDMA message contains address information.
[0193] The third device can pre-configure different RDMA packet loss rate intervals and their corresponding packet lengths N. For example, if the RDMA packet loss rate is >2.6*10e-2, N=1; if the RDMA packet loss rate is >3.5*10e-3, N=5; if the RDMA packet loss rate is >4.5*10e-3, N=10; and if the RDMA packet loss rate is <4.5*10e-3, N=50. The third device can determine the RDMA packet loss rate interval in which the obtained RDMA packet loss rate falls, and determine the packet length N corresponding to that RDMA packet loss rate interval. Therefore, the third device can generate and send configuration information to the first device where the QP is located based on the packet length N. The first device can then execute S801-S803 according to the configuration information.
[0194] It is understood that the packet length N is merely an exemplary name, and could also be called subGroup N, subpacket length N, or any other possible name, without any limitation. Furthermore, the first device may also pre-configure / predefine the packet length N according to the protocol; in this case, S800a-S800b may not need to be executed.
[0195] Optionally, in conjunction with the above S800a-S800b, the third device determines the packet length N by considering not only the RDMA message packet loss rate, but also the maximum transmission unit (MTU) of the RDMA message associated with QP.
[0196] The third device can obtain the MTU, such as from the first device and / or the network element used for user plane transmission.
[0197] For example, the third device is a network element used for session management:
[0198] The network element used for session management can receive session request messages, such as PDU session establishment or modification request messages, from the first device (terminal equipment) to request the establishment or modification of a QP-associated session. Specific implementation details can be found in the above description and will not be repeated here. The session request message may include the MTU, which the network element used for session management can obtain from the session request message. Alternatively, the network element used for session management can also receive a session response message returned by the session request message from the network element used for user plane transmission. The network element used for user plane transmission can be a QP-associated network element, such as the network element carrying the user plane management of the QP-associated session, or specifically, the second device mentioned above. The session request message is used to request the establishment or modification of the QP-associated session, and the session response message includes the MTU, meaning the network element used for user plane transmission can reuse the session response message to actively report the MTU. Thus, the network element used for session management can obtain the MTU from the session response message.
[0199] In other words, network elements used for session management can reuse existing session establishment or modification procedures to obtain the MTU without introducing new procedures, making implementation simple. Alternatively, it can also be achieved through a newly defined procedure, with no specific restrictions.
[0200] For example, the third device is an access network device:
[0201] The access network device can receive radio resource control (RRC) messages from the first device. These RRC messages can be used to request the establishment / re-establishment of an RRC connection, such as an RRC connection associated with a QP, or an RRC connection used to carry services for that QP (such as RDMA services). The RRC message may include the MTU, which the access network device obtains from the message. That is, the access network device can reuse existing RRC establishment or modification procedures to obtain the MTU without introducing new procedures, simplifying implementation. Alternatively, it can be implemented through a newly defined procedure; no specific restrictions are imposed.
[0202] Based on this, the third device can send configuration information to the first device according to the RDMA packet loss rate and MTU. That is, the RDMA packet size also needs to take the MTU into account to ensure more reasonable packet size. For example, the third device can first determine various packet loss rates for the RDMA packets corresponding to the MTU. Different MTUs correspond to different packet loss rates; for example, the larger the MTU, the lower the overall packet loss rate will be, thus ensuring system capacity. The third device can determine a packet loss rate that matches the RDMA packet loss rate from among the various packet loss rates. The matched packet loss rate corresponds to one value of N, i.e., the packet length N, and sends configuration information to the first device according to the matched packet loss rate. For specific implementation details, please refer to the relevant introduction of S800b above, which will not be repeated here.
[0203] It is understood that 800a-S800b, S801-S803, and S804a-S804b can be implemented in any combination, or they can be implemented without combination. For example, each of 800a-S800b, S801-S803, and S804a-S804b can be implemented independently at the granularity of the method or embodiment.
[0204] Please refer to Figures 11-12, which are schematic diagrams of the simulation scenario of this application. In Figures 11-12, the horizontal axis is the packet loss rate and the vertical axis is the system capacity. N=1 means the group length is 1, i.e., groupSize=1. N=5 means the group length is 5, i.e., groupSize=5, and so on. As the RDMA packet loss rate increases, when the RDMA packet loss rate is >4.5*10e-3 and <3.5*10e-3, N=10 can be set to ensure that the overall system capacity is maintained at around 0.94, i.e., at a relatively high level, while also considering overhead. When the RDMA packet loss rate is >3.5*10e-3 and <2.6*10e-2, N=5 can be set to ensure that the overall system capacity is not lower than 0.93, i.e., still maintained at a relatively high level, while still considering overhead. When the RDMA packet loss rate is >2.6*10e-2, N=1 can be set to ensure that the overall system capacity is not lower than 0.8.
[0205] The message transmission method provided in the embodiments of this application has been described in detail above with reference to FIG8. The communication apparatus used to perform the message transmission method provided in the embodiments of this application is described in detail below with reference to FIG13 and FIG14.
[0206] Figure 13 is a schematic diagram of the structure of a communication device provided in an embodiment of this application. As exemplarily shown in Figure 13, the communication device 1300 includes a transceiver module 1302 and a processing module 1301. For ease of explanation, Figure 13 only shows the main components of the communication device.
[0207] The communication device 1300 can be applied to the communication methods shown in Figures 3-5 above to achieve the corresponding functions. For example, the transceiver module 1302 can be used to implement the transceiver function in the communication method shown in Figure 8 above, and the processing module 1301 can be used to implement other functions in the communication method shown in Figure 8 above besides the transceiver function.
[0208] Optionally, the transceiver module 1302 may include a transmitting module (not shown in FIG. 13) and a receiving module (not shown in FIG. 13). The transmitting module is used to implement the transmitting function of the communication device 1300, and the receiving module is used to implement the receiving function of the communication device 1300.
[0209] Optionally, the communication device 1300 may further include a storage module (not shown in FIG13) that stores programs or instructions. When the processing module 1301 executes the program or instructions, the communication device 1300 can perform the functions in the methods shown in FIG3-5 above.
[0210] It is understood that the communication device 1300 may be a network device, or a chip (system) or other component or assembly that can be set in the network device, or a device that includes the network device. This application does not limit this.
[0211] Furthermore, the technical effects of the communication device 1300 can be referenced from the technical effects of the communication method described above, and will not be repeated here.
[0212] For example, Figure 14 is a second schematic diagram of the structure of a communication device provided in an embodiment of this application. This communication device can be a terminal device or a network device, or it can be a chip (system) or other component or assembly that can be disposed in a terminal device or network device. As shown in Figure 14, the communication device 1400 may include a processor 1401. Optionally, the communication device 1400 may also include a memory 1402 and / or a transceiver 1403. The processor 1401 is coupled to the memory 1402 and the transceiver 1403, for example, they can be connected via a communication bus.
[0213] The following is a detailed description of each component of the communication device 1400 with reference to Figure 14:
[0214] The processor 1401 is the control center of the communication device 1400. It can be a single processor or a collective term for multiple processing elements. For example, the processor 1401 can be one or more central processing units (CPUs), application-specific integrated circuits (ASICs), or one or more integrated circuits configured to implement the embodiments of this application, such as one or more digital signal processors (DSPs), or one or more field-programmable gate arrays (FPGAs).
[0215] Optionally, the processor 1401 can perform various functions of the communication device 1400 by running or executing software programs stored in the memory 1402 and calling data stored in the memory 1402.
[0216] In a specific implementation, as one example, processor 1401 may include one or more CPUs, such as CPU0 and CPU1 shown in FIG14.
[0217] In a specific implementation, as one embodiment, the communication device 1400 may also include multiple processors, such as processors 1401 and 1404 shown in FIG. 14. Each of these processors may be a single-core processor (single-CPU) or a multi-core processor (multi-CPU). Here, a processor may refer to one or more devices, circuits, and / or processing cores for processing data (e.g., computer program instructions).
[0218] The memory 1402 is used to store the software program that executes the solution of this application, and is controlled by the processor 1401 to execute it. The specific implementation method can be referred to the above method embodiment, and will not be repeated here.
[0219] Optionally, the memory 1402 may be a read-only memory (ROM) or other type of static storage device capable of storing static information and instructions, random access memory (RAM) or other type of dynamic storage device capable of storing information and instructions, or electrically erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital universal optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, but not limited thereto. The memory 1402 may be integrated with the processor 1401 or may exist independently and be coupled to the processor 1401 through the interface circuit of the communication device 1400 (not shown in FIG. 14). This application embodiment does not specifically limit this.
[0220] Transceiver 1403 is used for communication with other communication devices. For example, if communication device 1400 is a terminal device, transceiver 1403 can be used to communicate with a network device or with another terminal device. As another example, if communication device 1400 is a network device, transceiver 1403 can be used to communicate with a terminal device or with another network device.
[0221] Optionally, transceiver 1403 may include a receiver and a transmitter (not shown separately in Figure 14). The receiver is used to implement the receiving function, and the transmitter is used to implement the transmitting function.
[0222] Optionally, the transceiver 1403 can be integrated with the processor 1401 or exist independently and be coupled to the processor 1401 through the interface circuit of the communication device 1400 (not shown in FIG14). This application embodiment does not specifically limit this.
[0223] It should be noted that the structure of the communication device 1400 shown in Figure 14 does not constitute a limitation on the communication device. The actual communication device may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0224] Furthermore, the technical effects of the communication device 1400 can be referred to the technical effects of the message transmission method described in the above method embodiments, and will not be repeated here.
[0225] It should be understood that the processor in the embodiments of this application can be a CPU, but it can also be other general-purpose processors, DSPs, ASICs, FPGAs, or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor, etc.
[0226] It should also be understood that the memory in the embodiments of this application can be volatile memory or non-volatile memory, or may include both volatile and non-volatile memory. Non-volatile memory can be ROM, programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), EEPROM, or flash memory. Volatile memory can be RAM, which is used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous linked dynamic random access memory (SLDRAM), and direct rambus RAM (DR RAM).
[0227] The above embodiments can be implemented, in whole or in part, by software, hardware (such as circuits), firmware, or any other combination thereof. When implemented using software, the above embodiments can be implemented, in whole or in part, in the form of a computer program product. The computer program product includes one or more computer instructions or computer programs. When the computer instructions or computer programs are loaded or executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more sets of available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium. A semiconductor medium can be a solid-state drive.
[0228] It should be understood that the term "and / or" in this article is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. A and B can be singular or plural. Additionally, the character " / " in this article generally indicates an "or" relationship between the preceding and following related objects, but it can also represent an "and / or" relationship. Please refer to the context for a more accurate understanding.
[0229] In this application, "at least one" means one or more, and "more than one" means two or more. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or multiple items. For example, at least one of a, b, or c can mean: a, b, c, ab, ac, bc, or abc, where a, b, and c can be single or multiple.
[0230] It should be understood that in the various embodiments of this application, the order of the above-mentioned processes does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0231] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0232] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0233] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0234] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0235] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0236] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.
[0237] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A communication method, message transmission method, characterized by, The method applied to the first device comprises: acquiring a first remote direct memory access (RDMA) message, the first RDMA message being any one of M RDMA messages, the M RDMA messages including a group of RDMA messages, is an integer greater than 1, and the The header of one RDMA packet in every N RDMA packet groups in an RDMA packet group contains address information, M is an integer greater than 1, N is a positive integer less than M, and the address information is used to determine the address of the RDMA packet containing the address information in the memory of the second device; The first RDMA packet is sent.
2. A message transmission method characterized by comprising: The method applied to the second device comprises: receiving a first remote direct memory access, RDMA, message, the first RDMA message being any one of M RDMA messages, the M RDMA messages comprising a group of RDMA messages, is an integer greater than 1, and the The header of one RDMA packet in every N RDMA packet groups in an RDMA packet group contains address information, M is an integer greater than 1, N is a positive integer less than M, and the address information is used to determine the address of the RDMA packet containing the address information in the memory of the second device; The first RDMA packet is written.
3. The method according to claim 1 or 2, characterized in that, The The header of the first RDMA packet in each of the RDMA packet groups contains the address information.
4. The method of claim 3, wherein, The packet sequence number of the first RDMA packet is X, the packet sequence number of the first RDMA packet in the M RDMA packets is Y, if (X-Y) mod N is 0 and (X-Y)*MTU is less than the size of the M RDMA packets, the header of the first RDMA packet contains the address information, and the MTU is the maximum transmission unit of the first RDMA packet.
5. The method of claim 4, wherein, The address information is used to indicate the address of the first RDMA packet, and the address of the first RDMA packet is the address of the first RDMA packet in the memory of the second device.
6. The method of claim 5, wherein, The offset of the address of the first RDMA packet compared with the address of the first RDMA packet is (X-Y)*MTU, and the address of the first RDMA packet is the address of the first RDMA packet in the memory of the second device.
7. The method according to claim 5 or 6, characterized in that, The header of the first RDMA packet is an RDMA extended transmission header (RETH), and the basic transmission packet header (BTH) of the first RDMA packet contains indication information indicating that the first RDMA packet contains the RETH.
8. The method of claim 4, wherein, The address information is the packet identification of the RDMA packet group where the first RDMA packet is located.
9. The method of claim 8, wherein, The packet sequence number of the first RDMA packet is Y, and the group identification of the RDMA packet group in which the first RDMA packet is located is The offset of the address of the first RDMA packet compared to the address of the first RDMA packet is The maximum transmission unit, and the address of the first RDMA packet is the address of the first RDMA packet written into the memory of the second device.
10. The method according to claim 8 or 9, characterized in that, The header of the first RDMA packet is a BTH.
11. The method according to any one of claims 1-10, characterized in that, The M RDMA packets correspond to a queue pair (QP), and the packet loss rate of the RDMA packets of the QP is negatively related to the value of N.
12. The method of claim 1, wherein, The method further comprises: receiving configuration information, the configuration information being used to indicate the The header of one RDMA packet in every N RDMA packet groups in an RDMA packet group contains the address information.
13. The method of claim 12, wherein, The configuration information is used to indicate the address information of the first RDMA message in each of the plurality of RDMA message groups. The header of the first RDMA message in each of the plurality of RDMA message groups contains the address information.
14. The method of any one of claims 1, 12-13, wherein, The method further comprises: Feedback information from the second device is received, the feedback information indicating that a second RDMA packet confirms packet loss, and the second RDMA packet belongs to the M RDMA packets; According to the feedback information, Q RDMA packets in the M RDMA packets are retransmitted to the second device, Q is a positive integer, and the Q RDMA packets include: from the second RDMA packet to the last RDMA packet in the RDMA packet group where the second RDMA packet is located.
15. The method of claim 2, wherein, The second device writes the first RDMA packet, comprising: According to the address information, the address of the first RDMA packet is determined; According to the address of the first RDMA packet, the first RDMA packet is written.
16. The method of claim 15, wherein, The method further comprises: sending feedback information, the feedback information indicating that a second RDMA packet confirms a packet loss, the second RDMA packet belonging to the M RDMA packets; receiving Q RDMA packets from the first device, Q being a positive integer, the Q RDMA packets including: from the second RDMA packet to a last RDMA packet in a RDMA packet group in which the second RDMA packet is located.
17. The method of any one of claims 2, 15-16, wherein, The method applied to a third device comprises: obtaining a remote direct memory access (RDMA) packet loss rate of a queue pair (QP); sending configuration information to a first device in which the QP is located according to the RDMA packet loss rate, the configuration information indicating that a header of one RDMA packet in each RDMA packet group associated with the QP contains address information, N being a positive integer, the RDMA packet loss rate being negatively related to the value of N, and the address information being used to determine an address at which a RDMA packet containing the address information is written into a memory.
18. A message transmission method characterized by comprising: The third device is a network element for session management, and the obtaining of the RDMA packet loss rate of the QP comprises: The network element for session management obtains the RDMA packet loss rate from at least one of the following network elements associated with the QP: a network element for policy management, a network element for user plane transmission, or an access network device. The network element for session management obtains the RDMA packet loss rate from a network element for policy management associated with the QP, and the obtaining comprises:
19. The method of claim 18, wherein, In a case where a session associated with the QP is established or modified, the network element for session management obtains a policy and charging rule (PCC) rule of the session from the network element for policy management; The network element for session management obtains a packet loss rate upper limit (PER) in the PCC rule, and the PER is taken as the RDMA packet loss rate.
20. The method of claim 19, wherein, The network element for session management obtains the RDMA packet loss rate from an access network device associated with the QP, and the obtaining comprises: The network element for session management obtains a packet loss rate of a data radio bearer (DRB) or a quality of service (QoS) flow associated with the QP from the access network device, and the packet loss rate of the DRB or the QoS flow is taken as the RDMA packet loss rate. The network element for session management obtains the RDMA packet loss rate from a network element for user plane transmission associated with the QP, and the obtaining comprises:
21. The method of claim 19, wherein, 22. The method of claim 19, wherein, The network element for session management obtains the PER of the QP association from the network element for user plane transmission, the PER being the PER of downlink data of a session of the QP association, and the PER being taken as the RDMA packet loss rate.
23. The method of claim 18, wherein, The third device is an access network device, and the method for obtaining the RDMA packet loss rate of a queue (QP) comprises: The access network device obtains the packet loss rate of a DRB or a Qos flow associated with the QP, and the packet loss rate of the DRB or the Qos flow is taken as the RDMA packet loss rate; or In the case of establishing or modifying a session associated with the QP, the access network device obtains the QoS configuration of the session from the network element for policy management and obtains the PER in the QoS configuration, and the PER is taken as the RDMA packet loss rate.
24. A communications device, characterized by The communication device is configured to perform the method of any one of claims 1-23.
25. A communications device, characterized by Comprise: At least one processor and a memory; the memory is used to store computer instructions, when the at least one processor executes the instructions, so that the communication device performs the method of any one of claims 1-23.
26. A communications device, characterized by Comprise at least one processor, the at least one processor is used to run computer programs or instructions to make the communication device perform the method of any one of claims 1-23.
27. The communication apparatus according to claim 26, wherein The communication device further comprises a memory, the memory is coupled with the processor, and the memory is used to store the computer programs or instructions.
28. The communication apparatus according to claim 26 or 27, wherein, The communication device further comprises a transceiver, the transceiver is used for information interaction between the communication device and other communication devices, and the at least one processor executes program instructions to perform the method of any one of claims 1-23.
29. The communication apparatus according to claim 28, wherein, The transceiver is a transceiver circuit or an interface circuit, The interface circuit is used to receive code instructions and transmit to the at least one processor.
30. The communication apparatus according to any one of claims 25-29, wherein, The communication device is a chip.
31. A computer readable storage medium, characterized in that, The computer readable storage medium comprises computer programs or instructions, when the computer programs or instructions are run on a computer, so that the computer executes the method of any one of claims 1-23.
32. A computer program product, characterised in that, The computer program product comprises: computer programs or instructions, when the computer programs or instructions are run on a computer, so that the computer executes the method of any one of claims 1-23.
33. A chip, characterized by Comprise a processor, the processor is configured to perform the method of any one of claims 1-23.
Citation Information
Patent Citations
Message transmission method and device
CN109691039A
Data sending method, data receiving method, data sending device, data receiving device and data transceiving system
CN115633104A
Data transmission method and device, computer equipment and readable medium
CN117424849A
Flexible remote direct memory access
US10509764B1
RDMA data sending and receiving methods, electronic device, and readable storage medium
US20200250129A1