Communication method, apparatus, and system

By isolating faulty channels and using non-faulty channels to send data in the communication system, the problem of low utilization of high-speed port resources is solved, and high efficiency and reliability of data transmission are achieved.

WO2026158224A1PCT designated stage Publication Date: 2026-07-30HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
HUAWEI TECH CO LTD
Filing Date
2026-01-19
Publication Date
2026-07-30

AI Technical Summary

Technical Problem

The resource utilization rate of high-speed ports is low and urgently needs to be improved.

Method used

After receiving a notification message, the first device isolates the faulty channel and continues to send data using the non-faulty channel. This includes determining the channel fault using methods such as remote defect indication messages, alignment flags, and forward error correction codewords, and then sending data through the non-faulty channel.

Benefits of technology

Even in the event of a channel failure, data can still be effectively transmitted using the non-faulty channels, improving port resource utilization and ensuring the continuity and quality of data transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2026073418_30072026_PF_FP_ABST
    Figure CN2026073418_30072026_PF_FP_ABST
Patent Text Reader

Abstract

The present application provides a communication system, comprising a first apparatus and a second apparatus, wherein the first apparatus comprises a first port, the second apparatus comprises a second port, a plurality of lanes are provided between the first port and the second port, the plurality of lanes are all lanes via which the first apparatus sends data to the second apparatus, and the plurality of lanes include a first lane. The first apparatus receives a notification message indicating that a fault has occurred in the first lane. In response to receiving the notification message, the first apparatus isolates the first lane, and sends data to the second apparatus via a non-faulty lane among the plurality of lanes. Accordingly, when the first apparatus isolates the first lane, the second apparatus receives, via the non-faulty lane among the plurality of lanes, the data sent by the first apparatus. By using the communication system provided by the present application, the resource utilization rate of the first port can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

A communication method, apparatus and system

[0001] This application claims priority to Chinese Patent Application No. 2025101238922, filed with the State Intellectual Property Office of China on January 24, 2025, entitled "A Communication Method and Apparatus", the entire contents of which are incorporated herein by reference. Technical Field

[0002] This application relates to the field of communications, and in particular to a communication method, apparatus and system. Background Technology

[0003] With the development of communication and computer technologies, the amount of data transmitted over networks is increasing. To meet the growing demand for data transmission over networks, the communication speeds provided by networks are also increasing. As an example, network devices may include high-speed ports, which, as mentioned herein, may be the high-speed port defined by the Institute of Electrical and Electronics Engineers (IEEE) standard 802.3. A "high-speed port" may be referred to as a "high-speed Ethernet port," "Ethernet high-speed port," "high-speed Ethernet interface," or "Ethernet high-speed interface," and these terms may be used interchangeably in this application.

[0004] Currently, the resource utilization rate of high-speed ports is low. Therefore, a solution is urgently needed to address the above problems. Summary of the Invention

[0005] This application provides a communication method that can improve the resource utilization of high-speed ports.

[0006] Firstly, this application provides a communication system including a first device and a second device. The first device includes a first port, and the second device includes a second port. Multiple channels (lanes) are connected between the first and second ports, meaning the first port is interconnected with the second port through multiple channels. These multiple channels are channels through which the first device sends data to the second device. The multiple channels include a first channel, which may be any one of the multiple channels. In this application, the first device can receive a notification message indicating a failure in the first channel. After receiving the notification message, the first device does not directly determine that the first port is faulty and stop sending data to the second device through the first port. Instead, in response to receiving the notification message, it isolates the first channel and sends data to the second device through a non-faulty channel among the multiple channels. Correspondingly, after the first device isolates the first channel, the second device receives the data sent by the first device through a non-faulty channel among the aforementioned multiple channels. Therefore, using the communication system provided by this application, even in the event of a first channel failure, the first device can still send data to the second device using the non-faulty channel between the first and second ports, instead of ceasing to send data through the first port, thereby improving the resource utilization of the first port.

[0007] In one possible implementation, the notification message includes a remote defect indication (RDI) message, which includes first indication information indicating a first channel failure. Accordingly, the first device can receive and parse the RDI message to obtain the first indication information, thereby determining a first channel failure. This facilitates subsequent implementation of fault channel management measures for the first channel, improving the resource utilization of the first port.

[0008] In one possible implementation, the RDI message can be a Layer 2 message. The RDI message includes a channel status field, which carries the first indication information. As an example, the channel status field may include multiple bits, which are indication bits corresponding to the aforementioned multiple channels, with one indication bit per channel. For any given channel, the indication bit indicates whether the channel is faulty. Accordingly, the first device can determine the status of the first channel based on the channel status field in the RDI message, thereby determining that the first channel is faulty, so as to facilitate subsequent implementation of fault channel management measures for the first channel to improve the resource utilization of the first port.

[0009] In one possible implementation, the notification message includes a first alignment marker (AM), which includes second indication information used to indicate a first channel failure. Accordingly, the first device can receive and parse the first AM to obtain the second indication information, thereby determining a first channel failure. This facilitates subsequent implementation of fault channel management measures for the first channel, improving the resource utilization of the first port.

[0010] In one possible implementation, the first AM includes an idle domain segment for carrying the second indication information. Accordingly, the first device can determine a first channel fault based on the idle domain segment in the first AM, so as to facilitate subsequent implementation of fault channel management measures for the first channel to improve the resource utilization of the first port.

[0011] In one possible implementation, the second device can determine a first channel fault if M consecutive forward error correction (FEC) codewords received through the first channel are not correctable, where M is an integer greater than or equal to 2. This approach improves the efficiency of determining first channel faults.

[0012] In one possible implementation, the first device isolates the first channel and sends data to the second device through a non-faulty channel among the plurality of channels. Specifically, at least one first alignment information can be sent to the second device through the non-faulty channel, and this first alignment information is used by the second device to align the non-faulty channel. If the second device aligns the non-faulty channel, it means that the second device can correctly receive the data sent by the first device through the non-faulty channel. Accordingly, after sending the at least one first alignment information to the second device, the first device sends data to the second device through the non-faulty channel. The first alignment information may include a second AM or a first rapid alignment marker (RAM). When the first alignment information includes the first RAM, the second device is more efficient at aligning the non-faulty channel compared to when the first alignment information includes the second AM.

[0013] In one possible implementation, the second device can receive at least one first alignment information sent by the first device through a non-faulty channel among the plurality of channels, and align the non-faulty channel according to the at least one alignment information, so as to facilitate subsequent reception of data sent by the first device based on the non-faulty channel.

[0014] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1. The second device aligns the non-faulty channel according to the at least one alignment information. In a specific implementation, the N channels can be aligned according to the at least one alignment information. Aligning the N channels refers to aligning multiple virtual channels (e.g., PCSLs) corresponding to the non-faulty channel, so that the multiple PCSLs can be correctly aligned in the subsequent data reception stage, thereby recovering the data sent by the first device based on the data carried by the multiple PCSLs. In one example, after receiving the first alignment information, the second device can lock the first alignment information on the multiple PCSLs corresponding to the aforementioned non-faulty channel, and align the multiple PCSLs corresponding to the non-faulty channel based on the locked first alignment information.

[0015] In one possible implementation, considering that a failure in the first channel might cause data (e.g., service streams) originally transmitted through the first channel to fail, the data sent by the first device to the second device through the non-faulty channel could include data that failed to transmit due to the failure of the first channel. In other words, after isolating the first channel, the first device can retransmit the data that failed to transmit due to the failure of the first channel using the non-faulty channel. In this way, when the data that failed to transmit due to the failure of the first channel is service data, lossless service retransmission can be achieved, ensuring the quality of service provided to the service.

[0016] In one possible implementation, to ensure resource utilization of the first port, the first device can also detect the status of the first channel. This allows for timely utilization of the first channel's bandwidth resources, improving data transmission efficiency, once the first channel's fault has been resolved (i.e., the first channel is no longer faulty). As a specific example, the first device can send first data to the second device through the first channel, which is used to detect the first channel. Correspondingly, the second device can receive the first data sent by the first device through the first channel and use it to detect the first channel. The second device can also send a first response to the first device in response to the first channel passing the detection. This first response indicates that the first channel has passed the detection, meaning it is fault-free. The first device can then receive the first response from the second device. In this way, the first device can determine that the first channel is no longer faulty based on the first response, allowing it to continue using the first channel to transmit data to the second device, thus improving data transmission efficiency.

[0017] In one possible implementation, the first data may include a specific code block and a third AM. The first data including the specific code block and the third AM can be understood as the first data including multiple third AMs and multiple specific code blocks, with the data between adjacent third AMs constituting the specific code block. In this scenario, the specific code block is sent to the second device after FEC encoding by the first device. The second device, for the data received through the first channel, can first lock the third AM, and then perform FEC decoding on the data between the third AMs (i.e., the data obtained by FEC encoding the specific code block), and determine the error rate of the specific code block. Further, based on the error rate of the specific code block, the detection result of the first channel is determined. As an example, if the error rate of the specific code block is low, the first channel can be determined to have passed the detection; conversely, if the error rate of the specific code block is high, the first channel can be determined to have failed the detection. Passing the first channel indicates that the first channel is fault-free, while failing the first channel indicates that the first channel has a fault.

[0018] In one possible implementation, the first data may include a specific code block and a second RAM. The first data including the specific code block and the second RAM can be understood as the first data comprising multiple second RAMs and multiple specific code blocks, with the data between adjacent second RAMs constituting the specific code block. In this scenario, the specific code block is sent to the second device after FEC encoding by the first device. The second device, for the data received through the first channel, can first lock the second RAM, and then perform FEC decoding on the data between the second RAMs (i.e., the data obtained by FEC encoding the specific code block), and determine the error rate of the specific code block. Furthermore, based on the error rate of the specific code block, the detection result of the first channel is determined. For example, if the error rate of the specific code block is low, the first channel is determined to have passed the detection; if the error rate of the specific code block is high, the first channel is determined to have failed the detection. Because the RAM locking period is short, this method enables the second device to efficiently complete the detection of the first channel.

[0019] In one possible implementation, after receiving the first response, the first device can, in response to receiving the first response, perform channel isolation release measures on the first channel and send data to the second device through the non-faulty channel and the first channel, thereby improving the efficiency of the first device sending data to the second device. Correspondingly, the second device can receive the data sent by the first device through the non-faulty channel and the first channel after the first device performs channel isolation release measures on the first channel.

[0020] In one possible implementation, the first device performs channel isolation release measures on the first channel to send data to the second device through the non-faulty channel and the first channel. Specifically, at least one second alignment information can be sent to the second device through the non-faulty channel and the first channel. This second alignment information includes a fourth AM or a third RAM. The at least one second alignment information is used by the second device to align the first channel and the non-faulty channel. After sending the at least one second alignment information to the second device, data is sent to the second device through the non-faulty channel and the first channel.

[0021] In one possible implementation, the second device can receive at least one second alignment information sent by the first device through the non-faulty channel and the first channel. Furthermore, based on the at least one second alignment information, the first channel and the non-faulty channel are aligned, thereby enabling the second device to correctly receive data sent by the first device based on both the first channel and the non-faulty channel. In other words, after aligning the first channel and the non-faulty channel, the second device receives data sent by the first device through both the non-faulty channel and the first channel.

[0022] In one possible implementation, the second alignment information is used by the second device to align the non-faulty channel and the first channel. For ease of description, the "non-faulty channel and the first channel" are referred to as the "channels to be worked." Aligning the channels to be worked refers to aligning the multiple PCSLs corresponding to the channels to be worked. In one example, the non-faulty channels may include N channels, and the channels to be worked include N+1 channels. The second alignment information is used to align the N+1 channels included in the channels to be worked. Assuming one channel corresponds to b PCSLs, the second alignment information is used by the second device to align the b*(N+1) PCSLs corresponding to these N+1 channels. After receiving the second alignment information, the second device can lock the second alignment information on the multiple PCSLs corresponding to the aforementioned channels to be worked, and align the multiple PCSLs corresponding to the channels to be worked based on the locked second alignment information.

[0023] In one possible implementation, before sending at least one second alignment message to the second device, the first device may send a third indication message to the second device via the non-faulty channel. This third indication message instructs the second device to align the first channel and the non-faulty channel. Correspondingly, the second device can receive the third indication message sent by the first device via the non-faulty channel, and after receiving the third indication message, further receive at least one second alignment message sent by the first device via both the first and non-faulty channels, so as to subsequently use the second alignment information to align the non-faulty channel and the first channel.

[0024] In one possible implementation, before sending the first data to the second device through the first channel, the first device may also send a fourth indication message to the second device through a non-faulty channel. This fourth indication message instructs the second device to detect the first channel. Correspondingly, the second device can receive this fourth indication message through the non-faulty channel. Furthermore, after receiving the fourth indication message, the second device can continue to receive the aforementioned first data through the first channel, so as to facilitate subsequent detection of the first channel based on the first data.

[0025] Secondly, this application provides a communication method applied to a first device, which includes a first port, and a second device, which includes a second port. Multiple channels are connected between the first and second ports. These multiple channels are channels through which the first device sends data to the second device. The multiple channels include a first channel, which may be any one of the multiple channels. The first device can receive a notification message indicating a failure of the first channel. Upon receiving the notification message, the first device does not directly determine that the first port is faulty and cease sending data to the second device through the first port. Instead, in response to receiving the notification message, it isolates the first channel to send data to the second device through a non-faulty channel among the multiple channels. Therefore, using this solution, even in the event of a first channel failure, the first device can still send data to the second device using the non-faulty channel between the first and second ports, instead of ceasing to send data through the first port, thereby improving the resource utilization of the first port.

[0026] In one possible implementation, receiving the notification message includes: receiving the notification message sent by the second device, the notification message including a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM), wherein the RDI message carries first indication information, the first AM carries second indication information, and both the first indication information and the second indication information are used to indicate a fault in the first channel.

[0027] In one possible implementation, the RDI message includes a channel status field, which carries the first indication information.

[0028] In one possible implementation, the idle pad domain segment of the first AM carries the second indication information.

[0029] In one possible implementation, isolating the first channel and sending data to the second device through a non-faulty channel among the plurality of channels includes: sending at least one first alignment information to the second device through the non-faulty channel, the first alignment information including a second AM or a first fast alignment mark RAM, the at least one first alignment information being used by the second device to align the non-faulty channel; and after sending the at least one first alignment information to the second device, sending data to the second device through the non-faulty channel.

[0030] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

[0031] In one possible implementation, sending data to the second device via the non-faulty channel includes: retransmitting data that failed to be transmitted due to a fault in the first channel to the second device via the non-faulty channel.

[0032] In one possible implementation, the method further includes: sending first data to a second device through the first channel, the first data being used to detect the first channel; receiving a first response sent by the second device, the first response being used to indicate that the first channel has passed the detection, and the first channel passing the detection indicating that the first channel is fault-free.

[0033] In one possible implementation, the first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

[0034] In one possible implementation, the method further includes: in response to receiving the first response, performing channel isolation release measures on the first channel, and sending data to the second device through the non-faulty channel and the first channel.

[0035] In one possible implementation, the step of performing channel isolation release measures on the first channel and sending data to the second device through the non-faulty channel and the first channel includes: sending at least one second alignment information to the second device through the non-faulty channel and the first channel, the second alignment information including a fourth AM or a third RAM, the at least one second alignment information being used by the second device to align the first channel and the non-faulty channel; and after sending the at least one second alignment information to the second device, sending data to the second device through the non-faulty channel and the first channel.

[0036] In one possible implementation, the non-faulty channel includes N channels, and the second alignment information is used by the second device to align the first channel and the N channels.

[0037] In one possible implementation, before sending at least one second alignment information to the second device, the method further includes: sending a third indication information to the second device via the non-faulty channel, the third indication information instructing the second device to align the first channel and the non-faulty channel.

[0038] In one possible implementation, before sending the first data to the second device through the first channel, the method further includes: sending a fourth indication message to the second device through the non-faulty channel, the fourth indication message instructing the second device to detect the first channel.

[0039] Thirdly, this application provides a communication method applied to a second device. A first device includes a first port, and a second device includes a second port. Multiple channels are connected between the first and second ports, each channel allowing the first device to send data to the second device. The second device can determine if the first channel is faulty, where the multiple channels include the first channel, which may be any one of the multiple channels. After determining the first channel is faulty, the second device can send a notification message to the first device. Further, the second device can receive at least one first alignment information sent by the first device through a non-faulty channel among the multiple channels. The first alignment information includes a second AM or a first RAM, and the at least one first alignment information is used by the second device to align the non-faulty channel. After receiving at least one first alignment information, the second device can align the non-faulty channel according to the at least one alignment information, so as to subsequently use the non-faulty channel to receive data sent by the first device. Therefore, using this solution, even in the event of a first channel failure, the first device can still use the non-faulty channel between the first and second ports to send data to the second device, instead of ceasing to send data through the first port, thereby improving the resource utilization of the first port.

[0040] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

[0041] In one possible implementation, the notification message includes: a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM), wherein the RDI message carries first indication information, the first AM carries second indication information, and both the first and second indication information are used to indicate a fault in the first channel.

[0042] In one possible implementation, the RDI message includes a channel status field, which carries the first indication information.

[0043] In one possible implementation, the idle pad domain segment of the first AM carries the second indication information.

[0044] In one possible implementation, determining the first channel fault includes: determining the first channel fault in response to M consecutive forward error correction (FEC) codewords received through the first channel being uncorrectable, wherein M is an integer greater than or equal to 2.

[0045] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels. The step of aligning the non-faulty channel using the at least one alignment information includes: locking the at least one first alignment information and aligning the N channels.

[0046] In one possible implementation, the method further includes: after aligning the non-faulty channel, receiving data sent by the first device through the non-faulty channel.

[0047] In one possible implementation, receiving data sent by the first device through the non-faulty channel includes: receiving data retransmitted by the first device that failed to be transmitted due to a fault in the first channel.

[0048] In one possible implementation, the method further includes: receiving first data sent by the first device through the first channel, the first data being used to detect the first channel; using the first data to detect the first channel; and in response to the first channel passing the detection, sending a first response to the first device, the first response being used to indicate that the first channel has passed the detection, and the first channel passing the detection indicating that the first channel is fault-free.

[0049] In one possible implementation, the first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

[0050] In one possible implementation, the method further includes: receiving at least one second alignment information sent by the first device through the non-faulty channel and the first channel, the second alignment information including a fourth AM or a third RAM, the at least one second alignment information being used by the second device to align the first channel and the non-faulty channel; aligning the first channel and the non-faulty channel according to the at least one second alignment information; and after aligning the first channel and the non-faulty channel, receiving data sent by the second device through the non-faulty channel and the first channel.

[0051] In one possible implementation, the non-faulty channel includes N channels, and the second alignment information is used by the second device to align the first channel and the N channels. The step of aligning the first channel and the non-faulty channel according to the at least one second alignment information includes: aligning the first channel and the N channels according to the at least one second alignment information.

[0052] In one possible implementation, before receiving at least one second alignment information sent by the first device, the method further includes: receiving third indication information sent by the first device through the non-faulty channel, the third indication information instructing the second device to align the first channel and the non-faulty channel.

[0053] In one possible implementation, before receiving the first data sent by the first device through the first channel, the method further includes: receiving fourth indication information sent by the first device through the non-faulty channel, the fourth indication information instructing the second device to detect the first channel.

[0054] Fourthly, this application provides a communication device applied to a first device, the device comprising: a receiving unit for receiving a notification message indicating a first channel failure, wherein the first device includes a first port, a second device includes a second port, a plurality of channels are included between the first port and the second port, the plurality of channels including the first channel, and the plurality of channels are channels through which the first device sends data to the second device; and a sending unit for isolating the first channel in response to receiving the notification message, and sending data to the second device through a non-faulty channel among the plurality of channels.

[0055] In one possible implementation, the receiving unit is specifically configured to: receive the notification message sent by the second device, the notification message including a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM), wherein the RDI message carries first indication information, the first AM carries second indication information, and both the first indication information and the second indication information are used to indicate a fault in the first channel.

[0056] In one possible implementation, the RDI message includes a channel status field, which carries the first indication information.

[0057] In one possible implementation, the idle pad domain segment of the first AM carries the second indication information.

[0058] In one possible implementation, the transmitting unit is specifically configured to: transmit at least one first alignment information to the second device through the non-faulty channel, the first alignment information including a second AM or a first fast alignment mark RAM, the at least one first alignment information being used by the second device to align the non-faulty channel; and after transmitting the at least one first alignment information to the second device, transmit data to the second device through the non-faulty channel.

[0059] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

[0060] In one possible implementation, sending data to the second device via the non-faulty channel includes: retransmitting data that failed to be transmitted due to a fault in the first channel to the second device via the non-faulty channel.

[0061] In one possible implementation, the transmitting unit is further configured to transmit first data to the second device through the first channel, the first data being used to detect the first channel; the receiving unit is further configured to receive a first response sent by the second device, the first response being used to indicate that the first channel has passed the detection, and the first channel passing the detection indicating that the first channel is fault-free.

[0062] In one possible implementation, the first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

[0063] In one possible implementation, the sending unit is further configured to, in response to receiving the first response, perform channel isolation release measures on the first channel, and send data to the second device through the non-faulty channel and the first channel.

[0064] In one possible implementation, the transmitting unit is specifically configured to: transmit at least one second alignment information to the second device through the non-faulty channel and the first channel, the second alignment information including a fourth AM or a third RAM, the at least one second alignment information being used by the second device to align the first channel and the non-faulty channel; and after transmitting the at least one second alignment information to the second device, transmit data to the second device through the non-faulty channel and the first channel.

[0065] In one possible implementation, the non-faulty channel includes N channels, and the second alignment information is used by the second device to align the first channel and the N channels.

[0066] In one possible implementation, the apparatus further includes: the transmitting unit, which is further configured to transmit third indication information to the second device via the non-faulty channel before transmitting at least one second alignment information to the second device, the third indication information indicating that the second device aligns the first channel and the non-faulty channel.

[0067] In one possible implementation, the transmitting unit is further configured to transmit a fourth indication message to the second device via the non-faulty channel before transmitting the first data to the second device via the first channel, the fourth indication message instructing the second device to detect the first channel.

[0068] Fifthly, this application provides a communication device applied to a second device, the device comprising: a processing unit configured to determine a first channel failure, wherein the first device includes a first port, the second device includes a second port, and a plurality of channels are included between the first port and the second port, the plurality of channels including the first channel, the plurality of channels being channels through which the first device sends data to the second device; a sending unit configured to send a notification message to the first device, the notification message indicating a first channel failure; a receiving unit configured to receive at least one first alignment information sent by the first device through a non-faulty channel among the plurality of channels, the first alignment information including a second AM or a first fast alignment mark RAM, the at least one first alignment information being used by the second device to align the non-faulty channel; the processing unit further configured to align the non-faulty channel according to the at least one alignment information.

[0069] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

[0070] In one possible implementation, the notification message includes: a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM), wherein the RDI message carries first indication information, the first AM carries second indication information, and both the first and second indication information are used to indicate a fault in the first channel.

[0071] In one possible implementation, the RDI message includes a channel status field, which carries the first indication information.

[0072] In one possible implementation, the idle pad domain segment of the first AM carries the second indication information.

[0073] In one possible implementation, the processing unit is specifically configured to: determine that the first channel is faulty in response to M consecutive forward error correction (FEC) codewords received through the first channel being uncorrectable, wherein M is an integer greater than or equal to 2.

[0074] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels. The processing unit is specifically used to: lock the at least one first alignment information and align the N channels.

[0075] In one possible implementation, the receiving unit is further configured to: receive data sent by the first device through the non-faulty channel after aligning the non-faulty channel.

[0076] In one possible implementation, the receiving unit is specifically configured to: receive, via the non-faulty channel, the data retransmitted by the first device that failed to be transmitted due to a fault in the first channel.

[0077] In one possible implementation, the receiving unit is further configured to receive first data sent by the first device through the first channel, the first data being used to detect the first channel; the processing unit is further configured to use the first data to detect the first channel; and the sending unit is further configured to send a first response to the first device in response to the first channel passing the detection, the first response being used to indicate that the first channel has passed the detection, and the first channel passing the detection indicating that the first channel is fault-free.

[0078] In one possible implementation, the first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

[0079] In one possible implementation, the receiving unit is further configured to receive at least one second alignment information sent by the first device through the non-faulty channel and the first channel, the second alignment information including a fourth AM or a third RAM, the at least one second alignment information being used by the second device to align the first channel and the non-faulty channel; the processing unit is further configured to align the first channel and the non-faulty channel according to the at least one second alignment information; the sending unit is further configured to receive data sent by the second device through the non-faulty channel and the first channel after aligning the first channel and the non-faulty channel.

[0080] In one possible implementation, the non-faulty channel includes N channels, the second alignment information is used by the second device to align the first channel and the N channels, and the processing unit is specifically used to: align the first channel and the N channels according to the at least one second alignment information.

[0081] In one possible implementation, the receiving unit is further configured to receive, before receiving at least one second alignment information sent by the first device, a third indication information sent by the first device via the non-faulty channel, the third indication information instructing the second device to align the first channel and the non-faulty channel.

[0082] In one possible implementation, the receiving unit is further configured to receive a fourth indication information sent by the first device through the non-faulty channel before receiving the first data sent by the first device through the first channel, the fourth indication information instructing the second device to detect the first channel.

[0083] Sixthly, this application provides a device including a communication interface, the communication interface being used to perform data transmission and reception operations as described in the second aspect above and any one of the second aspects above; or, the communication interface being used to perform data transmission and reception operations as described in the third aspect above and any one of the third aspects above.

[0084] In one possible implementation, the device further includes a processor configured to perform data processing operations as described in the second aspect and any one of the second aspects above; or, the processor configured to perform data processing operations as described in the third aspect and any one of the third aspects above.

[0085] In one possible implementation, the device further includes a memory for storing instructions or computer programs, and the processor is configured to execute the instructions or computer programs in the memory to perform the method described in the second aspect and any one of the second aspects above. Alternatively, the processor is configured to execute the instructions or computer programs in the memory to perform the method described in the third aspect and any one of the third aspects above.

[0086] In a seventh aspect, this application provides an apparatus comprising an interface circuit for performing data transmission and reception operations as described in the second aspect and any one of the methods described in the second aspect above. Alternatively, the interface circuit is used to perform data transmission and reception operations as described in the third aspect and any one of the methods described in the third aspect above.

[0087] In one possible implementation, the device further includes a processing circuit for performing the data processing operations described in the second aspect and any one of the methods described in the second aspect above. Alternatively, the processing circuit is used to perform the data processing operations described in the third aspect and any one of the methods described in the third aspect above.

[0088] Eighthly, this application provides a computer-readable storage medium including instructions or a computer program that, when run on a computer, causes the computer to perform the methods described in the second aspect above and any one of the second aspects above, or, when run on a computer, causes the computer to perform the methods described in the third aspect above and any one of the third aspects above.

[0089] Ninthly, this application provides a computer program product comprising instructions or a computer program, which, when run on a computer, causes the computer to perform the methods described in the second aspect above and any one of the second aspects above, or causes the computer to perform the methods described in the third aspect above and any one of the third aspects above. Attached Figure Description

[0090] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0091] Figure 1a shows a schematic diagram of a transmitting end device and a receiving end device;

[0092] Figure 1b is a schematic diagram of an exemplary application scenario provided by an embodiment of this application;

[0093] Figure 2 is a schematic diagram of signaling interaction of a communication method provided in an embodiment of this application;

[0094] Figure 3 is a flowchart illustrating a fault channel isolation method provided in an embodiment of this application;

[0095] Figure 4 is a flowchart illustrating a channel status detection method provided in an embodiment of this application;

[0096] Figure 5 is a flowchart illustrating a fault channel recovery method provided in an embodiment of this application;

[0097] Figure 6 is a schematic diagram of the structure of a first device provided in an embodiment of this application;

[0098] Figure 7 is a schematic diagram of the structure of a communication device provided in an embodiment of this application;

[0099] Figure 8 is a schematic diagram of another communication device provided in an embodiment of this application;

[0100] Figure 9 is a schematic diagram of the structure of a device provided in an embodiment of this application;

[0101] Figure 10 is a schematic diagram of the structure of a device provided in an embodiment of this application. Detailed Implementation

[0102] This application provides a communication method and apparatus that can improve the resource utilization of high-speed ports.

[0103] The apparatus mentioned in the embodiments of this application (e.g., the first apparatus and the second apparatus) may be an apparatus including a high-speed Ethernet interface, such as a network device including a high-speed Ethernet interface, or a component (e.g., a chip or board) on a network device including a high-speed Ethernet interface. The embodiments of this application do not specifically limit the scope of the apparatus. The network device including a high-speed Ethernet interface may also be referred to as a high-speed Ethernet interface device. The apparatus may also be a high-speed Ethernet interface.

[0104] The high-speed Ethernet interface mentioned in this application embodiment includes an Ethernet media access control (MAC) layer device and a physical layer (PHY) device that support data transmission at a certain rate.

[0105] Refer to Figure 1a for further understanding. Figure 1a shows a schematic diagram of a transmitting end device and a receiving end device. Both the transmitting end device and the receiving end device include a high-speed Ethernet interface. The transmitting end device refers to the communication device that acts as a data sender, and the receiving end device refers to the communication device that acts as a data receiver. Considering that data traffic is bidirectional, in some scenarios, the roles of the transmitting end device and the receiving end device shown in Figure 1a can be interchanged.

[0106] As shown in Figure 1a, both the transmitting and receiving devices include: a MAC layer device (referred to as MAC in Figure 1a) and a physical layer device (referred to as PHY in Figure 1a).

[0107] The physical layer device includes a physical coding sublayer (PCS), an FEC module, and a physical medium attachment (PMA) sublayer. Additionally, although not shown in Figure 1a, a reconciliation sublayer (RS) may be included between the MAC layer and the physical layer. The RS and PCS can communicate via a medium independent interface (MII) channel. The MII channel can be a virtual channel or a logical channel.

[0108] In one example, the aforementioned MAC layer device can be a MAC chip, and the physical layer device can be a PHY chip.

[0109] In another example, the aforementioned MAC layer device and physical layer device can be different functional circuits on the same chip.

[0110] When transmitting data, the transmitting and receiving devices can process the data according to the seven-layer Open Systems Interconnection (OSI) model. The first layer of the OSI model is the Physical Layer, and the second layer is the Data Link Layer, which includes the MAC layer. The Physical Layer can include the aforementioned PCS, FEC module, and PMA.

[0111] The MAC layer of the transmitting device can generate MAC frames. The MAC layer of the transmitting device sends the MAC frames to the physical layer of the transmitting device. In scenarios where an RS is included between the MAC layer and the physical layer, the RS can convert the serial MAC frames into a parallel data stream and pass the data stream to the PCS through the MII channel.

[0112] The PCS can process the data stream received through the MII channel. In a specific example, the PCS can first encode (e.g., 64B / 66B encoding) and rate match the data stream, and then transcode (e.g., 256B / 257B transcoding) the encoded and rate-matched data stream. Further, scrambling is performed on the transcoded data stream. After scrambling, AM insertion is performed on the scrambled data stream to add AM. After AM insertion, the FEC module performs FEC encoding on the AM-encoded data stream, and then performs interleaving and distribution on the FEC-encoded data to distribute the interleaved data to m PCS channels (lanes) connected to the PMA, where "PCS channel" can be abbreviated as "PCSL". Of course, in some scenarios, the execution order of the aforementioned transcoding and scrambling operations is not limited to transcoding followed by scrambling; scrambling can also be performed first, followed by transcoding. In one example, interleaving and distribution can be performed on the data after FEC encoding at the FEC codeword granularity.

[0113] PMA can perform m:n bit multiplexing on the data from PCS (i.e., data on m PCSLs), mapping the data transmitted in the m PCSLs to n physical channels, so that the data carried by the n physical channels can be sent to the receiving device later.

[0114] Currently, for Ethernet interfaces of 800GE (800 Gigabit Ethernet) and below, the bandwidth of a single PCSL is 25 gigabits per second (Gbps). Therefore, for a 100GE Ethernet interface, the number of PCSLs is 4; for a 200GE Ethernet interface, the number of PCSLs is 8; for a 400GE Ethernet interface, the number of PCSLs is 16; and for an 800GE Ethernet interface, the number of PCSLs is 32. For a 1600GE (i.e., 1.6TE) Ethernet interface, the bandwidth of a single PCSL is 100 Gbps, and the number of PCSLs is 16.

[0115] The physical layer of the receiving device also includes the PMA, FEC module, and PCS. The operations performed by the physical layer of the receiving device are the inverse operations performed by the physical layer of the data sending device, which will not be described in detail here.

[0116] In this application, the bandwidth is 100Gbps. Those skilled in the art will understand that this is a common industry term and does not mean that the bandwidth is exactly 100Gbps. Rather, it means that the bandwidth is approximately equal to 100Gbps. The precise value of the bandwidth could be, for example, 106.25Gbps or 103.125Gbps.

[0117] In this application, the term "c*100GE Ethernet interface" is a common industry term, as those skilled in the art will understand. It does not mean that the Ethernet speed (or the bandwidth of the Ethernet interface) is exactly c*100Gbps, but rather that the Ethernet speed is approximately equal to c*100Gbps. The precise value of the Ethernet speed could be, for example, c*106.25Gbps or c*103.125Gbps.

[0118] In addition, although not shown in Figure 1a, the transmitting and receiving devices may include other layer devices besides the MAC layer device and the physical layer device, such as the application layer (APP) device, which will not be described in detail here.

[0119] Please refer to Figure 1b for further understanding. Figure 1b is a schematic diagram of an exemplary application scenario provided by an embodiment of this application. Figure 1b shows a schematic diagram of the structure of a communication system. The communication system shown in Figure 1b includes device 100 and device 200, wherein:

[0120] Device 100 includes a high-speed port 110, and device 200 includes a high-speed port 210. Device 100 can send data to device 200 via high-speed port 110, and device 200 can receive data sent via high-speed port 110 via high-speed port 210.

[0121] Multiple channels are included between high-speed port 110 and high-speed port 210 (Figure 1b shows y channels), meaning that high-speed port 110 and high-speed port 210 can communicate through these multiple channels. These multiple channels are for high-speed port 110 to send data to high-speed port 210. That is, high-speed port 110 can send data to high-speed port 210 through these multiple channels.

[0122] Currently, when one of the aforementioned channels fails, the entire high-speed port is considered to be faulty. For example, if channel 1 shown in Figure 1b fails, high-speed port 110 is considered faulty. Consequently, high-speed port 110 can no longer be used to send data to high-speed port 210. However, only some channels (e.g., one channel) among the aforementioned channels may fail, while other non-faulty channels still have the ability to transmit data. Therefore, considering the entire high-speed port to be faulty because of one channel failure leads to a certain amount of bandwidth waste. Specifically, the bandwidth of the aforementioned non-faulty channels is wasted, resulting in lower resource utilization of the high-speed port.

[0123] Therefore, embodiments of this application provide a communication method, apparatus, and system that can improve the resource utilization of high-speed ports.

[0124] The communication system provided in this application includes a first device and a second device. The first device includes a first port, and the second device includes a second port, wherein both the first port and the second port are high-speed ports. Multiple channels are included between the first port and the second port, which are channels through which the first device sends data to the second device. In one example, these multiple channels may be all channels used by the first port to send data to the second port. In another example, if the first device is in power-saving mode, then these multiple channels may be the channels currently in operation among all channels used by the first port to send data to the second port.

[0125] The first device may correspond to device 100 shown in FIG1b, the second device may correspond to device 200 shown in FIG1b, the first port may correspond to port 110 shown in FIG1b, and the second port may correspond to port 210 shown in FIG1b.

[0126] Next, referring to Figure 2, we will introduce the communication method applied to this communication system.

[0127] Referring to Figure 2, this figure is a signaling interaction diagram of a communication method provided in an embodiment of this application.

[0128] The method shown in Figure 2 includes the following steps S101-S105.

[0129] S101: The second device determines that the first channel is faulty.

[0130] In this application, the second device can use channel fault detection technology to determine whether the first channel is faulty.

[0131] The first channel is one of the multiple channels through which the first port sends data to the second port.

[0132] As an example, the second device can relock AM to the data received through the first channel if multiple consecutive (e.g., M) FEC codewords become uncorrectable. If multiple consecutive (e.g., a) AM locking failures occur, the first channel is considered faulty. Assuming the first port corresponds to a 100GE Ethernet interface, the time to determine the first channel fault using this method is approximately a * 104.8576 microseconds. Here, a is typically set to 6, so the time to determine the first channel fault is approximately 6 * 104.8576 = 629.2536 microseconds.

[0133] As another example, the second device can determine a first channel fault if M consecutive FEC codewords received through the first channel are uncorrectable, where M is an integer greater than or equal to 2. Using this method, after determining that M consecutive FEC codewords are uncorrectable, there is no need to relock AM to the first channel, thus effectively improving the efficiency of determining a first channel fault. Assuming the first port corresponds to a 100GE Ethernet interface, the time to determine a first channel fault using this method is approximately M * 51.2 ns (microseconds). Since M is typically 5, the time to determine a first channel fault is approximately 5 * 51.2 = 256 microseconds, which is significantly more efficient than the 629.2536 microseconds required for determining a first channel fault mentioned above.

[0134] Of course, the second device can also use other means to determine the fault of the first channel. For example, the second device can determine the fault of the first channel by means of increased bit error rate of the first channel, or by hardware signal fault indication of the first channel, or by analog circuit fault indication of the first channel, or by management software fault indication of the first channel, or by service interruption of the first channel. These will not be described in detail here.

[0135] S102: The second device sends a notification message to the first device, the notification message indicating a fault in the first channel.

[0136] After the second device determines that the first channel is faulty, it can send a notification message to the first device to inform the first device of the fault information.

[0137] In one example, the notification message includes an RDI message, which contains first indication information indicating a first channel failure. Accordingly, the first device can receive and parse the RDI message to obtain the first indication information, thereby determining that the first channel is faulty. In one example, the RDI message can be a Layer 2 message. The RDI message includes a channel status field, which carries the first indication information. As an example, the channel status field can include multiple bits, which are indication bits corresponding to the aforementioned multiple channels, one indication bit per channel. For any given channel, the indication bit indicates whether the channel is faulty. For example, for the first channel, if the value of the indication bit corresponding to the first channel is 0, it indicates that the first channel is faulty. Correspondingly, for non-faulty channels among the aforementioned multiple channels, the value of the indication bit corresponding to the non-faulty channel can be 1. The length of one indication bit can be 1 bit.

[0138] In addition to the channel status field, the RDI message may also include other fields, which are not specifically limited in this embodiment. In one example, the RDI message includes a message type field in addition to the channel status field, which indicates that the message is an RDI message. In another example, the RDI message may also include a reserved field, so that extended information can be carried later as needed.

[0139] In another example, the notification message includes a first AM, which includes second indication information used to indicate a first channel failure. Accordingly, the first device can receive and parse the first AM to obtain the second indication information, thereby determining a first channel failure. In one example, the first AM includes a pad segment used to carry the second indication information. As an example, the first AM may include 257 bits, with bits 0 to 239 (240 bits) carrying the AM pattern, and bits 240 to 256 (17 bits) forming the pad segment. In one example, the aforementioned second indication information can be carried using the 17-bit pad segment of the first AM.

[0140] In a specific example, the pad field segment may include a fifth indication information, which indicates that the pad field segment includes a second indication information.

[0141] As an example, the 240th bit of the pad field is used to carry the fifth indication information. For instance, when the value of the 240th bit is 1, it indicates that the pad field includes the second indication information; when the value of the 240th bit is 0, it indicates that the pad field does not include the second indication information; or, when the value of the 240th bit is 0, it indicates that the information in the pad field is invalid.

[0142] Accordingly, bits 241 to 256 of the pad field segment, totaling 16 bits, carry the aforementioned second indication information. As a specific example, these 16 bits include indication bits corresponding to the multiple channels, with one indication bit per channel. For any given channel, the indication bit indicates whether the channel is faulty. For instance, for the first channel, if the information in the pad field segment is invalid, the value of the indication bit corresponding to the first channel is 0. Therefore: a value of 0 indicates that the first channel is not faulty; a value of 1 indicates that the first channel is faulty. Example:

[0143] Assuming the information in the pad field is invalid, the value of the aforementioned 16 bits from bit 241 to bit 256 is 1010101010101010, then:

[0144] For bit 241, if the value of this bit is 1, it means that the channel corresponding to bit 241 is fault-free; if the value of this bit is 0, it means that the channel corresponding to bit 241 is faulty.

[0145] For bit 242, if the value of this bit is 0, it means that the channel corresponding to bit 241 is fault-free; if the value of this bit is 1, it means that the channel corresponding to bit 241 is faulty.

[0146] Similarly, for the 2*i-1th bit, if the value of this bit is 1, it indicates that the channel corresponding to this bit is fault-free; if the value of this bit is 0, it indicates that the channel corresponding to this bit is faulty. For the 2*ith bit, if the value of this bit is 0, it indicates that the channel corresponding to this bit is fault-free; if the value of this bit is 1, it indicates that the channel corresponding to this bit is faulty. Here, i is greater than or equal to 122 and less than or equal to 128.

[0147] In one example, the second device may send either the aforementioned RDI message or the first AM to the first device. In another example, the second device may send both the aforementioned RDI message and the first AM to the first device to ensure that the first device can receive either the RDI message or the first AM, thereby enabling the first device to determine that the first channel has failed.

[0148] Of course, the notification message can be any of the aforementioned RDI messages or the first AM, or other implementations. For example, the notification message can be a special service message, a special coded block, or an indication transmitted through a hardware interface, etc., which will not be described in detail here.

[0149] S103: The first device receives the notification message.

[0150] S104: In response to receiving the notification message, the first device isolates the first channel and sends data to the second device through a non-faulty channel among multiple ports.

[0151] S105: After the first device isolates the first channel, the second device receives the data sent by the first device through a non-faulty channel among the plurality of channels.

[0152] The first device can receive a notification message sent by the second device. Upon receiving the notification message, the first device does not treat the first port as a faulty port and cease using it to send data. In this application, after receiving the notification message, the first device can isolate the first channel in response to receiving the notification message. After isolating the first channel, it sends data to the second device through a non-faulty channel among the multiple ports. Using this method, even if the first channel fails, the resources of the non-faulty channels among the multiple channels can still be used to send data, effectively improving the resource utilization of the first port compared to treating it as a faulty port.

[0153] In a specific example, when the first device isolates the first channel, it can send at least one first alignment information to the second device through a non-faulty channel. Correspondingly, the second device can receive the first alignment information sent by the first device through the non-faulty channel. The first alignment information mentioned here can be AM or RAM; for example, the first alignment information includes a second AM or a first RAM. Regarding RAM, it should be noted that:

[0154] As an example, RAM is a block of bits of a specific length, for example, 120 bits. In one example, RAM can be obtained by modifying the AM structure corresponding to 200G as specified in IEEE 802.3. Specifically, the positions of CM3-CM5 and CM0-CM2 in the AM corresponding to 200G are swapped, UP0 in the AM corresponding to 200G is modified to CD7, and UP1 in the AM corresponding to 200G is modified to CD3, thus obtaining RAM.

[0155] The lock period of RAM is much shorter than that of AM. The lock period of RAM can be understood as the distance between adjacent RAMs, while the lock period of AM can be understood as the distance between adjacent AMs.

[0156] In one example, each of the at least one first alignment information carries a sequence number, which is used by the second device to determine the number of first alignment information received. That is, the second device can determine the number of first alignment information it has received based on the sequence numbers in the received first alignment information. Assume the number of first alignment information sent by the first device to the second device is N1. Then:

[0157] In a specific example, the sequence number carried in the j-th first alignment information sent by the first device is N1-j+1, where j is an integer greater than or equal to 1 and less than or equal to N1. Taking N1 as 36 as an example, the first first alignment information sent by the first device carries sequence number 36, the second first alignment information sent by the first device carries sequence number 35, and so on. The 35th first alignment information sent by the first device carries sequence number 2, and the 36th first alignment information sent by the first device carries sequence number 1.

[0158] In another example, the sequence number carried in the j-th first alignment information sent by the first device is j, where j is an integer greater than or equal to 1 and less than or equal to N1. Taking N1 as 36 as an example, the first first alignment information sent by the first device carries sequence number 1, the second first alignment information sent by the first device carries sequence number 2, and so on, with the 35th first alignment information sent by the first device carrying sequence number 35, and the 36th first alignment information sent by the first device carrying sequence number 36. In this application, the first alignment information is used by the second device to align the non-faulty channel.

[0159] Aligning non-faulty channels refers to aligning multiple PCSLs corresponding to a non-faulty channel. In one example, the non-faulty channels may include N channels, where N is an integer greater than or equal to 1. The first alignment information is used to align the N channels. Assuming one channel corresponds to b PCSLs, the first alignment information is used by the second device to align the b*N PCSLs corresponding to these N channels. After receiving the first alignment information, the second device can lock the first alignment information on the multiple PCSLs corresponding to the aforementioned non-faulty channels, and align the multiple PCSLs corresponding to the non-faulty channels based on the locked first alignment information.

[0160] As described above, the first alignment information can be either the second AM or the first RAM. Since the locking period of RAM is much shorter than that of AM, the second device will be more efficient in aligning non-faulty channels when the first alignment information is the first RAM.

[0161] After the first device isolates the first channel, that is, after the first device sends at least one first alignment message to the second device through the non-faulty channel, it can send data to the second device through the non-faulty channel. For example, the first device sends data to the second device through the non-faulty channel after the last of the aforementioned at least one first alignment message has been sent. Correspondingly, after the second device aligns the non-faulty channel based on at least one first alignment message, it can receive the data sent by the first device through the non-faulty channel. For example, after the second device receives the last of the aforementioned at least one first alignment message and aligns the non-faulty channel, it can receive the data sent by the first device through the non-faulty channel. The data mentioned here may be, for example, a service flow.

[0162] In one example, considering that a failure in the first channel might cause data (e.g., service streams) originally transmitted through the first channel to fail, the data sent by the first device to the second device through the non-faulty channel can include data that failed to transmit due to the failure of the first channel. In other words, after isolating the first channel, the first device can use the non-faulty channel to retransmit data that failed to transmit due to the failure of the first channel. In this way, when the data that failed to transmit due to the failure of the first channel is service data, lossless service retransmission can be achieved, ensuring the quality of service provided to the service.

[0163] Although in the above description, the notification message indicating a first channel failure is sent from the second device to the first device, in other embodiments, this notification message may also be sent to the first device by other devices. For example, after determining that the first channel is faulty through certain detection methods, other devices may send a notification message indicating the first channel failure to the first device. This application does not specifically limit other devices; other devices may be, for example, controllers or network management systems, and are not listed here. This application also does not limit the specific implementation of other devices determining the first channel failure.

[0164] In one example, in order to ensure the resource utilization of the first port, the first device can also detect the status of the first channel so that when the fault of the first channel has been recovered (i.e. the first channel is no longer faulty), the bandwidth resources of the first channel can be utilized in a timely manner to improve data transmission efficiency.

[0165] As a concrete example, the first device can send first data to the second device through a first channel, and the first data is used to detect the first channel. Correspondingly, the second device can receive the first data sent by the first device through the first channel and use the first data to detect the first channel.

[0166] The embodiments in this application do not specifically limit the first data.

[0167] As an example, the first data may include a specific code block and a third AM. The first data including the specific code block and the third AM can be understood as the first data including multiple third AMs and multiple specific code blocks, with the data between adjacent third AMs constituting the specific code block. In this scenario, the specific code block is sent to the second device after FEC encoding by the first device. The second device, for the data received through the first channel, can first lock onto the third AM, and then perform FEC decoding on the data between the third AMs (i.e., the data obtained by FEC encoding the specific code block), and determine the error rate of the specific code block. Further, based on the error rate of the specific code block, the detection result of the first channel is determined. As an example, if the error rate of the specific code block is low, the first channel can be determined to have passed the detection; conversely, if the error rate of the specific code block is high, the first channel can be determined to have failed the detection. Passing the first channel indicates that the first channel is fault-free, while failing the first channel indicates that the first channel has a fault.

[0168] As another example, the first data may include specific code blocks and a second RAM. The first data including specific code blocks and a second RAM can be understood as the first data comprising multiple second RAMs and multiple specific code blocks, with the data between adjacent second RAMs constituting the specific code blocks. In this scenario, the specific code block is sent to the second device after FEC encoding by the first device. The second device, for the data received through the first channel, can first lock the second RAM, and then perform FEC decoding on the data between the second RAMs (i.e., the data obtained by FEC encoding the specific code block), and determine the error rate of the specific code block. Furthermore, based on the error rate of the specific code block, the detection result of the first channel is determined. For example, if the error rate of the specific code block is low, the first channel is determined to have passed the detection; if the error rate of the specific code block is high, the first channel is determined to have failed the detection.

[0169] The error rate mentioned in this application may be at least one of the following: bit error ratio (BER), symbol error ratio (SER), or codeword error ratio (CER).

[0170] This application does not specifically limit the preset code block. The preset code block may be a PCS code block, for example, an idle (IDLD) code block or an order sequence (O) code block.

[0171] Of course, the first data is not limited to the two implementation methods mentioned above. For example, in another example, the aforementioned specific code block can also be replaced with other data, for example, this application does not make specific limitations.

[0172] In one example, before sending the first data to the second device through the first channel, the first device may also send a fourth indication message to the second device through a non-faulty channel. This fourth indication message instructs the second device to detect the first channel. Correspondingly, the second device can receive this fourth indication message through the non-faulty channel. Furthermore, after receiving the fourth indication message, the second device can continue to receive the aforementioned first data through the first channel, so as to facilitate subsequent detection of the first channel based on the first data.

[0173] The embodiments of this application do not specifically limit the fourth indication information. The fourth indication information may be a Layer 2 message, a specific PCS code block, or a hardware-triggered signal, etc. The embodiments of this application do not make specific limitations.

[0174] In one example, if the second device determines that the first channel has passed the detection, the second device may send a first response to the first device in response to the first channel passing the detection. This first response is used to indicate that the first channel has passed the detection. This application embodiment does not specifically limit the specific format of the first response. Similar to the aforementioned fourth indication information, the first response may also be a Layer 2 message or a specific PCS code block. This application embodiment does not make specific limitations.

[0175] Accordingly, if the second device sends a first response to the first device, the first device can receive the first response. After receiving the first response, the first device can determine that the fault in the first channel has been resolved. Therefore, in response to receiving the first response, the first device can perform channel isolation release measures on the first channel, and after performing channel isolation release measures on the first channel, send data to the second device through the non-faulty channel and the first channel. That is, after the fault in the first channel is resolved, the first device continues to use the first channel to send data to the second device, thereby effectively utilizing the bandwidth resources of the first channel and improving the resource utilization of the first port. Correspondingly, the second device can also receive data sent by the first device through the non-faulty channel and the first channel after the first device performs channel isolation release measures on the first channel.

[0176] In a specific example, when the first device performs channel isolation release measures on the first channel, it can send at least one second alignment information to the second device through the non-faulty channel and the first channel. Correspondingly, the second device can receive the second alignment information sent by the first device through the non-faulty channel and the first channel. The second alignment information mentioned here can be AM or RAM; for example, the second alignment information includes a fourth AM or a third RAM.

[0177] In one example, each of the at least one second alignment information carries a sequence number, which is used by the second device to determine the number of second alignment information received. That is, the second device can determine the number of second alignment information it has received based on the sequence numbers in the received second alignment information. Assume the number of second alignment information sent by the first device to the second device is N². Then:

[0178] In a specific example, the sequence number carried in the j-th second alignment information sent by the first device is N2-j+1, where j is an integer greater than or equal to 1 and less than or equal to N2. Taking N2 as 36 as an example, the first second alignment information sent by the first device carries sequence number 36, the second second alignment information sent by the first device carries sequence number 35, and so on. The 35th second alignment information sent by the first device carries sequence number 2, and the 36th second alignment information sent by the first device carries sequence number 1.

[0179] In another example, the sequence number carried in the j-th second alignment message sent by the first device is j, where j is an integer greater than or equal to 1 and less than or equal to N2. Taking N2 as 36 as an example, the first second alignment message sent by the first device carries sequence number 1, the second second alignment message sent by the first device carries sequence number 2, and so on, with the 35th second alignment message sent by the first device carrying sequence number 35, and the 36th second alignment message sent by the first device carrying sequence number 36.

[0180] In this application, the second alignment information is used by the second device to align the non-faulty channel and the first channel. For ease of description, the "non-faulty channel and the first channel" are referred to as the "channels to be worked." Aligning the channels to be worked refers to aligning the multiple PCSLs corresponding to the channels to be worked. In one example, the non-faulty channels may include N channels, and the channels to be worked include N+1 channels. The second alignment information is used to align the N+1 channels included in the channels to be worked. Assuming one channel corresponds to b PCSLs, the second alignment information is used by the second device to align the b*(N+1) PCSLs corresponding to these N+1 channels. After receiving the second alignment information, the second device can lock the second alignment information on the multiple PCSLs corresponding to the aforementioned channels to be worked, and align the multiple PCSLs corresponding to the channels to be worked based on the locked second alignment information.

[0181] In this application, if a channel corresponds to a PCSL, then the bandwidth of the channel is equal to the sum of the bandwidths of the PCSLs. As an example, if the aforementioned non-faulty channel corresponds to multiple PCSLs, then the bandwidth of the non-faulty channel is equal to the sum of the bandwidths of the multiple PCSLs corresponding to that non-faulty channel. Assuming the bandwidth of a non-faulty channel is 100Gbps, then a non-faulty channel can correspond to 4 PCSLs, each PCSL having a bandwidth of 25Gbps, and the sum of the bandwidths of the 4 PCSLs equals the bandwidth of the non-faulty channel.

[0182] As another example, if the channel to be worked corresponds to multiple PCSLs, then the bandwidth of the channel to be worked is equal to the sum of the bandwidths of the multiple PCSLs corresponding to the channel to be worked. Assuming the bandwidth of the channel to be worked is 150Gbps, then the channel to be worked can correspond to 6 PCSLs, each with a bandwidth of 25Gbps, and the sum of the bandwidths of the 6 PCSLs equals the bandwidth of the channel to be worked. As described above, the second alignment information can be either the fourth AM or the third RAM. Since the locking period of RAM is much shorter than that of AM, when the second alignment information is the third RAM, the second device will be more efficient in aligning the channel to be worked.

[0183] After the first device performs the channel isolation release measure, that is, after the first device sends at least one second alignment information to the second device through the non-faulty channel and the first channel, data can be sent to the second device through the non-faulty channel and the first channel. As a specific example, the first device can send data to the second device through the non-faulty channel and the first channel after sending the last of the aforementioned at least one second alignment information. Correspondingly, after the second device aligns the non-faulty channel and the first channel based on at least one second alignment information, it can receive the data sent by the first device through the non-faulty channel and the first channel. As a specific example, the second device can receive the data sent by the first device through the non-faulty channel and the first channel after receiving the last of the at least one second alignment information and aligning the non-faulty channel and the first channel.

[0184] In one example, before sending at least one second alignment message to the second device, the first device may send a third indication message to the second device via the non-faulty channel. This third indication message instructs the second device to align the first channel and the non-faulty channel. Correspondingly, the second device can receive the third indication message sent by the first device via the non-faulty channel, and after receiving the third indication message, further receive at least one second alignment message sent by the first device via both the first and non-faulty channels, so as to subsequently use the second alignment information to align the non-faulty channel and the first channel.

[0185] Regarding the third indication information, it is similar to the aforementioned fourth indication information, and may also be a Layer 2 message, a specific PCS code block, or a hardware-triggered signal, etc. This application embodiment does not make specific limitations.

[0186] The solutions provided by the embodiments of this application have been described above. Next, with reference to the accompanying drawings, a possible implementation of the embodiments of this application will be described.

[0187] Referring to Figure 3, this figure is a schematic flowchart of a fault channel isolation method provided in an embodiment of this application.

[0188] The process shown in Figure 3 includes steps ① through ⑧. Wherein:

[0189] Step 1: The first device sends traffic to the second device through all lanes.

[0190] Step 2: When the PCS (RXPCS) of the second device detects a faulty lane, it ignores the data received from that lane and merges the traffic received from other lanes.

[0191] Step 3: The MAC (TXMAC) of the second device inserts the RDI messages and the PCS (TXPCS) of the second device transmits the RDI AM.

[0192] The RDI AM mentioned here can correspond to the first AM in the above embodiments.

[0193] Step 4: The MAC (RXMAC) of the first device receives an RDI message or the PCS (RXPCS) of the first device receives an RDI AM.

[0194] Step 5: The first device sends k RAMs to the second device through the fault-free lanes (Send#K……#1RAM on fault-free lanes).

[0195] Here, #K……#1RAM represents k RAMs, and the k RAMs mentioned here correspond to the N1 first alignment information in the above embodiment.

[0196] Step 6: The second device locks the k RAMs sent by the first device and aligns the non-faulty channels.

[0197] Step 7: After the first device finishes sending data in the last RAM of the k RAMs, it sends data on the fault-free lanes.

[0198] Step 8: After receiving the last RAM in the k RAMs, the second device receives data on the fault-free lanes.

[0199] Referring to Figure 4, this figure is a schematic flowchart of a channel state detection method provided in an embodiment of this application.

[0200] The process shown in Figure 4 includes steps ① through ⑦. Wherein:

[0201] Step 1: The first device starts lane check.

[0202] For example, channel detection can be initiated by the processor or logic module of the first device.

[0203] Step 2: The MAC (TXMAC) of the first device sends a channel detection message to the second device and creates a timer, lane_check_wait_resp_timer, to wait for a response (TXMAC sent check message, start lane_check_wait_resp_timer).

[0204] The channel detection message mentioned here corresponds to the fourth indication information in the above embodiments.

[0205] Step 3: The MAC (RXMAC) of the second device receives the channel detection message and reports it to its own processor (RXMAC received check message, report to MCORE).

[0206] Step 4: The first device sends RAM+IDLE on the channel to be checked, or the first device sends AM+IDLE on the channel to be checked, and starts the aforementioned waiting response timer (Send AM and IDLE on checking lanes, or RAMs and IDLE on checking lanes, start lane_check_wait_resp_timer).

[0207] The RAM+IDLE mentioned here corresponds to the first data in the above embodiments.

[0208] The AM+IDLE mentioned here corresponds to the first data in the above embodiments.

[0209] Step 5: The PCS of the second device sends a message to its own MAC (RXMAC) to indicate that the AM lock (or RAM lock) on the channel to be checked is successful and the FEC SER has passed. The RXMAC of the second device notifies its own TXMAC to send a channel detection response message (Sensing AM lock, RAM lock and FEC SER OK of checking lane, RXMAC notice TXMAC to send check response message).

[0210] The channel to be detected mentioned here corresponds to the first channel in the above embodiments; the channel detection response message mentioned here corresponds to the first response in the above embodiments.

[0211] Step 6: The first device receives the channel detection response message via the RXMAC and reports its own TXMAC (RX MAC receive check response message, notice TXMAC).

[0212] Step 7: If the TXMAC of the first device receives the channel detection response message before lane_check_wait_resp_timer expires, it reports that the channel to be detected has passed the detection; otherwise, it reports that the channel to be detected has failed the detection.

[0213] Referring to Figure 5, this figure is a flowchart illustrating a fault channel recovery method provided in an embodiment of this application.

[0214] The process shown in Figure 5 includes steps ① through ⑥. Wherein:

[0215] Step 1: The first device starts to speed up and sends a trigger message.

[0216] The trigger message mentioned here corresponds to the third indication information in the above embodiments. The trigger message can also be called the anchor message.

[0217] Step 2: The MAC (RXMAC) of the second device receives any trigger message.

[0218] Step 3: The first device sends k RAMs (send#1, ..., #k RAM) to the second device.

[0219] The k RAMs mentioned here correspond to the N2 second alignment information in the above embodiments.

[0220] In specific implementation, step ③ involves sending k RAM units to the channel awaiting operation after the speed-up. The channel awaiting operation mentioned here can correspond to the "non-faulty channel and the first channel" in the above embodiments.

[0221] Step 4: The second device locks the k RAMs sent by the first device and aligns the channels to be used.

[0222] Step 5: After the first device finishes sending data in the last RAM of the k RAMs, it sends data on the lanes to be added and the working lanes.

[0223] The channel to be added mentioned here corresponds to the first channel in the above embodiments; the working channel mentioned here corresponds to the non-faulty channel in the above embodiments.

[0224] Step 6: After the second device finishes receiving data from the last RAM in the k RAMs, it receives data on the lanes to be added and the working lanes.

[0225] Referring to Figure 6, this figure is a schematic diagram of the structure of a first device provided in an embodiment of this application.

[0226] Next, the data processing process of the first device will be described in conjunction with the structure shown in Figure 6.

[0227] As shown in Figure 6:

[0228] The first device includes a PHY module, a MAC module, a RETRY module, and an APP module.

[0229] The MAC module includes TXMAC and RXMAC. The RETRY module includes the RETRY_RX module and the RETRY_TX module. The RETRY_RX module is the receiving part of the RETRY module, used to receive data; the RETRY_TX module is the transmitting part of the RETRY module, used to transmit data.

[0230] First, the service data arrives at the RETRY_TX module via the APP module. The RETRY_TX module then sends the service data and buffers a copy of the sent data in the retransmission buffer. The service data sent by the RETRY_TX module is then transmitted to the second device via the TXMAC module and PHY module of the first device.

[0231] The second device verifies the received data.

[0232] If the second device determines that the data passes the verification, the second device sends an acknowledgment (ACK) to the first device. Correspondingly, after receiving the ACK, the RXMAC of the first device passes the ACK to the RETRY module, and the RETRY module releases the retransmission buffer based on the ACK.

[0233] If the second device determines that the data has failed verification, it sends a negative acknowledgment (NACK) to the first device. Upon receiving the NACK, the first device's RXMAC notifies the RETRY_TX module to retransmit the erroneous data. Retransmitting the erroneous data can, for example, involve executing the fault channel isolation procedure shown in Figure 3, allowing retransmission via a non-faulty channel, thus achieving lossless data transmission during fault channel isolation.

[0234] Regarding Figures 3 to 6, it is necessary to clarify that in Figures 3 to 6, TXMAC represents the transmitting part of the MAC, used for transmitting data, and RXMAC represents the receiving part of the MAC, used for receiving data. TXPCS represents the transmitting part of the PCS, used for transmitting data, and RXPCS represents the receiving part of the PCS, used for receiving data.

[0235] Based on the methods provided in the above embodiments, this application also provides a corresponding apparatus. Next, the apparatus provided in this application will be described in conjunction with the accompanying drawings.

[0236] Referring to Figure 7, this figure is a schematic diagram of the structure of a communication device provided in an embodiment of this application. The communication device 700 shown in Figure 7 is applied to the first device provided in the above embodiments to execute the method steps performed by the first device in the above embodiments.

[0237] As shown in Figure 7, the device 700 includes a receiving unit 701 and a transmitting unit 702.

[0238] The receiving unit 701 is used to receive a notification message indicating a first channel failure. The first device includes a first port, the second device includes a second port, and multiple channels are included between the first port and the second port. The multiple channels include the first channel and are channels through which the first device sends data to the second device.

[0239] The sending unit 702 is configured to, in response to receiving the notification message, isolate the first channel and send data to the second device through a non-faulty channel among the plurality of channels.

[0240] In one possible implementation, the receiving unit 701 is specifically configured to: receive the notification message sent by the second device, the notification message including a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM), wherein the RDI message carries first indication information, the first AM carries second indication information, and both the first indication information and the second indication information are used to indicate a fault in the first channel.

[0241] In one possible implementation, the RDI message includes a channel status field, which carries the first indication information.

[0242] In one possible implementation, the idle pad domain segment of the first AM carries the second indication information.

[0243] In one possible implementation, the sending unit 702 is specifically configured to: send at least one first alignment information to the second device through the non-fault channel, the first alignment information including a second AM or a first fast alignment mark RAM, the at least one first alignment information being used by the second device to align the non-fault channel; and after sending the at least one first alignment information to the second device, send data to the second device through the non-fault channel.

[0244] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

[0245] In one possible implementation, sending data to the second device via the non-faulty channel includes: retransmitting data that failed to be transmitted due to a fault in the first channel to the second device via the non-faulty channel.

[0246] In one possible implementation, the sending unit 702 is further configured to send first data to the second device through the first channel, the first data being used to detect the first channel; the receiving unit 701 is further configured to receive a first response sent by the second device, the first response being used to indicate that the first channel has passed the detection, and the first channel passing the detection indicating that the first channel is fault-free.

[0247] In one possible implementation, the first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

[0248] In one possible implementation, the sending unit 702 is further configured to, in response to receiving the first response, perform channel isolation release measures on the first channel, and send data to the second device through the non-faulty channel and the first channel.

[0249] In one possible implementation, the transmitting unit 702 is specifically configured to: transmit at least one second alignment information to the second device through the non-faulty channel and the first channel, the second alignment information including a fourth AM or a third RAM, the at least one second alignment information being used by the second device to align the first channel and the non-faulty channel; after transmitting the at least one second alignment information to the second device, transmit data to the second device through the non-faulty channel and the first channel.

[0250] In one possible implementation, the non-faulty channel includes N channels, and the second alignment information is used by the second device to align the first channel and the N channels.

[0251] In one possible implementation, the apparatus further includes: the transmitting unit 702, which is further configured to transmit third indication information to the second device via the non-faulty channel before transmitting at least one second alignment information to the second device, the third indication information instructing the second device to align the first channel and the non-faulty channel.

[0252] In one possible implementation, the sending unit 702 is further configured to send a fourth indication message to the second device via the non-faulty channel before sending the first data to the second device via the first channel, the fourth indication message instructing the second device to detect the first channel.

[0253] Referring to Figure 8, this figure is a schematic diagram of the structure of another communication device provided in an embodiment of this application. The communication device 800 shown in Figure 8 is applied to the second device provided in the above embodiments to execute the method steps performed by the second device in the above embodiments.

[0254] As shown in Figure 8, the communication device 800 includes: a processing unit 801, a transmitting unit 802, and a receiving unit 803.

[0255] The processing unit 801 is used to determine a first channel fault, wherein the first device includes a first port, the second device includes a second port, and multiple channels are included between the first port and the second port, the multiple channels including the first channel, and the multiple channels are channels through which the first device sends data to the second device.

[0256] The sending unit 802 is used to send a notification message to the first device, the notification message indicating that the first channel is faulty.

[0257] The receiving unit 803 is configured to receive at least one first alignment information sent by the first device through a non-faulty channel among the plurality of channels. The first alignment information includes a second AM or a first fast alignment mark RAM. The at least one first alignment information is used by the second device to align the non-faulty channel.

[0258] The processing unit 801 is further configured to align the non-faulty channel according to the at least one alignment information.

[0259] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

[0260] In one possible implementation, the notification message includes: a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM), wherein the RDI message carries first indication information, the first AM carries second indication information, and both the first and second indication information are used to indicate a fault in the first channel.

[0261] In one possible implementation, the RDI message includes a channel status field, which carries the first indication information.

[0262] In one possible implementation, the idle pad domain segment of the first AM carries the second indication information.

[0263] In one possible implementation, the processing unit 801 is specifically configured to: determine that the first channel is faulty in response to M consecutive forward error correction (FEC) codewords received through the first channel being uncorrectable, wherein M is an integer greater than or equal to 2.

[0264] In one possible implementation, the non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels. The processing unit 801 is specifically used to: lock the at least one first alignment information and align the N channels.

[0265] In one possible implementation, the receiving unit 803 is further configured to: receive data sent by the first device through the non-faulty channel after aligning the non-faulty channel.

[0266] In one possible implementation, the receiving unit 803 is specifically configured to: receive data retransmitted by the first device that failed to be transmitted due to a fault in the first channel via the non-faulty channel.

[0267] In one possible implementation, the receiving unit 803 is further configured to receive first data sent by the first device through the first channel, the first data being used to detect the first channel; the processing unit 801 is further configured to use the first data to detect the first channel; and the sending unit 802 is further configured to send a first response to the first device in response to the first channel passing the detection, the first response being used to indicate that the first channel has passed the detection, and the first channel passing the detection indicating that the first channel is fault-free.

[0268] In one possible implementation, the first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

[0269] In one possible implementation, the receiving unit 803 is further configured to receive at least one second alignment information sent by the first device through the non-faulty channel and the first channel, the second alignment information including a fourth AM or a third RAM, the at least one second alignment information being used by the second device to align the first channel and the non-faulty channel; the processing unit 801 is further configured to align the first channel and the non-faulty channel according to the at least one second alignment information; the sending unit 802 is further configured to receive data sent by the second device through the non-faulty channel and the first channel after aligning the first channel and the non-faulty channel.

[0270] In one possible implementation, the non-faulty channel includes N channels, the second alignment information is used by the second device to align the first channel and the N channels, and the processing unit 801 is specifically used to: align the first channel and the N channels according to the at least one second alignment information.

[0271] In one possible implementation, the receiving unit 803 is further configured to receive, before receiving at least one second alignment information sent by the first device, a third indication information sent by the first device through the non-faulty channel, the third indication information instructing the second device to align the first channel and the non-faulty channel.

[0272] In one possible implementation, the receiving unit 803 is further configured to receive a fourth indication information sent by the first device through the non-faulty channel before receiving the first data sent by the first device through the first channel, the fourth indication information instructing the second device to detect the first channel.

[0273] Referring to Figure 9, this figure is a schematic diagram of the structure of a device provided in an embodiment of this application. The device 900 shown in Figure 9 includes an interface circuit 901 and a processing circuit 902. The interface circuit 901 is used to receive and / or transmit data, and the processing circuit 902 is used to perform data processing. The processing circuit 902 is optional.

[0274] In a specific example, the device 900 is used to perform the steps provided by the first device in the above embodiments, in which case the processing circuit 902 is optional.

[0275] The interface circuit 901 is used to receive a notification message indicating a first channel failure, wherein the first device includes a first port, the second device includes a second port, and multiple channels are included between the first port and the second port, the multiple channels including the first channel, the multiple channels being channels through which the first device sends data to the second device, and in response to receiving the notification message, to isolate the first channel, and to send data to the second device through a non-faulty channel among the multiple channels.

[0276] Optionally, the processing circuit 902 is used for retransmission control.

[0277] In yet another specific example, the device 900 is used to perform the steps provided in the above embodiments by the second device, in which case:

[0278] The processing circuit 902 is used to determine a first channel fault, wherein the first device includes a first port, the second device includes a second port, and multiple channels are included between the first port and the second port, the multiple channels including the first channel, and the multiple channels are channels through which the first device sends data to the second device.

[0279] The interface circuit 901 is used to send a notification message to the first device, the notification message indicating a fault in the first channel;

[0280] The first device receives at least one first alignment information through a non-faulty channel among the plurality of channels. The first alignment information includes a second AM or a first fast alignment mark RAM. The at least one first alignment information is used by the second device to align the non-faulty channel.

[0281] The processing circuit 902 is also used to align the non-faulty channel according to the at least one alignment information.

[0282] Referring to Figure 10, this figure is a schematic diagram of the structure of a device provided in an embodiment of this application.

[0283] In one example, the device 1000 shown in FIG10 can be used to perform the communication method provided in the above method embodiments.

[0284] Referring to Figure 10, device 1000 includes: processor 1010 (optional) and communication interface 1020. The number of processors 1010 in device 1000 can be one or more; Figure 10 shows an example with one processor. Processor 1010 is used for data processing.

[0285] Processor 1010 may be a central processing unit (CPU), an NP, or a combination of CPU and NP. Processor 1010 may further include hardware chips. The aforementioned hardware chips may be ASICs, programmable logic devices (PLDs), or combinations thereof. The aforementioned PLD may be complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), generic array logic (GALs), or any combination thereof.

[0286] The communication interface 1020 is used to receive and / or send data.

[0287] In a specific example, the device 1000 is used to perform the steps provided by the first device in the above embodiments, in which case the processor 1010 is optional.

[0288] The communication interface 1020 is used to receive a notification message indicating a first channel failure. The first device includes a first port, the second device includes a second port, and multiple channels are included between the first port and the second port. The multiple channels include the first channel and are channels through which the first device sends data to the second device. In response to receiving the notification message, the first channel is isolated, and data is sent to the second device through a non-faulty channel among the multiple channels.

[0289] In yet another specific example, the device 1000 is used to perform the steps provided in the above embodiments by the second device, in which case:

[0290] The processor 1010 is used to determine a first channel failure, wherein the first device includes a first port, the second device includes a second port, and a plurality of channels are included between the first port and the second port, the plurality of channels including the first channel, and the plurality of channels are channels through which the first device sends data to the second device.

[0291] The communication interface 1020 is used to send a notification message to the first device, the notification message indicating a fault in the first channel; and to receive at least one first alignment information sent by the first device through a non-faulty channel among the plurality of channels, the first alignment information including a second AM or a first fast alignment mark RAM, the at least one first alignment information being used by the second device to align the non-faulty channel.

[0292] The processor 1010 is also configured to align the non-faulty channel according to the at least one alignment information.

[0293] In one example, the device 1000 further includes a memory 1030. The memory 1030 may include volatile memory, such as random-access memory (RAM); the memory 1030 may also include non-volatile memory, such as flash memory, a hard disk drive (HDD), or a solid-state drive (SSD); the memory 1030 may also include combinations of the above types of memory. The memory 1030 may, for example, store the aforementioned data that failed to be transmitted due to a failure of the first channel.

[0294] Optionally, the memory 1030 stores an operating system and programs, executable modules, or data structures, or subsets thereof, or extended sets thereof. The programs may include various operation instructions for implementing various operations. The operating system may include various system programs for implementing various basic services and handling hardware-based tasks. The processor 1010 can read the programs in the memory 1030 to implement the methods provided in the embodiments of this application.

[0295] In one example, the processor 1010, communication interface 1020, and memory 1030 can be connected via a bus system or other means, with Figure 10 showing an example of connection via bus system 1040.

[0296] The bus system 1040 can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus system 1040 can be divided into address bus, data bus, control bus, etc. For ease of illustration, only one thick line is used in Figure 10, but this does not indicate that there is only one bus or one type of bus.

[0297] This application provides a computer-readable storage medium, including instructions or a computer program, which, when run on a computer, causes the computer to perform the methods described in the above method embodiments.

[0298] This application provides a computer program product containing instructions or computer programs, which, when run on a computer, causes the computer to perform the methods described in the above method embodiments.

[0299] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a particular order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in a sequence other than that illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0300] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0301] In the embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical business division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, indirect coupling or communication connection between apparatuses or units, and may be electrical, mechanical, or other forms.

[0302] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0303] Furthermore, the various business units in the embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software business unit.

[0304] If the integrated unit is implemented as a software business unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0305] Those skilled in the art will recognize that, in one or more of the examples above, the services described in this application can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, these services can be stored in a computer-readable medium or transmitted as one or more instructions or code on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein communication media include any medium that facilitates the transfer of computer programs from one place to another. Storage media can be any available medium accessible to general-purpose or special-purpose computers.

[0306] The above specific embodiments further illustrate the purpose, technical solution and beneficial effects of this application. It should be understood that the above are only specific embodiments of this application.

[0307] The above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.

Claims

1. A communication system, characterized in that, The system includes a first device and a second device. The first device includes a first port, and the second device includes a second port. Multiple channels are included between the first port and the second port. The multiple channels include a first channel, and the multiple channels are channels through which the first device sends data to the second device. The first device is used to receive a notification message indicating a fault in the first channel; The first device is also configured to, in response to receiving the notification message, isolate the first channel and send data to the second device through a non-faulty channel among the plurality of channels; The second device is used to receive data sent by the first device through a non-faulty channel among the plurality of channels after the first device isolates the first channel.

2. The system according to claim 1, characterized in that, The second device is further configured to determine the first channel failure and send the notification message to the first device. The notification message includes a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM), wherein the RDI message carries first indication information and the first AM carries second indication information, and both the first indication information and the second indication information are used to indicate the first channel failure. The first device is used to receive notification messages, specifically including: The first device is used to receive the notification message sent by the second device.

3. The system according to claim 2, characterized in that, The RDI message includes a channel status field, which is used to carry the first indication information.

4. The system according to claim 2, characterized in that, The idle pad domain segment of the first AM carries the second indication information.

5. The system according to any one of claims 1-4, characterized in that, The first device is used to isolate the first channel and to send data to the second device through a non-faulty channel among the plurality of channels, specifically including: At least one first alignment information is sent to the second device through the non-faulty channel. The first alignment information includes a second AM or a first fast alignment mark RAM. The at least one first alignment information is used by the second device to align the non-faulty channel. After sending the at least one first alignment information to the second device, data is sent to the second device through the non-faulty channel.

6. The system according to claim 5, characterized in that, The second device is also used for: The first device sends at least one first alignment information through a non-faulty channel among the plurality of channels, and the non-faulty channel is aligned according to the at least one alignment information. The second device is used to receive data sent by the first device through a non-faulty channel among the plurality of channels after the first device isolates the first channel, specifically including: After aligning the non-faulty channel, data sent by the first device is received through the non-faulty channel.

7. The system according to claim 6, characterized in that, The non-faulty channels include N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1. Aligning the non-faulty channels according to the at least one alignment information specifically includes: Align the N channels according to the at least one alignment information.

8. The system according to any one of claims 5-7, characterized in that, Sending data to the second device through the non-faulty channel includes: The data that failed to be transmitted due to the failure of the first channel is retransmitted to the second device through the non-faulty channel.

9. The system according to any one of claims 1-8, characterized in that, The first device is also used to send first data to the second device through the first channel, the first data being used to detect the first channel; The second device is also used to receive first data sent by the first device through the first channel, and to use the first data to detect the first channel; In response to the first channel passing the detection, a first response is sent to the first device, the first response indicating that the first channel has passed the detection, and the first channel passing the detection indicating that the first channel is fault-free; The first device is also configured to receive the first response sent by the second device.

10. The system according to claim 9, characterized in that, The first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

11. The system according to claim 9 or 10, characterized in that, The first device is also configured to, in response to receiving the first response, perform channel isolation release measures on the first channel, and send data to the second device through the non-faulty channel and the first channel; The second device is further configured to receive data sent by the first device through the non-faulty channel and the first channel after the first device performs channel isolation release measures on the first channel.

12. The system according to claim 11, characterized in that, The first device is used to perform channel isolation release measures on the first channel to send data to the second device through the non-faulty channel and the first channel, specifically including: At least one second alignment information is sent to the second device through the non-faulty channel and the first channel. The second alignment information includes a fourth AM or a third RAM. The at least one second alignment information is used by the second device to align the first channel and the non-faulty channel. After sending the at least one second alignment information to the second device, data is sent to the second device through the non-faulty channel and the first channel.

13. The system according to claim 12, characterized in that, The second device is also used for: The first device sends at least one second alignment information through the non-faulty channel and the first channel; Align the first channel and the non-faulty channel according to the at least one second alignment information; The second device is further configured to receive data sent by the first device through the non-faulty channel and the first channel after the first device performs channel isolation release measures on the first channel, specifically including: After aligning the first channel and the non-faulty channel, data sent by the first device is received through the non-faulty channel and the first channel.

14. The system according to claim 13, characterized in that, The non-faulty channel includes N channels, and the second alignment information is used by the second device to align the first channel and the N channels. The step of aligning the first channel and the non-faulty channel according to the at least one piece of second alignment information includes: Align the first channel and the N channels according to the at least one second alignment information.

15. The system according to any one of claims 12-14, characterized in that, The first device is further configured to send a third indication message to the second device via the non-faulty channel before sending at least one second alignment message to the second device, the third indication message indicating that the second device aligns the first channel and the non-faulty channel; The second device is also used to receive third indication information sent by the second device through the non-fault channel.

16. The system according to any one of claims 9-15, characterized in that, The first device is further configured to send a fourth indication message to the second device through the non-faulty channel before sending the first data to the second device through the first channel, the fourth indication message instructing the second device to detect the first channel; The second device is also configured to receive the fourth indication information sent by the first device through the non-fault channel.

17. The system according to any one of claims 2-4, characterized in that, The second device is used to determine a fault in the first channel, specifically including: In response to the non-correction of M consecutive forward error correction (FEC) codewords received through the first channel, a fault is determined in the first channel, wherein M is an integer greater than or equal to 2.

18. A communication method, characterized in that, Applied to a first device, the method includes: A notification message is received, indicating a first channel failure. The first device includes a first port, the second device includes a second port, and multiple channels are included between the first port and the second port. The multiple channels include the first channel and are channels through which the first device sends data to the second device. In response to receiving the notification message, the first channel is isolated, and data is sent to the second device through a non-faulty channel among the plurality of channels.

19. The method according to claim 18, characterized in that, The received notification message includes: The notification message sent by the second device is received. The notification message includes a Remote Defect Indication (RDI) message and / or a First Alignment Flag (AM). The RDI message carries first indication information, and the first AM carries second indication information. Both the first and second indication information are used to indicate a fault in the first channel.

20. The method according to claim 19, characterized in that, The RDI message includes a channel status field, which is used to carry the first indication information.

21. The method according to claim 19, characterized in that, The idle pad domain segment of the first AM carries the second indication information.

22. The method according to any one of claims 18-21, characterized in that, The isolation of the first channel and the transmission of data to the second device through a non-faulty channel among the plurality of channels include: At least one first alignment information is sent to the second device through the non-faulty channel. The first alignment information includes a second AM or a first fast alignment mark RAM. The at least one first alignment information is used by the second device to align the non-faulty channel. After sending the at least one first alignment information to the second device, data is sent to the second device through the non-faulty channel.

23. The method according to claim 22, characterized in that, The non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

24. The method according to claim 22 or 23, characterized in that, Sending data to the second device through the non-faulty channel includes: The data that failed to be transmitted due to the failure of the first channel is retransmitted to the second device through the non-faulty channel.

25. The method according to any one of claims 18-24, characterized in that, The method further includes: First data is sent to the second device through the first channel, and the first data is used to detect the first channel; The device receives a first response from the second device, the first response indicating that the first channel has passed the test, and the first channel passing the test indicating that the first channel is fault-free.

26. The method according to claim 25, characterized in that, The first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

27. The method according to claim 25 or 26, characterized in that, The method further includes: In response to receiving the first response, the system performs channel isolation release measures on the first channel and sends data to the second device through the non-faulty channel and the first channel.

28. The method according to claim 27, characterized in that, The step of performing channel isolation release measures on the first channel and sending data to the second device through the non-faulty channel and the first channel includes: At least one second alignment information is sent to the second device through the non-faulty channel and the first channel. The second alignment information includes a fourth AM or a third RAM. The at least one second alignment information is used by the second device to align the first channel and the non-faulty channel. After sending the at least one second alignment information to the second device, data is sent to the second device through the non-faulty channel and the first channel.

29. The method according to claim 28, characterized in that, The non-faulty channel includes N channels, and the second alignment information is used by the second device to align the first channel and the N channels.

30. The method according to claim 28 or 29, characterized in that, Before sending at least one second alignment information to the second device, the method further includes: A third instruction message is sent to the second device through the non-faulty channel, the third instruction message instructing the second device to align the first channel and the non-faulty channel.

31. The method according to any one of claims 25-30, characterized in that, Before sending the first data to the second device through the first channel, the method further includes: A fourth indication message is sent to the second device through the non-faulty channel, the fourth indication message instructing the second device to detect the first channel.

32. A communication method, characterized in that, Applied to a second device, the method includes: A first channel failure is identified, wherein the first device includes a first port, the second device includes a second port, and multiple channels are included between the first port and the second port, the multiple channels including the first channel, and the multiple channels are channels through which the first device sends data to the second device; Send a notification message to the first device, the notification message indicating a fault in the first channel; The first device receives at least one first alignment information through a non-faulty channel among the plurality of channels. The first alignment information includes a second AM or a first fast alignment mark RAM. The at least one first alignment information is used by the second device to align the non-faulty channel. Align the non-faulty channels according to the at least one alignment information.

33. The method according to claim 32, characterized in that, The non-faulty channel includes N channels, and the at least one alignment information is used by the second device to align the N channels, where N is an integer greater than or equal to 1.

34. The method according to claim 32 or 33, characterized in that, The notification message includes: The remote defect indication (RDI) message and / or the first alignment flag (AM) are used to indicate a fault in the first channel. The RDI message carries first indication information, and the first AM carries second indication information. Both the first and second indication information are used to indicate a fault in the first channel.

35. The method according to claim 34, characterized in that, The RDI message includes a channel status field, which is used to carry the first indication information.

36. The method according to claim 34, characterized in that, The idle pad domain segment of the first AM carries the second indication information.

37. The method according to any one of claims 32-36, characterized in that, The determination of the first channel fault includes: In response to the non-correction of M consecutive forward error correction (FEC) codewords received through the first channel, a fault is determined in the first channel, wherein M is an integer greater than or equal to 2.

38. The method according to any one of claims 32-37, characterized in that, The non-faulty channels include N channels, and the at least one alignment information is used by the second device to align the N channels. Aligning the non-faulty channels using the at least one alignment information includes: Lock the at least one first alignment information and align the N channels.

39. The method according to any one of claims 32-38, characterized in that, The method further includes: after aligning the non-faulty channel, receiving data sent by the first device through the non-faulty channel.

40. The method according to claim 39, characterized in that, Receiving data sent by the first device through the non-faulty channel includes: The non-faulty channel receives the data retransmitted by the first device that failed to be transmitted due to a fault in the first channel.

41. The method according to any one of claims 32-40, characterized in that, The method further includes: The first data sent by the first device is received through the first channel, and the first data is used to detect the first channel. The first channel is detected using the first data; In response to the first channel passing the detection, a first response is sent to the first device. The first response indicates that the first channel has passed the detection and that the first channel is fault-free.

42. The method according to claim 41, characterized in that, The first data includes a specific code block and a third AM, or the first data includes a specific code block and a second RAM.

43. The method according to claim 42, characterized in that, The method further includes: The second device receives at least one second alignment information sent by the first device through the non-faulty channel and the first channel. The second alignment information includes a fourth AM or a third RAM. The at least one second alignment information is used by the second device to align the first channel and the non-faulty channel. Align the first channel and the non-faulty channel according to the at least one second alignment information; After aligning the first channel and the non-faulty channel, data sent by the second device is received through the non-faulty channel and the first channel.

44. The method according to claim 43, characterized in that, The non-faulty channel includes N channels, and the second alignment information is used by the second device to align the first channel and the N channels. The step of aligning the first channel and the non-faulty channel according to the at least one piece of second alignment information includes: Align the first channel and the N channels according to the at least one second alignment information.

45. The method according to claim 43 or 44, characterized in that, Before receiving at least one second alignment information sent by the first device, the method further includes: The third indication information sent by the first device is received through the non-faulty channel, and the third indication information instructs the second device to align the first channel and the non-faulty channel.

46. ​​The method according to any one of claims 41-45, characterized in that, Before receiving the first data sent by the first device through the first channel, the method further includes: The second device receives a fourth indication message sent by the first device through the non-faulty channel, the fourth indication message instructing the second device to detect the first channel.

47. A communication device, characterized in that, The apparatus includes a unit for performing the method of any one of claims 18-46.

48. A communication device, characterized in that, It includes a processing circuit and an interface circuit, wherein the interface circuit is used to perform the receiving operation and / or transmitting operation as described in any one of claims 18-46, and the processing circuit is used to perform other operations as described in any one of claims 18-46 besides the receiving operation and the transmitting operation.

49. A computer program product, characterized in that, The computer program product includes instructions or a computer program that, when run on a computer, causes the computer to perform the method described in any one of claims 18-46.