| CPC H04L 69/18 (2013.01) [H04J 14/086 (2013.01); H04L 69/08 (2013.01); H04J 2203/0085 (2013.01); H04L 1/0006 (2013.01)] | 23 Claims |

|
1. A communication method performed by a first device, comprising:
obtaining, by the first device, a protocol type supported by a second port of a second device, wherein the protocol type supported by the second port of the second device is at least one of a flexible Ethernet protocol or a standard Ethernet protocol, and wherein a first port of the first device supports the flexible Ethernet protocol and the standard Ethernet protocol;
obtaining, by the first device, a first protocol type used by the second port for transmission, wherein the obtaining, by the first device, a first protocol type used by the second port for transmission comprises:
determining whether a first preset physical coding sublayer (PCS) code block is received; and
in response to determining that the first preset PCS code block is not received, determining that the first protocol type used by the second port for transmission is the standard Ethernet protocol;
determining, by the first device and based on the protocol type supported by the second port and a protocol type supported by the first port, whether a target protocol type is the flexible Ethernet protocol or the standard Ethernet protocol; and
communicating, by the first device, with the second device based on the target protocol type through the first port and the second port.
|