Forward error correction mode notification method, device, equipment, system and storage medium

By using optical modules to transmit notification messages in optical interface connection scenarios, the FEC mode announcement is realized, solving the problem of FEC mode selection in the prior art, and improving the flexibility and applicability of the system.

CN120034289APending Publication Date: 2025-05-23HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311562986.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-11-21
Publication Date
2025-05-23

AI Technical Summary

Technical Problem

In the case where the prior art supports multiple forward error correction (FEC) modes, it is difficult to realize the notification of the FEC mode in the optical interface connection scenario, and the auto-negotiation method is only applicable to electrical interface connections, and the applicable scenarios are relatively limited.

Method used

By generating an announcement message on the transmitting terminal, the optical module transmits the announcement message to the receiver, and implementing the FEC mode announcement. The method includes monitoring link quality, generating an advertisement message based on configuration information or application conditions, and acknowledging or denying the application of the FEC mode through a response message.

Benefits of technology

In the scenario including optical module, the FEC mode announcement is implemented, which solves the problem of FEC mode selection under optical interface connection and improves the flexibility and applicability of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120034289A_ABST
    Figure CN120034289A_ABST
Patent Text Reader

Abstract

The invention discloses a forward error correction mode notification method, device, equipment and system and a storage medium, and relates to the technical field of communication. The method is applied to a first control module included in a first device, the first device further comprises a first optical module, the first optical module is connected with the first control module and a second device, and the method comprises the steps that the first control module generates a first notification message, and the first notification message is obtained based on a first AM; the first control module sends a first announcement message to the second device via the first optical module, and announces the second device to apply the first FEC mode by the first announcement message. In the method, by sending a first notification message, a first control module connected with a first optical module can notify a second device of applying a first FEC mode, so that notification of applying the FEC mode can be realized in a scene including the optical module.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communication technology, and in particular to a forward error correction mode notification method, device, equipment, system and storage medium. Background Art

[0002] With the continuous development of communication technology, forward error correction (FEC) has gradually become a more commonly used data protection method in the data transmission process. The transmitter (transmitter, Tx) performs FEC encoding on the data to be transmitted at least once to obtain the encoding result, and transmits the encoding result to the receiver (receiver, Rx). After receiving the encoding result, the receiver performs FEC decoding and error correction on the encoding result at least once to restore the data to be transmitted.

[0003] When FEC encoding is applied once during data transmission, it is called end-to-end FEC mode. When FEC encoding is applied multiple times during data transmission, if the process of performing multiple FEC encodings includes FEC decoding operations, it is called segmented FEC mode; if the process of performing multiple FEC encodings does not include FEC decoding operations, it is called cascaded FEC mode. Therefore, a FEC mode notification method is needed to determine the applied FEC mode when the sender and receiver support multiple FEC modes.

[0004] In the related art, if the transmitting end and the receiving end are connected by an electrical interface, and the transmitting end and the receiving end support multiple FEC modes, the transmitting end and the receiving end use auto-negotiation (AN) to select the FEC mode to be used among the multiple FEC modes, thereby completing the mode notification. However, AN is a negotiation method applied between electrical interfaces, which makes the related art only applicable to the scenario of electrical interface connection, and the applicable scenario is relatively limited. Summary of the invention

[0005] The present application proposes a forward error correction mode notification method, device, equipment, system and storage medium for implementing FEC mode notification.

[0006] In the first aspect, a forward error correction mode notification method is provided, the method is applied to a first control module included in a first device, the first device also includes a first optical module, the first optical module is connected to the first control module and the second device respectively, the method includes: the first control module generates a first notification message, the first notification message is obtained based on a first alignment marker (AM); the first control module sends the first notification message to the second device via the first optical module, and notifies the second device of the application of the first FEC mode through the first notification message. In the method, by sending the first notification message to the second device, the first control module connected to the first optical module can notify the second device of the application of the first FEC mode, so that the notification of the application of the FEC mode can be realized in the scene including the optical module.

[0007] In some embodiments, the first control module generates the first notification message, including: the first control module monitors the quality of the first link between the first device and the second device; based on the first link quality meeting the first application condition, the first control module generates the first notification message. That is, the first control module can actively monitor the quality of the first link, and thus generate the first notification message when the first link quality meets the first application condition.

[0008] In some embodiments, the first link quality includes at least one of a bit error rate or a frame loss rate. Therefore, the types of the first link quality are relatively rich, and the first control module can obtain the first link quality by monitoring different indicators.

[0009] In some embodiments, the first control module generates a first notification message, including: the first control module obtains configuration information, the configuration information is used to indicate the application of the first FEC mode; based on the configuration information, the first control module generates the first notification message. That is, the first control module can generate the first notification message based on the obtained configuration information, and the conditions for the first control module to generate the first notification message are relatively flexible.

[0010] In some embodiments, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module receives a first response message, the first response message is obtained based on the second AM, the first response message is sent by the second device after receiving the first notification message, and the first response message is used to confirm the application of the first FEC mode; based on the first response message, the first control module determines to apply the first FEC mode. By determining to apply the first FEC mode when the first response message is received, the method can ensure that the first device and the second device apply the same FEC mode.

[0011] In some embodiments, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module receives a second response message, the second response message is obtained based on the third AM, the second response message is sent by the second device after receiving the first notification message, and the second response message is used to refuse to apply the first FEC mode; based on the second response message, the first control module determines not to apply the first FEC mode. By determining not to apply the first FEC mode when receiving the second response message, the method can maintain the FEC mode applied by the first device and the second device unchanged. Therefore, when the first device and the second device initially apply the same FEC mode, the method can ensure that the first device and the second device apply the same FEC mode.

[0012] In some embodiments, the method further includes: the first control module receives a second notification message sent by the second device, the second notification message is obtained based on the first AM, and the second notification message is used to notify the application of the first FEC mode; based on the second notification message, the first control module determines to apply the first FEC mode. In other words, the second device can also actively send a second notification message to the first device to apply the first FEC mode, and is not limited to the second device being only a response device to the first notification message. In the case where the first control module receives the second notification message, the first control module determines to apply the first FEC mode, and the way in which the first control module determines to apply the first FEC mode is relatively flexible.

[0013] In some embodiments, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module monitors the second link quality between the first device and the second device; based on the second link quality meeting the second application condition, the first control module generates a third notification message, the third notification message is obtained based on the fourth AM, the first control module sends the third notification message to the second device via the first optical module, and notifies the second device of the application of other FEC modes except the first FEC mode through the third notification message. By monitoring the second link quality and determining whether the second link quality meets the second application condition, the first control module can flexibly adjust the FEC mode to be applied, thereby making the applied FEC mode adapt to the link condition between the first device and the second device.

[0014] In some embodiments, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module receives a fourth notification message sent by the second device, the fourth notification message is obtained based on the fourth AM, and the fourth notification message is used to notify the application of other FEC modes other than the first FEC mode; in the case of determining to apply other FEC modes other than the first FEC mode based on the fourth notification message, applying the other FEC modes other than the first FEC mode. That is, the first device including the first control module can determine whether to switch to other FEC modes other than the first FEC mode based on the received fourth notification message, and the way in which the first device determines the FEC mode that needs to be switched is more flexible.

[0015] In some embodiments, applying the first FEC mode includes applying the first FEC mode in a first receiving direction, or applying the first FEC mode in a first sending direction and a first receiving direction, wherein the first receiving direction is a direction in which the first device receives data from the second device, and the first sending direction is a direction in which the first device sends data to the second device. Therefore, the method is more flexible in applying the first FEC mode.

[0016] In some embodiments, the first optical module includes an optical digital signal processor (oDSP) chip, and the method further includes: the first control module sends a first switch instruction to the oDSP chip, and the first switch instruction is used to instruct the oDSP chip to adjust the FEC encoding function to implement the first FEC mode. That is, the method can be applied to the case where the first optical module has FEC encoding capability.

[0017] In some embodiments, the first optical module includes a linear-driver pluggable optics (LPO), and the method further includes: the first control module regulates the FEC encoding function to implement the first FEC mode. That is, the method can be applied to the case where the first optical module does not have FEC encoding capability. Since the first optical module may have FEC encoding capability or may not have FEC encoding capability, the method is applicable to a wide range of scenarios.

[0018] In some embodiments, the first AM is also used to identify a physical coding sublayer (PCS) channel. Thus, the first AM can be compatible with the AM function specified in the Institute of Electrical and Electronics Engineers (IEEE) 802.3 standard. In the case where the first notification message includes the first AM and the first AM is used to notify the application of the first FEC mode, there is no need to introduce overhead other than the first AM to notify the application of the FEC mode. The overhead of notifying the application of the FEC mode is low, and there is no need to include information on the application of the FEC mode by deleting certain information, thereby avoiding information loss.

[0019] In some embodiments, the method further includes: the first optical module acquires a transmission rate corresponding to the first FEC mode; the first control module transmits a signal to the second device via the first optical module according to the transmission rate. By transmitting the signal according to the transmission rate corresponding to the first FEC mode, the transmission rate can be adapted to the first FEC mode.

[0020] In some embodiments, the first control module sends the first notification message to the second device via the first optical module, including: the first control module sends multiple first notification messages to the second device via the first optical module. The number of first notification messages sent by the first control module is relatively flexible. In the case of sending multiple first notification messages, the probability of the second device receiving the first notification message is higher, so that the reliability of transmitting the first notification message is higher.

[0021] In some embodiments, the first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, where n is an integer not less than 0, and the number of first response messages is at least one. The number and sending timing of the first response messages are relatively flexible. In the case where the number of first response messages is multiple, the probability that the first device receives the first response message is high, so that the reliability of transmitting the first response message is high.

[0022] In some embodiments, the method further includes: based on receiving m first response messages, adjusting the FEC encoding function to apply the first FEC mode, where m is a positive integer and is less than or equal to the number of first response messages. Since m is a positive integer and is less than or equal to the number of first response messages, the timing of applying the first FEC mode is more flexible.

[0023] In some embodiments, the first notification message includes an FEC mode domain field, the FEC mode domain field is determined based on the first AM, the FEC mode domain field includes a request field, and the value of the request field is used to request the application of the first FEC mode. Therefore, the first notification message can realize the function of requesting the application of the first FEC mode. Exemplarily, the FEC mode domain field is determined based on the unique pad (UP) field of the first AM, or the FEC mode domain field is determined based on the padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on the recovery field located after the AM group, wherein the multiple AMs and the AM group include the first AM. Therefore, the situation of the FEC mode domain field is more flexible.

[0024] In some embodiments, the first response message includes an FEC mode domain field, the FEC mode domain field is determined based on the second AM, the FEC mode domain field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode. Therefore, the first response message can realize the function of confirming the application of the first FEC mode. Exemplarily, the FEC mode domain field is determined based on the UP field of the second AM, or the FEC mode domain field is determined based on the padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on the recovery field located after the AM group, wherein the multiple AMs and the AM group include the second AM. Therefore, the situation of the FEC mode domain field is more flexible.

[0025] In some embodiments, the first control module includes a physical layer (PHY) chip, so that the first control module has a FEC encoding and decoding function, and the first device can apply the FEC mode.

[0026] In the second aspect, another forward error correction mode notification method is provided, which is applied to a second control module included in a second device, the second device also includes a second optical module, and the second optical module is connected to the second control module and the first device respectively, and the method includes: the second control module receives a first notification message from the first device via the second optical module, the first notification message is obtained based on the first AM, and the first notification message is used to notify the application of the first FEC mode; in the case of determining to apply the first FEC mode based on the first notification message, the first FEC mode is applied. In this method, based on the first notification message sent by the first device, the second control module connected to the second optical module can be notified by the first device to apply the first FEC mode, so that the notification of applying the FEC mode can be implemented in the scene including the optical module.

[0027] In some embodiments, in the case where the first FEC mode is determined to be applied based on the first notification message, before the first FEC mode is applied, the method further includes: the second control module monitors the first link quality between the second device and the first device; based on receiving the first notification message and the first link quality meeting the first application condition, the second control module determines to apply the first FEC mode. In other words, the second control module can also monitor the first link quality, so as to determine to apply the first FEC mode in the case where the first notification message is received and the first link quality meets the first application condition.

[0028] In some embodiments, the first link quality includes at least one of a bit error rate and a frame loss rate, so that the types of the first link quality are relatively rich, and the second control module can obtain the first link quality by monitoring different indicators.

[0029] In some embodiments, the method further includes: when the first link quality meets the first application condition, the second control module generates a second notification message, the second notification message is obtained based on the first AM; the second control module sends the second notification message to the first device via the second optical module, and notifies the first device of the application of the first FEC mode through the second notification message. In other words, the second device can also actively send the second notification message of applying the first FEC mode to the first device, and is not limited to the second device being only a response device to the first notification message.

[0030] In some embodiments, the method further includes: when it is determined that the first FEC mode is applied, the second control module sends a first response message to the first device via the second optical module, the first response message is obtained based on the second AM, and the first response message is used to confirm the application of the first FEC mode. By sending the first response message, the first device can determine to apply the first FEC mode when receiving the first response message, thereby ensuring that the first device and the second device can apply the same FEC mode.

[0031] In some embodiments, the method further includes: in the case of determining that the first FEC mode is not to be applied, the second control module sends a second response message to the first device via the second optical module, the second response message is obtained based on the third AM, and the second response message is used to refuse to apply the first FEC mode. By sending the second response message, the first device can determine that the first FEC mode is not to be applied when receiving the second response message, so that the FEC modes applied by the first device and the second device can be maintained unchanged. In the case where the first device and the second device initially apply the same FEC mode, the method can ensure that the first device and the second device apply the same FEC mode.

[0032] In some embodiments, after applying the first FEC mode, the method further includes: the second control module receives a third notification message sent by the first device, the third notification message is obtained based on the fourth AM, and the third notification message is used to notify the application of other FEC modes other than the first FEC mode; in the case of determining to apply other FEC modes other than the first FEC mode based on the third notification message, applying the other FEC modes other than the first FEC mode. That is, the second device including the second control module can determine whether to switch to other FEC modes other than the first FEC mode based on the received third notification message, and the second device determines the FEC mode that needs to be switched to be applied in a more flexible manner.

[0033] In some embodiments, after applying the first FEC mode, the method further includes: a second control module monitors the second link quality between the second device and the first device; based on the second link quality meeting the second application condition, the second control module generates a fourth notification message, the fourth notification message is obtained based on the fourth AM, the second control module sends the fourth notification message to the first device via the second optical module, and notifies the first device of the application of other FEC modes except the first FEC mode through the fourth notification message. By monitoring the second link quality and determining whether the second link quality meets the second application condition, the second control module can flexibly adjust the FEC mode to be applied, thereby making the applied FEC mode adapt to the link situation between the first device and the second device.

[0034] In some embodiments, applying the first FEC mode includes applying the first FEC mode in the second sending direction, or applying the first FEC mode in both the second sending direction and the second receiving direction, wherein the second sending direction is the direction in which the second device sends data to the first device, and the second receiving direction is the direction in which the second device receives data from the first device. Therefore, the manner of applying the first FEC mode is relatively flexible.

[0035] In some embodiments, the second optical module includes an oDSP chip, and the first FEC mode is applied, including: the second control module sends a second switch instruction to the oDSP chip, and the second switch instruction is used to instruct the oDSP chip to adjust the FEC decoding function to implement the first FEC mode. That is, the method can be applied to the case where the second optical module has FEC encoding capability.

[0036] In some embodiments, the second optical module includes LPO, and the first FEC mode is applied, including: the second control module regulates the FEC decoding function to implement the first FEC mode. That is, the method can be applied to the case where the second optical module does not have FEC encoding capability. Since the second optical module may have FEC encoding capability or may not have FEC encoding capability, the method has a wide range of applicable scenarios.

[0037] In some embodiments, the first AM is also used to identify the PCS channel. Therefore, the first AM can be compatible with the AM function specified in the IEEE 802.3 standard. In the case where the first notification message includes the first AM and the first AM is used to notify the application of the first FEC mode, there is no need to introduce overhead other than the first AM to notify the application of the FEC mode. The overhead of notifying the application of the FEC mode is low, and there is no need to include information for notifying the application of the FEC mode by deleting certain information, thereby avoiding information loss.

[0038] In some embodiments, the method further includes: the second optical module acquires the transmission rate corresponding to the first FEC mode; the second control module receives a signal from the first device via the second optical module according to the transmission rate. By receiving the signal according to the transmission rate corresponding to the first FEC mode, the transmission rate can be adapted to the first FEC mode.

[0039] In some embodiments, the second control module receives the first notification message from the first device via the second optical module, including: the second control module receives multiple first notification messages from the first device via the second optical module. The number of first notification messages is relatively flexible, and further, when the number of first notification messages is multiple, the probability of the second device receiving the first notification message is higher, so that the reliability of transmitting the first notification message is higher.

[0040] In some embodiments, the first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, where n is an integer not less than 0, and the number of first response messages is at least one. The number and sending timing of the first response messages are relatively flexible. In the case where the number of first response messages is multiple, the probability that the first device receives the first response message is high, so that the reliability of transmitting the first response message is high.

[0041] In some embodiments, the first notification message includes an FEC mode domain field, the FEC mode domain field is determined based on the first AM, the FEC mode domain field includes a request field, and the value of the request field is used to request the application of the first FEC mode. Therefore, the first notification message can realize the function of requesting the application of the first FEC mode. Exemplarily, the FEC mode domain field is determined based on the UP field of the first AM, or the FEC mode domain field is determined based on the padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on the recovery field located after the AM group, and the multiple AMs and the AM group include the first AM. Thus, the situation of the FEC mode domain field is more flexible.

[0042] In some embodiments, the first response message includes an FEC mode domain field, the FEC mode domain field is determined based on the second AM, the FEC mode domain field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode. Therefore, the first response message can realize the function of confirming the application of the first FEC mode. Exemplarily, the FEC mode domain field is determined based on the UP field of the second AM, or the FEC mode domain field is determined based on the padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on the recovery field located after the AM group, wherein the multiple AMs and the AM group include the second AM. Therefore, the situation of the FEC mode domain field is more flexible.

[0043] In some embodiments, the second control module includes a PHY chip, so that the second control module has FEC encoding and decoding functions, and the second device can apply the FEC mode.

[0044] In a third aspect, a forward error correction mode notification device is provided, which is applied to a first control module included in a first device, and the first device also includes a first optical module, and the first optical module is connected to the first control module and the second device respectively, and the device includes: a transceiver module, used to perform operations related to receiving and / or sending in the first aspect and any corresponding possible implementation method; a processing module, used to perform other operations besides the operations related to receiving and / or sending in the first aspect and any corresponding possible implementation method.

[0045] In a fourth aspect, a forward error correction mode notification device is provided, which is applied to a second control module included in a second device, and the second device also includes a second optical module, and the second optical module is connected to the second control module and the first device respectively, and the device includes: a transceiver module, used to perform operations related to receiving and / or sending in the second aspect and any corresponding possible implementation method; a processing module, used to perform other operations in addition to the operations related to receiving and / or sending in the second aspect and any corresponding possible implementation method.

[0046] In a fifth aspect, an electronic device is provided, comprising a processor coupled to a memory, wherein the memory stores at least one program instruction or code, and the at least one program instruction or code is loaded and executed by the processor so that the electronic device implements any forward error correction mode notification method in the first aspect or the second aspect.

[0047] In a sixth aspect, a computer-readable storage medium is provided, in which at least one program instruction or code is stored. When the program instruction or code is loaded and executed by a processor of a computer, the computer implements any forward error correction mode notification method in the first aspect or the second aspect.

[0048] In the seventh aspect, a communication system is provided, which includes a first device and a second device, the first device includes a first control module and a first optical module, the second device includes a second control module and a second optical module, the first optical module is connected to the first control module and the second optical module respectively, the second optical module is also connected to the second control module, the first control module is used to execute any forward error correction mode notification method in the first aspect, and the second control module is used to execute any forward error correction mode notification method in the second aspect.

[0049] In an eighth aspect, another communication device is provided, the device comprising: a transceiver, a memory, and a processor. The transceiver, the memory, and the processor communicate with each other through an internal connection path, the memory is used to store instructions, and the processor is used to execute the instructions stored in the memory to control the transceiver to receive signals and control the transceiver to send signals, and when the processor executes the instructions stored in the memory, the processor executes the forward error correction mode notification method of any one of the first aspect or the second aspect.

[0050] Illustratively, there are one or more processors and one or more memories.

[0051] For example, the memory may be integrated with the processor, or the memory may be provided separately from the processor.

[0052] In the specific implementation process, the memory can be a non-transitory memory, such as a read-only memory (ROM), which can be integrated with the processor on the same chip or can be set on different chips. This application does not limit the type of memory and the setting method of the memory and the processor.

[0053] In the ninth aspect, a computer program or a computer program product is provided, wherein the computer program or the computer program product comprises: a computer program code, and when the computer program code is executed by a computer, the computer executes the forward error correction mode notification method of any one of the first aspect or the second aspect.

[0054] In a tenth aspect, a chip is provided, the chip comprising an interface module, and the interface module is used to execute any forward error correction mode notification method in the first aspect or the second aspect.

[0055] In an eleventh aspect, a chip is provided, the chip including a processor, the processor being used to call and run instructions stored in a memory from a memory, so that a communication device equipped with the chip performs any forward error correction mode notification method in the first aspect or the second aspect. Exemplarily, the chip also includes: an input interface, an output interface, and a memory, and the input interface, the output interface, the processor, and the memory are connected through an internal connection path.

[0056] It should be understood that the beneficial effects achieved by the technical solutions of the third to eleventh aspects of the present application and the corresponding possible implementation methods can be referred to the technical effects of the technical solutions of the first to second aspects and their corresponding possible implementation methods, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0057] Figure 1 It is a schematic diagram of a transmitting end applying various FEC modes provided in an embodiment of the present application;

[0058] Figure 2 It is a schematic diagram of an implementation environment provided by an embodiment of the present application;

[0059] Figure 3 It is a schematic diagram of a system architecture provided by an embodiment of the present application;

[0060] Figure 4 is a schematic diagram of another system architecture of an embodiment of the present application;

[0061] Figure 5 It is a structural schematic diagram of a traditional pluggable optical module interface provided in an embodiment of the present application;

[0062] Figure 6 It is a structural schematic diagram of an LPO interface provided in an embodiment of the present application;

[0063] Figure 7 is a flow chart of a forward error correction mode notification method provided by an embodiment of the present application;

[0064] Figure 8 is a schematic diagram of the structure of an AM provided in an embodiment of the present application;

[0065] Fig. 9 It is a schematic diagram of AM mapping to PCS channel provided in an embodiment of the present application;

[0066] Fig.10 It is a structural diagram of an FEC mode domain field provided in an embodiment of the present application;

[0067] Fig.11 It is a structural diagram of another FEC mode domain field provided in an embodiment of the present application;

[0068] Fig.12 is a schematic diagram of the structure of another AM provided in an embodiment of the present application;

[0069] Fig.13 is a schematic diagram of a process of sending a first switch instruction provided by an embodiment of the present application;

[0070] Fig.14is a flowchart of another forward error correction mode notification method provided by an embodiment of the present application;

[0071] Fig.15 This is a schematic diagram of a process of unilaterally initiating unilateral switching provided by an embodiment of the present application;

[0072] Fig.16 This is a schematic diagram of a process of bidirectionally initiating unilateral switching provided by an embodiment of the present application;

[0073] Fig.17 This is a schematic diagram of a process of unidirectionally initiating bilateral switching provided by an embodiment of the present application;

[0074] Fig.18 This is a schematic diagram of a notification switching process provided by an embodiment of the present application;

[0075] Fig.19 It is a structural diagram of a forward error correction mode notification device provided in an embodiment of the present application;

[0076] Fig. 20 It is a structural diagram of another forward error correction mode notification device provided in an embodiment of the present application;

[0077] Fig.21 is a schematic diagram of the structure of a computer system provided in an embodiment of the present application;

[0078] Fig. 22 It is a structural diagram of another computer system provided in an embodiment of the present application. DETAILED DESCRIPTION

[0079] The terms used in the implementation method of this application are only used to explain the embodiments of this application, and are not intended to limit this application. The embodiments of this application are described below in conjunction with the accompanying drawings.

[0080] With the development of communication technology, the transmission rate of channels in Ethernet is constantly improving. Among them, channels can be divided into two categories: optical channels and electrical channels. For example, in the IEEE 802.3dj project, the single-channel transmission rate of optical channels and electrical channels can reach 200 gigabits per second (Gb / s). Among them, 200Gb / s can also be called 200G, and a channel with a transmission rate of 200Gb / s can be called a 200G channel. The optical channel is implemented based on a physical architecture including an optical module. However, due to the limitations of link performance, optical module specifications, packaging methods, serializer / deserializer (serdes) performance and power consumption, the optical module has certain performance risks. If the performance risk is reduced by improving the specifications of the optical module, the cost of the optical module will increase. The specifications of the optical module include but are not limited to the transmission distance supported by the optical module and the transmitter dispersion eye closure quaternary (TDECQ) index. Exemplarily, the optical module is located in the optical Ethernet interface, and the types of optical Ethernet interfaces supporting 200G channels are as follows: 200G baseband (BASE)-DR1, 200GBASE-DR1-2, 400GBASE-DR4, 400GBASE-DR4-2, 800GBASE-DR4, 800GBASE-DR4-2, 1.6 terabit (T) BASE-DR8, 1.6TBASE-DR8-2. The above optical Ethernet interfaces are all Ethernet interface types defined by the IEEE 802.3 standard.

[0081] In the physical architecture including the optical module, FEC can be used to encode the data to be transmitted to achieve data protection. Different FEC modes can provide different data protection capabilities. Therefore, while reducing the requirements for the optical module specifications, the accurate transmission of data can be guaranteed by using an FEC mode with higher protection capabilities. Figure 1 Schematic diagram of a transmitter applying various FEC modes provided in an embodiment of the present application. Figure 1As shown, the architecture of the transmitting end application includes a media access control (MAC) layer or a reconciliation sublayer (RS), a physical coding sublayer (PCS), a physical medium attachment (PMA) sublayer, a physical medium dependent (PMD) sublayer and a transmission medium (medium). Among them, the number of PMA sublayers can be multiple, and multiple PMA sublayers are connected through an attachment unit interface (AUI), and the PMD sublayer is connected to the transmission medium through a medium dependent interface (MDI). In addition, when the PCS at the transmitting end performs both FEC encoding and FEC decoding, the PCS can also be expressed as XS.

[0082] See also Figure 1 , Figure 1 (1) in FIG. 1 shows a transmitter architecture without applying the FEC mode, and the transmission rate of the architecture can be 800 Gbps or 1.6 terabit per second (Tb / s). Figure 1 (2) in FIG. 1 shows the application of the end-to-end FEC mode, such as Figure 1 As shown in (2), FEC coding is applied once in PCS. Figure 1 The PCS shown in (2) is represented by PCS1, and the FEC code type used for FEC encoding is represented by FEC1. Figure 1 (3) in FIG. 1 shows the segmented FEC mode, such as Figure 1 As shown in (3), the first FEC encoding and the first FEC decoding are performed at XS2, and the FEC code type used in the first FEC encoding and the first FEC decoding is represented by FEC2. Then, the second FEC encoding is performed at PCS3, and the FEC code type used in the second FEC encoding is represented by FEC3. XS2 and PCS3 both correspond to PCS. Figure 1 (4) in FIG. 4 shows the cascaded FEC mode, such as Figure 1 As shown in (4), the first FEC encoding is performed in PCS4, and the second FEC encoding is performed in the FEC layer. The FEC code type used in the first FEC encoding is represented by FEC4, and the FEC code type used in the second FEC encoding is represented by FEC5. The FEC layer may be PCS. Figure 1 The FEC code type in is limited.

[0083] Exemplarily, the FEC mode used for data transmission is adapted to the application type, link quality, and device capabilities. For example, for applications that are sensitive to latency and power consumption, and systems with good link quality and device capabilities, an end-to-end FEC mode is used. Taking the latency-sensitive short-distance artificial intelligence (AI) or high-performance computing (HPC) optical interconnection scenario as an example, when the device capabilities and link quality meet the requirements, an end-to-end FEC mode is used to provide low-latency Ethernet interconnection. For another example, for applications that are not sensitive to latency and power consumption, and systems with poor link quality and device capabilities, a cascade FEC mode is used to ensure the accuracy of end-to-end data transmission. In the case where the sender and receiver of data transmission support multiple FEC modes, a FEC mode notification method is required so that the sender and receiver determine the FEC mode of the application.

[0084] In a related technology, multiple optical modules are used to support multiple FEC modes, wherein one optical module supports one FEC mode, and the FEC mode to be used is determined by using different optical modules. However, the solution of the related technology requires the provision of multiple optical modules, which is costly. In another related technology, for a transmitter and a receiver connected by an electrical interface, auto-negotiation (AN) is used to determine the FEC mode to be used in a plurality of FEC modes. However, AN is a negotiation method applied between electrical interfaces, which makes the related technology only applicable to scenarios connected by electrical interfaces, and the applicable scenarios are relatively limited.

[0085] The present invention provides a forward error correction mode notification method for implementing FEC mode notification. The method can be applied to Figure 2 The implementation environment shown. Figure 2As shown, the implementation environment includes a first device 201 and a second device 202, and the first device 201 and the second device 202 are connected. Among them, the first device 201 includes a first control module 2011 and a first optical module 2012, and the second device 202 includes a second control module 2021 and a second optical module 2022. The first optical module 2012 is connected to the first control module 2011 and the second optical module 2022 respectively, and the second optical module 2022 is also connected to the second control module 2021. Exemplarily, the first control module 2011 and the second control module 2021 are both application-specific integrated circuit (ASIC) chips, the first control module 2011 and the first optical module 2012 are connected through an electrical interface, the second control module 2021 and the second optical module 2022 are connected through an electrical interface, and the first optical module 2012 and the second optical module 2022 are connected through an optical fiber.

[0086] Figure 3 Schematic diagram of a system architecture provided by an embodiment of the present application. Figure 3 As shown, the first control module and the second control module are located in the MAC layer, PCS and PMA sublayer, and the first control module and the second control module can perform FEC encoding and FEC decoding in the PCS. The first optical module and the second optical module are located in the PMA sublayer, the FEC layer and the PMD sublayer. Among them, the PMA sublayer where the first optical module is located includes a PMA sublayer connected to the first control module through AUI and a PMA sublayer connected to the FEC layer and the PMD sublayer respectively, and the PMA sublayer where the second optical module is located includes: a PMA sublayer connected to the second control module through AUI and a PMA sublayer connected to the FEC layer and the PMD sublayer respectively. Figure 3 As shown, the first control module and the first optical module are connected via AUI, the second control module and the second optical module are connected via AUI, and the first optical module and the second optical module are connected via optical fiber.

[0087] For example, Figure 3As shown, in the case where the first optical module and the second optical module have data encoding and decoding functions, the first optical module and the second optical module can perform FEC encoding and FEC decoding at the FEC layer. In the case where both the first control module and the first optical module perform FEC encoding, and the second control module and the second optical module perform FEC decoding, the first device and the second device apply a cascade FEC mode, wherein the FEC code type applied by the first control module and the second control module is called an outer code, and the FEC code type applied by the first optical module and the second optical module is called an inner code. Exemplarily, the first control module performs FEC encoding twice, and the second control module performs FEC decoding twice, that is, in the case of applying the cascade FEC mode, multiple FEC encodings are implemented by the first control module, and multiple FEC decodings are implemented by the second control module, so that the first optical module and the second optical module may not have data encoding and decoding functions.

[0088] Figure 4 is a schematic diagram of another system architecture provided by an embodiment of the present application. The system architecture can be applied to a data center. Figure 4 As shown, the system architecture includes a server and a spine switch, and the system architecture also includes a top of rack (TOR) switch or a leaf switch, and the server and the spine switch are communicatively connected through the top of rack switch or the leaf switch. Exemplarily, the first device and the second device are located in the switch of the system architecture, and the first device and the second device are both used as Ethernet optical interfaces of the switch, and the single-channel transmission rate supported by the first device and the second device is 200Gb / s. Figure 4 The number of switches and servers shown is for illustration only and is not intended to limit the number of switches and servers.

[0089] In a possible implementation manner, the first device and the second device are used as a traditional pluggable optical module interface. Figure 5 1 is a schematic diagram of a conventional pluggable optical module interface provided in an embodiment of the present application. The conventional pluggable optical module interface is referred to as an optical interface. Figure 5 As shown in (1), the optical interface includes an ASIC and an optical module, the first control module and the second control module may be the ASIC included in the optical interface, and the first optical module and the second optical module may be the optical modules included in the optical interface. Figure 5 As shown, the optical modules are connected by optical fiber, and the length of the optical fiber can be 500 meters or less or 2 kilometers or less. The PCS of the ASIC implements the FEC encoding and decoding function, and the ASIC also includes Serdes. Figure 5As shown in (2), the optical module includes an optical digital signal processor (oDSP) chip. On the transmitting side, the oDSP chip is connected to the Serdes (Serdes Tx) on the transmitting side, and the oDSP chip includes the receiving side (Serdes Rx) of the very short reach (VSR) Serdes, FEC encoding function and long reach (LR) Serdes Tx. The optical module on the transmitting side also includes a driver, a modulator and a laser. Among them, the oDSP chip is connected to the driver, the driver is connected to the modulator, and the modulator is also connected to the laser. The modulator is an electro absorption modulator (EAM) or a modulator based on a Mach-Zehnder interferometer (MZI).

[0090] On the receiving side, the oDSP chip is connected to the Serdes Rx, and the oDSP chip includes LR Serdes Rx, FEC decoding function and VSR Serdes Tx. The optical module on the receiving side also includes a photodiode (PD) and a transimpedance amplifier (TIA). Among them, the PD is connected to the modulator on the transmitting side through an optical fiber, and the PD is also connected to the TIA, and the TIA is connected to the oDSP chip. In the case of jointly implementing cascaded FEC encoding and decoding through ASIC and the oDSP chip in the optical module, the FEC encoding and decoding performed in the ASIC is called outer FEC (outer FEC), and the FEC encoding and decoding performed by the oDSP chip is called inner FEC (inner FEC). Exemplarily, the PCS of the ASIC supports the selection and switching of FEC modes based on alignment markers (AM), and the optical module supports the switch for obtaining signals from the ASIC for FEC encoding and decoding functions.

[0091] Figure 6 1 is a schematic diagram of a linear-driver pluggable optics (LPO) interface provided in an embodiment of the present application. The LPO interface is referred to as an optical interface. Figure 6 As shown in (1), the optical interface includes an ASIC and an optical module, the first control module and the second control module may be the ASIC included in the optical interface, and the first optical module and the second optical module may be the optical modules included in the optical interface. Figure 6In the embodiment, optical modules are connected by optical fiber, and the length of the optical fiber can be 500 meters or less. The PCS of the ASIC implements the cascaded FEC encoding and decoding function, and the ASIC also includes Serdes. The optical module can be any of the near packaged optics (NPO), co-packaged optics (CPO) or linear optical modules.

[0092] In the case where the optical interface is a digital pluggable optical interface, such as Figure 6 As shown in (2), the optical module on the transmitting side includes a driver, a modulator and a laser. The driver is connected to the Serdes Tx and the modulator respectively. The modulator is also connected to the laser. The modulator can be an EAM or an MZI-based modulator. The optical module on the receiving side includes a PD and a TIA. The PD is connected to the modulator on the transmitting side through an optical fiber. The TIA is connected to the PD and the Serdes Rx respectively. In the case where the optical interface is an analog pluggable optical interface, such as Figure 6 As shown in (3), the optical module on the transmitting side includes a modulator and a laser. The modulator is connected to the Serdes Tx and the laser respectively. The modulator can be an EAM or an MZI-based modulator. The optical module on the receiving side includes a PD and a TIA. The PD is connected to the modulator on the transmitting side through an optical fiber. The TIA is connected to the PD and the Serdes Rx respectively.

[0093] For example, in Figure 6 In the optical interface shown, the PCS of the ASIC supports the selection and switching of the FEC mode based on AM, and the ASIC also supports the switch of the cascaded FEC codec function. Figure 5 The optical interface shown is still Figure 6 The optical interface and ASIC shown are capable of transmitting signals at a transmission rate corresponding to the FEC mode. For example, the transmission rate corresponding to the end-to-end FEC mode is 106.25G baud (GBd), and the transmission rate corresponding to the cascade FEC mode is 113.4375GBd.

[0094] The encoding method provided in the embodiment of the present application can be as follows Figure 7 As shown, next, combined with Figure 2 The method is described in the implementation environment shown. The method can be applied to Figure 2 The first control module 2011 shown, that is, the method is applied to the first control module included in the first device, the first device also includes a first optical module, and the first optical module is connected to the first control module and the second device respectively. For example, the first optical module is connected to the first control module and the second optical module in the second device respectively. Figure 7As shown, the method includes but is not limited to S701 and S702.

[0095] S701, a first control module generates a first notification message, where the first notification message is obtained based on a first AM.

[0096] In a possible implementation, the first control module includes a physical layer (PHY) chip. Exemplarily, the first control module generates the first notification message, including but not limited to the following method A and method B.

[0097] In mode A, the first control module monitors the quality of a first link between the first device and the second device; based on the first link quality satisfying a first application condition, the first control module generates a first notification message.

[0098] That is to say, the first control module can actively monitor the quality of the first link and generate a first notification message based on the monitored first link quality. In one possible implementation, the first link quality includes at least one of a bit error rate (BER) or a frame loss rate (FLR). For example, when the first link quality includes BER, the first application condition includes that the BER is higher than a first BER threshold. When the first link quality includes FLR, the first application condition includes that the FLR is higher than a first FLR threshold. Exemplarily, when the BER is higher than the first BER threshold or the FLR is higher than the first FLR threshold, the generated first notification message is used to notify the application of the cascaded FEC mode. Both the first BER threshold and the first FLR threshold can be set according to experience or actual needs, and the embodiments of the present application are not limited to this.

[0099] For another example, when the first link quality includes BER, the first application condition includes that the BER is lower than a second BER threshold, wherein the second BER threshold is less than or equal to the first BER threshold. When the first link quality includes FLR, the first application condition includes that the FLR is lower than a second FLR threshold, wherein the second FLR threshold is less than or equal to the first FLR threshold. Exemplarily, when the BER is lower than the second BER threshold or the FLR is lower than the second FLR threshold, the generated first notification message is used to notify the application of the end-to-end FEC mode. Both the second BER threshold and the second FLR threshold can be set according to experience or actual needs, and the embodiments of the present application are not limited to this.

[0100] For another example, when the first link quality includes BER and the second BER threshold is lower than the first BER threshold, the first application condition includes that the BER is higher than the second BER threshold and lower than the first BER threshold. When the first link quality includes FLR and the second FLR threshold is lower than the first FLR threshold, the first application condition includes that the FLR is higher than the second FLR threshold and lower than the first FLR threshold. Exemplarily, when the BER is higher than the second BER threshold and lower than the first BER threshold or the FLR is higher than the second FLR threshold and lower than the first FLR threshold, the first notification message is used to notify the application of the segmented FEC mode.

[0101] In mode B, the first control module obtains configuration information, where the configuration information is used to indicate application of the first FEC mode; based on the configuration information, the first control module generates a first notification message.

[0102] That is, the first control module generates a first notification message based on the acquired configuration information. For example, the first control module acquires configuration information, including but not limited to: the first control module receives configuration information sent by the control device, or the first control module reads register parameters inside the first control module to obtain configuration information. The control device may be a device connected to the first control module and capable of receiving user input, so that the control device can transmit configuration information to the first control module after receiving the configuration information input by the user. Exemplarily, the configuration information corresponds to the application type. In the case where the application is an AI application or an HPC application, the configuration information indicates a low-latency mode, and in the case where the configuration information indicates a low-latency mode, the first notification message is used to notify the application of an end-to-end FEC mode. In the case of an application other than an AI application and an HPC application, the configuration information indicates a performance mode, and in the case where the configuration information indicates a performance mode, the first notification message is used to notify the application of a cascaded FEC mode.

[0103] Regardless of whether the first notification message is generated in mode A or mode B, the first notification message is obtained based on the first AM. In one possible implementation, the first notification message includes the first AM, and the first AM can be used to notify the second device to apply the first FEC mode. Exemplarily, the first AM is also used to identify the PCS channel. That is to say, on the basis of the AM function specified in the IEEE 802.3 standard, the first AM can also be used to notify the second device to apply the first FEC mode, thereby eliminating the need to introduce overhead other than the first AM to notify the application of the FEC mode. The overhead of notifying the application of the FEC mode is low, and there is no need to include information on the application of the FEC mode by deleting certain information, thereby avoiding information loss.

[0104] Figure 8 Schematic diagram of the structure of an AM provided in an embodiment of the present application. Figure 8As shown, AM includes a common marker (CM) field, a unique marker (UM) field, and a unique pad (UP) field. The CM field includes CM0 to CM5, and CM0 to CM5 are common markers of each virtual channel, that is, the value of the CM field of each virtual channel is the same. The UM field includes UM1 to UM5, and a group of values ​​of UM0 to UM5 uniquely identifies a virtual channel. The UP field includes UP0 to UP2, and the values ​​of UP0 to UP2 are padding data set based on experience or actual needs. The bit positions of CM0 to CM2, UP0, CM3 to CM5, UP1, UM0 to UM2, UP2, and UM3 to UM5 can be as shown. Figure 8 Furthermore, CM3 to CM5 are bit inversions of CM0 to CM2, and UM3 to UM5 are bit inversions of UM0 to UM2.

[0105] In a possible implementation, the first notification message includes an FEC mode domain field, the FEC mode domain field is determined based on the first AM, the FEC mode domain field includes a request field, and the value of the request field is used to request the application of the first FEC mode. Therefore, the second device can determine whether to apply the first FEC mode based on the request field of the first notification message. Exemplarily, the FEC mode domain field is determined based on the UP field of the first AM, or the FEC mode domain field is determined based on the pad field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on the resumption field located after the AM group, wherein the multiple AMs and the AM group include the first AM. That is, if the FEC mode domain field is determined based on the pad field used to form a 257-bit code block with multiple AMs, the first AM can be any one of the multiple AMs; if the FEC mode domain field is determined based on the resumption field located after the AM group, the first AM can be any one of the AMs in the AM group.

[0106] Exemplarily, when the FEC mode domain field is determined based on the UP field of the first AM, at least one of the fields UP0 to UP2 included in the UP field includes the FEC mode domain field. The number of fields in UP0 to UP2 that include the FEC mode domain field can be determined according to the length of the FEC mode domain field. According to the IEEE 802.3 standard, the lengths of UP0 to UP2 are both 8 bits. When the length of the FEC mode domain field is less than or equal to 8 bits, any one of the fields UP0 to UP2 may include the FEC mode domain field, and when the length of the FEC mode domain field is greater than 8 bits, at least two of the fields UP0 to UP2 may include the FEC mode domain field.

[0107] In an embodiment of the present application, the FEC mode domain field can also be determined based on any one of the padding fields used to form a 257-bit code block with multiple AMs or the recovery field located after the AM group. Among them, the AM group includes AMs corresponding to multiple virtual channels in Ethernet, padding fields, and status domain fields. For example, in 200G Ethernet, the AM group includes AMs corresponding to 8 virtual channels, a 65-bit padding field, and a 3-bit status domain field. For another example, in 400G Ethernet, the AM group includes AMs corresponding to 16 virtual channels, a 133-bit padding field, and a 3-bit status domain field. Fig. 9 : is a schematic diagram of an AM mapping to a PCS channel provided in an embodiment of the present application. Fig. 9 Take the PCS channel corresponding to 400G Ethernet as an example. Fig. 9 , the AM corresponding to the i-th PCS channel is represented by AM_i, and the value range of i is 0 to 15. The symbols included in AM_i come from FEC codeword A and FEC codeword B respectively, and each symbol includes 10 bits. For the acquisition method and mapping method of FEC codeword A and FEC codeword B, please refer to the relevant contents of FEC encoding and PCS channel mapping in the IEEE 802.3 standard, which will not be described here. Fig. 9 The content shown also includes a 133-bit padding field, a 3-bit status field, and a 257-bit block recovery field. The 133-bit padding field and the 3-bit status field are used together with the 16 AMs to form 8 257-bit code blocks. Fig. 9 In the embodiment, the AM group includes AM_0 to AM_15, a 133-bit padding field and a 3-bit status domain field, and the recovery field is located after the AM group. Fig. 9 For other contents, please refer to the relevant contents in the IEEE802.3 standard and will not be repeated here.

[0108] In a possible implementation, the request field includes at least one bit, and different values ​​of the at least one bit are used to indicate different FEC modes. Fig.10 Schematic diagram of the structure of a FEC mode field provided in an embodiment of the present application. Fig.10 As shown, the FEC mode domain field includes a request field, the request field includes 1 bit, the request field is a first value used to indicate a request to apply the end-to-end FEC mode, and the request field is a second value used to indicate a request to apply the cascade FEC mode. For example, the first value is 1 and the second value is 0.

[0109] In another possible implementation, the request field includes multiple bits, and the multiple bits indicate the requested FEC mode in a bitmap manner, with one bit corresponding to one FEC mode. Fig.11 Schematic diagram of another structure of FEC mode field provided in the embodiment of the present application. Fig.11 As shown, the FEC mode domain field includes a request field, and the request field includes 3 bits, one bit corresponding to an FEC mode. For example, the first bit of the request field corresponds to the end-to-end FEC mode, the second bit corresponds to the segmented FEC mode, and the third bit corresponds to the cascaded FEC mode. For any of the three bits, if the value of any one of the bits is a third value, the third value is used to indicate that the FEC mode corresponding to any one of the bits is requested, and if the value of any one of the bits is a fourth value, the fourth value is used to indicate that the FEC mode corresponding to any one of the bits is not requested. For example, the third value is 1 and the fourth value is 0. In some embodiments, when the request field includes multiple bits and the multiple bits indicate the requested FEC mode in a bitmap manner, the value of the request field can be used to request multiple FEC modes, that is, these requested FEC modes are all used as the first FEC mode.

[0110] Exemplarily, the FEC mode domain field includes a response field, and the value of the response field is used to confirm the application of the first FEC mode. The value of the response field can also be used to refuse to apply the first FEC mode, wherein the value used to confirm the application of the first FEC mode is different from the value used to refuse to apply the first FEC mode. In an embodiment of the present application, the FEC mode domain field may include both a request field and a response field, or may include only one of the request field or the response field. For example, the first notification message only includes the request field, and the first response message received by the subsequent first control module only includes the response field.

[0111] In a possible implementation, the response field includes at least one bit, and different values ​​of the at least one bit are used to indicate different FEC modes. Fig.10 The FEC mode domain field includes a response field, the response field includes 1 bit, the response field is a fifth value used to indicate confirmation of applying the first FEC mode, and the response field is a sixth value used to indicate refusal to apply the first FEC mode. For example, the fifth value is 1 and the sixth value is 0.

[0112] In another possible implementation, the response field includes multiple bits, and the multiple bits indicate the confirmed or rejected FEC mode in a bitmap manner, with one bit corresponding to one FEC mode. Fig.11, the FEC mode domain field includes a response field, and the response field includes 3 bits, one bit corresponding to an FEC mode. For example, the first bit of the response field corresponds to the end-to-end FEC mode, the second bit corresponds to the segmented FEC mode, and the third bit corresponds to the cascaded FEC mode. For any of the three bits, if the value of any of the bits is the seventh value, the seventh value is used to indicate confirmation of the application of the FEC mode corresponding to any of the bits, and if the value of any of the bits is the eighth value, the fourth value is used to indicate the refusal to apply the FEC mode corresponding to any of the bits. For example, the seventh value is 1 and the eighth value is 0. In some embodiments, when the response field includes multiple bits and the multiple bits indicate the confirmed or rejected FEC mode in a bitmap manner, if the first AM requests multiple FEC modes, the response field can confirm the FEC mode with the shortest delay or the FEC mode with the highest performance among the multiple FEC modes, and reject other FEC modes except the confirmed FEC mode among the multiple FEC modes. In the embodiment of the present application, the performance of the FEC mode may refer to the error correction capability. The stronger the error correction capability, the higher the performance of the FEC mode.

[0113] Exemplarily, in the case where the first notification message includes the first AM, the first AM is obtained based on the codeword encoded by extended Bose-Chaudhuri-Hocquenghem (eBCH), and the first AM is used to announce the application of the first FEC mode. For example, the first AM is obtained based on the codeword encoded by eBCH (16,5), wherein eBCH (16,5) refers to encoding 5 bits of information bits to generate 11 bits of check bits, and the codeword encoded by eBCH (16,5) can be used to correct 3 bits of errors. The 32 codewords encoded by eBCH (16,5) and the four-level pulse amplitude modulation (4-level pulse amplitude modulation, PAM4) direct current (DC) values ​​corresponding to each codeword are shown in Tables 1 to 4 below.

[0114] Table 1

[0115]

[0116]

[0117] Table 2

[0118] Codeword 8 Codeword 9 Codeword 10 Codeword 11 Codeword 12 Codeword 13 Codeword 14 Codeword 15 Bit 0 0 0 0 0 0 0 0 0 Bit 1 1 1 1 1 1 1 1 1 Bit2 0 0 0 0 1 1 1 1 Bit 3 0 0 1 1 0 0 1 1 Bit 4 0 1 0 1 0 1 0 1 Bit5 1 1 0 0 1 1 0 0 Bit6 1 0 1 0 0 1 0 1 Bit7 1 1 1 1 0 0 0 0 Bit8 1 1 0 0 0 0 1 1 Bit9 0 1 1 0 1 0 0 1 Bit10 1 0 1 0 1 0 1 0 Bit 11 0 0 1 1 1 1 0 0 Bit 12 1 0 0 1 1 0 0 1 Bit 13 1 0 0 1 0 1 1 0 Bit 14 0 1 0 1 1 0 1 0 Bit 15 0 1 1 0 0 1 1 0 PAM4 DC Value 0 -8 -8 0 4 0 0 4

[0119] Table 3

[0120] Codeword 16 Codeword 17 Codeword 18 Codeword 19 Codeword 20 Codeword 21 Codeword 22 Codeword 23 Bit 0 1 1 1 1 1 1 1 1 Bit 1 0 0 0 0 0 0 0 0 Bit2 0 0 0 0 1 1 1 1 Bit 3 0 0 1 1 0 0 1 1 Bit 4 0 1 0 1 0 1 0 1 Bit5 1 1 0 0 1 1 0 0 Bit6 0 1 0 1 1 0 1 0 Bit7 1 1 1 1 0 0 0 0 Bit8 0 0 1 1 1 1 0 0 Bit9 0 1 1 0 1 0 0 1 Bit10 1 0 1 0 1 0 1 0 Bit 11 1 1 0 0 0 0 1 1 Bit 12 0 1 1 0 0 1 1 0 Bit 13 1 0 0 1 0 1 1 0 Bit 14 1 0 1 0 0 1 0 1 Bit 15 1 0 0 1 1 0 0 1 PAM4 DC Value -4 0 8 4 8 8 0 0

[0121] Table 4

[0122]

[0123]

[0124] Exemplarily, the codewords with a PAM4 DC value of 0 in Tables 1 to 4 are used to obtain the first AM. That is, codeword 4, codeword 8, codeword 11, codeword 13, codeword 14, codeword 17, codeword 22, codeword 23, codeword 26, and codeword 27 are used to obtain the first AM. In a possible implementation, the AM obtained based on the codeword encoded by eBCH (16, 5) includes a CM field, a UM field, and a UP field, wherein the CM field has the same value as the CM field specified in the Ethernet standard, and the values ​​of the UM field and the UP field are obtained based on the codeword encoded by eBCH (16, 5). Fig.12 is a schematic diagram of the structure of another AM provided in the embodiment of the present application. Fig.12 , AM includes CM field, UM field and UP field, and the arrangement of CM field, UM field and UP field is as follows Fig.12 As shown in the figure, the CM field includes CM0 to CM5, and the length of CM0 to CM5 is 1 byte; the length of the UP field is 1 byte; the UM field includes UM0 to UM7, and the length of UM0 to UM7 is 1 byte. That is, the length of the AM is also 120 bits.

[0125] In a possible implementation, the values ​​of the UM field and the UP field are obtained based on a codeword with a PAM4 DC value of 0, so that the AM obtained based on the codeword encoded by eBCH (16, 5) has the characteristics of PAM4 DC balance. The selection set of the value of the UM field can be shown in Table 5, where one codeword corresponds to the values ​​of two UM fields.

[0126] Table 5

[0127] {UM0, UM1} {UM2, UM3} {UM4, UM5} {UM6,UM7} Codeword 4 Codeword 4 Codeword 4 Codeword 4 Codeword 8 Codeword 8 Codeword 8 Codeword 8 Codeword 11 Codeword 11 Codeword 11 Codeword 11 Codeword 13 Codeword 13 Codeword 13 Codeword 13 Codeword 14 Codeword 14 Codeword 14 Codeword 14 Codeword 17 Codeword 17 Codeword 17 Codeword 17 Codeword 22 Codeword 22 Codeword 22 Codeword 22 Codeword 23 Codeword 23 Codeword 23 Codeword 23 Codeword 26 Codeword 26 Codeword 26 Codeword 26 Codeword 27 Codeword 27 Codeword 27 Codeword 27

[0128] As shown in Table 5, the selected sets of {UM0, UM1}, {UM2, UM3}, {UM4, UM5} and {UM6, UM7} all include codeword 4, codeword 8, codeword 11, codeword 13, codeword 14, codeword 17, codeword 22, codeword 23, codeword 26 and codeword 27. The specific codewords selected from {UM0, UM1}, {UM2, UM3}, {UM4, UM5} and {UM6, UM7} may be the same or different, and this is not limited in the embodiment of the present application. The selected set of values ​​of the UP field may be shown in Table 6.

[0129] Table 6

[0130] UP 0x1E 0x2D 0x4B 0x78 0x87 0xB4 0xD2 0xE1

[0131] In a possible implementation, the CM field included in the first AM is the same as the value of the CM field specified in the Ethernet standard. If the first AM is used to request the application of the cascade FEC mode, the values ​​of the UM field and the UP field of the first AM are shown in Table 7. If the first AM is used to request the application of the end-to-end FEC mode, the values ​​of the UM field and the UP field of the first AM are shown in Table 8. Exemplarily, the first control module receives a first response message or a second response message sent by the second device, the first response message is obtained based on the second AM, the first response message is used to confirm the application of the first FEC mode, the second response message is obtained based on the third AM, and the second response message is used to refuse to apply the first FEC mode. In the case where the first response message includes the second AM, the CM field included in the second AM is the same as the value of the CM field specified in the Ethernet standard, and the values ​​of the UM field and the UP field of the second AM are shown in Table 9. In the case where the second response message includes the third AM, the CM field included in the third AM is the same as the value of the CM field specified in the Ethernet standard, and the values ​​of the UM field and the UP field of the third AM are shown in Table 10. The specific values ​​in Tables 7 to 10 are only used for illustration. The values ​​of the UM field and the UP field of the first AM, the second AM and the third AM can be set according to experience or actual needs, and the embodiments of the present application are not limited to this.

[0132] Table 7

[0133] {UM0, UM1} {UM2, UM3} {UM4, UM5} {UM6,UM7} UP Codeword 4 Codeword 4 Codeword 4 Codeword 4 0x1E

[0134] Table 8

[0135] {UM0, UM1} {UM2, UM3} {UM4, UM5} {UM6,UM7} UP Codeword 8 Codeword 8 Codeword 8 Codeword 8 0x2D

[0136] Table 9

[0137] {UM0, UM1} {UM2, UM3} {UM4, UM5} {UM6,UM7} UP Codeword 11 Codeword 11 Codeword 11 Codeword 11 0x4B

[0138] Table 10

[0139] {UM0, UM1} {UM2, UM3} {UM4, UM5} {UM6,UM7} UP Codeword 13 Codeword 13 Codeword 13 Codeword 13 0x78

[0140] In some embodiments, the number of first notification messages sent by the first control module to the second device is multiple. That is, the first control module sends the first notification message to the second device via the first optical module, including: the first control module sends multiple first notification messages to the second device via the first optical module. Thus, the probability of the second device receiving the first notification message is higher, and the reliability of transmitting the first notification message is higher.

[0141] S702: The first control module sends a first notification message to the second device via the first optical module, and notifies the second device of applying the first FEC mode through the first notification message.

[0142] Exemplarily, the first FEC mode is any one of an end-to-end FEC mode, a segmented FEC mode, or a cascaded FEC mode. In one possible implementation, after the first control module sends the first notification message to the second device via the first optical module, it determines to apply the first FEC mode. In another possible implementation, after the first control module sends the first notification message to the second device via the first optical module, it determines whether to apply the first FEC mode based on a response message received from the second device.

[0143] For example, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module receives a first response message, the first response message is obtained based on the second AM, the first response message is sent by the second device after receiving the first notification message, and the first response message is used to confirm the application of the first FEC mode; based on the first response message, the first control module determines to apply the first FEC mode. For another example, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module receives a second response message, the second response message is obtained based on the third AM, the second response message is sent by the second device after receiving the first notification message, and the second response message is used to refuse to apply the first FEC mode; based on the second response message, the first control module determines not to apply the first FEC mode.

[0144] Exemplarily, the first response message includes an FEC mode domain field, the first response message is determined based on the second AM, the FEC mode domain field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode. The second response message also includes an FEC mode domain field, the FEC mode domain field is determined based on the third AM, the FEC mode domain field includes an answer field, and the value of the answer field is used to refuse to apply the first FEC mode. The situation of the answer field can be referred to in the above Fig.10 and Fig.11 The description is not repeated here.

[0145] Exemplarily, the FEC mode field in the first response message is determined based on the UP field of the second AM, or the FEC mode field is determined based on the padding field used to form a 257-bit code block with multiple AMs, or the FEC mode field is determined based on the recovery field located after the AM group, wherein the multiple AMs and the AM group include the second AM. That is, in the first response message, if the FEC mode field is determined based on the padding field used to form a 257-bit code block with multiple AMs, the second AM may be any one of the multiple AMs; if the FEC mode field is determined based on the recovery field located after the AM group, the second AM may be any one of the AMs. Similarly, the FEC mode field in the second response message is determined based on the UP field of the third AM, or the FEC mode field is determined based on the padding field used to form a 257-bit code block with multiple AMs, or the FEC mode field is determined based on the recovery field located after the AM group, wherein the multiple AMs and the AM group include the third AM. That is, in the second response message, if the FEC mode domain field is determined based on the padding field used to form a 257-bit code block with multiple AMs, the third AM may be any one of the multiple AMs; if the FEC mode domain field is determined based on the recovery field located after the AM group, the third AM may be any one of the AMs in the AM group.

[0146] In a possible implementation, the first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, n is an integer not less than 0, and the number of first response messages is at least one. Therefore, the number and sending timing of the first response message are relatively flexible. Similarly, the second response message is sent by the second device after receiving the first notification message and sending t AMs to the first device, t is an integer not less than 0, and the number of second response messages is at least one. Therefore, the number and sending timing of the second response message are relatively flexible. In some embodiments, when the number of first response messages is multiple, the reliability of transmitting the first response message is higher. When the number of second response messages is multiple, the reliability of transmitting the second response message is higher.

[0147] In some embodiments, the second device generates a second notification message, the second notification message is obtained based on the first AM, the second notification message is used to notify the application of the first FEC mode, and the second device transmits the second notification message to the first control module. That is, both the first device and the second device can send notification messages to inform the other end to apply the first FEC mode. The way in which the second device generates the second notification message is the same as the principle of the first control module generating the first notification message, which will not be repeated here. Therefore, the method may also include: the first control module receives the second notification message sent by the second device, the second notification message is obtained based on the first AM, and the second notification message is used to notify the application of the first FEC mode; based on the second notification message, the first control module determines to apply the first FEC mode. In an embodiment of the present application, the second notification message may include an FEC mode domain field, the FEC mode domain field is determined based on the first AM, and the structure of the FEC mode domain field included in the second notification message is the same as the structure of the FEC mode domain field included in the first notification message, which will not be repeated here.

[0148] Exemplarily, in the case where it is determined not to apply the first FEC mode, if the first device does not apply the FEC mode, the FEC mode continues to not be applied, and if it is determined to apply the first FEC mode, the first device applies the first FEC mode. In some embodiments, applying the first FEC mode includes applying the first FEC mode in a first receiving direction, or applying the first FEC mode in both a first sending direction and a first receiving direction, wherein the first receiving direction is a direction in which the first device receives data from the second device, and the first sending direction is a direction in which the first device sends data to the second device. Thus, the manner of applying the first FEC mode in the method is more flexible.

[0149] Exemplarily, when it is determined to apply the first FEC mode, the first FEC mode is applied. In one possible implementation, the first control module can start applying the first FEC mode after sending the first notification message for the first reference time without waiting for a response from the second device, so that when the second device determines to switch to the first FEC mode, the time when the first device and the second device start applying the first FEC mode can be relatively close. The first reference time can be set based on experience or actual needs, and the embodiments of the present application do not limit this. For example, the first reference time is greater than or equal to the sum of the transmission time of the first notification message between the first device and the second device and the time it takes the second device to process the first notification message.

[0150] In a possible implementation, the method further includes: based on receiving m first response messages, adjusting the FEC encoding function to apply the first FEC mode, where m is a positive integer and is less than or equal to the number of first response messages. Thus, when the number of first response messages is multiple, the FEC encoding function can be adjusted to apply the first FEC mode when m first response messages are received, and the timing of applying the first FEC mode is more flexible.

[0151] Exemplarily, in the case where the first device applies the FEC mode, the first control module performs FEC encoding by default. In some embodiments, in the case where the first optical module includes an oDSP chip, the method further includes: the first control module sends a first switch instruction to the oDSP chip, and the first switch instruction is used to instruct the oDSP chip to apply the first FEC mode by regulating the FEC encoding function. For example, in the case where the first FEC mode is a cascade FEC mode, the first switch instruction is used to instruct the oDSP chip to apply the cascade FEC mode by turning on the FEC encoding function. For another example, in the case where the first FEC mode is an end-to-end FEC mode, the first switch instruction is used to instruct the oDSP chip to apply the end-to-end FEC mode by turning off the FEC encoding function. For another example, in the case where the first FEC mode is a segmented FEC mode, the first switch instruction is used to instruct the oDSP chip to apply the segmented FEC mode by turning on the FEC decoding function and the FEC encoding function, the FEC decoding function is used to decode the FEC codeword encoded by the first control module to obtain a decoding result, and the FEC encoding function is used to perform FEC encoding on the decoding result.

[0152] In a possible implementation, the first control module sends the first switch instruction to the oDSP chip through a local management channel, and the local management channel is implemented based on a management data input output (MDIO) or a two-wire serial (inter-integrated circuit, I2C) bus. Alternatively, the first control module extends the implementation of the AN so that the extended implementation of the AN can be used to send the first switch instruction. Alternatively, the oDSP chip includes a register, and the first control module sends a write instruction to the register of the oDSP chip, and the write instruction is used as the first switch instruction.

[0153] Fig.13 Schematic diagram of a process of sending a first switch instruction provided by an embodiment of the present application. Fig.13As shown, the first control module included in the first device and the second control module included in the second device are both located in the MAC layer, PCS and PMA sublayers, and the first optical module included in the first device and the second optical module included in the second device are both located in the PMA sublayer, FEC layer and PMD layer. The PMA sublayer where the first optical module is located includes a PMA sublayer connected to the first control module and a PMA sublayer connected to the FEC layer and the PMD sublayer respectively, and the PMA sublayer where the second optical module is located includes a PMA sublayer connected to the second control module and a PMA sublayer connected to the FEC layer and the PMD sublayer respectively. Among them, the first optical module and the second optical module both include an oDSP chip, and the oDSP chip is not in Fig.13 When the first control module determines to apply the first FEC mode, it sends a first switch instruction to the oDSP chip in the first optical module, and the first switch instruction is used to instruct the oDSP chip to adjust the FEC encoding function to implement the first FEC mode. Exemplarily, the transmission rate between the first control module and the first optical module is 106.25GBd, and the transmission rate between the second control module and the second optical module is also 106.25GBd.

[0154] In some other embodiments, the first optical module includes LPO, that is, the first optical module does not have an FEC encoding function. In this case, the method further includes: a first control module regulates the FEC encoding function to implement the application of a first FEC mode. For example, in the case where the first optical module includes LPO, if the first FEC mode is an end-to-end FEC mode, the first control module performs an FEC encoding operation once. If the first FEC mode is a segmented FEC mode, the first control module can perform a first FEC encoding operation, a first FEC decoding operation, and a second FEC encoding operation. If the first FEC mode is a cascaded FEC mode, the first control module can perform two FEC encoding operations. The method provided in the embodiments of the present application can be applied to different types of optical modules and has a wide range of applicable scenarios.

[0155] Exemplarily, the method further includes: the first optical module acquires the transmission rate corresponding to the first FEC mode; the first control module transmits a signal to the second device via the first optical module according to the transmission rate. By transmitting the signal according to the transmission rate corresponding to the first FEC mode, the transmission rate can be adapted to the first FEC mode. For example, when the overhead of the first FEC mode is high, the transmission rate corresponding to the first FEC mode is faster. When the overhead of the first FEC mode is low, the transmission rate corresponding to the first FEC mode is slower. Therefore, when the applied FEC mode changes, the data transmission rate can be kept unchanged. Please continue to refer to Fig.13The transmission rate corresponding to the end-to-end FEC mode is 106.25GBd, and the transmission rate corresponding to the cascade FEC mode is 113.4375GBd.

[0156] In a possible implementation, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module monitors the second link quality between the first device and the second device; based on the second link quality satisfying the second application condition, the first control module generates a third notification message, the third notification message is obtained based on the fourth AM, the first control module sends the third notification message to the second device via the first optical module, and notifies the second device of the application of other FEC modes except the first FEC mode through the third notification message. That is, after applying the first FEC mode, the first control module can continue to monitor the link quality between the first device and the second device, so that when the link quality changes, the FEC mode to be applied can be flexibly adjusted based on the changed link quality. Exemplarily, the second application condition is different from the first application condition.

[0157] In some embodiments, the second link quality includes at least one of BER or FLR. For example, when the second link quality includes BER and the first application condition includes BER higher than the first BER threshold, the second application condition includes BER not higher than a third BER threshold, and the third BER threshold is less than or equal to the first BER threshold. When the first link quality includes FLR and the first application condition includes FLR higher than the first FLR threshold, the second application condition includes FLR not higher than the third FLR threshold, and the third FLR threshold is less than or equal to the first FLR threshold. Exemplarily, when BER is not higher than the third BER threshold or FLR is not higher than the third FLR threshold, if the first FEC mode is a cascade FEC mode, it is determined to switch from applying the cascade FEC mode to applying the end-to-end FEC mode. Both the third BER threshold and the third FLR threshold can be set according to experience or actual needs, and the embodiments of the present application are not limited to this.

[0158] For another example, when the second link quality includes BER and the first application condition includes that the BER is lower than the second BER threshold, the second application condition includes that the BER is not lower than a fourth BER threshold, and the fourth BER threshold is greater than or equal to the second BER threshold. When the second link quality includes FLR and the first application condition includes that the FLR is lower than the second FLR threshold, the second application condition includes that the FLR is not lower than the fourth FLR threshold, and the fourth FLR threshold is greater than or equal to the second FLR threshold. Exemplarily, when the BER is not lower than the fourth BER threshold or the FLR is not lower than the fourth FLR threshold, if the first FEC mode is an end-to-end FEC mode, it is determined to switch from applying the end-to-end FEC mode to applying the cascade FEC mode. Both the fourth BER threshold and the fourth FLR threshold can be set according to experience or actual needs, and the embodiments of the present application are not limited to this.

[0159] For another example, when the second link quality includes BER and the third BER threshold is lower than the fourth BER threshold, the second application condition includes that the BER is higher than the third BER threshold and lower than the fourth BER threshold. If the first application mode is an end-to-end FEC mode or a cascade FEC mode, it is determined to switch to an application segmented FEC mode.

[0160] Exemplarily, the way in which the first control module generates the third notification message is the same as the principle of generating the first notification message. The difference between the third notification message and the first notification message lies in that the FEC mode of the notification application is different and the AM used to generate the third notification message is the fourth AM. The embodiment of the present application will no longer elaborate on the way to generate the third notification message.

[0161] In some embodiments, after the first control module sends the first notification message to the second device via the first optical module, the method further includes: the first control module receives a fourth notification message sent by the second device, the fourth notification message is obtained based on the fourth AM, and the fourth notification message is used to notify the application of other FEC modes other than the first FEC mode; in the case of determining to apply other FEC modes other than the first FEC mode based on the fourth notification message, the FEC mode other than the first FEC mode is applied. That is, the first device including the first control module can determine whether to switch to other FEC modes other than the first FEC mode based on the received fourth notification message, and the way in which the first device determines the FEC mode to be switched is more flexible. Exemplarily, the way in which the second device generates the fourth notification message is the same as the way in which the second notification message is generated. The difference between the fourth notification message and the second notification message is that the FEC mode of the notification application is different and the AM used to generate the fourth notification message is the fourth AM. The embodiment of the present application will not repeat the way to generate the fourth notification message.

[0162] Exemplarily, the third notification message and the fourth notification message both include an FEC mode domain field, the FEC mode domain field is determined based on the fourth AM, and the FEC mode domain field includes a request field, and the request field is used to request the application of other FEC modes except the first FEC mode. In a possible implementation, the FEC mode domain field is determined based on the UP field of the fourth AM, or the FEC mode domain field is determined based on the padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on the recovery field located after the AM group, wherein the multiple AMs and the AM group include the fourth AM. That is, in the third notification message or the fourth notification message, if the FEC mode domain field is determined based on the padding field used to form a 257-bit code block with multiple AMs, the fourth AM may be any one of the multiple AMs; if the FEC mode domain field is determined based on the recovery field located after the AM group, the fourth AM may be any one of the AMs.

[0163] In a possible implementation, the third notification message or the fourth notification message includes a fourth AM, and the fourth AM is used to request the application of other FEC modes except the first FEC mode. For example, the fourth AM includes a CM field, a UM field, and a UP field, wherein the CM field included in the fourth AM is the same as the value of the CM field specified in the Ethernet standard. If the first FEC mode is an end-to-end FEC mode, the values ​​of the UM field and the UP field of the fourth AM may be as shown in Table 7, that is, the fourth AM is used to request the application of the cascade FEC mode. If the first FEC mode is a cascade FEC mode, the values ​​of the UM field and the UP field of the fourth AM may be as shown in Table 9, that is, the fourth AM is used to request the application of the end-to-end FEC mode.

[0164] In the method provided in the embodiment of the present application, by sending a first notification message to the second device, the first control module connected to the first optical module can notify the second device of the application of the first FEC mode, so that the notification of the application of the FEC mode can be implemented in the scenario including the optical module. In the case where the first AM is also used to identify the PCS channel, the first AM can be compatible with the AM function specified in the IEEE802.3 standard. Therefore, in the case where the first notification message includes the first AM and the first AM is used to notify the application of the first FEC mode, there is no need to introduce overhead other than the first AM to notify the application of the FEC mode, the overhead of notifying the application of the FEC mode is low, and there is no need to include information for notifying the application of the FEC mode by deleting certain information, thereby avoiding information loss.

[0165] The foregoing description is from the perspective of the first device side executing the forward error correction mode notification method. Next, the forward error correction mode notification method provided by the embodiment of the present application is described from the perspective of the second device side. The method can be applied to Figure 2The second control module 2021 shown, that is, the method is applied to the second control module included in the second device, the second device also includes a second optical module, and the second optical module is connected to the second control module and the first device respectively. For example, the second optical module is connected to the second control module and the first optical module in the first device respectively. Fig.14 As shown, the method includes but is not limited to S1401 and S1402.

[0166] S1401, a second control module receives a first notification message from a first device via a second optical module, where the first notification message is obtained based on a first AM, and is used to notify application of a first FEC mode.

[0167] Exemplarily, the second control module includes a PHY chip. For the relevant contents of the first notification message and the first AM, please refer to the description in S701 above, which will not be repeated here.

[0168] S1402: When it is determined based on the first notification message that the first FEC mode is to be applied, apply the first FEC mode.

[0169] In a possible implementation, in the case of determining to apply the first FEC mode based on the first notification message, before applying the first FEC mode, the method further includes: the second control module monitors the first link quality between the second device and the first device; based on receiving the first notification message and the first link quality meeting the first application condition, the second control module determines to apply the first FEC mode. That is, the second control module may also monitor the first link quality between the second device and the first device, and if the first notification message is received and the first link quality meets the first application condition, it is determined that the first FEC mode can be applied. The first link quality and the first application condition are the same as the first link quality and the first application condition in S701, and will not be repeated here.

[0170] Exemplarily, the method further includes: when the first link quality meets the first application condition, the second control module generates a second notification message, the second notification message is obtained based on the first AM; the second control module sends the second notification message to the first device via the second optical module, and notifies the first device of the application of the first FEC mode through the second notification message. That is, when the first link quality meets the first application condition, the second control module can also generate the second notification message based on the first AM, so that after receiving the second notification message, the first control module can determine to apply the first FEC mode based on the second notification message.

[0171] Exemplarily, in the case of determining to apply the first FEC mode based on the first notification message, before applying the first FEC mode, the method also includes: the second control module receives configuration information, the configuration information is used to indicate the application of the first FEC mode, so that after receiving the first notification message, the second control module can determine to apply the first FEC mode based on the configuration information.

[0172] In some embodiments, the method further includes: in the case of determining to apply the first FEC mode, the second control module sends a first response message to the first device via the second optical module, the first response message is obtained based on the second AM, and the first response message is used to confirm the application of the first FEC mode. Thus, after receiving the first response message, the first control module of the first device can determine to apply the first FEC mode based on the first response message. Exemplarily, the first response message includes an FEC mode domain field, the FEC mode domain field is determined based on the second AM, the FEC mode domain field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode. For the FEC mode domain field and the answer field, please refer to the relevant description of the FEC mode domain field and the answer field in S701 above. In the case where the first response message includes the second AM, the second AM can refer to the relevant description of Table 9 above, and will not be repeated here.

[0173] Exemplarily, the first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, where n is an integer not less than 0, and the number of first response messages is at least one. Thus, the number and timing of the first response messages sent by the second control module are relatively flexible. In the case where there are multiple first response messages, the probability that the first device receives the first response message is relatively high, and the reliability of transmitting the first response message is relatively high.

[0174] In some other embodiments, the method further includes: in the case of determining that the first FEC mode is not to be applied, the second control module sends a second response message to the first device via the second optical module, the second response message is obtained based on the third AM, and the second response message is used to refuse to apply the first FEC mode. Thus, after receiving the second response message, the first control module of the first device can determine not to apply the first FEC mode based on the second response message. Exemplarily, the second response message includes an FEC mode domain field, the FEC mode domain field is determined based on the third AM, the FEC mode domain field includes a response field, and the value of the response field is used to refuse to apply the first FEC mode. For the FEC mode domain field and the response field, please refer to the relevant description of the FEC mode domain field and the response field in S701 above. In the case where the second response message includes the third AM, the third AM can refer to the relevant description of Table 10 above, and no further description is given here. Exemplarily, the second response message is sent by the second device after receiving the first notification message and sending t AMs to the first device, t is an integer not less than 0, and the number of second response messages is at least one. Thus, the number and timing of the second response message sent by the second control module are relatively flexible. In the case where there are multiple second response messages, the probability that the first device receives the second response message is greater, and the reliability of transmitting the second response message is higher.

[0175] In a possible implementation, when the second control module determines that the first FEC mode is not applied, the second control module does not respond, that is, does not send a second response message. When the second control module does not respond, if the second device does not apply the FEC mode, the FEC mode remains unapplied; if the second device applies the FEC mode, the applied FEC mode remains unchanged.

[0176] Exemplarily, in the case of determining to apply the first FEC mode, the first FEC mode is applied. In some embodiments, applying the first FEC mode includes applying the first FEC mode in the second sending direction, or applying the first FEC mode in both the second sending direction and the second receiving direction, wherein the second sending direction is the direction in which the second device sends data to the first device, and the second receiving direction is the direction in which the second device receives data from the first device.

[0177] In a possible implementation, the first FEC mode is applied after the second control module sends the second notification message for the second reference duration, so that when the first device determines to switch to the first FEC mode, the time when the first device and the second device start to apply the first FEC mode can be relatively close. The second reference duration can be set based on experience or actual needs, and the embodiments of the present application are not limited to this. For example, the second reference duration is greater than or equal to the sum of the transmission duration of the second notification message between the first device and the second device and the duration of the first device processing the second notification message.

[0178] Exemplarily, when the second device applies the FEC mode, the second control module performs FEC decoding by default. In some embodiments, when the second optical module includes an oDSP chip, the first FEC mode is applied, including: the second control module sends a second switch instruction to the oDSP chip, and the second switch instruction is used to instruct the oDSP chip to apply the first FEC mode by regulating the FEC encoding function. For example, when the first FEC mode is a cascade FEC mode, the second switch instruction is used to instruct the oDSP chip to apply the cascade FEC mode by turning on the FEC decoding function. For another example, when the first FEC mode is an end-to-end FEC mode, the second switch instruction is used to instruct the oDSP chip to apply the end-to-end FEC mode by turning off the FEC decoding function. For another example, when the first FEC mode is a segmented FEC mode, the second switch instruction is used to instruct the oDSP chip to apply the segmented FEC mode by turning on the FEC decoding function and the FEC encoding function, the FEC decoding function is used to decode the FEC codeword transmitted by the first device to obtain a decoding result, and the FEC encoding function is used to perform FEC encoding on the decoding result. Exemplarily, the manner in which the second control module sends the second switch instruction to the oDSP chip is the same as the manner in which the first control module sends the first switch instruction to the oDSP chip, and will not be described in detail here. Fig.13 When determining to apply the first FEC mode, the second control module sends a second switch instruction to the oDSP chip in the second optical module, where the second switch instruction is used to instruct the oDSP chip to implement the first FEC mode by adjusting the FEC encoding function.

[0179] In other embodiments, the second optical module includes LPO, that is, the second optical module does not have an FEC decoding function. In this case, the first FEC mode is applied, including: the second control module regulates the FEC decoding function to implement the application of the first FEC mode. For example, in the case where the second optical module includes LPO, if the first FEC mode is an end-to-end FEC mode, the second control module performs an FEC decoding operation once. If the first FEC mode is a segmented FEC mode, the second control module can perform a first FEC decoding operation, a first FEC encoding operation, and a second FEC decoding operation. If the first FEC mode is a cascaded FEC mode, the second control module can perform two FEC decoding operations. The method provided in the embodiments of the present application can be applied to different types of optical modules and has a wide range of applicable scenarios.

[0180] Exemplarily, the method further includes: the second optical module obtains the transmission rate corresponding to the first FEC mode; the second control module receives a signal from the first device via the second optical module according to the transmission rate. By transmitting the signal according to the transmission rate corresponding to the first FEC mode, the transmission rate can be adapted to the first FEC mode. For example, when the overhead of the first FEC mode is high, the transmission rate corresponding to the first FEC mode is faster. When the overhead of the first FEC mode is low, the transmission rate corresponding to the first FEC mode is slower. Thus, when the applied FEC mode changes, the data transmission rate can be kept unchanged.

[0181] In some embodiments, after applying the first FEC mode, the method further includes: the second control module receives a third notification message sent by the first device, the third notification message is obtained based on the fourth AM, and the third notification message is used to notify the application of other FEC modes other than the first FEC mode; in the case of determining to apply other FEC modes other than the first FEC mode based on the third notification message, applying the other FEC modes other than the first FEC mode. That is to say, the second device including the second control module can determine whether to switch to other FEC modes other than the first FEC mode based on the received third notification message, and the way in which the second device determines the FEC mode to be switched is more flexible. The third notification message and the fourth AM can be found in the description of the third notification message and the fourth AM after S702 in the previous text, which will not be repeated here.

[0182] In one possible implementation, after applying the first FEC mode, the method further includes: a second control module monitors the second link quality between the second device and the first device; based on the second link quality satisfying the second application condition, the second control module generates a fourth notification message, and the fourth notification message is obtained based on the fourth AM; the second control module sends the fourth notification message to the first device via the second optical module, and notifies the first device of the application of other FEC modes except the first FEC mode through the fourth notification message. That is, after applying the first FEC mode, the second control module can continue to monitor the link quality between the first device and the second device, so that when the link quality changes, the FEC mode to be applied can be flexibly adjusted based on the changed link quality. The second link quality, the second application condition and the fourth notification message can be found in the description of the second link quality, the second application condition and the fourth notification message after S702 in the previous text, which will not be repeated here.

[0183] Exemplarily, if the first device applies the first FEC mode and the second device does not apply the first FEC mode, since the FEC modes used by the first device and the second device are inconsistent, the first device and the second device will monitor a rapid increase in the bit error rate when transmitting according to the FEC modes applied by each device. In this case, the first device and the second device can both switch to apply other FEC modes except the first FEC mode. Alternatively, if the first device and the second device initially apply the same FEC mode, if the first device applies the first FEC mode and the second device does not apply the first FEC mode, the first device can switch to apply the initial FEC mode, and the second device keeps the applied FEC mode unchanged.

[0184] In the method provided in the embodiment of the present application, based on the first notification message sent by the first device, the second control module connected to the second optical module can be notified by the first device to apply the first FEC mode, so that the notification of applying the FEC mode can be implemented in the scenario including the optical module. In the case where the first AM is also used to identify the PCS channel, the first AM can be compatible with the AM function specified in the IEEE802.3 standard. Therefore, in the case where the first notification message includes the first AM, there is no need to introduce overhead other than the first AM to notify the application of the FEC mode, the overhead of notifying the application of the FEC mode is low, and there is no need to include information for notifying the application of the FEC mode by deleting certain information, thereby avoiding information loss.

[0185] Next, taking the interaction process between the first control module and the second control module as an example, Figures 15 to 18 The forward error correction mode notification method provided in an embodiment of the present application is described. Fig.15 1 is a schematic diagram of a process of unilaterally initiating unilateral switching provided by an embodiment of the present application. The first control module and the second control module both support the end-to-end FEC mode and the cascade FEC mode, and the first control module and the second control module start data transmission and reception in the same default FEC mode. Fig.15 As shown, the process includes the following S1501 to S1504.

[0186] S1501, the Rx of the first control module detects the first link quality between the first device and the second device, and based on the first link quality satisfying the first application condition, the Tx of the first control module sends a first notification message, the first notification message is obtained based on the first AM, and the first notification message is used to indicate the application of the first FEC mode.

[0187] S1502, after the Rx of the second control module receives the first notification message, if it is confirmed to apply the first FEC mode, the Tx of the second control module sends a first response message, the first response message is obtained based on the second AM, and the first response message is used to confirm the application of the first FEC mode; if the first FEC mode is refused to be applied, the Tx of the second control module sends a second response message, the second response message is obtained based on the third AM, and the second response message is used to refuse to apply the first FEC mode.

[0188] S1503: When the second control module confirms to apply the first FEC mode, notify the second optical module to apply the first FEC mode in the second sending direction.

[0189] S1504: When the first control module receives the first response message, notify the first optical module to apply the first FEC mode in the first receiving direction.

[0190] Combination Fig.15 As shown in the figure, the request to apply the first FEC mode is initiated by the first control module, so the process is called a unidirectional initiation process. Since the first FEC mode is only applied in the first receiving direction of the first control module and the second sending direction of the second control module, the process is called a unilateral switching process.

[0191] Fig.16 1 is a schematic diagram of a process of bidirectionally initiating unilateral switching provided by an embodiment of the present application. The first control module and the second control module both support the end-to-end FEC mode and the cascade FEC mode, and the first control module and the second control module start data transmission and reception in the same default FEC mode. Fig.16 As shown, the process includes the following S1601 to S1608.

[0192] S1601, the Rx of the first control module detects the first link quality between the first device and the second device, and based on the first link quality satisfying the first application condition, the Tx of the first control module sends a first notification message, the first notification message is obtained based on the first AM, and the first notification message is used to indicate the application of the first FEC mode.

[0193] S1602, the Rx of the second control module detects the first link quality between the first device and the second device, and based on the first link quality satisfying the first application condition, the Tx of the second control module sends a second notification message, the second notification message is obtained based on the first AM, and the second notification message is used to indicate the application of the first FEC mode.

[0194] S1603, after the Rx of the second control module receives the first notification message, if it is confirmed to apply the first FEC mode, the Tx of the second control module sends a first response message, the first response message is obtained based on the second AM, and the first response message is used to confirm the application of the first FEC mode.

[0195] S1604, after the Rx of the first control module receives the second notification message, if it is confirmed to apply the first FEC mode, the Tx of the first control module sends a third response message, the third response message is obtained based on the second AM, and the third response message is used to confirm the application of the first FEC mode.

[0196] In the embodiment of the present application, the third response message is generated by the first control module. The way in which the first control module generates the third response message is the same as the way in which the second control module generates the first response message, which will not be repeated here.

[0197] S1605: When the second control module confirms to apply the first FEC mode, notify the second optical module to apply the first FEC mode in the second sending direction.

[0198] S1606: When the first control module receives the first response message, notify the first optical module to apply the first FEC mode in the first receiving direction.

[0199] S1607: When the first control module confirms to apply the first FEC mode, notify the first optical module to apply the first FEC mode in the first sending direction.

[0200] S1608: When the second control module receives the third response message, notify the second optical module to apply the first FEC mode in the second receiving direction.

[0201] Combination Fig.16 As shown in the figure, the request to apply the first FEC mode is initiated by the first control module and the second control module, so the process is called a bidirectional initiation process. Since the application of the first FEC mode in the first receiving direction and the second sending direction is determined based on the first notification message and the first response message, and the application of the first FEC mode in the first sending direction and the second receiving direction is determined based on the second notification message and the third response message, the process is still called a unilateral switching process.

[0202] Fig.17 1 is a schematic diagram of a process of unidirectionally initiating bilateral switching provided by an embodiment of the present application. The first control module and the second control module both support the end-to-end FEC mode and the cascade FEC mode, and the first control module and the second control module start data transmission and reception in the same default FEC mode. Fig.17 As shown, the process includes the following S1701 to S1704.

[0203] S1701, the Rx of the first control module detects the first link quality between the first device and the second device, and based on the first link quality satisfying the first application condition, the Tx of the first control module sends a first notification message, the first notification message is obtained based on the first AM, and the first notification message is used to indicate the application of the first FEC mode.

[0204] S1702, after the Rx of the second control module receives the first notification message, if it is confirmed to apply the first FEC mode, the Tx of the second control module sends a first response message, the first response message is obtained based on the second AM, and the first response message is used to confirm the application of the first FEC mode; if the first FEC mode is refused to be applied, the Tx of the second control module sends a second response message, the second response message is obtained based on the third AM, and the second response message is used to refuse to apply the first FEC mode.

[0205] S1703: When the second control module confirms that the first FEC mode is to be applied, notify the second optical module to apply the first FEC mode in both the second sending direction and the second receiving direction.

[0206] S1704: When the first control module receives the first response message, notify the first optical module to apply the first FEC mode in both the first sending direction and the first receiving direction.

[0207] Combination Fig.17 As shown in the content, the request to apply the first FEC mode is initiated by the first control module, so the process is called a unidirectional initiation process. Since the first FEC mode is applied in the first sending direction, the first receiving direction, the second sending direction and the second receiving direction, the process is called a bilateral switching process.

[0208] Fig.18 : is a schematic diagram of a notification switching process provided by an embodiment of the present application. Among them, the first control module and the second control module both support the end-to-end FEC mode and the cascade FEC mode, and the first control module and the second control module start data transmission and reception in the same default FEC mode. Fig.18 As shown, the process includes the following S1801 to S1803.

[0209] S1801, the Rx of the first control module detects the first link quality between the first device and the second device, and based on the first link quality satisfying the first application condition, the Tx of the first control module sends a first notification message, the first notification message is obtained based on the first AM, and the first notification message is used to indicate the application of the first FEC mode.

[0210] S1802. After the first control module sends the first notification message, it notifies that the first optical module applies the first FEC mode in both the first transmission direction and the first reception direction.

[0211] S1803. After the second control module receives the first notification message, if it confirms to apply the first FEC mode, it notifies that the second optical module applies the first FEC mode in both the second transmission direction and the second reception direction; if it refuses to apply the first FEC mode, the applied FEC mode remains unchanged.

[0212] Combined with Fig.18 As shown in the content, since the first control module can apply the first FEC mode without the second device's response after sending the first notification message, this process is called the notification switching process.

[0213] The embodiment of the present application also provides a forward error correction mode notification device. Fig.19 FIG. is a schematic structural diagram of a forward error correction mode notification device provided by the embodiment of the present application. This device is applied to Figure 2 The first device 201 shown in, based on Fig.19 The multiple modules shown, this device can execute Figure 7 All or part of the operations in the forward error correction mode notification method shown. It should be understood that this device may include more additional modules than the shown modules or omit some of the shown modules, and the embodiment of the present application does not limit this. As Fig.19 shown, this device includes a first control module 1901 and a first optical module 1902. The first optical module 1902 is respectively connected to the first control module 1901 and the second device.

[0214] In some embodiments, the first control module 1901 is used to generate a first notification message, and the first notification message is obtained based on the first AM; the first control module 1901 is further used to send the first notification message to the second device via the first optical module 1902, and notify the second device to apply the first FEC mode through the first notification message.

[0215] In some embodiments, the first control module 1901 is used to monitor the first link quality between the first device and the second device; based on the first link quality meeting the first application condition, generate a first notification message.

[0216] In some embodiments, the first link quality includes at least one of the bit error rate or the frame loss rate.

[0217] In some embodiments, the first control module 1901 is used to obtain configuration information, and the configuration information is used to indicate to apply the first FEC mode; based on the configuration information, generate a first notification message.

[0218] In some embodiments, the first control module 1901 is also used to receive a first response message, the first response message is obtained based on the second AM, the first response message is sent by the second device after receiving the first notification message, and the first response message is used to confirm the application of the first FEC mode; based on the first response message, determine to apply the first FEC mode.

[0219] In some embodiments, the first control module 1901 is also used to receive a second response message, the second response message is obtained based on the third AM, the second response message is sent by the second device after receiving the first notification message, and the second response message is used to refuse to apply the first FEC mode; based on the second response message, it is determined not to apply the first FEC mode.

[0220] In some embodiments, the first control module 1901 is further used to receive a second notification message sent by a second device, where the second notification message is obtained based on the first AM; and based on the second notification message, determine to apply the first FEC mode.

[0221] In some embodiments, the first control module 1901 is also used to monitor the second link quality between the first device and the second device; generate a third notification message based on the second link quality satisfying the second application condition, and the third notification message is obtained based on the fourth AM; send the third notification message to the second device via the first optical module, and notify the second device through the third notification message to apply other FEC modes except the first FEC mode.

[0222] In some embodiments, the first control module 1901 is also used to receive a fourth notification message sent by the second device, the fourth notification message is obtained based on the fourth AM, and the fourth notification message is used to announce the application of other FEC modes except the first FEC mode; when it is determined to apply other FEC modes except the first FEC mode based on the fourth notification message, other FEC modes except the first FEC mode are applied, or the first optical module 1902 is controlled to apply other FEC modes.

[0223] In some embodiments, applying the first FEC mode includes applying the first FEC mode in a first receiving direction, or applying the first FEC mode in both a first sending direction and a first receiving direction, wherein the first receiving direction is a direction in which the first device receives data from the second device, and the first sending direction is a direction in which the first device sends data to the second device.

[0224] In some embodiments, the first optical module 1902 includes an oDSP chip, and the first control module 1901 is further used to send a first switch instruction to the oDSP chip, and the first switch instruction is used to instruct the oDSP chip to implement the first FEC mode by adjusting the FEC encoding function.

[0225] In some embodiments, the first optical module 1902 includes a linear drive pluggable optical module LPO, and the first control module 1901 is further used to regulate the FEC encoding function to implement the application of the first FEC mode.

[0226] In some embodiments, the first AM is also used to identify the PCS channel.

[0227] In some embodiments, the first optical module 1902 is further used to obtain a transmission rate corresponding to the first FEC mode; the first control module 1901 is further used to transmit a signal to the second device via the first optical module according to the transmission rate.

[0228] In some embodiments, the first control module 1901 is configured to send a plurality of first notification messages to the second device via the first optical module 1902 .

[0229] In some embodiments, the first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, where n is an integer not less than 0, and the number of first response messages is at least one.

[0230] In some embodiments, the first control module 1901 is used to adjust the FEC encoding function to apply the first FEC mode based on receiving m first response messages, where m is a positive integer and is less than or equal to the number of first response messages. Alternatively, the first control module 1901 is used to control the first optical module 1902 to adjust the FEC encoding function to apply the first FEC mode based on receiving m first response messages, where m is a positive integer and is less than or equal to the number of first response messages.

[0231] In some embodiments, the first notification message includes an FEC mode field field, the FEC mode field field is determined based on the first AM, the FEC mode field field includes a request field, and the value of the request field is used to request the application of the first FEC mode. Exemplarily, the FEC mode field field is determined based on the UP field of the first AM, or the FEC mode field field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode field field is determined based on a recovery field located after the AM group, wherein the multiple AMs and the AM group include the first AM.

[0232] In some embodiments, the first response message includes an FEC mode field, the FEC mode field field is determined based on the second AM, the FEC mode field field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode. Exemplarily, the FEC mode field field is determined based on the UP field of the second AM, or the FEC mode field field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode field field is determined based on a recovery field located after the AM group, wherein the multiple AMs and the AM group include the second AM.

[0233] In some embodiments, the first control module 1901 includes a PHY chip.

[0234] In the device provided in the embodiment of the present application, by sending a first notification message, the first control module connected to the first optical module can notify the second device of the application of the first FEC mode, so that the notification of the application of the FEC mode can be implemented in the scenario including the optical module. In the case where the first AM is also used to identify the PCS channel, the first AM can be compatible with the AM function specified in the IEEE 802.3 standard. Therefore, in the case where the first notification message includes the first AM and the first AM is used to notify the application of the first FEC mode, there is no need to introduce overhead other than the first AM to notify the application of the FEC mode, the overhead of notifying the application of the FEC mode is low, and there is no need to include information for notifying the application of the FEC mode by deleting certain information, thereby avoiding information loss.

[0235] The embodiment of the present application also provides another forward error correction mode notification device. Fig. 20 is a schematic diagram of the structure of another forward error correction mode notification device provided in an embodiment of the present application. The device is applied to Figure 2 The second control module 202 shown is based on Fig.19 The multiple modules shown in the figure can perform Fig.14 It should be understood that the device may include more additional modules than the modules shown or omit some of the modules shown therein, and the embodiments of the present application are not limited to this. Fig. 20 As shown, the device includes a second control module 2001 and a second optical module 2002, and the second optical module 2002 is connected to the second control module 2001 and the first device respectively.

[0236] The second control module 2001 is used to receive a first notification message from the first device via the second optical module, the first notification message is obtained based on the first AM, and the first notification message is used to announce the application of the first FEC mode; the second control module 2001 is also used to apply the first FEC mode when it is determined to apply the first FEC mode based on the first notification message, or the second control module 2001 is also used to control the second optical module 2002 to apply the first FEC mode when it is determined to apply the first FEC mode based on the first notification message.

[0237] In some embodiments, the second control module 2001 is further used to monitor the quality of the first link between the second device and the first device; based on receiving the first notification message and the first link quality meeting the first application condition, determine to apply the first FEC mode.

[0238] In some embodiments, the first link quality includes at least one of a bit error rate or a frame loss rate.

[0239] In some embodiments, the second control module 2001 is also used to generate a second notification message when the first link quality meets the first application condition, and the second notification message is obtained based on the first AM; send the second notification message to the first device via the second optical module, and notify the first device of the application of the first FEC mode through the second notification message.

[0240] In some embodiments, the second control module 2001 is further used to send a first response message to the first device via the second optical module when it is determined to apply the first FEC mode, the first response message is obtained based on the second AM, and the first response message is used to confirm the application of the first FEC mode.

[0241] In some embodiments, the second control module 2001 is further used to send a second response message to the first device via the second optical module when it is determined that the first FEC mode is not to be applied, the second response message is obtained based on the third AM, and the second response message is used to refuse to apply the first FEC mode.

[0242] In some embodiments, the second control module 2001 is also used to receive a third notification message sent by the first device, the third notification message is obtained based on the fourth AM, and the third notification message is used to announce the application of other FEC modes other than the first FEC mode; when it is determined to apply other FEC modes other than the first FEC mode based on the third notification message, other FEC modes other than the first FEC mode are applied, or the second optical module 2002 is controlled to apply other FEC modes.

[0243] In some embodiments, the second control module 2001 is also used to monitor the second link quality between the second device and the first device; generate a fourth notification message based on the second link quality satisfying the second application condition, and the fourth notification message is obtained based on the fourth AM; send the fourth notification message to the first device via the second optical module, and notify the first device through the fourth notification message of the application of other FEC modes except the first FEC mode.

[0244] In some embodiments, applying the first FEC mode includes applying the first FEC mode in a second sending direction, or applying the first FEC mode in both the second sending direction and the second receiving direction, wherein the second sending direction is the direction in which the second device sends data to the first device, and the second receiving direction is the direction in which the second device receives data from the first device.

[0245] In some embodiments, the second optical module 2002 includes an oDSP chip, and the second control module 2001 is used to send a second switch instruction to the oDSP chip, and the second switch instruction is used to instruct the oDSP chip to adjust the FEC decoding function to implement the first FEC mode.

[0246] In some embodiments, the second optical module 2002 includes an LPO, and the second control module 2001 is used to regulate the FEC decoding function to implement the application of the first FEC mode.

[0247] In some embodiments, the first AM is also used to identify the PCS channel.

[0248] In some embodiments, the second optical module 2002 is further used to obtain the transmission rate corresponding to the first FEC mode; the second control module 2001 is further used to receive a signal from the first device according to the transmission rate via the second optical module.

[0249] In some embodiments, the second control module 2001 is configured to receive a plurality of first notification messages from the first device via the second optical module 2002 .

[0250] In some embodiments, the first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, where n is an integer not less than 0, and the number of first response messages is at least one.

[0251] In some embodiments, the first notification message includes an FEC mode field field, the FEC mode field field is determined based on the first AM, the FEC mode field field includes a request field, and the value of the request field is used to request the application of the first FEC mode. Exemplarily, the FEC mode field field is determined based on the UP field of the first AM, the FEC mode field field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode field field is determined based on a recovery field located after the AM group, wherein the multiple AMs and the AM group include the first AM.

[0252] In some embodiments, the first response message includes an FEC mode field, the FEC mode field field is determined based on the second AM, the FEC mode field field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode. Exemplarily, the FEC mode field field is determined based on the UP field of the second AM, or the FEC mode field field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode field field is determined based on a recovery field located after the AM group, wherein the multiple AMs and the AM group include the second AM.

[0253] In some embodiments, the second control module 2001 includes a PHY chip.

[0254] In the device provided in the embodiment of the present application, based on the first notification message sent by the first device, the second control module connected to the second optical module can be notified by the first device to apply the first FEC mode, so that the notification of applying the FEC mode can be implemented in the scenario including the optical module. In the case where the first AM is also used to identify the PCS channel, the first AM can be compatible with the AM function specified in the IEEE802.3 standard. Therefore, in the case where the first notification message includes the first AM and the first AM is used to notify the application of the first FEC mode, there is no need to introduce overhead other than the first AM to notify the application of the FEC mode, the overhead of notifying the application of the FEC mode is low, and there is no need to include information for notifying the application of the FEC mode by deleting certain information, thereby avoiding information loss.

[0255] See also Fig.21 , Fig.21 The following is a schematic diagram of the structure of a computer system provided in an embodiment of the present application. Fig.21 As shown, the computer system is a computer system 2100. The computer system 2100 may be a network device, a routing device, or a switching device. Fig.21 The computer system 2100 shown is used to execute the above Figure 7 or Fig.14 The operations in the forward error correction mode notification method are shown. The computer system 2100 is, for example, a server, etc. The computer system 2100 can be implemented by a general bus architecture.

[0256] like Fig.21 As shown, the computer system 2100 includes at least one processor 2101 , an optical module 2102 , a memory 2103 , and at least one communication interface 2104 .

[0257] Processor 2101 is a central processing unit (CPU), a digital signal processor (DSP), a network processor (NP), a graphics processing unit (GPU), a neural-network processing unit (NPU), a data processing unit (DPU), a microprocessor or one or more integrated circuits for implementing the method provided in the embodiment of the present application. For example, processor 2101 includes an application-specific integrated circuit (ASIC), a programmable logic device (PLD) or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. PLD is, for example, a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL) or any combination of the above three. Processor 2101 can be a combination of various logic boxes, modules and circuits described in conjunction with the disclosure of the embodiment of the present application, or a combination of computing functions, such as a combination of one or more microprocessors, a combination of DSPs and microprocessors, and the like.

[0258] Optionally, the computer system 2100 further includes a bus. The bus is used to transmit information between components of the computer system 2100. The bus may be a peripheral component interconnect express (PCIe) bus or an extended industry standard architecture (EISA) bus. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Fig.21Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0259] The optical module 2102 may include an oDSP chip or an LPO. The memory 2103 is, for example, a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, or a random access memory (RAM) or other types of dynamic storage devices that can store information and instructions, or an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of an instruction or data structure and can be accessed by a computer, but is not limited thereto. The memory 2103 is, for example, independent and connected to the processor 2101 via a bus. The memory 2103 can also be integrated with the processor 2101.

[0260] The communication interface 2104 uses any transceiver-like device to communicate with other devices or communication networks, and the communication network can be Ethernet, radio access network (RAN) or wireless local area network (WLAN), etc. The communication interface 2104 may include a wired communication interface and may also include a wireless communication interface. Specifically, the communication interface 2104 may be an Ethernet interface, a fast Ethernet (FE) interface, a gigabit Ethernet (GE) interface, an asynchronous transfer mode (ATM) interface, a WLAN interface, a cellular network communication interface or a combination thereof. The Ethernet interface may be an optical interface, an electrical interface or a combination thereof. In an embodiment of the present application, the communication interface 2104 may be used for the computer system 2100 to communicate with other devices.

[0261] In a specific implementation, as an embodiment, the processor 2101 may include one or more CPUs, such as Fig.210 and CPU1 shown in FIG. Each of these processors may be a single-core processor or a multi-core processor. A processor herein may refer to one or more devices, circuits, and / or processing cores for processing data (e.g., computer program instructions).

[0262] In a specific implementation, as an embodiment, the computer system 2100 may include multiple processors, such as Fig.21 2101 and processor 2105 shown in FIG. Each of these processors may be a single-core processor or a multi-core processor. A processor herein may refer to one or more devices, circuits, and / or processing cores for processing data (such as computer program instructions).

[0263] In a specific implementation, as an embodiment, the computer system 2100 may also include an output device and an input device. The output device communicates with the processor 2101 and can display information in a variety of ways. For example, the output device may be a liquid crystal display (LCD), a light emitting diode (LED) display device, a cathode ray tube (CRT) display device, or a projector. The input device communicates with the processor 2101 and can receive user input in a variety of ways. For example, the input device may be a mouse, a keyboard, a touch screen device, or a sensor device.

[0264] In some embodiments, the memory 2103 is used to store program code 2110, and the processor 2101 can execute the program code 2110 stored in the memory 2103. The program code 2110 may include one or more software modules. Optionally, the processor 2101 itself may also store program code or instructions.

[0265] In a specific embodiment, the computer system 2100 of the embodiment of the present application may include the first control module and / or the second control module in the above-mentioned method embodiments, and the first control module and / or the second control module may be implemented by the processor 2101 in the computer system 2100.

[0266] The computer system 2100 may also correspond to the above Fig.19 and Fig. 20 The device shown, Fig.19 The first control module or Fig. 20The second control module in the illustrated device may be implemented by a circuit in the processor 2100 .

[0267] in, Figure 7 or Fig.14 Each step of the forward error correction mode notification method shown is completed by a hardware integrated logic circuit in the processor of the computer system 2100. The steps of the method disclosed in the embodiment of the present application can be directly embodied as being executed by a hardware processor.

[0268] Fig. 22 is a schematic diagram of the structure of another computer system provided in an embodiment of the present application, the computer system is used to execute the above Figure 7 or Fig.14 The operations in the forward error correction mode notification method shown. Exemplarily, the computer system is a switch, and the switch may have relatively large differences due to different configurations or performances. The computer system may include one or more processors 2201, and the one or more processors 2201 are used to implement the first control module and / or the second control module in the method embodiment. The computer system also includes an optical module 2202, and the optical module 2202 is used to implement the first optical module and / or the second optical module in the method embodiment. Fig. 22 As shown, the computer system may further include one or more memories 2203, wherein at least one computer program is stored in the one or more memories 2203, and the at least one computer program is loaded and executed by one or more processors 2201. Exemplarily, the processor 2201 is a CPU. Of course, the computer system may also have components such as a wired or wireless network interface, a keyboard, and an input and output interface for input and output, and the computer system may also include other components for realizing device functions, which will not be described in detail here.

[0269] The present application also provides a communication device, which includes: a transceiver module for executing Figure 7 The receiving and / or sending related operations in the forward error correction mode notification method shown in the figure; the processing module is used to perform Figure 7 The forward error correction mode notification method shown in the figure has other operations other than the operations related to receiving and / or sending. The embodiment of the present application also provides another communication device, which includes: a transceiver module, which is used to perform Fig.14 The receiving and / or sending related operations in the forward error correction mode notification method shown in the figure; the processing module is used to perform Fig.14 Other operations in the forward error correction mode notification method shown except for the receiving and / or sending related operations.

[0270] The present application embodiment provides a chip, which includes: an interface module, the interface module is used to execute Figure 7 or Fig.14The embodiment of the present application also provides another chip, which includes a processor, and the processor is used to call and execute instructions stored in the memory from the memory, so that the communication device equipped with the chip executes Figure 7 or Fig.14 The forward error correction mode notification method shown. Exemplarily, the chip also includes: an input interface, an output interface and a memory, the input interface, the output interface, the processor and the memory are connected through an internal connection path, and the memory contains the above-mentioned program instructions or codes.

[0271] The embodiment of the present application also provides an electronic device, comprising: a processor, the processor is coupled to a memory, the memory stores at least one program instruction or code, the at least one program instruction or code is loaded and executed by the processor, so that the electronic device can realize Figure 7 or Fig.14 The forward error correction mode notification method shown.

[0272] The embodiment of the present application also provides a communication system, the communication system includes a first device and a second device, the first device includes a first control module and a first optical module, the second device includes a second control module and a second optical module, the first optical module is connected to the first control module and the second optical module respectively, and the second optical module is also connected to the second control module; the first control module is used to execute Figure 7 The forward error correction mode notification method shown, the second control module is used to execute Fig.14 The forward error correction mode notification method shown.

[0273] An embodiment of the present application also provides a computer-readable storage medium, in which at least one program instruction or code is stored. When the program instruction or code is loaded and executed by a processor of a computer, the computer implements the forward error correction mode notification method in the method embodiment.

[0274] An embodiment of the present application further provides a computer program or a computer program product, wherein the computer program or the computer program product comprises: a computer program code, and when the computer program code is executed by a computer, the computer executes the forward error correction mode notification method in the method embodiment.

[0275] It should be understood that the processor may be a CPU, or other general-purpose processors, DSPs, ASICs, FPGAs or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. It is worth noting that the processor may be a processor supporting an advanced RISC machines (ARM) architecture.

[0276] Further, in an optional embodiment, if one or more of the above-mentioned computer system, communication device, chip or communication system also includes a memory, the memory may include a read-only memory and a random access memory, and provide instructions and data to the processor. The memory may also include a non-volatile random access memory. For example, the memory may also store information about the device type.

[0277] The memory may be a volatile memory or a nonvolatile memory, or may include both volatile and nonvolatile memory. Among them, the nonvolatile memory may be a ROM, a programmable read-only memory (programmable ROM, PROM), an erasable programmable read-only memory (erasable PROM, EPROM), an electrically erasable programmable read-only memory (electrically EPROM, EEPROM) or a flash memory. The volatile memory may be a RAM, which is used as an external cache. By way of example but not limitation, many forms of RAM are available. For example, static random access memory (static RAM, SRAM), dynamic random access memory (dynamic random access memory, DRAM), synchronous dynamic random access memory (synchronous DRAM, SDRAM), double data rate synchronous dynamic random access memory (double data rate SDRAM, DDR SDRAM), enhanced synchronous dynamic random access memory (enhanced SDRAM, ESDRAM), synchronous connection dynamic random access memory (synchlink DRAM, SLDRAM) and direct memory bus random access memory (direct rambus RAM, DR RAM).

[0278] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program or a computer program product. A computer program or a computer program product includes one or more computer instructions. When loading and executing a computer program instruction on a computer, a process or function according to the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. Computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, a computer instruction can be transmitted from a website site, a computer, a server or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. A computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server, a data center, etc. that contains one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital video disc (DVD)), or a semiconductor medium (eg, a solid state disk (SSD)).

[0279] In order to clearly illustrate the interchangeability of hardware and software, the steps and components of each embodiment have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. A person of ordinary skill in the art may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0280] The computer program code for realizing the method for the embodiment of the present application can be written in one or more programming languages. These computer program codes can be provided to the processor of the storage device of general-purpose computer, special-purpose computer or other programmable annotation content, so that the program code, when being executed by the storage device of computer or other programmable annotation content, causes the function / operation specified in the flow chart and / or block diagram to be implemented. The program code can be executed completely on the computer, partially on the computer, as an independent software package, partially on the computer and partially on the remote computer or completely on the remote computer or server.

[0281] In the context of the embodiments of the present application, computer program codes or related data may be carried by any appropriate carrier to enable a device, apparatus or processor to perform the various processes and operations described above. Examples of carriers include signals, computer readable media, etc. Examples of signals may include electrical, optical, radio, acoustic or other forms of propagation signals, such as carrier waves, infrared signals, etc.

[0282] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and modules described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0283] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the module is only a logical function division. There may be other division methods in actual implementation, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or modules, or it can be an electrical, mechanical or other form of connection.

[0284] The modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical modules, that is, they may be located in one place or distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the embodiments of the present application.

[0285] In addition, each functional module in each embodiment of the present application can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The above integrated modules can be implemented in the form of hardware or software functional modules.

[0286] In this application, the terms "first", "second", etc. are used to distinguish between identical or similar items with substantially the same effects and functions. It should be understood that there is no logical or temporal dependency between "first", "second", and "nth", nor is the quantity and execution order limited. It should also be understood that although the following description uses the terms first, second, etc. to describe various elements, these elements should not be limited by the terms. These terms are only used to distinguish one element from another. For example, without departing from the scope of various examples, the first device can be referred to as the second device, and similarly, the second device can be referred to as the first device.

[0287] It should also be understood that in the various embodiments of the present application, the size of the serial number of each process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0288] The term "at least one" in this application means one or more, and the term "multiple" in this application means two or more, for example, multiple first AMs means two or more first AMs. The terms "system" and "network" are often used interchangeably herein.

[0289] It should be understood that the terms used in the description of various examples herein are only for describing specific examples and are not intended to be limiting. As used in the description of various examples and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.

[0290] It should also be understood that the term “comprise” (also known as “includes,” “including,” “comprises” and / or “comprising”) when used in this specification specifies the presence of stated features, integers, steps, operations, elements, and / or components, but does not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof.

[0291] It should also be understood that, depending on the context, the phrase “if it is determined that…” or “if [stated condition or event] is detected” may be interpreted to mean “upon determining that…” or “in response to determining that…” or “upon detecting [stated condition or event]” or “in response to detecting [stated condition or event]”.

[0292] It should be understood that determining B based on A does not mean determining B only based on A. B can also be determined based on A and / or other information.

[0293] It should also be understood that the references to "one embodiment", "an embodiment", or "a possible implementation" throughout the specification mean that specific features, structures, or characteristics related to the embodiment or implementation are included in at least one embodiment of the present application. Therefore, the references to "in one embodiment" or "in an embodiment", or "a possible implementation" throughout the specification do not necessarily refer to the same embodiment. In addition, these specific features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.

[0294] The above description is only an optional embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present application should be included in the protection scope of the present application.

Claims

1. A forward error correction mode notification method, It is characterized in that The method is applied to a first control module included in a first device, the first device also includes a first optical module, the first optical module is connected to the first control module and the second device respectively, and the method includes: The first control module generates a first notification message, where the first notification message is obtained based on the first alignment mark AM; The first control module sends the first notification message to the second device via the first optical module, and notifies the second device of applying a first forward error correction FEC mode through the first notification message.

2. The method according to claim 1, It is characterized in that The first control module generates a first notification message, including: The first control module monitors a first link quality between the first device and the second device; Based on the first link quality satisfying a first application condition, the first control module generates the first notification message.

3. The method according to claim 2, It is characterized in that The first link quality includes at least one of a bit error rate or a frame loss rate.

4. The method according to claim 1, It is characterized in that The first control module generates a first notification message, including: The first control module acquires configuration information, where the configuration information is used to indicate application of the first FEC mode; Based on the configuration information, the first control module generates the first notification message.

5. The method according to any one of claims 1 to 4, It is characterized in that After the first control module sends the first notification message to the second device via the first optical module, the method further includes: The first control module receives a first response message, the first response message is obtained based on the second AM, the first response message is sent by the second device after receiving the first notification message, and the first response message is used to confirm the application of the first FEC mode; Based on the first response message, the first control module determines to apply the first FEC mode.

6. The method according to any one of claims 1 to 4, It is characterized in that After the first control module sends the first notification message to the second device via the first optical module, the method further includes: The first control module receives a second response message, the second response message is obtained based on the third AM, the second response message is sent by the second device after receiving the first notification message, and the second response message is used to refuse to apply the first FEC mode; Based on the second response message, the first control module determines not to apply the first FEC mode.

7. The method according to any one of claims 1 to 4, It is characterized in that The method further comprises: The first control module receives a second notification message sent by the second device, where the second notification message is obtained based on the first AM, and the second notification message is used to notify application of the first FEC mode; Based on the second notification message, the first control module determines to apply the first FEC mode.

8. The method according to any one of claims 1 to 5 and 7, It is characterized in that After the first control module sends the first notification message to the second device via the first optical module, the method further includes: The first control module monitors a second link quality between the first device and the second device; Based on the second link quality satisfying the second application condition, the first control module generates a third notification message, where the third notification message is obtained based on the fourth AM; The first control module sends the third notification message to the second device via the first optical module, and notifies the second device through the third notification message of applying other FEC modes except the first FEC mode.

9. The method according to any one of claims 1 to 5 and 7, It is characterized in that After the first control module sends the first notification message to the second device via the first optical module, the method further includes: The first control module receives a fourth notification message sent by the second device, the fourth notification message is obtained based on a fourth AM, and the fourth notification message is used to notify the application of other FEC modes except the first FEC mode; In a case where it is determined based on the fourth notification message to apply another FEC mode except the first FEC mode, the other FEC mode except the first FEC mode is applied.

10. The method according to any one of claims 1 to 9, It is characterized in that Applying the first FEC mode includes applying the first FEC mode in a first receiving direction, or applying the first FEC mode in a first sending direction and in the first receiving direction, wherein the first receiving direction is a direction in which the first device receives data from the second device, and the first sending direction is a direction in which the first device sends data to the second device.

11. The method according to any one of claims 1 to 5, 7 to 10, It is characterized in that The first optical module includes an optical digital signal processor oDSP chip, and the method further includes: The first control module sends a first switch instruction to the oDSP chip, where the first switch instruction is used to instruct the oDSP chip to implement the first FEC mode by adjusting the FEC encoding function.

12. The method according to any one of claims 1 to 5, 7 to 10, It is characterized in that The first optical module includes a linear drive pluggable optical module LPO, and the method further includes: The first control module regulates the FEC encoding function to implement the application of the first FEC mode.

13. The method according to any one of claims 1 to 12, It is characterized in that The first AM is also used to identify a physical coding sublayer PCS channel.

14. The method according to any one of claims 1 to 13, It is characterized in that The method further comprises: The first optical module acquires a transmission rate corresponding to the first FEC mode; The first control module transmits a signal to the second device via the first optical module at the transmission rate.

15. The method according to any one of claims 1 to 14, It is characterized in that The first control module sending the first notification message to the second device via the first optical module includes: The first control module sends a plurality of the first notification messages to the second device via the first optical module.

16. The method according to claim 5, It is characterized in that The first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, where n is an integer not less than 0, and the number of the first response message is at least one.

17. The method according to claim 16, It is characterized in that The method further comprises: Based on receiving m first response messages, the FEC encoding function is adjusted to apply the first FEC mode, where m is a positive integer and is less than or equal to the number of the first response messages.

18. The method according to any one of claims 1 to 17, It is characterized in that The first notification message includes an FEC mode domain field, the FEC mode domain field is determined based on the first AM, the FEC mode domain field includes a request field, and a value of the request field is used to request application of the first FEC mode.

19. The method according to claim 18, It is characterized in that The FEC mode domain field is determined based on a unique padding UP field of the first AM, or the FEC mode domain field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on a recovery field located after an AM group, wherein the multiple AMs and the AM group include the first AM.

20. The method according to any one of claims 5, 16 and 17, It is characterized in that The first response message includes an FEC mode domain field, the FEC mode domain field is determined based on the second AM, the FEC mode domain field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode.

21. The method according to claim 20, It is characterized in that The FEC mode domain field is determined based on the unique padding UP field of the second AM, or the FEC mode domain field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on a recovery field located after an AM group, wherein the multiple AMs and the AM group include the second AM.

22. The method according to any one of claims 1 to 21, It is characterized in that The first control module includes a physical layer PHY chip.

23. A forward error correction mode notification method, It is characterized in that The method is applied to a second control module included in a second device, the second device also includes a second optical module, the second optical module is connected to the second control module and the first device respectively, and the method includes: The second control module receives a first notification message from the first device via the second optical module, where the first notification message is obtained based on a first alignment marker AM, and the first notification message is used to notify application of a first forward error correction FEC mode; In a case where it is determined based on the first notification message to apply the first FEC mode, the first FEC mode is applied.

24. The method according to claim 23, It is characterized in that In the case where it is determined based on the first notification message to apply the first FEC mode, before applying the first FEC mode, the method further includes: The second control module monitors a first link quality between the second device and the first device; Based on receiving the first notification message and the first link quality meeting a first application condition, the second control module determines to apply the first FEC mode.

25. The method according to claim 24, It is characterized in that The first link quality includes at least one of a bit error rate or a frame loss rate.

26. The method according to any one of claims 23 to 25, It is characterized in that The method further comprises: When the first link quality meets the first application condition, the second control module generates a second notification message, where the second notification message is obtained based on the first AM; The second control module sends the second notification message to the first device via the second optical module, and notifies the first device of applying the first FEC mode through the second notification message.

27. The method according to any one of claims 23 to 25, It is characterized in that The method further comprises: In the case of determining to apply the first FEC mode, the second control module sends a first response message to the first device via the second optical module, the first response message is obtained based on the second AM, and the first response message is used to confirm the application of the first FEC mode.

28. The method according to any one of claims 23 to 25, It is characterized in that The method further comprises: When it is determined that the first FEC mode is not to be applied, the second control module sends a second response message to the first device via the second optical module, where the second response message is obtained based on the third AM and is used to refuse to apply the first FEC mode.

29. The method according to any one of claims 23 to 28, It is characterized in that After applying the first FEC mode, the method further includes: The second control module receives a third notification message sent by the first device, where the third notification message is obtained based on the fourth AM, and the third notification message is used to notify the application of other FEC modes except the first FEC mode; In a case where it is determined based on the third notification message that another FEC mode other than the first FEC mode is to be applied, the other FEC mode other than the first FEC mode is applied.

30. The method according to any one of claims 23 to 28, It is characterized in that After applying the first FEC mode, the method further includes: The second control module monitors a second link quality between the second device and the first device; Based on the second link quality satisfying the second application condition, the second control module generates a fourth notification message, where the fourth notification message is obtained based on the fourth AM; The second control module sends the fourth notification message to the first device via the second optical module, and notifies the first device of applying other FEC modes except the first FEC mode through the fourth notification message.

31. The method according to any one of claims 23 to 30, It is characterized in that Applying the first FEC mode includes applying the first FEC mode in a second sending direction, or applying the first FEC mode in both the second sending direction and the second receiving direction, wherein the second sending direction is the direction in which the second device sends data to the first device, and the second receiving direction is the direction in which the second device receives data from the first device.

32. A method according to any one of claims 23 to 31, It is characterized in that The second optical module includes an optical digital signal processor oDSP chip, and the applying the first FEC mode includes: The second control module sends a second switch instruction to the oDSP chip, where the second switch instruction is used to instruct the oDSP chip to implement the first FEC mode by adjusting the FEC decoding function.

33. A method according to any one of claims 23 to 31, It is characterized in that The second optical module includes a linear drive pluggable optical module LPO, and the applying of the first FEC mode includes: The second control module regulates the FEC decoding function to implement the application of the first FEC mode.

34. The method according to any one of claims 23 to 33, It is characterized in that The first AM is also used to identify a physical coding sublayer PCS channel.

35. The method according to any one of claims 23 to 34, It is characterized in that The method further comprises: The second optical module acquires a transmission rate corresponding to the first FEC mode; The second control module receives a signal from the first device at the transmission rate via the second optical module.

36. The method according to any one of claims 23 to 35, It is characterized in that The second control module receives a first notification message from the first device via the second optical module, including: The second control module receives a plurality of the first announcement messages from the first device via the second optical module.

37. The method according to claim 27, It is characterized in that The first response message is sent by the second device after receiving the first notification message and sending n AMs to the first device, where n is an integer not less than 0, and the number of the first response message is at least one.

38. The method according to any one of claims 23 to 37, It is characterized in that The first notification message includes an FEC mode domain field, the FEC mode domain field is determined based on the first AM, the FEC mode domain field includes a request field, and a value of the request field is used to request application of the first FEC mode.

39. The method according to claim 38, It is characterized in that The FEC mode domain field is determined based on a unique padding UP field of the first AM, or the FEC mode domain field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on a recovery field located after an AM group, wherein the multiple AMs and the AM group include the first AM.

40. The method according to claim 27 or 37, It is characterized in that The first response message includes an FEC mode domain field, the FEC mode domain field is determined based on the second AM, the FEC mode domain field includes an answer field, and the value of the answer field is used to confirm the application of the first FEC mode.

41. The method according to claim 40, It is characterized in that The FEC mode domain field is determined based on a unique padding UP field of the second AM, or the FEC mode domain field is determined based on a padding field used to form a 257-bit code block with multiple AMs, or the FEC mode domain field is determined based on a recovery field located after an AM group, wherein the multiple AMs and the AM group include the second AM.

42. The method according to any one of claims 23 to 41, It is characterized in that The second control module includes a physical layer PHY chip.

43. A forward error correction mode notification device, It is characterized in that The device is applied to a first control module included in a first device, the first device also includes a first optical module, the first optical module is connected to the first control module and the second device respectively, and the device includes: A transceiver module, used to perform operations related to receiving and / or sending in any of the methods described in claims 1-22; A processing module, used to perform other operations in the method described in any one of claims 1-22 except for operations related to receiving and / or sending.

44. A forward error correction mode notification device, It is characterized in that The device is applied to a second control module included in a second device, the second device also includes a second optical module, the second optical module is connected to the second control module and the first device respectively, and the device includes: A transceiver module, used to perform the operations related to receiving and / or sending in any of the methods described in claims 23-42; A processing module, used to perform other operations in the method described in any one of claims 23-42 except for operations related to receiving and / or sending.

45. A chip, It is characterized in that The chip includes: an interface module, and the interface module is used to execute the forward error correction mode notification method as described in any one of claims 1-42.

46. ​​A chip, It is characterized in that The chip includes a processor, which is used to call and execute instructions stored in the memory from the memory, so that a communication device equipped with the chip executes the forward error correction mode notification method as described in any one of claims 1-42.

47. An electronic device, It is characterized in that The electronic device includes: a processor, the processor is coupled to a memory, the memory stores at least one program instruction or code, and the at least one program instruction or code is loaded and executed by the processor so that the electronic device implements the forward error correction mode notification method as described in any one of claims 1-42.

48. A communication system, It is characterized in that The system includes a first device and a second device, the first device includes a first control module and a first optical module, the second device includes a second control module and a second optical module, the first optical module is connected to the first control module and the second optical module respectively, the second optical module is also connected to the second control module, the first control module is used to execute the forward error correction mode notification method as described in any one of claims 1-22, and the second control module is used to execute the forward error correction mode notification method as described in any one of claims 23-42.

49. A computer readable storage medium, It is characterized in that The computer-readable storage medium stores at least one program instruction or code, and when the program instruction or code is loaded and executed by the computer's processor, the computer implements the forward error correction mode notification method as described in any one of claims 1-42.