WO2021047606A1 - 报文处理方法、装置以及芯片 - Google Patents

报文处理方法、装置以及芯片 Download PDF

Info

Publication number
WO2021047606A1
WO2021047606A1 PCT/CN2020/114586 CN2020114586W WO2021047606A1 WO 2021047606 A1 WO2021047606 A1 WO 2021047606A1 CN 2020114586 W CN2020114586 W CN 2020114586W WO 2021047606 A1 WO2021047606 A1 WO 2021047606A1
Authority
WO
WIPO (PCT)
Prior art keywords
messages
fec
target
encoding
task
Prior art date
Application number
PCT/CN2020/114586
Other languages
English (en)
French (fr)
Inventor
陈庆
史济源
陈杰
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from CN201911205835.XA external-priority patent/CN112564855A/zh
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to JP2022513649A priority Critical patent/JP2022546102A/ja
Priority to MX2022002813A priority patent/MX2022002813A/es
Priority to EP20862858.6A priority patent/EP3996302B1/en
Priority to KR1020227005436A priority patent/KR20220033055A/ko
Publication of WO2021047606A1 publication Critical patent/WO2021047606A1/zh
Priority to US17/684,729 priority patent/US11695502B2/en
Priority to US18/320,860 priority patent/US20230299878A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0041Arrangements at the transmitter end
    • H04L1/0043Realisations of complexity reduction techniques, e.g. use of look-up tables
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M13/00Coding, decoding or code conversion, for error detection or error correction; Coding theory basic assumptions; Coding bounds; Error probability evaluation methods; Channel models; Simulation or testing of codes
    • H03M13/03Error detection or forward error correction by redundancy in data representation, i.e. code words containing more digits than the source words
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M13/00Coding, decoding or code conversion, for error detection or error correction; Coding theory basic assumptions; Coding bounds; Error probability evaluation methods; Channel models; Simulation or testing of codes
    • H03M13/37Decoding methods or techniques, not specific to the particular type of coding provided for in groups H03M13/03 - H03M13/35
    • H03M13/373Decoding methods or techniques, not specific to the particular type of coding provided for in groups H03M13/03 - H03M13/35 with erasure correction and erasure determination, e.g. for packet loss recovery or setting of erasures for the decoding of Reed-Solomon codes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0041Arrangements at the transmitter end
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0045Arrangements at the receiver end
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0045Arrangements at the receiver end
    • H04L1/0052Realisations of complexity reduction techniques, e.g. pipelining or use of look-up tables
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/625Queue scheduling characterised by scheduling criteria for service slots or service orders
    • H04L47/6275Queue scheduling characterised by scheduling criteria for service slots or service orders based on priority
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/55Prevention, detection or correction of errors
    • H04L49/557Error correction, e.g. fault recovery or fault tolerance
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/12Protocol engines

Definitions

  • This application relates to the field of data encoding technology, and in particular to a message processing method, device, and chip.
  • FEC forward error correction
  • the first-level network device performs FEC encoding on the original message in the data stream to obtain the redundant message of the original message, and the first-level network device adds an FEC header to the original message and the redundant message. , And send the original message and redundant message carrying the FEC message header to the secondary network device.
  • the secondary network device will Message, restore the lost original message, combine the original message that is not lost and the restored original message into the original data stream, the secondary network device and output the data stream, so the data stream transmission process can be avoided There is a message loss situation in the process.
  • Both the FEC encoding process in the message transmission process and the original message recovery process require a lot of calculations, and these calculations are completed by the central processing unit (CPU) of the network device.
  • CPU central processing unit
  • the CPU's own computing power and computing speed are limited, and it is difficult to meet the large throughput requirements in the message transmission process if the requirements for fast encoding and decoding are to be met.
  • the present application provides a message processing method, device, and chip, so that the network device can quickly perform message encoding and decoding processing while meeting the requirements for large throughput in the process of transmitting messages.
  • a message processing method is provided, which is applied to a network device including a processor and a target hardware engine, and the method includes:
  • the processor generates a first encoding task according to the M original messages in the first data stream to be processed, where M is a positive integer, and the first encoding task is used to instruct to encode the M original messages ;
  • the target hardware engine performs forward error correction FEC encoding on the M original messages according to the first encoding task to obtain R redundant messages, where R is a positive integer.
  • This method directly performs FEC encoding on the M original messages in the first data stream in the target hardware engine of the network device without FEC encoding in the processor. Therefore, the CPU overhead can be reduced and the network device can be improved.
  • the coding efficiency of, in turn, can make it easy for network equipment to meet the requirements of large throughput in the process of transmitting messages.
  • the method further includes:
  • the processor stores the first encoding task in a first target sending queue, and the first target sending queue is used to store the encoding task of the data stream to be processed of the network device, and the data to be processed of the network device
  • the stream includes the first data stream
  • the target hardware engine reads the first encoding task from the first target sending queue.
  • storing, by the processor, the first encoding task in a first target sending queue includes:
  • the processor adds the first encoding task to the first target sending queue according to the priority of the first data stream, and the priority of the first target sending queue is the same as that of the first data stream. Are equal in priority.
  • the target hardware engine reading the first encoding task from the first target sending queue includes:
  • the target hardware engine sequentially queries whether there is an encoding task in each sending queue according to the priority order of each sending queue, and each queue in each sending queue corresponds to a priority;
  • the target hardware engine reads the first code from the first target sending queue task.
  • the first target sending queue is located in any one of the memory of the network device, the processor, and the target hardware engine.
  • the method before the processor generates the first encoding task according to the stored M original messages in the first data stream to be processed, the method further includes:
  • the processor obtains the uncoded original messages of the first data stream The M original messages.
  • the first encoding task includes the storage addresses of the M original messages, or the first encoding task includes the storage addresses of the M original messages and the first data stream Or, the first encoding task includes the M original messages, or the first encoding task includes the M original messages and the priority of the first data stream.
  • a message processing method is provided, which is applied to a network device including a processor and a target hardware engine, and the method includes:
  • the processor obtains a first group of FEC messages from the received first data stream, all FEC messages in the first group of FEC messages have the same FEC message header, and the FEC message header includes The original message volume M of FEC encoding;
  • the processor When the number of original messages in the first group of FEC messages is less than the original message quantity M, the processor generates a first decoding task according to the first group of FEC messages, and the first The decoding task is used to instruct to decode the first group of FEC messages;
  • the target hardware engine performs FEC decoding on the original messages in the first group of FEC messages and the redundant messages of the original messages according to the first decoding task, to obtain the first group of FEC messages The original message lost in the text.
  • This method directly performs FEC decoding on the FEC messages that are not lost in the first group of FEC messages in the target hardware engine of the network device without FEC decoding in the CPU. Therefore, the CPU overhead can be reduced and the network can be improved.
  • the decoding efficiency of the device in turn, can make it easy for the network device to meet the requirement of large throughput in the process of transmitting packets.
  • the method further includes:
  • the processor stores the first decoding task in a second target sending queue, and the second target sending queue is used to store the decoding task of the data stream to be processed of the network device, and the data to be processed of the network device
  • the stream includes the first data stream
  • the target hardware engine reads the first decoding task from the second target sending queue.
  • storing, by the processor, the first decoding task in a second target sending queue includes:
  • the processor adds the first decoding task to the second target sending queue, and the priority of the second target sending queue is the same as that of the first data stream. Are equal in priority.
  • the target hardware engine reading the first decoding task from the second target sending queue includes:
  • the target hardware engine sequentially queries whether there is a decoding task in each transmission queue according to the priority of each transmission queue, and each queue in each transmission queue corresponds to a priority;
  • the target hardware engine reads the first target from the second target sending queue. Decoding task.
  • the second target sending queue is located in any one of the memory of the network device, the processor, and the target hardware engine.
  • the first decoding task includes the storage address of the first group of FEC packets, or the first decoding task includes the storage address of the first group of FEC packets and the Priority of the first data stream, or, the first decoding task includes the first group of FEC packets, or, the first decoding task includes the first group of FEC packets and the first data stream Priority.
  • a message processing device for executing the above message processing method.
  • the device includes a functional module for executing the message processing method provided in the foregoing first aspect or any optional manner of the foregoing first aspect.
  • a message processing device for executing the above message processing method.
  • the device includes a functional module for executing the packet processing method provided in the foregoing second aspect or any optional manner of the foregoing second aspect.
  • a chip in a fifth aspect, includes a processor and a target hardware engine.
  • the processor is configured to implement the processor provided in the foregoing first aspect or any optional manner of the foregoing first aspect, and the target hardware
  • the engine is used to implement the target hardware engine provided in the foregoing first aspect or any optional manner of the foregoing first aspect.
  • a chip in a sixth aspect, includes a processor and a target hardware engine.
  • the processor is configured to implement the processor provided in the foregoing second aspect or any optional manner of the foregoing second aspect, and the target hardware
  • the engine is used to implement the target hardware engine provided in the foregoing second aspect or any optional manner of the foregoing second aspect.
  • Fig. 1 is a schematic diagram of an FEC encoding calculation process provided by an embodiment of the present application
  • FIG. 2 is a schematic diagram of an FEC decoding calculation process provided by an embodiment of the present application.
  • FIG. 3 is a schematic diagram of a message transmission system provided by an embodiment of the present application.
  • FIG. 4 is a schematic structural diagram of a message processing apparatus provided by an embodiment of the present application.
  • FIG. 5 is a schematic structural diagram of a message processing apparatus provided by an embodiment of the present application.
  • FIG. 6 is a schematic diagram of a target hardware engine provided by an embodiment of the present application.
  • Fig. 7 is a flowchart of a message processing method provided by an embodiment of the present application.
  • FIG. 8 is a flowchart of a message processing method provided by an embodiment of the present application.
  • FIG. 9 is a schematic diagram of an internal interaction process of a network device according to an embodiment of the present application.
  • FIG. 10 is a schematic diagram of an FEC message provided by an embodiment of the present application.
  • FIG. 11 is a flowchart of FEC encoding provided by an embodiment of the present application.
  • FIG. 12 is a flowchart of a message processing method provided by an embodiment of the present application.
  • FIG. 13 is a flowchart of FEC decoding provided by an embodiment of the present application.
  • the parameters used in the FEC encoding process are encoding parameters .
  • the coding parameters include the original message volume M, the redundant message volume R and the target size L, where M and R are both positive integers, L is a value greater than 0, and the original message volume M is the original message to be encoded
  • the number of redundant packets R is the number of redundant packets obtained after FEC encoding of M original packets.
  • the first network device is In the process of encoding the original message to generate redundant messages, the filling process is first performed based on M original messages to obtain M equal-length messages, and each equal-length message is a message filled with the original message.
  • the size of each equal-length message and the size of the redundant message are the target size L, and the target size L can be the size of the largest original message among the M original messages. At this time, the largest message among the M original messages The text does not need to be filled, it can be regarded as an equal length message.
  • M0M3 the matrix to be encoded is composed of equal-length messages M0-M3;
  • the first network device constructs a (M+R)*M generator matrix, and the generator matrix is composed of the first sub-matrix and the second sub-matrix , Where the first sub-matrix is the identity matrix of M*M, and the second sub-matrix is the Cauchy matrix of R*M.
  • the element in the i-th row and j-th column in the second sub-matrix is
  • x i-1 and y i-1 are all elements in the galois field (GF) (2 w ), where i and j are integers greater than or equal to 0, and w can be 8, for example ,
  • the generator matrix in Figure 1; the network device multiplies the generator matrix and the matrix to be coded to obtain a coding matrix of (M+R)*L, where the coding matrix includes the matrix to be coded and the R*L check matrix , Where, each row of the check matrix is a redundant message, for example, in Figure 1, R 2, and the redundant messages are R0 and R1.
  • the first network device After the first network device obtains the R redundant messages, it adds the same FEC header to the M original messages and the R redundant messages, so that the M original messages and the R redundant messages are redundant.
  • the remaining messages are encapsulated into a group of FEC messages, and this group of FEC messages is sent to the second network device.
  • this group of FEC packets is lost during transmission, any equal-length packets belonging to the coding matrix are lost, the second network device can also recover any missing equal-length packets through the decoding process.
  • 2 shows a schematic diagram of the FEC decoding calculation process provided by the embodiment of the present application.
  • the FEC decoding is introduced as follows: When the equal-length messages M2 and M3 in the coding matrix are lost, the second network device can remove Equal-length messages M0, M1 and redundant messages R0, R1 form a recovery matrix; construct the target check matrix, where the target check matrix includes the third sub-matrix and the second sub-matrix, because two equal-length messages are missing Therefore, the third sub-matrix is a 2*M identity matrix; the second network device multiplies the inverse matrix of the target check matrix by the recovery matrix to obtain the matrix to be encoded, and the second network device can obtain the matrix to be encoded. Obtain the missing equal-length messages M2 and M3.
  • FIG. 3 is a schematic diagram of a message transmission system provided by an embodiment of the present application.
  • a first terminal 301 a first network device 302, a second network device 303, and a second terminal 304, wherein the first terminal 301 Used to generate a data stream and send the data stream to the first network device 302.
  • the first network device 302 can perform FEC encoding on the packets in the data stream and send an encoded stream composed of FEC packets to the second network device 303 ,
  • the second network device 303 decodes the FEC messages that are not lost in the encoded stream, restores the lost original messages, and combines the restored original messages and the original messages that are not lost into the original data stream, and combines the data
  • the stream is sent to the second terminal 304, where the first terminal 301 and the second terminal 302 can be mobile phones, laptops, etc., the first network device 302 and the second network device 303 can be computer devices such as routers and switches, and the data stream can be It is a video stream or a text stream composed of text data.
  • the embodiment of the present application does not specifically limit the data stream type.
  • the first terminal 301 when the first terminal 301 and multiple second terminals 302 are in a video session, the first terminal 301 is used to send to the first network device 302 the original message used to compose the video to form a video stream (That is, the data stream), the first network device 302 performs FEC encoding on the original message in the video stream to obtain a redundant message, and encapsulates the original message and the redundant message into an FEC message to obtain the encoding And send the encoded stream to the second network device 303.
  • the second network device 303 judges each group of FEC messages according to the FEC header of each group of FEC messages Whether the original message is lost, if it is lost, decode a group of FEC messages that lost the original message to recover the lost original message, and send the recovered original message and the original message that are not lost to form a video stream.
  • a second terminal 304 after each second terminal 304 receives the video stream, performs video playback, thereby realizing a video conversation between multiple terminals.
  • the first terminal 301 may also have the function of the first network device.
  • the apparatus 400 includes:
  • the processor 401 is configured to generate a first encoding task according to the M original messages in the first data stream to be processed, where M is a positive integer, and the first encoding task is used to instruct the processing of the M original messages Encode
  • the target hardware engine 402 is configured to perform forward error correction FEC encoding on the M original messages according to the first encoding task to obtain R redundant messages, where R is a positive integer.
  • the processor 401 is further configured to store the first encoding task in a first target sending queue, and the first target sending queue is used to store the encoding task of the data stream to be processed by the device,
  • the to-be-processed data stream of the device includes the first data stream;
  • the target hardware engine is also used to read the first encoding task from the first target sending queue.
  • the processor 401 is configured to add the first encoding task to the first target sending queue according to the priority of the first data stream, and the priority of the first target sending queue is The priority is equal to the priority of the first data stream.
  • the target hardware engine 402 is used to:
  • the target hardware engine sequentially queries whether there is an encoding task in each sending queue according to the priority order of each sending queue, and each queue in each sending queue corresponds to a priority;
  • each of the sending queues when there is no encoding task in a queue with a higher priority than the first target sending queue, the first encoding task is read from the first target sending queue.
  • the apparatus 400 further includes a memory 403, and the first target sending queue is located in any one of the memory of the network device, the processor, and the target hardware engine.
  • the device 400 further includes a memory 403;
  • the memory 403 is used to store the received original message in the first data stream
  • the processor 401 is further configured to: if the amount of uncoded original messages of the first data stream in the memory is greater than or equal to M, extract the uncoded original messages from the first data stream Obtain the M original messages in, and execute the step of generating an encoding task according to the stored M original messages in the first data stream to be processed.
  • the processor 401 may be a general-purpose processor, such as a CPU, or a network processor (network processor, NP), or a combination of CPU and NP.
  • the processor may also include a hardware chip, and the above-mentioned hardware chip may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or a combination thereof.
  • ASIC application-specific integrated circuit
  • PLD programmable logic device
  • the above-mentioned PLD may be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL) or any combination thereof.
  • CPLD complex programmable logic device
  • FPGA field-programmable gate array
  • GAL generic array logic
  • the memory 403 may include volatile memory (volatile memory), such as random-access memory (random-access memory, RAM); the memory may also include non-volatile memory (non-volatile memory), such as flash memory (flash memory). ), hard disk drive (HDD) or solid-state drive (SSD), or any combination thereof.
  • volatile memory such as random-access memory (random-access memory, RAM
  • non-volatile memory such as flash memory (flash memory).
  • flash memory flash memory
  • HDD hard disk drive
  • SSD solid-state drive
  • the first encoding task includes the storage addresses of the M original messages, or the first encoding task includes the storage addresses of the M original messages and the priority of the first data stream, Or, the first encoding task includes the M original messages, or the first encoding task includes the M original messages and the priority of the first data stream.
  • the function of the message processing apparatus shown in FIG. 4 may also be implemented by a chip, and the chip may include the processor 401 in FIG. 4 and the target processing engine 402 in FIG. 4.
  • the second terminal 304 may also have the function of the second network device 303.
  • FIG. 5 for a schematic structural diagram of a message processing apparatus provided in an embodiment of the present application.
  • the apparatus 500 includes a processor 501. And target hardware engine 502;
  • the processor 501 is configured to obtain a first group of FEC messages from the received first data stream. All FEC messages in the first group of FEC messages have the same FEC message header.
  • the header includes the FEC-encoded original message volume M;
  • a first decoding task is generated according to the first group of FEC messages, and the first decoding task is used for Instructing to decode the first group of FEC messages;
  • the target hardware engine 502 is configured to perform FEC decoding on the original messages in the first group of FEC messages and the redundant messages of the original messages according to the first decoding task, to obtain the first A group of original packets lost in FEC packets.
  • the processor 501 is further configured to store the first decoding task in a second target sending queue, and the second target sending queue is used to store the decoding task of the to-be-processed data stream of the device,
  • the to-be-processed data stream of the device includes the first data stream;
  • the target hardware engine 502 is also used to read the first decoding task from the second target sending queue.
  • the processor 501 is configured to add the first decoding task to the second target sending queue according to the priority of the first data stream, and the second target The priority of the sending queue is equal to the priority of the first data flow.
  • the target hardware engine 502 is used to:
  • each sending queue inquire whether there is a decoding task in each sending queue in turn, and each queue in each sending queue corresponds to a priority
  • the apparatus device further includes a memory, and the second target sending queue is located in any one of the memory, the processor, and the target hardware engine.
  • the first decoding task includes the storage address of the FEC message that is not lost in the first group of FEC messages, or the storage address of the FEC message that is not lost in the first group of FEC messages, and The priority of the first data stream, or, the first decoding task includes the first group of FEC packets, or, the first decoding task includes the first group of FEC packets and the first group of FEC packets The priority of the data stream.
  • the function of the message processing apparatus shown in FIG. 5 may also be implemented by a chip, and the chip may include the processor 501 in FIG. 5 and the target processing engine 502 in FIG. 5.
  • both the first network device 302 and the second network device 303 are recorded as computing devices.
  • Each computing device may include a target hardware engine, and the target hardware engine is used to perform codec calculations.
  • An embodiment of the present application provides a schematic diagram of a target hardware engine. See the target hardware engine 600 in FIG. 6.
  • the target hardware engine 600 includes a controller 601, a cache unit 602, a data processing unit 603, a matrix generator 604, and a codec unit. 605.
  • the controller 601 is used to receive the encoding and decoding parameters sent by the CPU of the computing device and the storage address of the message to be encoded and decoded, and determine the corresponding data processing strategy, the model parameters of the encoding and decoding model, and the model parameters of the matrix model according to the encoding and decoding parameters.
  • the encoding and decoding parameters include encoding parameters or decoding parameters
  • the decoding parameters can be the content in the FEC header
  • the message to be encoded and decoded can be M original messages, or FEC messages that are not lost
  • the model can include an encoding model or a decoding model.
  • the model parameters of the encoding model are the original message volume M and the target size L, and the model parameters of the decoding model include the lost original FEC message message volume F and the target size L.
  • F is greater than 0 and less than or equal to R;
  • the model parameters of the matrix model include the model parameters of the generator matrix or the model parameters of the target check matrix.
  • the model parameters of the generator matrix include the original message volume M, the redundant message volume R and the target size L, the target
  • the model parameters of the check matrix include the amount of lost original FEC packets F, the amount of redundant packets R, and the target size L.
  • the controller 601 is further configured to obtain the message to be encoded and decoded from the memory of the computing device according to the storage address of the message to be encoded and decoded, and store the message to be encoded and decoded in the buffer unit 602.
  • the controller 601 is also used to send the model parameters of the codec model and the data processing strategy to the data processing unit 603, so that the data processing unit 603 generates the pending code based on the message to be coded and decoded according to the model parameters and data processing strategy of the codec model.
  • the encoding matrix or the recovery matrix is sent, and the matrix to be encoded or the recovery matrix is sent to the encoding and decoding unit 605.
  • the controller 601 is also used to send the model parameters of the matrix model to the matrix generator 604, so that the verification matrix generator 604 constructs a generator matrix or a target check matrix according to the model parameters of the matrix model, and generates the matrix or the target check matrix. Send to the codec unit 605.
  • the encoding and decoding unit 605 is configured to perform encoding and decoding calculations on the received matrix to be encoded or the recovery matrix and the corresponding generator matrix or target check matrix to obtain redundant messages or missing original FEC messages (see Figure 1 and Figure 2 for details).
  • the encoding and decoding calculation process shown), and the redundant message or the missing original FEC message is sent to the buffer unit 602, and the buffer unit 602 sends the redundant message or the restored message to the memory or processing of the computing device Device.
  • the encoding and decoding unit 605 in the target hardware engine can reuse FEC encoding logic and FEC decoding logic.
  • the encoding and decoding unit 605 performs FEC encoding on the generating matrix and the matrix to be encoded according to the FEC encoding logic;
  • the encoding and decoding unit 605 performs FEC decoding on the target check matrix and the recovery matrix according to the FEC decoding logic.
  • the encoding and decoding unit 605 may include an encoding subunit and a decoding subunit.
  • the encoding subunit may perform FEC encoding on the generator matrix and the matrix to be encoded according to FEC encoding logic, and the decoding subunit may decode according to FEC. Logically, FEC decoding is performed on the target check matrix and the recovery matrix.
  • the computing device uses a gigabit ethernet (GE) network port or ten -gigabit Ethernet (GXE) network port receives the packet in the data stream, GE/GXE network port sends the received packet to the packet parse engine (PPE), PPE stores the packet in the memory, and Preliminary analysis of the message is carried out to obtain the descriptor of the message, and a notification message carrying the storage address of the message is sent to the network processer (NP) engine through offloading; the NP engine can analyze the message in the memory Perform in-depth analysis to determine whether it needs to be encoded.
  • GE gigabit ethernet
  • GXE ten -gigabit Ethernet
  • the NP engine can also forward the notification message to the CPU; the protocol stack of the CPU sends a notification message to the user datagram protocol (UDP) agent ;
  • UDP user datagram protocol
  • the number of notification messages received by the UDP agent reaches a certain number, it means that the message to be encoded for this encoding has been stored in the current time period, and the CPU issues an encoding task to the target hardware engine through the FEC software interface;
  • the hardware engine obtains the message to be encoded from the memory according to the storage address of the message to be encoded carried in the encoding task, generates redundant messages, and stores the redundant messages in the memory.
  • the target hardware engine sends the message to The FEC software interface in the CPU reports the completion information of the encoding task; the FEC software interface obtains the message to be encoded and the redundancy from the memory according to the storage address of the message to be encoded and the storage address of the redundant message carried in the completion information of the encoding task Message, add FEC message header to the obtained message to be encoded and redundant message to generate FEC message; FEC software interface sends FEC message to traffic management (traffic management, TM) engine to form the encoded code Stream (that is, data stream); the TM engine manages the encoded stream according to the requirements of the CPU or other hardware engines, such as quality of service (QOS) scheduling, traffic shaping, traffic statistics, etc.
  • traffic management traffic management
  • the TM engine will manage The encoded stream is sent to the PPE; the PPE forwards the managed encoded stream to the GE/GXE network port, and the GE/GXE network port outputs the managed encoded stream.
  • the computing device does not include the NP engine, the PPE, and the TM engine, and the work of the NP engine, the PPE, and the TM engine can all be completed by a processor or a CPU. Or the work of the NP engine, PPE, TM engine, and CPU can be done by a single processor.
  • the description of the decoding process of the computing device is as follows:
  • the message stored in the memory of the computing device is an FEC message
  • the target hardware engine obtains a set of FEC packets from the memory according to the storage address of a set of FEC packets carried in the decoding task, and according to a set of FEC Message, restore the lost original message, store the restored original message in the memory, when the storage is completed, the target hardware engine reports the decoding task completion information to the FEC software interface in the CPU;
  • the FEC software interface is based on the decoding task completion information
  • the storage address of the original message that is not lost in a group of FEC messages and the storage address of the restored original message are carried, and the original messages of a group of FEC messages that are not lost and the restored
  • the protocol stack, UDP proxy, and FEC software interface may not be deployed in the CPU, but in the NP engine.
  • the NP engine, target hardware engine, and memory are required. Interaction between users, without the need for the CPU to interact with the target hardware engine and memory.
  • the target hardware engine after the target hardware engine obtains the encoding matrix or the to-be-encoded matrix through encoding and decoding, it can directly encapsulate the original message and redundant messages in the encoding matrix into FEC messages and output them to network devices, or It directly obtains the original message from the matrix to be encoded and outputs it to the network device.
  • the target hardware engine can also directly send the encoding matrix or the matrix to be encoded to the FEC software interface.
  • the FEC software interface encapsulates the original message and redundant messages in the encoding matrix into FEC messages, and Output the network device, or obtain the original message from the matrix to be coded by the FEC software interface, and output the network device.
  • the encoding process of the network device is summarized as follows: after the network device obtains any data stream, it can store any data stream in the memory, and if the message in any data stream is to be encoded Message, the processor in the network device can generate an encoding task for instructing to encode multiple messages to be encoded, and the processor can deliver the encoding task to the memory; read by the target hardware engine in the network device Encoding tasks in the memory, and perform FEC encoding on multiple messages to be encoded stored in the memory according to the encoding tasks to obtain redundant messages for multiple messages to be encoded, and the target hardware engine then stores the redundant messages in the memory ; Then, the processor can obtain multiple to-be-coded messages and redundant messages of the multiple to-be-coded messages from the memory, and encapsulate the obtained messages into FEC messages.
  • the first network device may include a processor and a target hardware engine.
  • the flow of the method is It may include the following steps 801-812:
  • the first network device acquires M original packets in the first data stream to be processed.
  • the first network device can acquire multiple data streams.
  • the first data stream is any data stream among the multiple data streams, and the first data stream may include multiple packets.
  • the data stream may be a video data stream, an audio data stream, or a text data stream, etc.
  • the embodiment of the present application does not specifically limit the type of the first data stream.
  • the M original messages are any M continuous original messages in the first data stream.
  • the first network device can encode the M original messages each time. After one encoding is completed, the first data stream The other M original messages are encoded. In some possible implementation manners, this step 801 can be implemented through the process shown in steps 8011-8012.
  • Step 8011 the first network device stores the received original message in the first data stream into the memory of the first network device.
  • the original packet is sent to the PPE.
  • the PPE receives the original packet
  • the original packet is sent to the PPE.
  • the message is stored in the memory, and the storage address of the original message is recorded.
  • Step 8012 If the amount of uncoded original messages of the first data stream in the memory is equal to or greater than M, the processor obtains M original messages from the uncoded original messages of the first data stream.
  • the processor may include at least one of the CPU and the NP engine in the first network device. Since the first network device will encode the next set of M unencoded original messages every time the first network device performs encoding, therefore, For the original messages in the first data stream, when each new M original messages are cached in the memory of the first network device, the newly cached M original messages can be used as the next time in the first data stream. M original messages to be encoded.
  • the first network device may also set a preset duration. For the original message in the first data stream, the first network device will store the preset duration in each preset duration. The original message newly stored in the memory is used as the original message to be encoded next time.
  • the size of M may change during each encoding. For example, if the first network device obtains 5 original packets after a preset period of time, then M is equal to 5 at this time, and then the next step is For a preset duration, the first network device newly obtains 4 original messages, then M is equal to 4 at this time.
  • the embodiment of the present application does not specifically limit the preset duration.
  • the PPE When the PPE stores an original message in the memory, the PPE sends the storage completion message corresponding to the original message to the NP engine.
  • the storage completion message can carry the flow identifier of the first data flow and the storage address of the original message
  • the flow identifier may be the name or number of the first data flow, and is used to indicate the data flow to which the original packet belongs.
  • the first network device sets a corresponding priority for each received data stream according to service requirements. The first network device can preferentially process the data stream with higher priority. Accordingly, the storage completion message
  • the priority corresponding to the first data stream may also be carried, so that each module in the first network device can process the original packet in the corresponding data stream according to the priority.
  • the user can configure a priority information table on the first network device.
  • the priority information table includes multiple priorities from high to low, and each priority corresponds to a service type.
  • the service type of the first data stream can be determined according to the data carried in the original message in the first data stream, and the service type corresponding to the first data stream can be determined from the priority information table Therefore, the first network device can set a corresponding priority for the first data stream.
  • the NP engine When the NP engine receives the storage completion message, it can send the storage completion message to the protocol stack. Therefore, the UDP agent can collect each storage completion message from the protocol stack.
  • the number of storage completion messages newly collected by the UPD agent is When M, the newly collected M storage completion messages can indicate that M messages to be encoded are newly stored in the memory. Therefore, the UDP agent can use the M original messages corresponding to the M storage completion messages as the messages to be encoded. M original messages.
  • the processor generates a first encoding task according to the M original packets in the first data stream to be processed, where M is a positive integer, and the first encoding task is used to instruct to encode the M original packets.
  • This step 802 may be performed by the FEC software interface in the processor of the first network device. Whenever the UDP agent collects M storage completion messages, the UDP agent may send the collected M storage completion messages to the processor. When the FEC software interface in the FEC software interface receives M storage complete messages, this step 802 can be executed.
  • the FEC software interface can obtain the storage addresses of M original messages from the M storage completion messages, where the storage addresses of the M original messages include the storage address of each message in the M original messages; the FEC The software interface can generate the encoding task according to the storage addresses and encoding parameters of the M original messages.
  • the encoding task can include the storage addresses and encoding parameters of the M original messages, so that the target hardware engine can read from the memory according to the storage addresses.
  • the first encoding task may not include the storage addresses of the M original messages, but include M original messages, so that the target hardware engine can directly obtain the M original messages from the first encoding task.
  • the first encoding task may also include the priority of the first data stream, and the encoding task may also carry an encoding identifier to indicate that each message is performed Encoding, the embodiment of the present application does not specifically limit the representation mode of the encoding identifier.
  • the encoding parameter may be an encoding parameter preset by the first network device, and the first network device may use the encoding parameter every time it performs encoding.
  • the first network device may also perform encoding parameters on the encoding parameter according to the message transmission situation. Appropriate adjustments.
  • the first packet amount may be the original packet amount M in the encoding parameter, and the first network device may also be based on the current CPU overhead or The current computing power of the target hardware engine dynamically modifies the original message volume M in the encoding parameters. For example, when the CPU overhead is small or the target hardware engine still has sufficient computing power, the first network device can appropriately increase the original message volume.
  • the amount of text is to increase the amount of packets that are encoded once.
  • the amount of original packets can be appropriately reduced, that is, to reduce the amount of packets that are encoded once.
  • the first network device can also dynamically adjust the amount of redundant packets R in the model parameters according to the current network packet loss rate. For example, when the network packet loss rate is high, the amount of redundant packets R can be appropriately increased, that is, It is to increase the amount of redundant packets generated in one encoding process so that all the lost packets can be recovered later. When the network packet loss rate is low, the amount of redundant packets R can be appropriately reduced, which is to reduce The amount of redundant messages generated in one encoding process to improve encoding efficiency.
  • the first network device can perform the above-mentioned dynamic adjustment of the coding parameters, the coding efficiency of the first network device can be improved by adjusting the coding parameters.
  • the processor stores the first encoding task in a first target sending queue, where the first target sending queue is used to store the encoding task of the to-be-processed data stream of the first network device, and the to-be-processed data stream of the first network device includes the first data flow.
  • This step 803 can be executed by the FEC software interface in the processor.
  • the first network device may preset multiple sending queues, each sending queue is used to store the encoding task of the data stream to be processed of the first network device, and the first target sending queue may be any one of the multiple sending queues. queue.
  • the multiple sending queues may be located in any one of the memory, the processor, and the target hardware engine of the first network device.
  • the first network device may set a priority for each sending queue, and each sending queue is used to store encoding tasks of data streams of the same priority.
  • FIG. 9 shows a schematic diagram of an internal interaction process of a network device provided by an embodiment of the present application.
  • FIG. 9 there are 1 sending queue A with priority A and sending queue B with priority B in the memory.
  • Priority A is higher than Priority B.
  • encoding tasks 3, 5, and 6 are stored in sending queue A
  • encoding tasks 1, 2, and 4 are stored in sending queue B.
  • encoding tasks 3, 5, and 6 Each is an encoding task with priority A
  • encoding tasks 1, 2 and 4 are an encoding task with priority B respectively.
  • this step 803 may include: the processor adds the first encoding task to the first target sending queue according to the priority of the first data stream, and the priority of the first target sending queue is the same as that of the first target sending queue.
  • the priority of the data stream is equal.
  • the FEC software interface can determine the first target sending queue corresponding to the priority of the first data stream in the memory according to the priority of the first data stream.
  • the FEC software interface adds the first encoding task to the first target sending queue, where the first target number is the first target The maximum number of encoding tasks that can be stored in the sending queue.
  • the FEC software interface queries whether the number of encoding tasks in the sending queue of the first target is less than the first preset time interval every interval. Once the number of targets is less than the number of first targets, the first encoding task is added to the first target sending queue.
  • the embodiment of the present application does not specifically limit the first preset duration.
  • the target hardware engine can query the first target sending queue whenever the codec unit is idle.
  • the target hardware engine reads the first encoding task from the first target sending queue.
  • the target hardware engine can first poll each sending queue in the memory according to the priority level, so as to determine whether the target hardware engine wants to send the queue from the first target.
  • the target hardware engine sends according to each sending queue.
  • the priority order of the queues is to inquire whether there is an encoding task in each sending queue in turn, and each queue in each sending queue corresponds to a priority; in each sending queue, when the priority is higher than the priority of the first target sending queue When there is no encoding task in the queue, the target hardware engine reads the first encoding task from the first target sending queue.
  • the process of the target hardware engine polling each sending queue may be: the target hardware engine queries the first sending queue with the highest priority in each sending queue, and when there is an encoding task in the first sending queue, the target hardware engine starts from Obtain an encoding task from the head of the first sending queue, and execute the following step 805 according to the encoding task; every second preset time period, the target hardware engine queries the first sending queue again, and when the first sending queue is in When there are still coding tasks, a new coding task is obtained from the head of the first sending queue again; until no coding tasks are stored in the first sending queue, the target hardware engine queries the first sending queue in the multiple sending queues.
  • the encoding task is obtained from the second sending queue, and the following step 805 is executed, where the second priority is second only to the highest priority
  • the sending queue next to the second priority will be queried according to the priority.
  • the next encoding task in the sending queue becomes the head of the sending queue, so that the target hardware engine can obtain the task from the head of the sending queue next time.
  • the next coding task is the encoding task at the head of a sending queue.
  • the target hardware engine obtains the M original messages from the memory according to the storage addresses of the M original messages in the first encoding task.
  • the controller in the target hardware engine After the controller in the target hardware engine obtains the first encoding task, it can obtain the storage addresses of the M original messages from the first encoding task, and the target hardware engine can send the first message to the memory to obtain Request, the first message acquisition request carries the storage addresses of the M original messages, and when the memory receives the first message acquisition request, it sends the M original messages stored in the storage address to the target hardware engine, After receiving the M original messages, the target hardware engine caches the M first messages in the buffer unit, so that the data processing unit can process the M original messages. Of course, if the M original messages are directly carried in the first encoding task, the target hardware engine can directly obtain the M original messages from the first encoding task without obtaining the M original messages from the memory. Text.
  • the target hardware engine performs forward error correction FEC encoding on the M original messages according to the first encoding task to obtain R redundant messages, where R is a positive integer.
  • the target hardware engine After the target hardware engine obtains the M original messages, it can perform forward error correction FEC encoding on the M original messages according to the encoding parameters in the first encoding task.
  • the data processing unit in the target hardware engine can perform filling processing on the M original messages according to the original message amount M in the encoding parameters to obtain M equal-length messages; data;
  • the processing unit composes the M equal-length messages into a matrix to be encoded, where one row of the matrix to be encoded is an equal-length message; the data processing unit sends the matrix to be encoded to the encoding and decoding unit; the encoding and decoding matrix unit will correspond to Perform multiplication calculation on the generating matrix of and the matrix to be coded to obtain R redundant messages, so as to realize this step 806.
  • FIG. 1 the process of the multiplication calculation of the generating matrix and the matrix to be coded is introduced, and this process is not described in detail in the embodiment of the present application.
  • the generator matrix can be generated by a matrix generator in the target hardware engine and sent to the codec unit.
  • the process of the matrix generator generating the corresponding generating matrix is: the controller in the target hardware engine can obtain the amount of redundant packets R and the amount of original packets M from the first encoding task, and will obtain the amount of redundant packets R And the original message volume M is sent to the matrix generator, and the matrix generator generates the (M+R)*M generating matrix according to the redundant message volume R and the original message volume M, and the (M+R)* The generator matrix of M is sent to the codec unit.
  • the target hardware engine stores the R redundant messages in the memory.
  • the R redundant messages are cached in the cache unit, and the cache unit sends the first message storage request to the memory, and the first message
  • the storage request carries the storage address of the R redundant messages and the R redundant messages.
  • the storage address of the R redundant messages includes the storage address of each redundant message.
  • the target hardware engine adds the storage addresses of the R redundant messages in the first encoding task to obtain the first encoding completion information of the M original messages, An encoding completion message is used to indicate that the encoding of the M original messages is completed.
  • the target hardware engine may also replace the encoding identifier in the first encoding task with an encoding completion identifier, which is used to complete the encoding of the original message.
  • the embodiment of the present application does not specifically limit the representation of the encoding completion identifier. Since the first encoding task includes the storage addresses and encoding parameters of M first messages, the first encoding completion information may include the storage addresses of R redundant messages, the storage addresses of M original messages, and the encoding parameters . When the first encoding task carries the priority of the first data stream, the first encoding completion information further includes the priority of the first data stream.
  • the target hardware engine stores the first encoding completion information in a first target receiving queue, and the first target receiving queue is used to store the encoding completion information task of the to-be-processed data stream of the first network device.
  • the first network device may preset multiple receiving queues, each receiving queue is used to store the encoding completion information of the data stream to be processed of the first network device, and the first target receiving queue may be any of the multiple receiving queues.
  • the multiple receiving queues may be located in any one of the memory, the processor, and the target hardware engine of the first network device.
  • the first network device may set a priority for each receiving queue, and each receiving queue is used to store encoding completion information of data streams of the same priority.
  • each receiving queue is used to store encoding completion information of data streams of the same priority.
  • receiving queue A Task completion information 3, 5, and 6 (referred to as “completion information 3, 5, and 6" in Figure 9) are stored, and task completion information 1, 2 and 4 are stored in the receiving queue B.
  • task completion information 3, 5 and 6 are respectively an encoding completion information with priority A
  • task completion information 1, 2 and 4 (referred to as "complete information 3, 5 and 6" in Figure 9) are respectively an encoding completion information with priority B .
  • the target hardware engine adds the first encoding completion information to the first target receiving queue in the memory according to the priority of the first data stream, and the priority of the first target receiving queue is equal to the first data stream. Priority. Specifically, the target hardware engine may determine the first target receiving queue corresponding to the priority of the first data stream in the memory according to the priority of the first data stream, and when the number of encoded information in the first target receiving queue is When the number is less than the second target number, the target hardware engine adds the first encoding completion information to the first target receiving queue, where the second target number is the largest number of encoding completion information that can be stored in the first target receiving queue Number.
  • the FEC software interface queries whether the number of encoded messages in the first target receiving queue is less than the second preset time interval Once the number of second targets is less than the number of second targets, the first encoding completion information is added to the first target receiving queue.
  • the embodiment of the present application does not specifically limit the second preset duration.
  • the processor reads the first encoding completion information from the first target receiving queue.
  • This step 810 can be executed by the FEC software interface of the processor.
  • the FEC software interface can poll each receiving queue according to the priority.
  • the FEC software interface can first determine whether the encoding completion information can be obtained in the first target receiving queue by polling.
  • the FEC software interface queries each one in order according to the priority order. Whether there is other encoding completion information in the receiving queue, each queue in each receiving queue corresponds to a priority; in each first receiving queue, when there is no other encoding completion information in the queue with a higher priority than the first target receiving queue At the time, obtain the first encoding completion information from the first target receiving queue.
  • the process of the FEC software interface polling each receiving queue may be: the FEC software interface queries the first receiving queue with the highest priority in each receiving queue. When there is encoding completion information in the first receiving queue, the FEC software interface starts from the first receiving queue. Obtain an encoding completion message from the head of a receiving queue, and perform the following step 811 according to the encoding completion information; every third preset time period, the FEC software interface queries the first receive queue again, and when the first receive queue is in When the encoding completion information is still stored, a new encoding completion information is obtained from the head of the first receiving queue again, until the encoding task is not stored in the first sending queue, the FEC software interface queries the multiple first Whether the second receiving queue corresponding to the next priority in the receiving queue has encoding completion information, when the encoding completion information is stored, the encoding completion information is obtained from the second receiving queue, and the following step 811 is executed.
  • the third receiving queue When the second receiving queue When there is no encoding completion information stored in
  • the next encoding completion information in the first receiving queue becomes the head of the first receiving queue, so that the FEC software interface can download from the first receiving queue next time.
  • the head of the receiving queue obtains the next encoding completion information.
  • the processor obtains M original messages and R redundant messages from the memory according to the first encoding completion information.
  • This step 811 can be executed by the FEC software interface in the processor.
  • the FEC software interface can obtain the storage addresses of the R redundant messages, the storage addresses of the M original messages, and the coding parameters from the first encoding completion information; the FEC software interface sends the second message acquisition request to the memory.
  • the second message acquisition request carries the storage addresses of R redundant messages and the storage addresses of M original messages.
  • the memory receives the second message acquisition request, it will acquire the R redundant messages according to the second message acquisition request.
  • the storage addresses of the remaining messages and the storage addresses of M original messages are returned to the FEC software interface with R redundant messages and M original messages.
  • the processor sends M original messages and R redundant messages to the second network device.
  • This step 812 can be executed by the FEC software interface in the processor.
  • the FEC software interface obtains the R redundant messages and M original messages returned from the memory; the FEC software interface completes the encoding parameters in the information according to the first encoding; the R redundant messages and the M original messages are respectively Encapsulated as a FEC message.
  • this step 812 can be implemented by the process shown in the following steps 8121-8123.
  • step 8121 the FEC software interface fills the packets whose size is smaller than the target size among the M original packets according to the target size in the encoding parameter, to obtain M equal-length packets, and the size of each equal-length packet is the target size.
  • Step 8122 The FEC software interface adds FEC message headers to each equal-length message to obtain M original FEC messages, and adds FEC message headers to each redundant message to obtain R redundancy FEC message, the FEC message header carries the coding parameters of M original messages.
  • the FEC message in the schematic diagram of an FEC message provided by the embodiment of the present application shown in FIG. 10, when the load message of the FEC message in FIG. 10 is formed by the original message in the first data stream, etc.
  • the FEC message is an original FEC message
  • the load message of the FEC message is a redundant message
  • the FEC message is a redundant FEC message.
  • the FEC message header is used to indicate the encoding conditions of the M original messages.
  • the FEC message header carries M original coding parameters.
  • the FEC message header may also carry the target identifiers of the M original messages, and the target identifiers are used to indicate the number of encodings of the original messages in the first data stream, for example, the FEC message header in FIG. 10
  • the target identifier in is 1.2, which indicates that the first network device performs the second encoding of the message in the first data stream 1, and the M original messages are the first data stream used in the second encoding The original message in.
  • the FEC message header can also carry priority identification, algorithm identification, the sequence number of each message in the M original messages in the first data stream, the sequence number of each equal-length message in the matrix to be coded, and The sequence number of each redundant packet in the encoding matrix, where the priority identifier is used to indicate the priority of the first data stream, and the algorithm identifier is used to indicate the algorithm used by the first network device in the encoding process,
  • the serial number of each equal-length message in the matrix to be encoded is the row number of each equal-length message in the matrix to be encoded
  • the serial number of each redundant message in the encoding matrix is each redundant message The row number in the encoding matrix.
  • the sequence numbers of the original messages A0-A3 in the first data stream are 10, 11, 12, and 13, respectively; the sequence numbers of the equal-length messages M0-M3 are 0, 1 respectively. , 2 and 3; the sequence numbers of redundant messages R0-R1 are 4 and 5 respectively.
  • the example of the FEC header in FIG. 10 is based on the encoding calculation process shown in FIG. 1.
  • Step 8123 The processor sends M original FEC messages and R redundant FEC messages.
  • the M original FEC messages and the R redundant FEC messages can be regarded as a group of FEC messages.
  • the FEC software interface sends the task to the TM engine in the first network device after each FEC message is obtained. An FEC message. Because the FEC software interface can continuously output FEC messages to the TM engine, the TM engine can form an encoded stream with the first data stream.
  • the TM engine After the TM engine manages the encoded stream, it sends it to the PPE Output the managed code stream, PPE forwards the managed code stream to the GE/GXE network port, and the GE/GXE network port outputs the managed code stream to the second network device so that the second network device can obtain it from the code stream To the encoded stream.
  • Step 1101 the UDP proxy sends a storage complete message to the FEC software interface.
  • Step 1102 When the number of storage completion messages received by the FEC software interface is equal to M, generate the first encoding task, and send the first encoding task to the task buffer in the memory,
  • the task buffer includes multiple sending queues and multiple receiving queues, and the FEC software interface can send the first encoding task to the first target sending queue corresponding to the priority.
  • Step 1103 The target hardware engine obtains the first encoding task from the first target sending queue in the task buffer, and reads M original messages from the memory according to the storage address in the first encoding task.
  • Step 1104 The target hardware engine performs FEC encoding on the read M original messages to obtain R redundant messages.
  • the target hardware engine stores the R redundant messages in the memory, and completes the first encoding information. It is sent to the first target receiving queue in the task buffer.
  • Step 1105 The FEC software interface reads the first encoding completion information from the first target receiving queue in the task buffer, and according to the first completion information, reads M original messages and R redundant messages in the memory. And encapsulate FEC message headers in M original messages and R redundant messages to obtain FEC messages.
  • Step 1106 The FEC software interface sends the FEC message.
  • the process shown in the above steps 807-812 is a process of sending M original messages and R redundant messages to the second network device in cooperation with the target processing engine, memory, and processor.
  • the target processing engine can also directly send M original messages and R redundant messages to the processor, and the processor executes the process shown in 8122-8123, so as to realize the M original messages.
  • the transmission of text and R redundant messages may also perform the process shown in 8122-8123 by itself, so as to realize the transmission of M original messages and R redundant messages.
  • the method provided by the embodiment of the present application directly performs FEC encoding on the M original messages in the first data stream in the target hardware engine of the first network device without performing FEC encoding in the processor. Therefore, it can reduce The overhead of the CPU improves the coding efficiency of the first network device, thereby making it easier for the first network device to meet the requirement of large throughput in the process of packet transmission.
  • the first network device can perform the above-mentioned dynamic adjustment on the encoding parameters, so that the encoding efficiency of the first network device can be improved by adjusting the encoding parameters.
  • the second network device may decode the un-lost FEC message to recover the lost FEC message.
  • the processing process may be: after obtaining any coded stream, the second network device may store any coded stream in the memory; if the original FEC message in any group of FEC messages in the any coded stream is When the number is less than the original message volume M during encoding, it means that any group of FEC messages has packet loss during transmission, and the processor in the second network device can generate instructions to indicate any group of FEC messages.
  • the processor can deliver the decoding task to the memory; the target hardware engine in the second network device reads the decoding task in the memory, and performs any set of FEC stored in the memory according to the encoding task.
  • the message is FEC encoded to restore the original message lost in any group of FEC messages, and the target hardware engine stores the restored original message in the memory; then, the processor can obtain any group of FEC messages from the memory
  • the original FEC message that is not lost and the restored original message, and the FEC header of the original FEC message that is not lost will be removed to obtain the original message that is not lost.
  • the second network device may include a processor and a target hardware engine, and the process of the method includes steps 1201-1213.
  • the processor obtains a first group of FEC messages from the received first data stream, where all FEC messages in the first group of FEC messages have the same FEC message header, and the FEC message header includes the FEC code.
  • the original message volume M The original message volume M.
  • the second network device may obtain multiple coded streams, the first data stream may be any coded stream of the pair of coded streams, the first data stream may be composed of multiple groups of FEC packets, and the first group of FEC packets It is any group of FEC messages in the multiple groups of FEC messages, and the first group of FEC messages includes M original FEC messages and R redundant FEC messages output by the first network terminal after performing one-time encoding.
  • the second network device starts to receive the first data stream, every time the second network device receives an FEC message in the first data stream, the FEC message is stored in the memory of the second network device.
  • the GE/GXE network port of the second network device receives the FEC message, and sends the FEC message to the PPE in the second network device, and the PPE stores the FEC message In the memory, the storage address of the FEC message is recorded, and a storage completion message is sent to the NP engine of the second network terminal, and the storage completion message carries the storage address of the FEC message.
  • the NP engine receives the storage completion message, it can send the storage completion message to the protocol stack in the CPU of the second network device.
  • the UDP agent can collect each storage completion message from the protocol stack and collect the The storage completion message is sent to the FEC software interface of the second network device.
  • the FEC software interface obtains each storage completion message every third preset time period.
  • the FEC software interface reads the corresponding storage address of the memory according to the storage address carried in each storage message.
  • the second network device will store the newly stored FEC messages in the third preset time every time a third preset time period has elapsed
  • the message with the same FEC message header is used as the first group of FEC messages, and the embodiment of the present application does not specifically limit the third preset duration.
  • the target identifier is carried in the FEC message header, the target identifier is used to indicate the number of times of encoding. In some possible implementations, when the target identifiers in the headers of multiple FEC messages are the same, it can also indicate that the multiple FEC messages
  • the text is a message obtained after the same encoding, that is, a group of FEC messages.
  • the processor When the number of original messages in the first group of FEC messages is less than the original message quantity M, the processor generates a first decoding task according to the first group of FEC messages, and the first decoding task is used for Indicate to decode the first group of FEC packets.
  • This step 1202 can be performed by the FEC software interface in the processor.
  • the second network device can obtain information from a message in the first group of FEC messages.
  • the encoding parameter is obtained from the message header, and the original message volume M in the encoding parameter is the message volume of the original FEC message initially included in the first group of FEC messages. Since each original FEC message corresponds to an original message during encoding, when the number of original FEC messages in the first group of FEC messages is less than the number of original messages M, it is the first group of FEC messages.
  • the number of original packets in the group of FEC packets is less than the number of original packets M, indicating that at least one of the original FEC packets in the first group of FEC packets is lost, that is, when the first group of FEC packets is used by the first network device During the transmission of the message to the second network device, part of the original FEC message is lost, that is, the original message when the encoding is lost.
  • the FEC software interface can generate a first decoding task, so that the target hardware engine decodes the FEC packets that are not lost in the first group of FEC packets according to the first decoding task to restore the loss The original FEC message.
  • the first decoding task includes the storage address of the first group of FEC messages or the first group of FEC messages, so that the target hardware engine can obtain the first group of FEC messages from the memory according to the storage address of the first group of FEC messages FEC messages, or so that the target hardware engine can directly obtain the first group of FEC messages from the first decoding task.
  • the first decoding task may also include the priority of the first data stream.
  • the second network device can Perform the following step 1211.
  • the processor stores the first decoding task in a second target sending queue, and the second target sending queue is used to store the decoding task of the to-be-processed data stream of the second network device, and the to-be-processed data stream of the network device includes the first data stream. .
  • This step 1203 can be executed by the FEC software interface in the processor.
  • the data stream to be processed in this step 1203 is also the encoded stream to be processed.
  • the second network device may preset multiple sending queues, each sending queue is used to store the decoding task of the to-be-processed data stream of the second network device, and the second target sending queue may be any of the multiple sending queues.
  • the multiple sending queues may be located in any one of the memory, the processor, and the target hardware engine of the second network device.
  • the second network device may set a priority for each sending queue, and each sending queue is used to store decoding tasks of data streams of the same priority.
  • this step 1203 may include: according to the priority of the first data stream, the processor adds the first decoding task to the second target sending queue, and the priority of the second target sending queue is the same as that of the first target sending queue. The priority of the data stream is equal.
  • the process in which the processor adds the first decoding task to the second target sending queue is the same as the process in which the processor adds the first encoding task to the first target sending queue in step 803.
  • the embodiment of the present application compares the first The specific process of adding the decoding task to the second target sending queue will not be described in detail.
  • the target hardware engine reads the first decoding task from the second target sending queue.
  • the target hardware engine can first poll each second sending queue in the memory according to the priority level to determine whether the target hardware engine wants to send the queue from the second target.
  • the target hardware engine is based on The priority of each sending queue is checked in turn whether there is a decoding task in each sending queue, and each queue in each sending queue corresponds to a priority; in each sending queue, when the priority is higher than the second target sending queue When there are no other decoding tasks in the queue, the target hardware engine reads the first decoding task from the second target sending queue.
  • the process in which the target hardware engine obtains the first decoding task by polling each transmission queue is the same as the process in which the target hardware engine obtains the first encoding task by polling each transmission queue in step 804.
  • the process of querying each sending queue to obtain the first decoding task will not be repeated.
  • the target hardware engine obtains the first group of FEC messages from the memory according to the storage address of the first group of FEC messages in the first decoding task.
  • the target hardware engine can directly obtain the first group of FEC messages from the first decoding task without having to Acquired in memory.
  • the first group of FEC messages obtained by the target hardware engine is the FC messages that are not lost in the first group of FEC messages, including original FEC messages that are not lost and redundant FEC messages that are not lost.
  • the target hardware engine performs FEC decoding on the original message in the first group of FEC messages and the redundant message of the original message, to obtain the original message lost in the first group of FEC messages.
  • the data processing unit in the target hardware engine can remove the headers of the original FEC messages and the redundant FEC messages in the first group of FEC messages.
  • the message header, multiple equal-length messages and at least one redundant message are obtained.
  • Each equal-length message is also an original message lost in the first group of FEC messages;
  • the data processing unit can After multiple messages of equal length and at least one redundant message form the recovery matrix, the recovery matrix is sent to the codec unit, the matrix generator constructs the corresponding target check matrix, and sends the corresponding target check matrix to the codec Unit; the encoding and decoding unit multiplies the inverse matrix of the corresponding target check matrix and the recovery matrix to obtain the matrix to be encoded; then according to the serial number of each equal-length message in the FEC header and the number of redundant messages The sequence number can determine which equal-length packets are lost, which redundant packets are missing, that is, which original FEC packets are missing or which redundant FEC packets are missing, so that the missing equal-length packets can be obtained from the matrix to be coded In this way, the lost original message is obtained, so as to realize this step 1206.
  • the process of the multiplication calculation of the inverse matrix of the target check matrix and the restoration matrix is introduced, and this process will not be repeated in
  • the process of the matrix generator constructing the corresponding target check matrix is: the controller in the target hardware engine determines the message of the missing redundant FEC message according to the redundant message amount R in the encoding parameter in the message header
  • the amount of lost redundant FEC messages is the difference between the amount of redundant messages R and the amount of redundant FEC messages in multiple FEC messages; the controller is based on the encoding in the FEC message header
  • the original message volume M in the parameter and the message volume of the original FEC message in the multiple FEC messages are used to determine the message volume of the original FEC message lost, and the message volume of the original FEC message lost is the original message
  • the matrix generator constructs the corresponding target check matrix according to the amount of lost redundant FEC messages and the amount of lost original FEC messages, and sends the corresponding target check matrix to the codec
  • steps 1205-1206 The process shown in steps 1205-1206 is to perform FEC decoding on the original message in the first group of FEC messages and the redundant messages of the original message according to the first decoding task, to obtain the first group The process of the original message lost in the FEC message.
  • the target hardware engine stores the original message lost in the first group of FEC messages in the memory.
  • This step 1207 is similar to the process shown in step 807. Here, this step 1207 is not described in detail in the embodiment of the present application.
  • the target hardware engine adds the storage address of the lost original message in the first decoding task to obtain the first decoding completion information, and the first encoding completion information is used to indicate the first group
  • the FEC message is decoded.
  • the first decoding completion information carries the storage address of the lost original message and the original FEC message in the first group of FEC messages.
  • the first decoding completion information also carries the information of the first data stream. priority.
  • the process shown in this step 1208 is the same as the process of generating the first encoding completion information in step 808. Here, the embodiment of the present application will not repeat this step 1208.
  • the target hardware engine adds the first decoding completion information to the second target receiving queue, and the second target receiving queue is used to store the decoding completion information of the to-be-processed encoded stream of the second network device.
  • the second network device may preset multiple receiving queues, each receiving queue is used to store the decoding completion information of the encoded stream to be processed of the second network device, and the second target receiving queue may be any of the multiple receiving queues.
  • the multiple receiving queues may be located in any one of the memory, the processor, and the target hardware engine of the second network device.
  • the second network device can set a priority for each receiving queue.
  • the first decoding completion information is added to the first in the memory.
  • the priority of the second target receiving queue is equal to the priority of the encoded stream.
  • the specific adding process is the same as the process of adding the first encoding completion information to the first target receiving queue in step 809.
  • the processor reads the first decoding completion information from the second target receiving queue.
  • This step 1210 can be executed by the FEC software interface in the processor.
  • the FEC software interface can poll each second receiving queue according to the priority level.
  • the FEC software interface can first determine whether it is possible to obtain the first decoding completion information in the second target receiving queue by polling.
  • each query in turn Whether there is other decoding completion information in the second receiving queue, each queue in each second receiving queue corresponds to a priority; in each second receiving queue, when there is no queue with a higher priority than the second target receiving queue When other decoding completion information is obtained, the decoding completion information is obtained from the second target receiving queue.
  • the process of polling each receiving queue by the FEC software interface in step 1210 is the same as the process of polling each receiving queue by the FEC software interface in step 810.
  • the processor obtains the original FEC message and the lost original message in the first group of FEC messages from the memory according to the first decoding completion information.
  • step 1211 is the same as the process of obtaining M original messages and R redundant messages in step 811.
  • the embodiment of the present application will not repeat this step 1211.
  • the processor restores the data stream before encoding with the first data stream according to the original FEC message in the first group of FEC messages and the lost original message.
  • This step 1212 can be executed by the FEC software interface in the processor.
  • the FEC software interface can first remove the headers of the original FEC messages that are not lost in the first group of FEC messages, wait for multiple equal-length messages, and then restore the first based on multiple equal-length messages and the lost original messages.
  • this step 1212 can be implemented by the process shown in the following steps 12A-12C.
  • Step 12A For the original FEC messages in the first group of FEC messages, the FEC software interface removes the FEC message header of each original FEC message to obtain multiple equal-length messages.
  • Step 12B The FEC software interface removes multiple equal-length packets and the data filled in the missing original packets to obtain M original packets in the data stream before the first data stream is encoded.
  • step 12C the FEC software interface sorts the M original messages according to the sequence number of each original message carried in the FEC message header according to the size of the sequence number to obtain the data stream before the first data stream is encoded.
  • the processor sends the data stream to the second terminal.
  • This step 1213 is the same as step 8123. Here, this step 1213 will not be repeated in this embodiment of the application.
  • Step 1301. The UDP proxy sends a storage completion message of each FEC message to the FEC software interface.
  • Step 1302 After the FEC software interface receives the storage completion message of a group of FEC messages, if the original FEC message in a group of FEC messages is lost, generate the first decoding according to the received group of FEC messages Task, and send the first decoding task to the task buffer in the memory.
  • the task buffer includes multiple sending queues and multiple receiving queues
  • the FEC software interface can send the first decoding task to the second target sending queue corresponding to the priority.
  • Step 1303 The target hardware engine obtains the first decoding task from the second target sending queue in the task buffer, and reads a group of FEC messages from the memory according to the storage address in the first decoding task.
  • Step 1304 The target hardware engine decodes the read set of FEC messages to obtain the lost original message, stores the lost original message in the memory, and adds the first message to the second target receiving queue in the memory. -Decoding complete information.
  • Step 1305 The FEC software interface reads the first decoding completion information from the second target receiving queue in the task buffer, and according to the first decoding completion information, reads a group of FEC messages and the missing original messages in the memory. And remove the message header of a group of FEC messages to obtain equal-length messages.
  • Step 1306 The FEC software interface processes the equal-length message to obtain a data stream, and output the data stream.
  • the process shown in the above steps 1207-1213 is a data flow process that the target processing engine, memory, and processor cooperate to send to the second terminal.
  • the target processing engine may also directly send the first group of FEC packets and the lost original packets to the processor, and the processor will execute the process shown in 1212-1213.
  • the target processing engine can also perform the processes shown in 1212-1213 by itself.
  • the method provided by the embodiment of the present application directly performs FEC decoding on the FEC messages that are not lost in the first group of FEC messages in the target hardware engine of the second network device without performing FEC decoding in the CPU. Therefore, it is possible to perform FEC decoding on the FEC messages that are not lost in the first group of FEC messages.
  • the CPU overhead is reduced, and the decoding efficiency of the second network device is improved, so that the second network device can easily meet the requirement of large throughput in the process of packet transmission.
  • the message processing device provided in the embodiments of the present application processes messages
  • only the division of the above-mentioned functional modules is used as an example for illustration.
  • the above-mentioned functions can be allocated by different functional modules as needed. That is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.
  • the message processing method embodiments provided in the foregoing embodiments belong to the same concept, and the specific implementation process is detailed in the method embodiments, which will not be repeated here.
  • the program can be stored in a computer-readable storage medium.
  • the storage medium mentioned can be a read-only memory, a magnetic disk or an optical disk, etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Probability & Statistics with Applications (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Detection And Prevention Of Errors In Transmission (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本申请公开了一种报文处理方法、装置以及芯片,属于数据处理技术领域。本方法通过直接在网络设备的目标硬件引擎中对第一数据流中的M个原始报文进行FEC编码,而无需在CPU中进行FEC编码,因此,可以降低对CPU的开销,提高网络设备的编码效率,进而可以使得网络设备在传输报文过程中容易满足大吞吐量的要求。

Description

报文处理方法、装置以及芯片
本申请要求了2019年11月29日提交的,申请号为201911205835.X,发明名称为“报文处理方法、装置以及芯片”的中国申请的优先权,以及要求2019年09月10日提交的申请号为201910854367.2、申请名称为“FEC加速方法、装置、***和FEC硬件加速器”的中国专利申请的优先权,它们全部内容通过引用结合在本申请中。
技术领域
本申请涉及数据编码技术领域,特别涉及一种报文处理方法、装置以及芯片。
背景技术
数据流在两个网络设备之间进行传输时,往往会出现报文丢失的情况,目前,可以采用前向纠错(forward error correction,FEC)编解码技术,来解决数据流传输过程中出现的丢包问题。
具体地,一级网络设备对数据流中的原始报文进行FEC编码,得到原始报文的冗余报文,一级网络设备在原始报文和冗余报文上分别添加一个FEC报文头,并将携带FEC报文头的原始报文和冗余报文发送至二级网络设备,当在传输过程中有原始报文丢失时,二级网络设备根据未丢失的原始报文和冗余报文,恢复丢失的原始报文,将未丢失的原始报文和恢复出来的原始报文再组合成原来的的数据流,二级网络设备并输出数据流,因此,可以避免数据流传输过程中出现报文丢失的情况。
上述报文传输过程中的FEC编码过程以及原始报文恢复的过程均需要进行大量的计算,这些计算是由网络设备的中央处理器(central processing units,CPU)来完成的。而CPU自身的计算能力以及计算速率有限,如果要满足快速编码和解码的要求就难以满足在报文传输过程中的大吞吐量要求。
发明内容
本申请提供了一种报文处理方法、装置以及芯片,使得网络设备在快速进行报文的编码和解码处理的同时,满足传输报文过程中的大吞吐量的要求。
第一方面,提供了一种报文处理方法,应用于包括处理器以及目标硬件引擎的网络设备,所述方法包括:
所述处理器根据待处理的第一数据流中的M个原始报文,生成第一编码任务,M为正整数,所述第一编码任务用于指示对所述M个原始报文进行编码;
所述目标硬件引擎根据所述第一编码任务,对所述M个原始报文进行前向纠错FEC编码,得到R个冗余报文,R为正整数。
本方法通过直接在网络设备的目标硬件引擎中对第一数据流中的M个原始报文进行FEC编码,而无需在处理器中进行FEC编码,因此,可以降低对CPU的开销,提高网络设备的编码效率,进而可以使得网络设备在传输报文过程中容易满足大吞吐量的要求。
在一种可能实现方式中,所述处理器根据待处理的第一数据流中的M个原始报文,生成第一编码任务之后,所述方法还包括:
所述处理器将所述第一编码任务存储在第一目标发送队列,所述第一目标发送队列用于存储所述网络设备的待处理数据流的编码任务,所述网络设备的待处理数据流包括所述第一数据流;
所述目标硬件引擎从所述第一目标发送队列中读取所述第一编码任务。
在一种可能实现方式中,所述处理器将所述第一编码任务存储在第一目标发送队列包括:
所述处理器根据所述第一数据流的优先级,将所述第一编码任务添加在所述第一目标发送队列中,所述第一目标发送队列的优先级与所述第一数据流的优先级相等。
在一种可能实现方式中,所述目标硬件引擎从所述第一目标发送队列中读取所述第一编码任务包括:
所述目标硬件引擎根据各个发送队列的优先级的高低顺序,依次查询各个发送队列中是否有编码任务,所述各个发送队列中的每一个队列对应一个优先级;
在所述各个发送队列中,当比所述第一目标发送队列的优先级高的队列内没有编码任务时,所述目标硬件引擎从所述第一目标发送队列中读取所述第一编码任务。
在一种可能实现方式中,所述第一目标发送队列位于所述网络设备的内存、所述处理器以及所述目标硬件引擎中的任一个。
在一种可能实现方式中,所述处理器根据存储的待处理的第一数据流中的M个原始报文,生成第一编码任务之前,所述方法还包括:
所述网络设备将接收到的所述第一数据流中的原始报文存入所述网络设备的内存中;
若所述网络设备的内存中所述第一数据流的未编码的原始报文的报文量等于或大于M,所述处理器从所述第一数据流的未编码的原始报文中获取所述M个原始报文。
在一种可能实现方式中,所述第一编码任务包括所述M个原始报文的存储地址,或,所述第一编码任务包括M个原始报文的存储地址以及所述第一数据流的优先级,或,所述第一编码任务包括所述M个原始报文,或,所述第一编码任务包括所述M个原始报文以及所述第一数据流的优先级。
第二方面,提供了一种报文处理方法,应用于包括处理器以及目标硬件引擎的网络设备,所述方法包括:
所述处理器从接收到的第一数据流中获取第一组FEC报文,所述第一组FEC报文中所有FEC报文具有相同的FEC报文头,所述FEC报文头中包括FEC编码的原始报文量M;
当所述第一组FEC报文中原始报文的个数小于所述原始报文量M时,所述处理器根据所述第一组FEC报文,生成第一解码任务,所述第一解码任务用于指示对所述第一组FEC报文进行解码;
所述目标硬件引擎根据所述第一解码任务,对所述第一组FEC报文中的原始报文以及所述原始报文的冗余报文进行FEC解码,得到所述第一组FEC报文中丢失的原始报文。
本方法通过直接在网络设备的目标硬件引擎中对第一组FEC报文中未丢失的FEC报文进行FEC解码,而无需在CPU中进行FEC解码,因此,可以降低对CPU的开销,提高网络设备的解码效率,进而可以使得网络设备在传输报文过程中容易满足大吞吐量的要求。
在一种可能实现方式中,所述处理器根据所述第一组FEC报文,生成第一解码任务之后, 所述方法还包括:
所述处理器将所述第一解码任务存储在第二目标发送队列,所述第二目标发送队列用于存储所述网络设备的待处理数据流的解码任务,所述网络设备的待处理数据流包括所述第一数据流;
所述目标硬件引擎从所述第二目标发送队列中读取所述第一解码任务。
在一种可能实现方式中,所述处理器将所述第一解码任务存储在第二目标发送队列包括:
根据所述第一数据流的优先级,所述处理器将所述第一解码任务添加在所述第二目标发送队列中,所述第二目标发送队列的优先级与所述第一数据流的优先级相等。
在一种可能实现方式中,所述目标硬件引擎从所述第二目标发送队列中读取所述第一解码任务包括:
所述目标硬件引擎根据各个发送队列的优先级的高低,依次查询所述各个发送队列中是否有解码任务,所述各个发送队列中的每一个队列对应一个优先级;
在所述各个发送队列中,当比所述第二目标发送队列的优先级高的队列内没有其他解码任务时,所述目标硬件引擎从所述第二目标发送队列中读取所述第一解码任务。
在一种可能实现方式中,所述第二目标发送队列位于所述网络设备的内存、所述处理器以及所述目标硬件引擎中的任一个。
在一种可能实现方式中,所述第一解码任务包括所述第一组FEC报文的存储地址,或,所述第一解码任务包括所述第一组FEC报文的存储地址以及所述第一数据流的优先级,或,所述第一解码任务包括所述第一组FEC报文,或,所述第一解码任务包括所述第一组FEC报文以及所述第一数据流的优先级。
第三方面,提供了一种报文处理装置,用于执行上述报文处理方法。具体地,该装置包括用于执行上述第一方面或上述第一方面的任一种可选方式提供的报文处理方法的功能模块。
第四方面,提供了一种报文处理装置,用于执行上述报文处理方法。具体地,该装置包括用于执行上述第二方面或上述第二方面的任一种可选方式提供的报文处理方法的功能模块。
第五方面,提供一种芯片,该芯片包括处理器和目标硬件引擎,所述处理器用于实现上述第一方面或上述第一方面的任一种可选方式提供的处理器,所述目标硬件引擎用于实现上述第一方面或上述第一方面的任一种可选方式提供的目标硬件引擎。
第六方面,提供一种芯片,该芯片包括处理器和目标硬件引擎,所述处理器用于实现上述第二方面或上述第二方面的任一种可选方式提供的处理器,所述目标硬件引擎用于实现上述第二方面或上述第二方面的任一种可选方式提供的目标硬件引擎。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本申请实施例提供的一种FEC编码计算过程的示意图;
图2是本申请实施例提供的一种FEC解码计算过程的示意图;
图3是本申请实施例提供的一种报文传输***的示意图;
图4是本申请实施例提供的一种报文处理装置的结构示意图;
图5是本申请实施例提供的一种报文处理装置的结构示意图;
图6是本申请实施例提供的一种目标硬件引擎的示意图;
图7是本申请实施例提供的一种报文处理方法的流程图;
图8是本申请实施例提供的一种报文处理方法的流程图;
图9是本申请实施例提供的一种网络设备内部交互流程的示意图;
图10是本申请实施例提供的一种FEC报文的示意图;
图11是本申请实施例提供的一种FEC编码的流程图;
图12是本申请实施例提供的一种报文处理方法的流程图;
图13是本申请实施例提供的一种FEC解码的流程图。
具体实施方式
为使本申请的目的、技术方案和优点更加清楚,下面将结合附图对本申请实施方式作进一步地详细描述。
为了便于理解本申请的实施过程,在此结合图1所示的本申请实施例提供的一种FEC编码计算过程的示意图,对FEC编码进行如下介绍:FEC编码过程中用到的参数为编码参数,编码参数包括原始报文量M、冗余报文量R以及目标大小L,其中,M和R均为正整数,L为大于0的数值,原始报文量M为待编码的原始报文的个数,冗余报文量R为对M个原始报文进行FEC编码后所得的冗余报文的个数,由于M个原始报文的大小不一,第一网络设备在对M个原始报文进行编码生成冗余报文的过程中,首先基于M个原始报文进行填充处理,得到M个等长报文,每个等长报文为一个原始报文填充后的报文,每个等长报文的大小以及冗余报文的大小均为目标大小L,目标大小L可以是M个原始报文中最大的原始报文的大小,此时M个原始报文中最大报文无需填充,可以将其视为一个等长报文。然后,第一网络设备可以先将M个等长报文组成M*L待编码矩阵,待编码矩阵的每一行是一个等长报文,例如图1中的M=4,4个等长报文M0-M3,则待编码矩阵由等长报文M0-M3所组成;第一网络设备构建一个(M+R)*M的生成矩阵,生成矩阵由第一子矩阵和第二子矩阵组成,其中,第一子矩阵为M*M的单位矩阵,第二子矩阵为R*M的柯西矩阵。
其中,第二子矩阵中第i行第j列的元素为
Figure PCTCN2020114586-appb-000001
x i-1以及y i-1和均为迦罗华域(galois field,GF)(2 w)中的元素,其中,i和j均为大于或等于0的整数,w可以是8,例如,图1中的生成矩阵;网络设备将该生成矩阵和待编码矩阵进行乘法计算,得到(M+R)*L的编码矩阵,其中,编码矩阵包括待编码矩阵以及R*L的校验矩阵,其中,校验矩阵的每一行为一个冗余报文,例如图1的中R=2,冗余报文为R0和R1。
第一网络设备得到R个冗余报文后,将该M个原始报文和R个冗余报文添加相同的FEC报文头,从而将M个原始报文和R个冗余报文冗余报文封装成一组FEC报文,并将这一组FEC报文发送至第二网络设备。当这一组FEC报文在传输过程中,属于编码矩阵中的任一等长报文丢失时,第二网络设备还可以通过解码的过程恢复丢失的任一等长报文,在此结合图2所 示的本申请实施例提供的一种FEC解码计算过程的示意图,对FEC解码进行如下介绍:当编码矩阵中的等长报文M2和M3丢失时,第二网络设备可以将未丢失的等长报文M0、M1以及冗余报文R0、R1组成恢复矩阵;构建目标校验矩阵,其中,目标校验矩阵包括第三子矩阵和第二子矩阵,因为丢失了2个等长报文,因此,第三子矩阵为2*M的单位矩阵;第二网络设备将目标校验矩阵的逆矩阵乘以恢复矩阵,就可以得到待编码矩阵,第二网络设备可以从待编码矩阵中获取到丢失的等长报文M2和M3。
图3是本申请实施例提供的一种报文传输***的示意图,参见图3,第一终端301、第一网络设备302、第二网络设备303以及第二终端304,其中,第一终端301用于生成数据流,并将数据流发送至第一网络设备302,第一网络设备302可对数据流中的报文进行FEC编码并向第二网络设备303发送由FEC报文组成的编码流,第二网络设备303对编码流中未丢失的FEC报文进行解码,恢复丢失的原始报文,并将恢复的原始报文和未丢失的原始报文,组成原来的数据流,并将数据流发送至第二终端304,其中,第一终端301和第二终端302可以是手机、笔记本电脑等,第一网络设备302和第二网络设备303可以是路由器和交换机等计算机设备,数据流可以是视频流,也可以是文本数据组成的文本流,本申请实施例对数据流类型不做具体限定。
以视频流为例的示意图,当第一终端301和多个第二终端302进行视频会话时,用第一终端301向第一网络设备302发送用于组成该视频的原始报文,形成视频流(也即是数据流),由第一网络设备302对视频流中的原始报文进行FEC编码,得到冗余报文,并将原始报文和冗余报文封装成FEC报文,得到编码流,并将编码流发送至第二网络设备303,第二网络设备303在获取到编码流中的每组FEC报文后,根据每组FEC报文的FEC报文头判断每组FEC报文是否丢失原始报文,若丢失,则对丢失原始报文的一组FEC报文进行解码,来恢复丢失的原始报文,将恢复的原始报文和未丢失的原始报文组成视频流发送至多个第二终端304,当每第二终端304接收到该视频流以后,进行视频播放,从而实现多个终端之间的视频会话。
在一些可能的实现中,第一终端301也可以具有第一网络设备的功能,参见图4所示的是本申请实施例提供的一种报文处理装置的结构示意图,所述装置400包括:
处理器401,用于根据待处理的第一数据流中的M个原始报文,生成第一编码任务,M为正整数,所述第一编码任务用于指示对所述M个原始报文进行编码;
目标硬件引擎402,用于根据所述第一编码任务,对所述M个原始报文进行前向纠错FEC编码,得到R个冗余报文,R为正整数。
可选地,所述处理器401,还用于将所述第一编码任务存储在第一目标发送队列,所述第一目标发送队列用于存储所述装置的待处理数据流的编码任务,所述装置的待处理数据流包括所述第一数据流;
所述目标硬件引擎,还用于从所述第一目标发送队列中读取所述第一编码任务。
可选地,所述处理器401,用于根据所述第一数据流的优先级,将所述第一编码任务添加在所述第一目标发送队列中,所述第一目标发送队列的优先级与所述第一数据流的优先级相等。
可选地,所述目标硬件引擎402用于:
所述目标硬件引擎根据各个发送队列的优先级的高低顺序,依次查询所述各个发送队列中是否有编码任务,所述各个发送队列中的每一个队列对应一个优先级;
在所述各个发送队列中,当比所述第一目标发送队列的优先级高的队列内没有编码任务时,从所述第一目标发送队列中读取所述第一编码任务。
可选地,所述装置400还包括内存403,所述第一目标发送队列位于所述网络设备的内存、所述处理器以及所述目标硬件引擎中的任一个。
可选地,所述装置400还包括内存403;
所述内存403,用于存储接收到的所述第一数据流中的原始报文;
所述处理器401,还用于若所述内存中所述第一数据流的未编码的原始报文的报文量大于或等于M,从所述第一数据流的未编码的原始报文中获取所述M个原始报文,执行根据存储的待处理的第一数据流中的M个原始报文,生成编码任务的步骤。
所述处理器401可以是通用处理器,例如CPU,或者网络处理器(network processer,NP),或者CPU和NP的组合。所述处理器还可以包括硬件芯片,上述硬件芯片可以是专用集成电路(application-specific integrated circuit,ASIC),可编程逻辑器件(programmable logic device,PLD)或其组合。上述PLD可以是复杂可编程逻辑器件(complex programmable logic device,CPLD),现场可编程逻辑门阵列(field-programmable gate array,FPGA),通用阵列逻辑(generic array logic,GAL)或其任意组合。
内存403可以包括易失性存储器(volatile memory),例如随机存取存储器(random-access memory,RAM);存储器也可以包括非易失性存储器(non-volatile memory),例如快闪存储器(flash memory),硬盘(hard disk drive,HDD)或固态硬盘(solid-state drive,SSD),或其任意组合。
可选地,所述第一编码任务包括所述M个原始报文的存储地址,或,所述第一编码任务包括M个原始报文的存储地址以及所述第一数据流的优先级,或,所述第一编码任务包括所述M个原始报文,或,所述第一编码任务包括所述M个原始报文以及所述第一数据流的优先级。
在一些可能的实现中,图4所示的报文处理装置的功能还可以由一个芯片来实现,该芯片可以包括图4中的处理器401和图4中的目标处理引擎402。
在一些可能的实现中,第二终端304也可以具有第二网络设备303的功能,参见图5是本申请实施例提供的一种报文处理装置的结构示意图,所述装置500包括处理器501和目标硬件引擎502;
所述处理器501,用于从接收到的第一数据流中获取第一组FEC报文,所述第一组FEC报文中所有FEC报文具有相同的FEC报文头,所述FEC报文头中包括FEC编码的原始报文量M;
当所述第一组FEC报文中原始报文的个数小于所述原始报文量M时,根据所述第一组FEC报文,生成第一解码任务,所述第一解码任务用于指示对所述第一组FEC报文进行解码;
所述目标硬件引擎502,用于根据所述第一解码任务,对所述第一组FEC报文中的原始报文以及所述原始报文的冗余报文进行FEC解码,得到所述第一组FEC报文中丢失的原始报文。
可选地,所述处理器501,还用于将所述第一解码任务存储在第二目标发送队列,所述第二目标发送队列用于存储所述装置的待处理数据流的解码任务,所述装置的待处理数据流包括所述第一数据流;
所述目标硬件引擎502,还用于从所述第二目标发送队列中读取所述第一解码任务。
可选地,所述处理器501,用于根据所述第一数据流的优先级,所述处理器将所述第一解码任务添加在所述第二目标发送队列中,所述第二目标发送队列的优先级与所述第一数据流的优先级相等。
可选地,所述目标硬件引擎502用于:
根据各个发送队列的优先级的高低,依次查询所述各个发送队列中是否有解码任务,所述各个发送队列中的每一个队列对应一个优先级;
在所述各个发送队列中,当比所述第二目标发送队列的优先级高的队列内没有其他解码任务时,从所述第二目标发送队列中读取所述第一解码任。
可选地,所述装置设备还包括内存,所述第二目标发送队列位于所述内存、所述处理器以及所述目标硬件引擎中的任一个。
可选地,所述第一解码任务包括所述第一组FEC报文中未丢失的FEC报文的存储地址,或所述第一组FEC报文中未丢失的FEC报文的存储地址以及所述第一数据流的优先级,或,所述第一解码任务包括所述第一组FEC报文,或,所述第一解码任务包括所述第一组FEC报文以及所述第一数据流的优先级。
在一些可能的实现中,图5所示的报文处理装置的功能还可以由一个芯片来实现,该芯片可以包括图5中的处理器501和图5中的目标处理引擎502。
为了便于叙述将第一网络设备302和第二网络设备303均记为计算设备,计算设备均可以包括目标硬件引擎,目标硬件引擎用于进行编解码计算。本申请实施例提供一种目标硬件引擎的示意图,参见图6中的目标硬件引擎600,该目标硬件引擎600包括控制器601、缓存单元602、数据处理单元603、矩阵生成器604以及编解码单元605。其中,控制器601用于接收计算设备的CPU发送的编解码参数以及待编解码报文的存储地址,根据编解码参数确定对应的数据处理策略、编解码模型的模型参数以及矩阵模型的模型参数;其中,编解码参数包括编码参数或解码参数,解码参数可以是FEC报文头中的内容;待编解码的报文可以报文M个原始报文,或未丢失的FEC报文;编解码模型可以包括编码模型或解码模型,编码模型的模型参数为原始报文量M以及目标大小L,解码模型的模型参数包括为丢失的原始FEC报文的报文量F以及目标大小L,F大于0且小于等于R;矩阵模型的模型参数包括生成矩阵的模型参数或目标校验矩阵的模型参数,生成矩阵的模型参数包括原始报文量M、冗余报文量R以及目标大小L,目标校验矩阵的模型参数包括为丢失的原始FEC报文的报文量F、冗余报文量R以及目标大小L。
控制器601还用于根据接收的待编解码报文的存储地址,从计算设备的内存中获取待编解码报文,并将待编解码报文存储在缓存单元602。控制器601还用于将编解码模型的模型参数以及数据处理策略发送至数据处理单元603,以便数据处理单元603根据编解码模型的模型参数以及数据处理策略,基于待编解码的报文生成待编码矩阵或恢复矩阵,并将待编码矩阵或恢复矩阵发送至编解码单元605。
控制器601还用于将矩阵模型的模型参数发送至矩阵生成器604,以便验矩阵生成器604根据矩阵模型的模型参数,构建生成矩阵或目标校验矩阵,并将生成矩阵或目标校验矩阵发送至编解码单元605。
编解码单元605用于对接收的待编码矩阵或恢复矩阵以及对应的生成矩阵或目标校验矩 阵进行编解码计算,得到冗余报文或丢失的原始FEC报文(具体参见图1和图2所示的编解码计算过程),并将冗余报文或丢失的原始FEC报文发送至缓存单元602,由缓存单元602将冗余报文或恢复的报文发送至计算设备的内存或处理器。
目标硬件引擎中的编解码单元605可以复用FEC编码逻辑以及FEC解码逻辑,当需要进行FEC编码时,编解码单元605根据FEC编码逻辑,对生成矩阵和待编码矩阵进行FEC编码;当需要进行FEC解码时,编解码单元605根据FEC解码逻辑,对目标校验矩阵和恢复矩阵进行FEC解码。在一些可能的实现中,编解码单元605可以包括编码子单元和解码子单元,其中,编码子单元可以根据FEC编码逻辑,对生成矩阵和待编码矩阵进行FEC编码,解码子单元可以根据FEC解码逻辑,对目标校验矩阵和恢复矩阵进行FEC解码。
为了进一步说明计算设备的编解码过程,参见图7所示的本申请实施例提供的一种报文处理方法的流程图,计算设备通过千兆(gigabit ethernet,GE)网络端口或万兆(ten-gigabit Ethernet,GXE)网络端口接收数据流中的报文,GE/GXE网络端口将接收的报文发送至包解析硬件引擎(packet parse engine,PPE),PPE将该报文存储至内存,并对该报文进行初步解析,得到该报文的描述符,并通过分流向网络处理(network processer,NP)引擎发送携带该报文的存储地址的通知消息;NP引擎可以对内存中的报文进行深度解析,以确定其是否需要编码,当报文需要进行编码时,NP引擎还可以将通知消息转发至CPU;CPU的协议栈向用户数据报协议(user datagram protocol,UDP)代理发送通知消息;当UDP代理接收到的通知消息达到一定数目时,说明内存在当前时间段内已经存储了本次编码所需的待编码报文,则CPU通过FEC软件接口向目标硬件引擎下达编码任务;目标硬件引擎根据编码任务中携带的待编码报文的存储地址,从内存中获取待编码报文,并生成冗余报文,将冗余报文存储在内存,当存储完成之后,目标硬件引擎向CPU中的FEC软件接口报告编码任务完成信息;FEC软件接口根据编码任务完成信息中携带的待编码报文的存储地址以及冗余报文的存储地址,从内存中获取待编码报文以及冗余报文,在获取的待编码报文以及冗余报文上添加FEC报文头,生成FEC报文;FEC软件接口向流量管理(traffic management,TM)引擎发送FEC报文,形成编码后的编码流(也即是数据流);TM引擎依据CPU或者其他硬件引擎的需求,对编码流进行管理,例如服务质量(quality of service,QOS)调度、流量整形、流量统计等,TM引擎将管理后的编码流发送至PPE;PPE向GE/GXE网络端口转发管理后的编码流,GE/GXE网络端口输出管理后的编码流。需要说明是,在一些可能的实现中,计算设备未包括NP引擎、PPE以及TM引擎,而NP引擎、PPE以及TM引擎的工作可以均由一个处理器来完成或者CPU来完成。再或者NP引擎、PPE、TM引擎以及CPU的工作可以由一个处理器来完成。
以上是对计算设备编码过程的描述,对于计算设备的解码过程描述如下:当计算设备在内存中存储的报文为FEC报文时,若报文头相同的一组FEC报文中的原始报文有丢失时,CPU通过FEC软件接口向目标硬件引擎下达解码任务;目标硬件引擎根据解码任务中携带的一组FEC报文的存储地址,从内存中获取一组FEC报文,根据一组FEC报文,恢复丢失的原始报文,将恢复的原始报文存储在内存,当存储完成之后,目标硬件引擎向CPU中的FEC软件接口报告解码任务完成信息;FEC软件接口根据解码任务完成信息中携带的一组FEC报文中未丢失的原始报文的存储地址以及恢复的原始报文的存储地址,从内存中获取一组FEC报文中未丢失的原始报文以及恢复的原始报文,并将获取的原始报文组成数据流输出。其中,CPU 输出数据流和输出编码流的方式同理,在此,本申请实施例对CPU输出数据流的方式不做赘述。
在一些可能的实现中,协议栈、UDP代理以及FEC软件接口可以不部署在CPU中,而是部署在NP引擎中,此时在编解码过程中,则需要NP引擎、目标硬件引擎以及内存三者之间进行交互,而无需CPU与目标硬件引擎以及内存进行交互。在一些可能的实现中,目标硬件引擎通过编解码获取到编码矩阵或者待编码矩阵后,可以直接将编码矩阵中的原始报文和冗余报文封装成FEC报文,并输出网络设备,或者是直接从待编码矩阵中获取原始报文,并输出网络设备。在一些可能的实现中,目标硬件引擎还可以直接将编码矩阵或者待编码矩阵发送至FEC软件接口,由FEC软件接口将编码矩阵中的原始报文和冗余报文封装成FEC报文,并输出网络设备,或由FEC软件接口从待编码矩阵中获取原始报文,并输出网络设备。
综上所述,对网络设备的编码过程进行如下总结:网络设备在获取到任一数据流以后,可以将该任一数据流存储在内存,若该任一数据流中的报文为待编码报文,则网络设备内的处理器可以生成用于指示对多个待编码报文进行编码的编码任务,处理器可以将该编码任务下发至内存;由网络设备内的目标硬件引擎读取内存中的编码任务,并根据编码任务对内存中存储的多个待编码报文进行FEC编码,得到多个待编码报文的冗余报文,目标硬件引擎再将冗余报文存储至内存;然后,处理器可以从内存中获取待多个待编码报文以及多个待编码报文的冗余报文,并将获取的报文封装为FEC报文。为了进一步说明该处理过程,参见如图8所示的本申请实施例提供的一种报文处理方法的流程图,其中,该第一网络设备可以包括处理器以及目标硬件引擎,该方法的流程可以包括下述步骤801-812:
801、第一网络设备获取待处理的第一数据流中的M个原始报文。
第一网络设备可以获取多个数据流。该第一数据流为该多个数据流中的任一数据流,该第一数据流可能包括多个报文。数据流可以是视频数据流、音频数据流或文本数据流等,本申请实施例对第一数据流的类型不做具体限定。
该M个原始报文为该第一数据流中任意M个连续的原始报文,第一网络设备可以每次对M个原始报文进行编码,当一次编码完成后,再对第一数据流中另外M个原始报文进行编码,在一些可能的实现方式中,本步骤801可以通过步骤8011-8012所示的过程来实现。
步骤8011、第一网络设备将接收到的第一数据流中的原始报文存入第一网络设备的内存中。
第一网络设备的GE/GXE网络端口每接收到该第一数据流中的一个原始报文后,将该原始报文发送至PPE,每当PPE接收到该原始报文后,将该原始报文存储在内存,并记录下该原始报文的存储地址。
步骤8012,若内存中第一数据流的未编码的原始报文的报文量等于或大于M,处理器从第一数据流的未编码的原始报文中获取M个原始报文。
该处理器可以包括第一网络设备内的CPU以及NP引擎中至少一个,由于第一网络设备每进行一次编码后,就会对下一组M个的未编码的原始报文进行编码,因此,对于该第一数据流中的原始报文,当第一网络设备的内存中每新缓存了M个原始报文时,就可以将新缓存的M个原始报文作为第一数据流中下一次待编码的M个原始报文。
在一些可能的实现方式中,该第一网络设备还可以设置预设时长,对于该第一数据流中的原始报文,第一网络设备每经过一个预设时长,将内存在该预设时长内新存储的原始报文 作为该下一次待编码的原始报文。在一些可能的实现方式中,每次编码时M的大小可能会发生变化,例如,第一网络设备经过一个预设时长,获取到5个原始报文,则此时M等于5,再经过下一个预设时长,第一网络设备新获取到4个原始报文,则此时M等于4。本申请实施例对该预设时长不做具体限定。
当PPE将一个原始报文存储在内存后,PPE将该原始报文对应的存储完成消息发送至NP引擎,该存储完成消息可以携带该第一数据流的流标识以及该原始报文的存储地址,流标识可以是该第一数据流的名称或编号,用于指示该原始报文所属的数据流。在一些可能的实现方式中,第一网络设备根据业务需求,对每个接收的数据流设置对应的优先级,第一网络设备可以优先处理优先级高的数据流,相应地,该存储完成消息还可以携带该第一数据流对应的优先级,以便第一网络设备内的各个模块可以根据优先级处理对应的数据流中的原始报文。用户可以在该第一网络设备上配置优先级信息表,该优先级信息表中包括从高到低的多个优先级,每个优先级对应一种业务类型,当第一网络设备接收到第一数据流时,可以根据该第一数据流中的原始报文携带的数据,确定该第一数据流的业务类型,并从该优先级信息表中确定该第一数据流的业务类型所对应的优先级,从而第一网络设备可以为该第一数据流设置对应的优先级。
当NP引擎接收到该存储完成消息后,可以将该存储完成消息发送至协议栈,因此,UDP代理可以从协议栈中收集各个存储完成消息,每当UPD代理新收集的存储完成消息的数目为M时,则新收集的M个存储完成消息可以指示内存中新存储了M个待编码报文,因此,UDP代理可以将该M个存储完成消息所对应的M个原始报文作为待编码的M个原始报文。
802、处理器根据待处理的第一数据流中的M个原始报文,生成第一编码任务,M为正整数,第一编码任务用于指示对M个原始报文进行编码。
本步骤802可以由第一网络设备的处理器中的FEC软件接口来执行,每当UDP代理收集到M个存储完成消息,则UDP代理可以将该收集到的M个存储完成消息发送至处理器中的FEC软件接口,当FEC软件接口接收到M个存储完成消息后,可以执行本步骤802。
FEC软件接口可以从M个存储完成消息中,获取到M个原始报文的存储地址,其中,M个原始报文的存储地址包括M个原始报文中每个报文的存储地址;该FEC软件接口可以根据该M个原始报文的存储地址以及编码参数,生成该编码任务,该编码任务可以包括该M个原始报文的存储地址以及编码参数,以便目标硬件引擎可以根据存储地址从内存中获取M个原始报文,并根据编码参数对获取的M个原始报文进行编码。在一些可能的实现中,该第一编码任务可以不包括该M个原始报文的存储地址,而是包括M个原始报文,以便目标硬件引擎可以直接从第一编码任务中获取该M个原始报文;当该第一数据流具有优先级时,第一编码任务还可以包括该第一数据流的优先级,该编码任务还可以携带编码标识,用于指示对该每个报文进行编码,本申请实施例对该编码标识的表示方式不做具体限定。
该编码参数可以是第一网络设备预设的编码参数,该第一网络设备可以每进行一次编码均使用该编码参数,当然,第一网络设备也可以随着报文传输情况对该编码参数进行适当的调整。当第一网络设备每一次编码都按照相同的编码参数来进行时,该第一报文量可以是该编码参数中的原始报文量M,该第一网络设备还可以根据目前CPU的开销或目标硬件引擎当前的计算能力,动态修改编码参数中的原始报文量M,例如,当CPU开销较小或目标硬件引擎当前仍有足够的计算能力时,该第一网络设备可以适当提高原始报文量,也即是增加进行 一次编码的报文,反之,可以适当降低原始报文量,也即是减少进行一次编码的报文。
第一网络设备还可以根据当前的网络丢包率,动态调整模型参数中的冗余报文量R,例如,当网络丢包率较高时,可以适当提高冗余报文量R,也即是增加一次编码过程所生成的冗余报文的报文量,以便后续可以恢复丢失的所有报文,当网络丢包率较低时,可以适当降低冗余报文量R,也即是减少一次编码过程所生成的冗余报文的报文量,以提高编码效率。
由于第一网络设备可以对编码参数进行上述的动态调整,从而可以通过调整编码参数,来提高第一网络设备的编码效率。
803、处理器将第一编码任务存储在第一目标发送队列,第一目标发送队列用于存储第一网络设备的待处理数据流的编码任务,第一网络设备的待处理数据流包括第一数据流。
本步骤803可以由该处理器中FEC软件接口来执行。该第一网络设备可以预设多个发送队列,每个发送队列用于存储第一网络设备的待处理数据流的编码任务,该第一目标发送队列可以是该多个发送队列中的任一队列。该多个发送队列可以位于第一网络设备的内存、处理器以及目标硬件引擎中的任一个。
在一些可能的实现中,该第一网络设备可以为每个发送队列设置一个优先级,每个发送队列用于存储相同优先级的数据流的编码任务。例如,图9所示的本申请实施例提供的一种网络设备内部交互流程的示意图,图9中的内存中有1优先级为A的发送队列A和优先级为B的发送队列B,其中,优先级A高于优先级B,此时,发送队列A中存储有编码任务3、5和6,发送队列B中存储有编码任务1、2和4,其中,编码任务3、5和6分别为一个优先级为A的编码任务,编码任务1、2和4分别为一个优先级为B的编码任务。
在一些可能的实现方式中,本步骤803可以包括:处理器根据第一数据流的优先级,将第一编码任务添加在第一目标发送队列中,第一目标发送队列的优先级与第一数据流的优先级相等。具体地,当FEC软件接口生成一个第一编码任务后,该FEC软件接口可以根据第一数据流的优先级,确定内存中与该第一数据流优先级对应的第一目标发送队列,当该第一目标发送队列中编码任务的个数小于第一目标个数时,FEC软件接口将该第一编码任务添加在该第一目标发送队列中,其中,第一目标个数为该第一目标发送队列可以存储的最多编码任务的个数。当该第一目标发送队列中编码任务的个数等于第一目标个数时,FEC软件接口每间隔第一预设时长,查询该第一目标发送队列中的编码任务的个数是否小于第一目标个数,一旦小于第一目标个数,则将该第一编码任务添加在该第一目标发送队列中。本申请实施例对该第一预设时长不做具体限定。该目标硬件引擎可以每当该编解码单元空闲就可以查询该第一目标发送队列。
804、目标硬件引擎从第一目标发送队列中读取第一编码任务。
目标硬件引擎可以先按照优先级的高低轮询该内存中的每个发送队列,以便确定目标硬件引擎是否要从该第一目标发送队列,在一些可能的实现方式中,目标硬件引擎根据各个发送队列的优先级的高低顺序,依次查询各个发送队列中是否有编码任务,各个发送队列中的每一个队列对应一个优先级;在各个发送队列中,当比第一目标发送队列的优先级高的队列内没有编码任务时,目标硬件引擎从第一目标发送队列中读取第一编码任务。
该目标硬件引擎轮询各个发送队列的过程可以是:该目标硬件引擎查询该各个发送队列中的优先级最高的第一发送队列,当第一发送队列中有编码任务时,该目标硬件引擎从该第一发送队列的队头中获取一个编码任务,并根据编码任务执行下述步骤805;每隔第二预设 时长,该目标硬件引擎再次查询该第一发送队列,当第一发送队列中仍有编码任务时,则再次从该第一发送队列的队头中获取一个新的编码任务;直至该第一发送队列中未存储编码任务时,该目标硬件引擎查询该多个发送队列中第二个优先级对应的第二发送队列是否有编码任务,当有编码任务时,则从第二发送队列获取编码任务,并执行下述步骤805,其中第二优先级为仅次于最高优先级的优先级;当第二发送队列中没有编码任务时,依次类推按照优先级查询仅次于该第二个优先级的发送队列。
当一个发送队列队头的编码任务被目标硬件引擎获取后,该发送队列中下一个编码任务成为该发送队列的队头,这样目标硬件引擎下次就可以从该发送队列的队头获取到该下一个编码任务。
805、目标硬件引擎根据该第一编码任务中的M个原始报文的存储地址,从内存中获取该M个原始报文。
当该目标硬件引擎中的控制器获取到该第一编码任务后,可以从第一编码任务中获取到该M个原始报文的存储地址,该目标硬件引擎可以向内存发送第一报文获取请求,该第一报文获取请求携带该M个原始报文的存储地址,当内存接收到该第一报文获取请求后,向目标硬件引擎发送该存储地址内存储的M个原始报文,当接收到该M个原始报文后,目标硬件引擎将该M个第一报文缓存在缓存单元,以便数据处理单元对M个原始报文进行处理。当然,若该第一编码任务中直接携带该M个原始报文,该目标硬件引擎可以直接从第一编码任务中,获取该M个原始报文,而无需从内存中获取该M个原始报文。
806、目标硬件引擎根据第一编码任务,对M个原始报文进行前向纠错FEC编码,得到R个冗余报文,R为正整数。
当该目标硬件引擎获取到该M个原始报文后,可以根据该第一编码任务中的编码参数,对该M个原始报文进行前向纠错FEC编码。在一种可能的方式中,该目标硬件引擎内的数据处理单元,可以根据编码参数中的原始报文量M,对该M个原始报文进行填充处理,得到M个等长报文;数据处理单元将该M个等长报文,组成待编码矩阵,其中,待编码矩阵的一行为一个等长报文;数据处理单元将待编码矩阵发送至编解码单元;由编解码矩阵单元将对应的生成矩阵与待编码矩阵进行乘法计算,得到R个冗余报文,以实现本步骤806。在图1中介绍了生成矩阵与该待编码矩阵进行乘法计算的过程,在此本申请实施例对该过程不做赘述。
其中,生成矩阵可以由目标硬件引擎中的矩阵生成器生成,并发送至编解码单元。矩阵生成器生成对应的生成矩阵的过程为:目标硬件引擎内的控制器可以从第一编码任务中获取冗余报文量R以及原始报文量M,并将获取的冗余报文量R以及原始报文量M发送至矩阵生成器,矩阵生成器根据冗余报文量R以及原始报文量M,生成(M+R)*M的生成矩阵,并将第(M+R)*M的生成矩阵发送至编解码单元。
807、目标硬件引擎将该R个冗余报文存储在内存。
当该目标硬件引擎中的编解码单元生成该R个冗余报文后,将该R个冗余报文缓存在缓存单元,缓存单元向内存发送第一报文存储请求,该第一报文存储请求携带该R个冗余报文的存储地址以及该R个冗余报文,其中,该R个冗余报文的存储地址包括每个冗余报文的存储地址,当内存接收到该第一报文存储请求后,内存在该R个冗余报文的存储地址内存储该R个冗余报文。
808、当该R个冗余报文存储完成后,目标硬件引擎在第一编码任务中添加该R个冗余报 文的存储地址,得到该M个原始报文的第一编码完成信息,第一编码完成信息用于指示该M个原始报文编码完成。
目标硬件引擎还可以将该第一编码任务中的编码标识替换为编码完成标识,编码完成标识用于原始报文编码完成,本申请实施例对该编码完成标识的表示方式不做具体限定。由于第一编码任务包括M个第一报文的存储地址以及编码参数,因此,该第一编码完成信息可以包括R个冗余报文的存储地址、M个原始报文的存储地址以及编码参数。当该第一编码任务中携带第一数据流的优先级时,该第一编码完成信息还包括第一数据流的优先级。
809、目标硬件引擎将第一编码完成信息存储在第一目标接收队列,第一目标接收队列用于存储第一网络设备的待处理数据流的编码完成信息任务。
该第一网络设备可以预设多个接收队列,每个接收队列用于存储第一网络设备的待处理数据流的编码完成信息,该第一目标接收队列可以是该多个接收队列中的任一队列。该多个接收队列可以位于第一网络设备的内存、处理器以及目标硬件引擎中的任一个。
在一些可能的实现中,该第一网络设备可以为每个接收队列设置一个优先级,每个接收队列用于存储相同优先级的数据流的编码完成信息。仍以图9为例,图9中的内存中有1优先级为A的接收队列A和优先级为B的接收队列B,其中,优先级A高于优先级B,此时,接收队列A中存储有任务完成信息3、5和6(在图9中简称“完成信息3、5和6”),接收队列B中存储有任务完成信息1、2和4,其中,任务完成信息3、5和6分别为一个优先级为A的编码完成信息,任务完成信息1、2和4(在图9中简称“完成信息3、5和6”)分别为一个优先级为B的编码完成信息。
在一些可能的实现方式中,目标硬件引擎根据第一数据流的优先级,将第一编码完成信息添加在内存中的第一目标接收队列,第一目标接收队列的优先级等于第一数据流的优先级。具体地,目标硬件引擎可以根据第一数据流的优先级,确定内存中与该第一数据流的优先级对应的第一目标接收队列,当该第一目标接收队列中编码完成信息的个数小于第二目标个数时,目标硬件引擎将该第一编码完成信息添加在该第一目标接收队列中,其中,第二目标个数为该第一目标接收队列可以存储的最多编码完成信息的个数。当该第一目标接收队列中编码完成信息的个数等于第二目标个数时,FEC软件接口每间隔第二预设时长,查询该第一目标接收队列中的编码完成信息的个数是否小于目第二标个数,一旦小于第二目标个数,则将该第一编码完成信息添加在该第一目标接收队列中。本申请实施例对该第二预设时长不做具体限定。
810、处理器从第一目标接收队列中读取第一编码完成信息。
本步骤810可以由该处理器的FEC软件接口来执行。FEC软件接口可以按照优先级的高低轮询各个接收队列。FEC软件接口可以先通过轮询的方式,确定是否可以在该第一目标接收队列中,获取该编码完成信息,在一些可能的实现方式中,FEC软件接口根据优先级的高低顺序,依次查询各个接收队列中是否有其他编码完成信息,各个接收队列中的每一个队列对应一个优先级;在各个第一接收队列中,当比第一目标接收队列的优先级高的队列内没有其他编码完成信息时,从第一目标接收队列中,获取第一编码完成信息。
FEC软件接口轮询各个接收队列的过程可以是:FEC软件接口查询该各个接收队列中的优先级最高的第一接收队列,当第一接收队列中有编码完成信息时,FEC软件接口从该第一接收队列的队头中获取一个编码完成信息,并根据编码完成信息执行下述步骤811;每隔第三 预设时长,该FEC软件接口再次查询该第一接收队列,当第一接收队列中仍存储有编码完成信息时,则再次从该第一接收队列的队头中获取一个新的编码完成信息,直至该第一发送队列中未存储编码任务时,FEC软件接口查询该多个第一接收队列中下一个优先级对应的第二接收队列是否有编码完成信息,当存储有编码完成信息时,则从第二接收队列获取编码完成信息,并执行下述步骤811,当第二接收队列中未存储有编码完成信息时,依次类推按照优先级查询仅次于该第二优先级的第三接收队列。
当一个第一接收队列中的编完成码信息被FEC软件接口获取后,该第一接收队列中下一个编码完成信息成为该第一接收队列的队头,以便FEC软件接口下次从该第一接收队列的队头获取到该下一个编码完成信息。
811、处理器根据第一编码完成信息,从内存中获取M个原始报文以及R个冗余报文。
本步骤811可以由该处理器内的FEC软件接口来执行。FEC软件接口可以从第一编码完成信息中,获取R个冗余报文的存储地址、M个原始报文的存储地址以及编码参数;FEC软件接口向内存发送第二报文获取请求,该第二报文获取请求携带R个冗余报文的存储地址以及M个原始报文的存储地址,当内存接收到该第二报文获取请求时,根据第二报文获取请求中的R个冗余报文的存储地址以及M个原始报文的存储地址,向FEC软件接口返回R个冗余报文以及M个原始报文。
812、处理器向第二网络设备发送M个原始报文以及R个冗余报文。
本步骤812可以由该处理器内的FEC软件接口来执行。当FEC软件接口获取到内存返回的R个冗余报文以及M个原始报文后;FEC软件接口根据第一编码完成信息中的编码参数;R个冗余报文以及M个原始报文分别封装为一个FEC报文。在一些可能的实现方式中,本步骤812可以由下述步骤8121-8123所示的过程来实现。
步骤8121、FEC软件接口根据编码参数中的目标大小,对M个原始报文中大小小于目标大小的报文进行填充处理,得到M个等长报文,每个等长报文的大小为目标大小。
步骤8122、FEC软件接口在每个等长报文上均添加FEC报文头,得到M个原始FEC报文,并在每个冗余报文中均添加FEC报文头,得到R个冗余FEC报文,FEC报文头携带M个原始报文的编码参数。
例如,图10所示的本申请实施例提供的一种FEC报文的示意图中FEC报文,当图10中的FEC报文的负载报文为第一数据流中的原始报文形成的等长报文时,该FEC报文为一个原始FEC报文,当该FEC报文的负载报文为冗余报文时,该FEC报文为一个冗余FEC报文。
FEC报文头用于指示该M个原始报文的编码情况。FEC报文头携带M个原始的编码参数,例如图10中的FEC报文头携带原始报文量M=4、冗余报文量R=2、目标大小L=30MB。FEC报文头还可以携带该M个原始报文的目标标识,该目标标识用于指示对该第一数据流中的原始报文进行的编码的次数,例如,图10中的FEC报文头中的目标标识为1.2,则表明第一网络设备对第一数据流1中的报文进行的第二次编码,则该M个原始报文为第二次编码时用到的第一数据流中的原始报文。
FEC报文头还可以携带优先级标识、算法标识、该M个原始报文中每个报文在第一数据流中的序列号、每个等长报文在待编码矩阵中的序列号以及每个冗余报文在编码矩阵中的序列号,其中,优先级标识用于指示该第一数据流的优先级,算法标识用于指示第一网络设备在编码过程中所使用到的算法,每个等长报文在待编码矩阵中的序列号为每个等长报文在待 编码矩阵中的行号,每个冗余报文在编码矩阵中的序列号为每个冗余报文在编码矩阵中的行号。例如在图10中的FEC头中,原始报文A0-A3在第一数据流中的序列号分别为10、11、12和13;等长报文M0-M3的序列号分别为0、1、2和3;冗余报文R0-R1的序列号分别为4和5。图10中FEC报文头的举例是以图1所示的编码计算过程为基础的。
步骤8123、处理器发送M个原始FEC报文以及R个冗余FEC报文。
由于M个原始FEC报文以及R个冗余FEC报文的报文头均相同,因此,M个原始FEC报文以及R个冗余FEC报文可以视为一组FEC报文。对于该M个原始FEC报文以及R个冗余FEC报文中的任一FEC报文,FEC软件接口每获取到一个任一FEC报文后,向第一网络设备内的TM引擎输该任一FEC报文,由于FEC软件接口可以持续不断的向TM引擎输出FEC报文,因此,TM引擎处可以形成该与第一数据流的编码流,TM引擎对该编码流进行管理后,向PPE输出管理后的编码流,PPE向GE/GXE网络端口转发管理后的编码流,GE/GXE网络端口向第二网络设备输出该管理后的编码流,以便第二网络设备可以从编码流中获取到该编码流。
为了进一步说明在编码过程中第一网络设备内的处理器、目标硬件引擎以及内存之间的交互情况,参见图11所示的本申请实施例提供的一种FEC编码的流程图,该流程具体包括步骤1101-11106。
步骤1101、UDP代理向FEC软件接口发送存储完成消息。
步骤1102、当FEC软件接口接收的存储完成消息的个数等于M时,生成第一编码任务,并将第一编码任务发送到内存的任务缓存中,
其中,该任务缓存包括多个发送队列和多个接收队列,FEC软件接口可以将第一编码任务发送到优先级对应的第一目标发送队列。
步骤1103、目标硬件引擎从任务缓存的第一目标发送队列中获取到第一编码任务,并根据第一编码任务中存储地址,从内存中读取M个原始报文。
步骤1104、目标硬件引擎对读取到的M个原始报文进行FEC编码,得到R个冗余报文,目标硬件引擎将R个冗余报文存储在内存中,并将第一编码完成信息发送在任务缓存内的第一目标接收队列中。
步骤1105、FEC软件接口从任务缓存内的第一目标接收队列中读取第一编码完成信息,并根据第一完成信息,读取内存中的M个原始报文和R个冗余报文,并在M个原始报文和R个冗余报文分别封装FEC报文头,得到FEC报文。
步骤1106、FEC软件接口发送FEC报文。
上述步骤807-812所示的过程为以目标处理引擎、内存以及处理器协同将M个原始报文以及R个冗余报文向第二网络设备发送的过程。在一些可能的实现中,目标处理引擎还可以直接将M个原始报文以及R个冗余报文发送至处理器,由处理器执行8122-8123所示的过程,从而以实现M个原始报文以及R个冗余报文的传输。在一些可能的实现中,目标处理引擎还可以自己执行8122-8123所示的过程,从而以实现M个原始报文以及R个冗余报文的传输。
本申请实施例提供的方法,通过直接在第一网络设备的目标硬件引擎中对第一数据流中的M个原始报文进行FEC编码,而无需在处理器中进行FEC编码,因此,可以降低对CPU的开销,提高第一网络设备的编码效率,进而可以使得第一网络设备在传输报文过程中容易满足大吞吐量的要求。并且,第一网络设备可以对编码参数进行上述的动态调整,从而可以通过调整编码参数,来提高第一网络设备的编码效率。
当第二网络设备获取到编码流后,若编码流中的原始FEC报文有丢失,则第二网络设备可以通过对未丢失的FEC报文进行解码,以恢复丢失的FEC报文。该处理过程可以是:第二网络设备在获取到任一编码流以后,可以将该任一编码流存储在内存;若该任一编码流中任一组FEC报文中的原始FEC报文的个数小于编码时的原始报文量M时,说明该任一组FEC报文在传输过程中存在丢包情况,则第二网络设备内的处理器可以生成用于指示对任一组FEC报文进行解码的解码任务,处理器可以将该解码任务下发至内存;由第二网络设备内的目标硬件引擎读取内存中的解码任务,并根据编码任务对内存中存储的任一组FEC报文进行FEC编码,恢复任一组FEC报文中丢失的原始报文,目标硬件引擎再将恢复的原始报文存储至内存;然后,处理器可以从内存中获取任一组FEC报文中未丢失的原始FEC报文和恢复出的原始报文,并将除去未丢失的原始FEC报文的FEC报文头,得到未丢失的原始报文。为了进一步说明该处理过程,参见图12所示本申请实施例提供的一种报文处理方法的流程图,其中,该第二网络设备可以包括处理器以及目标硬件引擎,该方法的流程包括步骤1201-1213。
1201、处理器从接收到的第一数据流中获取第一组FEC报文,该第一组FEC报文中所有FEC报文具有相同的FEC报文头,该FEC报文头中包括FEC编码的原始报文量M。
该第二网络设备可以获取多个编码流,该第一数据流可以是该对个编码流中任一编码流,该第一数据流可以由多组FEC报文组成,第一组FEC报文为该多组FEC报文中的任一组FEC报文,该第一组FEC报文包括第一网络终端进行一次编码所输出的M个原始FEC报文以及R个冗余FEC报文。
当该第二网络设备开始接收该第一数据流时,该第二网络设备每接收到该第一数据流中的一个FEC报文,将该一FEC报文存储在该第二网络设备的内存中,在一些可能的实现方式中,第二网络设备的GE/GXE网络端口接收该FEC报文,并将该FEC报文发送至该第二网络设备内的PPE,PPE将该FEC报文存储在内存中,并记录下该FEC报文的存储地址,向该第二网络终端的NP引擎发送存储完成消息,该储完成消息携带该FEC报文的存储地址。当NP引擎接收到该存储完成消息后,可以将该存储完成消息发送至该第二网络设备的CPU中的协议栈,因此,UDP代理可以从协议栈中收集各个存储完成消息,并将收集的存储完成消息发送至第二网络设备的FEC软件接口,该FEC软件接口每经过第三预设时长,获取到各个存储完成消息,FEC软件接口根据各个存储消息携带的存储地址,读取内存对应的存储地址处的FEC报文的报文头,得到多个报文头,并对多个报文头进行比较,得到相同的报文头,并将具有相同报文头的FEC报文确定为一组FEC报文,也即是,对于该第一数据流中的FEC报文,第二网络设备每经过一个第三预设时长,将内存在该第三预设时长内新存储的FEC报文中具有相同FEC报文头的报文作为第一组FEC报文,本申请实施例对该第三预设时长不做具体限定。由于FEC报文头中携带目标标识,目标标识用于指示编码的次数,在一些可能的实现中,当多个FEC报文的报文头中目标标识相同时,也可以说明这多个FEC报文为同一次编码后得到的报文,也即是一组FEC报文。
1202、当该第一组FEC报文中原始报文的个数小于原始报文量M时,该处理器根据该第一组FEC报文,生成第一解码任务,该第一解码任务用于指示对该第一组FEC报文进行解码。
本步骤1202可以由处理器中的FEC软件接口来执行,当FEC软件接口确定完该第一组FEC报文后,该第二网络设备可以从该第一组FEC报文中的一个报文的报文头中获取到编码参数,该编码参数中的原始报文量M,也即是第一组FEC报文初始包括的原始FEC报文的报 文量。由于每个原始FEC报文对应一个编码时的一个原始报文,因此当该第一组FEC报文中中原始FEC报文的报文量小于原始报文量M时,也即是该第一组FEC报文中原始报文的个数小于原始报文量M,说明第一组FEC报文中的至少一个原始FEC报文丢失,也即是在由第一网络设备将该第一组FEC报文传输至第二网络设备的过程中,丢失了部分原始FEC报文,也即是丢失编码时的原始报文。为了恢复编码前的第一数据流,FEC软件接口可以生成第一解码任务,以便目标硬件引擎根据第一解码任务,对第一组FEC报文中未丢失的FEC报文进行解码,以恢复丢失的原始FEC报文。
该第一解码任务包括该第一组FEC报文的存储地址或该第一组FEC报文,以便目标硬件引擎可以根据该第一组FEC报文的存储地址,从内存中获取该第一组FEC报文,或者,以便目标硬件引擎可以直接从第一解码任务中获取该第一组FEC报文。当该第一数据流具有优先级时,所述第一解码任务还可以包括该第一数据流的优先级。
当多个FEC报文中的原始FEC报文的报文量等于编码参数中的原始报文量M时,说明第一组FEC报文中的原始FEC报文没有丢失,则第二网络设备可以执行下述步骤1211。
1203、处理器将第一解码任务存储在第二目标发送队列,第二目标发送队列用于存储第二网络设备的待处理数据流的解码任务,网络设备的待处理数据流包括第一数据流。
本步骤1203可以由该处理器中FEC软件接口来执行。在本步骤1203中的待处理数据流也即是待处理的编码流。该第二网络设备可以预设多个发送队列,每个发送队列用于存储述第二网络设备的待处理数据流的解码任务,该第二目标发送队列可以是该多个发送队列中的任一队列。该多个发送队列可以位于第二网络设备的内存、处理器以及目标硬件引擎中的任一个。
在一些可能的实现中,该第二网络设备可以为每个发送队列设置一个优先级,每个发送队列用于存储相同优先级的数据流的解码任务。在一些可能的实现方式中,本步骤1203可以包括:根据第一数据流的优先级,处理器将第一解码任务添加在第二目标发送队列中,第二目标发送队列的优先级与第一数据流的优先级相等。处理器将第一解码任务添加在第二目标发送队列的过程与步骤803中处理器将第一编码任务添加在第一目标发送队列的过程同理,在此,本申请实施例对将第一解码任务添加在第二目标发送队列的具体过程不做赘述。
1204、目标硬件引擎从第二目标发送队列中读取第一解码任务。
目标硬件引擎可以先按照优先级的高低轮询该内存中的每个第二发送队列,以便确定目标硬件引擎是否要从该第二目标发送队列,在一些可能的实现方式中,目标硬件引擎根据各个发送队列的优先级的高低,依次查询各个发送队列中是否有解码任务,各个发送队列中的每一个队列对应一个优先级;在各个发送队列中,当比第二目标发送队列的优先级高的队列内没有其他解码任务时,目标硬件引擎从第二目标发送队列中读取第一解码任务。
该目标硬件引擎通过轮询各个发送队列获取第一解码任务的过程与步骤804中目标硬件引擎通过轮询各个发送队列获取第一编码任务的过程同理,在此,本申请实施例对通过轮询各个发送队列获取第一解码任务的过程不做赘述。
1205、目标硬件引擎根据该第一解码任务中的第一组FEC报文的存储地址,从内存中获取该第一组FEC报文。
本步骤1205所示的过程与步骤805所示的过程同理,在此,本申请实施例对本步骤1205不做赘述。在一些可能的实现中,当该第一解码任任务中携带该第一组FEC报文时,该目标 硬件引擎可以直接从该第一解码任务中获取该第一组FEC报文,而无需从内存中获取。其中,目标硬件引擎获取的第一组FEC报文,也即是第一组FEC报文中未丢失的FC报文,包括未丢失的原始FEC报文和未丢失的冗余FEC报文。
1206、目标硬件引擎对对该第一组FEC报文中的原始报文以及该原始报文的冗余报文进行FEC解码,得到该第一组FEC报文中丢失的原始报文。
当该目标硬件引擎获取到第一组FEC报文时,该目标硬件引擎内的数据处理单元,可以去除第一组FEC报文中的原始FEC报文的报文头以及冗余FEC报文的报文头,得到多个等长报文报文和至少一个冗余报文,每个等长报文也即是第一组FEC报文中丢失的一个原始报文;该数据处理单元可以将多个等长报文和至少一个冗余报文组成恢复矩阵后,并将恢复矩阵发送至编解码单元,矩阵生成器构建对应的目标校验矩阵,将对应的目标校验矩阵发送至编解码单元;由编解码单元将对应的目标校验矩阵的逆矩阵与该恢复矩阵进行乘法计算,得到待编码矩阵;再根据FEC报文头中各个等长报文的序列号以及冗余报文的序列号,可以确定哪些等长报文丢失,哪些冗余报文丢失,也即是哪些原始FEC报文丢失或哪些冗余FEC报文丢失,从而可以从待编码矩阵中获取丢失的等长报文,从而得到丢失的原始报文,以实现本步骤1206。在图2中介绍了目标检验矩阵的逆矩阵与该恢复矩阵进行乘法计算的过程,在此本申请实施例对该过程不做赘述。
其中,矩阵生成器构建对应的目标检验矩阵的过程为:目标硬件引擎内的控制器根据报文头中的编码参数中的冗余报文量R,确定丢失的冗余FEC报文的报文量,丢失的冗余FEC报文的报文量为冗余报文量R与多个FEC报文中冗余FEC报文的报文量的差值;控制器根据FEC报文头中的编码参数中的原始报文量M以及多个FEC报文中原始FEC报文的报文量,确定丢失的原始FEC报文的报文量,丢失的原始FEC报文的报文量为原始报文量M与多个FEC报文中原始FEC报文的报文量的差值;控制器将丢失的冗余FEC报文的报文量和丢失的原始FEC报文的报文量发送至矩阵生成器,矩阵生成器根据丢失的冗余FEC报文的报文量和丢失的原始FEC报文的报文量,构建对应的目标校验矩阵,并将对应的目标校验矩阵发送至编解码单元。
步骤1205-1206所示的过程也即是根据该第一解码任务,对该第一组FEC报文中的原始报文以及该原始报文的冗余报文进行FEC解码,得到该第一组FEC报文中丢失的原始报文的过程。
1207、目标硬件引擎将该第一组FEC报文中丢失的原始报文存储在内存。
本步骤1207与步骤807所示的过程同理,在此,本申请实施例对本步骤1207不做赘述。
1208、当该丢失的原始报文存储完成后,目标硬件引擎在第一解码任务中添加丢失的原始报文的存储地址,得到第一解码完成信息,第一编码完成信息用于指示第一组FEC报文解码完成。
第一解码完成信息携带丢失的原始报文的存储地址以及第一组FEC报文中的原始FEC报文,当第一数据流具有优先级时,第一解码完成信息还携带第一数据流的优先级。本步骤1208所示的过程与步骤808生成第一编码完成信息的过程同理,在此,本申请实施例对本步骤1208不做赘述。
1209、目标硬件引擎在第二目标接收队列添加第一解码完成信息,第二目标接收队列用于存储第二网络设备的待处理编码流的解码完成信息。
该第二网络设备可以预设多个接收队列,每个接收队列用于存储第二网络设备的待处理编码流的解码完成信息,该第二目标接收队列可以是该多个接收队列中的任一队列。该多个接收队列可以位于第二网络设备的内存、处理器以及目标硬件引擎中的任一个。
在一些可能的实现中,该第二网络设备可以为每个接收队列设置一个优先级,在一些可能的实现方式中,根据编码流的优先级,将第一解码完成信息添加在内存中的第二目标接收队列,第二目标接收队列的优先级等于编码流的优先级。具体地添加过程与步骤809中在第一目标接收队列添加第一编码完成信息的过程同理。
1210、处理器从第二目标接收队列中读取第一解码完成信息。
本步骤1210可以由该处理器内的FEC软件接口来执行。FEC软件接口可以按照优先级的高低轮询各个第二接收队列。FEC软件接口可以先通过轮询的方式,确定是否可以在该第二目标接收队列中,获取该第一解码完成信息,在一些可能的实现方式中,根据优先级的高低顺序,依次查询的各个第二接收队列中是否有其他解码完成信息,各个第二接收队列中的每一个队列对应一个优先级;在各个第二接收队列中,当比第二目标接收队列的优先级高的队列内没有其他解码完成信息时,从第二目标接收队列中,获取解码完成信息。本步骤1210的FEC软件接口轮询各个接收队列的过程与步骤810中FEC软件接口轮询各个接收队列的过程同理。
1211、处理器根据第一解码完成信息,从内存中获取第一组FEC报文中的原始FEC报文以及丢失的原始报文。
本步骤1211所示的过程与步骤811中获取M个原始报文以及R个冗余报文的过程同理,在此,本申请实施例对本步骤1211不做赘述。
1212、处理器根据第一组FEC报文中的原始FEC报文以及丢失的原始报文,恢复与第一数据流编码前的数据流。
本步骤1212可以由该处理器内的FEC软件接口来执行。FEC软件接口可以先去除第一组FEC报文中未丢失的原始FEC报文的报文头,等到多个等长报文,再基于多个等长报文以及丢失的原始报文恢复第一数据流编码前的数据流,在一些可能的实现方式中,本步骤1212可以由下述步骤12A-12C所示的过程来实现。
步骤12A、对于第一组FEC报文中的原始FEC报文,FEC软件接口去除每个原始FEC报文的FEC报文头,得到多个等长报文。
步骤12B、FEC软件接口去除多个等长报文以及丢失的原始报文中填充的数据,得到第一数据流编码前的数据流中的M个原始报文。
步骤12C、FEC软件接口根据FEC报文头中携带的各个原始报文的序列号,按照序列号的大小,对M个原始报文进行排序,得到第一数据流编码前的数据流。
1213、处理器向第二终端发送该数据流。
本步骤1213与步骤8123同理,在此,本申请实施例对本步骤1213不做赘述。
为了进一步说明在解码过程中第二网络设备内的处理器、目标硬件引擎以及内存之间的交互情况,参见图13所示的本申请实施例提供的一种FEC解码的流程图,该流程具体包括步骤1301-1306。
步骤1301、UDP代理向FEC软件接口发送每个FEC报文的存储完成消息。
步骤1302、当FEC软件接口根据接收到一组FEC报文的存储完成消息后,若一组FEC报 文中有原始FEC报文丢失,则根据接收到的一组FEC报文,生成第一解码任务,并将第一解码任务发送到内存的任务缓存中。
其中,该任务缓存包括多个发送队列和多个接收队列,FEC软件接口可以将第一解码任务发送到优先级对应的第二目标发送队列。
步骤1303、目标硬件引擎从任务缓存的第二目标发送队列中获取到第一解码任务,并根据第一解码任务中存储地址,从内存中读取一组FEC报文。
步骤1304、目标硬件引擎对读取到的一组FEC报文进行解码,得到丢失的原始报文,并将丢失的原始报文存储在内存中,并在内存的第二目标接收队列中添加第一解码完成信息。
步骤1305、FEC软件接口从任务缓存内的第二目标接收队列中读取第一解码完成信息,并根据第一解码完成信息,读取内存中的一组FEC报文以及丢失的原始报文,并去除一组FEC报文的报文头,得到等长报文。
步骤1306、FEC软件接口对等长报文进行处理,得到数据流,并输出数据流。
上述步骤1207-1213所示的过程为以目标处理引擎、内存以及处理器协同向第二终端发送的数据流过程。在一些可能的实现中,目标处理引擎还可以直接将第一组FEC报文以及丢失的原始报文发送至处理器,由处理器执行1212-1213所示的过程。在一些可能的实现中,目标处理引擎还可以自己执行1212-1213所示的过程。
本申请实施例提供的方法,通过直接在第二网络设备的目标硬件引擎中对第一组FEC报文中未丢失的FEC报文进行FEC解码,而无需在CPU中进行FEC解码,因此,可以降低对CPU的开销,提高第二网络设备的解码效率,进而可以使得第二网络设备在传输报文过程中容易满足大吞吐量的要求。
上述所有可选技术方案,可以采用任意结合形成本公开的可选实施例,在此不再一一赘述。
本申请实施例提供的报文处理装置设备在对报文进行处理时,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。另外,上述实施例提供的报文处理方法实施例属于同一构思,其具体实现过程详见方法实施例,这里不再赘述。
本领域普通技术人员可以理解实现上述实施例的全部或部分步骤可以通过硬件来完成,也可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。
以上所述仅为本申请的较佳实施例,并不用以限制本申请,凡在本申请原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。

Claims (20)

  1. 一种报文处理方法,其特征在于,应用于包括处理器以及目标硬件引擎的网络设备,所述方法包括:
    所述处理器根据待处理的第一数据流中的M个原始报文,生成第一编码任务,M为正整数,所述第一编码任务用于指示对所述M个原始报文进行编码;
    所述目标硬件引擎根据所述第一编码任务,对所述M个原始报文进行前向纠错FEC编码,得到R个冗余报文,R为正整数。
  2. 根据权利要求1所述的方法,其特征在于,所述处理器根据待处理的第一数据流中的M个原始报文,生成第一编码任务之后,所述方法还包括:
    所述处理器将所述第一编码任务存储在第一目标发送队列,所述第一目标发送队列用于存储所述网络设备的待处理数据流的编码任务,所述网络设备的待处理数据流包括所述第一数据流;
    所述目标硬件引擎从所述第一目标发送队列中读取所述第一编码任务。
  3. 根据权利要求2所述的方法,其特征在于,所述处理器将所述第一编码任务存储在第一目标发送队列包括:
    所述处理器根据所述第一数据流的优先级,将所述第一编码任务添加在所述第一目标发送队列中,所述第一目标发送队列的优先级与所述第一数据流的优先级相等。
  4. 根据权利要求2所述的方法,其特征在于,所述目标硬件引擎从所述第一目标发送队列中读取所述第一编码任务包括:
    所述目标硬件引擎根据各个发送队列的优先级的高低顺序,依次查询各个发送队列中是否有编码任务,所述各个发送队列中的每一个队列对应一个优先级;
    在所述各个发送队列中,当比所述第一目标发送队列的优先级高的队列内没有编码任务时,所述目标硬件引擎从所述第一目标发送队列中读取所述第一编码任务。
  5. 根据权利要求1所述的方法,其特征在于,所述处理器根据存储的待处理的第一数据流中的M个原始报文,生成第一编码任务之前,所述方法还包括:
    所述网络设备将接收到的所述第一数据流中的原始报文存入所述网络设备的内存中;
    若所述网络设备的内存中所述第一数据流的未编码的原始报文的报文量等于或大于M,所述处理器从所述第一数据流的未编码的原始报文中获取所述M个原始报文。
  6. 根据权利要求1至5任一所述的方法,其特征在于,所述第一编码任务包括所述M个原始报文的存储地址,或,所述第一编码任务包括M个原始报文的存储地址以及所述第一数据流的优先级,或,所述第一编码任务包括所述M个原始报文,或,所述第一编码任务包括所述M个原始报文以及所述第一数据流的优先级。
  7. 一种报文处理方法,其特征在于,应用于包括处理器以及目标硬件引擎的网络设备,所述方法包括:
    所述处理器从接收到的第一数据流中获取第一组FEC报文,所述第一组FEC报文中所有FEC报文具有相同的FEC报文头,所述FEC报文头中包括FEC编码的原始报文量M;
    当所述第一组FEC报文中原始报文的个数小于所述原始报文量M时,所述处理器根据所述第一组FEC报文,生成第一解码任务,所述第一解码任务用于指示对所述第一组FEC报文进行解码;
    所述目标硬件引擎根据所述第一解码任务,对所述第一组FEC报文中的原始报文以及所述原始报文的冗余报文进行FEC解码,得到所述第一组FEC报文中丢失的原始报文。
  8. 根据权利要求7所述的方法,其特征在于,所述处理器根据所述第一组FEC报文,生成第一解码任务之后,所述方法还包括:
    所述处理器将所述第一解码任务存储在第二目标发送队列,所述第二目标发送队列用于存储所述网络设备的待处理数据流的解码任务,所述网络设备的待处理数据流包括所述第一数据流;
    所述目标硬件引擎从所述第二目标发送队列中读取所述第一解码任务。
  9. 根据权利要求8所述的方法,其特征在于,所述处理器将所述第一解码任务存储在第二目标发送队列包括:
    根据所述第一数据流的优先级,所述处理器将所述第一解码任务添加在所述第二目标发送队列中,所述第二目标发送队列的优先级与所述第一数据流的优先级相等。
  10. 根据权利要求8所述的方法,其特征在于,所述目标硬件引擎从所述第二目标发送队列中读取所述第一解码任务包括:
    所述目标硬件引擎根据各个发送队列的优先级的高低,依次查询所述各个发送队列中是否有解码任务,所述各个发送队列中的每一个队列对应一个优先级;
    在所述各个发送队列中,当比所述第二目标发送队列的优先级高的队列内没有其他解码任务时,所述目标硬件引擎从所述第二目标发送队列中读取所述第一解码任务。
  11. 一种报文处理装置,其特征在于,所述装置包括:
    处理器,用于根据待处理的第一数据流中的M个原始报文,生成第一编码任务,M为正整数,所述第一编码任务用于指示对所述M个原始报文进行编码;
    目标硬件引擎,用于根据所述第一编码任务,对所述M个原始报文进行前向纠错FEC编码,得到R个冗余报文,R为正整数。
  12. 根据权利要求11所述的装置,其特征在于,所述处理器,还用于将所述第一编码任务存储在第一目标发送队列,所述第一目标发送队列用于存储所述装置的待处理数据流的编码任务,所述装置的待处理数据流包括所述第一数据流;
    所述目标硬件引擎,还用于从所述第一目标发送队列中读取所述第一编码任务。
  13. 根据权利要求12所述的装置,其特征在于,所述处理器,用于根据所述第一数据流的优先级,将所述第一编码任务添加在所述第一目标发送队列中,所述第一目标发送队列的优先级与所述第一数据流的优先级相等。
  14. 根据权利要求13所述的装置,其特征在于,所述目标硬件引擎用于:
    所述目标硬件引擎根据各个发送队列的优先级的高低顺序,依次查询所述各个发送队列中是否有编码任务,所述各个发送队列中的每一个队列对应一个优先级;
    在所述各个发送队列中,当比所述第一目标发送队列的优先级高的队列内没有编码任务时,从所述第一目标发送队列中读取所述第一编码任务。
  15. 一种报文处理装置,其特征在于,所述装置包括处理器和目标硬件引擎;
    所述处理器,用于从接收到的第一数据流中获取第一组FEC报文,所述第一组FEC报文中所有FEC报文均有相同的FEC报文头,所述FEC报文头中包括FEC编码的原始报文量M;
    当所述第一组FEC报文中原始报文的个数小于所述原始报文量M时,根据所述第一组FEC报文,生成第一解码任务,所述第一解码任务用于指示对所述第一组FEC报文进行解码;
    所述目标硬件引擎,用于根据所述第一解码任务,对所述第一组FEC报文中的原始报文以及所述原始报文的冗余报文进行FEC解码,得到所述第一组FEC报文中丢失的原始报文。
  16. 根据权利要求15所述的装置,其特征在于,所述处理器,还用于将所述第一解码任务存储在第二目标发送队列,所述第二目标发送队列用于存储所述装置的待处理数据流的解码任务,所述装置的待处理数据流包括所述第一数据流;
    所述目标硬件引擎,还用于从所述第二目标发送队列中读取所述第一解码任务。
  17. 根据权利要求16所述的装置,其特征在于,所述处理器,用于根据所述第一数据流的优先级,所述处理器将所述第一解码任务添加在所述第二目标发送队列中,所述第二目标发送队列的优先级与所述第一数据流的优先级相等。
  18. 根据权利要求16所述的装置,其特征在于,所述目标硬件引擎用于:
    根据各个发送队列的优先级的高低,依次查询所述各个发送队列中是否有解码任务,所述各个发送队列中的每一个队列对应一个优先级;
    在所述各个发送队列中,当比所述第二目标发送队列的优先级高的队列内没有其他解码任务时,从所述第二目标发送队列中读取所述第一解码任。
  19. 一种芯片,其特征在于,包括处理器和目标硬件引擎,所述处理器用于实现如权利要求1-6任一所述的方法中的处理器,所述目标硬件引擎用于实现如权利要求1-6任一所述的方法中的目标硬件引擎。
  20. 一种芯片,其特征在于,包括处理器和目标硬件引擎,所述处理器用于实现如权利 要求7-10任一所述的方法中的处理器,所述目标硬件引擎用于实现如权利要求7-10任一所述的方法中的目标硬件引擎。
PCT/CN2020/114586 2019-09-10 2020-09-10 报文处理方法、装置以及芯片 WO2021047606A1 (zh)

Priority Applications (6)

Application Number Priority Date Filing Date Title
JP2022513649A JP2022546102A (ja) 2019-09-10 2020-09-10 パケット処理方法および装置、ならびにチップ
MX2022002813A MX2022002813A (es) 2019-09-10 2020-09-10 Metodo y aparato de procesamiento de paquetes y chip.
EP20862858.6A EP3996302B1 (en) 2019-09-10 2020-09-10 Message processing method and apparatus, and chip
KR1020227005436A KR20220033055A (ko) 2019-09-10 2020-09-10 패킷 처리 방법 및 장치 그리고 칩
US17/684,729 US11695502B2 (en) 2019-09-10 2022-03-02 Packet processing method and apparatus, and chip
US18/320,860 US20230299878A1 (en) 2019-09-10 2023-05-19 Packet Processing Method and Apparatus, and Chip

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN201910854367.2 2019-09-10
CN201910854367 2019-09-10
CN201911205835.X 2019-11-29
CN201911205835.XA CN112564855A (zh) 2019-09-10 2019-11-29 报文处理方法、装置以及芯片

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/684,729 Continuation US11695502B2 (en) 2019-09-10 2022-03-02 Packet processing method and apparatus, and chip

Publications (1)

Publication Number Publication Date
WO2021047606A1 true WO2021047606A1 (zh) 2021-03-18

Family

ID=74866580

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/114586 WO2021047606A1 (zh) 2019-09-10 2020-09-10 报文处理方法、装置以及芯片

Country Status (6)

Country Link
US (2) US11695502B2 (zh)
EP (1) EP3996302B1 (zh)
JP (1) JP2022546102A (zh)
KR (1) KR20220033055A (zh)
MX (1) MX2022002813A (zh)
WO (1) WO2021047606A1 (zh)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2010124651A1 (zh) * 2009-04-30 2010-11-04 华为技术有限公司 前向纠错方法、装置和***
CN102356585A (zh) * 2011-08-19 2012-02-15 华为技术有限公司 一种光传输模块和光信号传输装置
CN102595252A (zh) * 2011-01-11 2012-07-18 中兴通讯股份有限公司 流媒体前向纠错实现方法及***
CN103533453A (zh) * 2013-10-28 2014-01-22 苏州新海宜通信科技股份有限公司 一种抗丢包的传输方法
CN105933342A (zh) * 2016-06-24 2016-09-07 浙江宇视科技有限公司 一种视频监控数据的传输方法及装置

Family Cites Families (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5844897A (en) * 1994-09-16 1998-12-01 Sony Corporation Data transmission apparatus and data transmission method
US6317462B1 (en) * 1998-10-22 2001-11-13 Lucent Technologies Inc. Method and apparatus for transmitting MPEG video over the internet
JP3438651B2 (ja) * 1999-05-31 2003-08-18 日本電気株式会社 パケット多重装置
US6748441B1 (en) * 1999-12-02 2004-06-08 Microsoft Corporation Data carousel receiving and caching
US7178089B1 (en) * 2000-08-23 2007-02-13 Telefonaktiebolaget Lm Ericsson (Publ) Two stage date packet processing scheme
AU2003901931A0 (en) * 2003-04-23 2003-05-15 Thiss Pty Ltd Radio network assignment and access system
US7328393B2 (en) * 2004-04-13 2008-02-05 Cisco Technology, Inc. Forward error correction in packet networks
WO2007132016A1 (en) * 2006-05-16 2007-11-22 Interuniversitair Microelektronica Centrum (Imec) Digital receiver for software-defined radio implementation
JP2008028767A (ja) * 2006-07-21 2008-02-07 Sumitomo Electric Networks Inc ネットワークカードおよび情報処理装置
WO2009087774A1 (ja) * 2008-01-10 2009-07-16 Sumitomo Electric Networks, Inc. ネットワークカードおよび情報処理装置
JP5353278B2 (ja) * 2009-02-06 2013-11-27 富士通株式会社 通信装置
US9237105B2 (en) * 2009-12-08 2016-01-12 Microsoft Technology Licensing, Llc Data communication with compensation for packet loss
US8839078B2 (en) * 2010-03-05 2014-09-16 Samsung Electronics Co., Ltd. Application layer FEC framework for WiGig
US9009567B2 (en) * 2011-12-12 2015-04-14 Cleversafe, Inc. Encrypting distributed computing data
JP6070712B2 (ja) * 2012-10-01 2017-02-01 富士通株式会社 情報処理装置及び性能解析データの収集方法
JP6188093B2 (ja) * 2012-12-26 2017-08-30 リアルテック シンガポール プライベート リミテッド 通信トラフィック処理アーキテクチャおよび方法
US10320520B2 (en) * 2013-11-15 2019-06-11 Hitachi, Ltd. Communication device, system and method
US9755901B2 (en) * 2014-01-21 2017-09-05 Huawei Technologies Co., Ltd. System and method for a software defined protocol network node
JP6229543B2 (ja) 2014-02-28 2017-11-15 株式会社三洋物産 遊技機
US9417945B2 (en) * 2014-03-05 2016-08-16 International Business Machines Corporation Error checking and correction for NAND flash devices
WO2015162734A1 (ja) * 2014-04-23 2015-10-29 三菱電機株式会社 中継装置およびデータ転送方法

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2010124651A1 (zh) * 2009-04-30 2010-11-04 华为技术有限公司 前向纠错方法、装置和***
CN102595252A (zh) * 2011-01-11 2012-07-18 中兴通讯股份有限公司 流媒体前向纠错实现方法及***
CN102356585A (zh) * 2011-08-19 2012-02-15 华为技术有限公司 一种光传输模块和光信号传输装置
CN103533453A (zh) * 2013-10-28 2014-01-22 苏州新海宜通信科技股份有限公司 一种抗丢包的传输方法
CN105933342A (zh) * 2016-06-24 2016-09-07 浙江宇视科技有限公司 一种视频监控数据的传输方法及装置

Also Published As

Publication number Publication date
US20220190956A1 (en) 2022-06-16
US20230299878A1 (en) 2023-09-21
EP3996302A4 (en) 2022-09-07
EP3996302A1 (en) 2022-05-11
MX2022002813A (es) 2022-04-06
KR20220033055A (ko) 2022-03-15
JP2022546102A (ja) 2022-11-02
EP3996302B1 (en) 2024-03-20
US11695502B2 (en) 2023-07-04

Similar Documents

Publication Publication Date Title
WO2017161999A1 (zh) 一种报文处理的方法及相关设备
WO2013102179A1 (en) High capacity network communication link using multiple cellular devices
WO2018121742A1 (zh) 一种流数据的传输方法和装置
EP1505508B1 (en) Distributed data recording and retrieval
US8195821B2 (en) Autonomous information processing apparatus and method in a network of information processing apparatuses
KR20130140117A (ko) 방송 시스템에서 멀티미디어 데이터의 전송 장치 및 방법
WO2015135120A1 (zh) 端到端的网络QoS控制***、通信设备和端到端的网络QoS控制方法
JP2015520990A (ja) 放送及び通信システムにおけるパケット送受信装置及び方法
CN113079074A (zh) 一种基于can总线的协议栈通信方法、装置和存储介质
CN115037416A (zh) 数据前向纠错处理方法、装置、电子设备和存储介质
CN111385055B (zh) 一种数据传输方法和装置
WO2021047606A1 (zh) 报文处理方法、装置以及芯片
WO2009087774A1 (ja) ネットワークカードおよび情報処理装置
CN112564855A (zh) 报文处理方法、装置以及芯片
CN109558442B (zh) 一种数据实时汇聚方法及***
CN114513418B (zh) 一种数据处理方法及相关设备
CN116389455A (zh) 一种文件传输方法、***及电子设备
WO2020220986A1 (zh) 一种报文处理方法、装置及设备
WO2021047612A1 (zh) 报文处理方法、装置以及计算机存储介质
WO2012116564A1 (zh) 编码包转发方法、编码包接收处理方法和转发节点
CN112564856A (zh) 报文处理方法、装置以及计算机可读存储介质
WO2012103722A1 (zh) Rtp媒体数据的接收、发送方法及装置、处理***
JP2008028767A (ja) ネットワークカードおよび情報処理装置
CN111064673A (zh) 一种用户面数据完整性保护方法、装置、电子设备及介质
Chhangte et al. Index coding at the WiFi edge: An implementation study for video delivery

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20862858

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2020862858

Country of ref document: EP

Effective date: 20220204

ENP Entry into the national phase

Ref document number: 20227005436

Country of ref document: KR

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2022513649

Country of ref document: JP

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE