Method, device and system for switching channel direction
By sending and receiving channel direction adjustment messages between devices and dynamically switching channel direction, the problem of low channel bandwidth utilization in asymmetric service scenarios is solved, and efficient bandwidth utilization is achieved and link management complexity is reduced.
Patent Information
- Application Number
- CN202410122294.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-26
- Publication Date
- 2025-07-29
AI Technical Summary
In high-speed interconnection interfaces, in asymmetric service scenarios, the channel bandwidth utilization rate in the transmission and reception directions is low, and the existing technology cannot effectively solve it.
By adjusting the message and reply messages between devices, dynamically switch the channel direction, meeting the transmission needs of asymmetric services, improving channel bandwidth utilization, and reducing link management complexity.
It realizes efficient utilization of channel bandwidth in asymmetric service scenarios, reduces link management complexity, and improves the efficiency and robustness of channel direction switching.
Smart Images

Figure CN120389950A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of communication technologies, and in particular, to a method, apparatus, and system for switching channel directions. Background Art
[0002] In a high-speed interconnect interface, it generally includes a primary link for transmitting service information and an auxiliary link for transmitting control information. The primary link can also be referred to as a high-speed link, and specifically, it can include multiple channels that support high-speed data transmission. For example, the transmission rate supported by the channels of the primary link can be 2 Gbps, 4 Gbps, or 8 Gbps, etc. The auxiliary link can also be referred to as a low-speed link, and specifically, it can include multiple channels that support low-speed transmission. For example, the transmission rate supported by the channels of the auxiliary link can be 12.5 Mbps.
[0003] Currently, the channels in the transmit direction and receive direction included in a high-speed interconnect interface appear in pairs and are used to transmit service data with the same or similar data rates for transmission and reception. For an asymmetric service scenario, such as a service scenario with an upstream transmission rate of 4 Gbps and a downstream transmission rate of 200 Mbps, channels with a transmission rate of 4 Gbps need to be used in both the transmit direction and the receive direction, resulting in a problem of low channel bandwidth utilization. Summary of the Invention
[0004] This application provides a method, apparatus, and system for switching channel directions, which can be used to meet the transmission requirements of asymmetric services and improve channel bandwidth utilization.
[0005] To achieve the above object, the embodiments of this application adopt the following technical solutions:
[0006] In a first aspect, a method for switching channel directions is provided. The method includes: a first device sends a channel direction adjustment message to a second device. For example, when the first device determines that it is necessary to switch the channel direction according to the service transmission situation, it sends the channel direction adjustment message to the second device. The channel direction adjustment message is used to indicate the channel numbers of at least one first channel that needs to be switched. The at least one first channel is the transmit channel of the first device, and the at least one first device is determined by the first device; the first device receives an acknowledgment message from the second device. The acknowledgment message is used to confirm that the second device supports switching the channel direction of the at least one first channel, that is, when the second device supports switching the channel direction, it can send the acknowledgment message to the first device.
[0007] In the above technical solution, when the first device needs to switch the channel direction and the second device supports the channel direction switching, the first device and the second device can dynamically switch the channel direction of at least one first channel through the channel direction adjustment message and the response message. For example, at least one transmission channel of the first device can be adjusted to a reception channel. In this way, when the first device and the second device are in an asymmetric service transmission scenario, the transmission of asymmetric services can be satisfied by switching the channel directions of some channels, thereby improving the utilization rate of the channel bandwidth. In addition, since the channel direction adjustment message is initiated by the sending end of the at least one first channel, the complexity of link management caused by transceiver coupling can be reduced, that is, the complexity of link management is reduced.
[0008] In a possible implementation manner of the first aspect, the channel direction adjustment message includes a plurality of direction adjustment request parameters respectively corresponding to a plurality of transmission channels. The at least one direction adjustment request parameter corresponding to the at least one first channel is used to indicate a channel direction adjustment request, and the at least one direction adjustment request parameter corresponding to at least one second channel is used to indicate that the channel direction is not adjusted. The plurality of transmission channels include the at least one first channel and the at least one second channel. In the above possible implementation manner, the first device and the second device can simultaneously adjust the channel directions of a plurality of first channels through the channel direction adjustment message, thereby improving the switching efficiency of the channel direction.
[0009] In a possible implementation manner of the first aspect, the method further includes: the first device sends LLCF_EI on the at least one first channel, and the LLCF_EI is used to mark the end of data transmission; after a first preset duration, the first device switches the at least one first channel to a reception channel and performs channel training on the at least one first channel. In the above possible implementation manner, the first device notifies the second device of the end of data transmission by sending LLCF_EI on the at least one first channel, thereby ensuring that the second device can correctly receive the service data in the at least one first channel. In addition, the first device switches the at least one first channel to a reception channel and performs channel training after the first preset duration, which can avoid the bidirectional drive of the at least one first channel and ensure that the first device and the second device have enough time to switch the channel direction of the at least one channel.
[0010] In a possible implementation manner of the first aspect, the method further includes: the first device sends one or more of a channel lock feedback message LLFM, a clock lock feedback message CLFM, and an equalization feedback message EQFM to the second device. In the above possible implementation manner, the first device can perform flexible channel training according to the channel conditions of the at least one first channel, thereby improving the flexibility of channel training.
[0011] In a possible implementation of the first aspect, the method further includes: The first device receives at least one first LLCF_PAD on the at least one first channel, and aligns a plurality of receiving channels according to the at least one first LLCF_PAD. The plurality of receiving channels includes the at least one first channel and at least one third channel, and the at least one third channel is a receiving channel of the first device. In the above possible implementation, by aligning the plurality of receiving channels, the first device can reduce the delay deviation between channels, thereby ensuring the correct reception of data in the plurality of receiving channels.
[0012] In a possible implementation of the first aspect, the method further includes: The first device receives a second LLCF_PAD on a plurality of receiving channels, and the lengths of the second LLCF_PADs of different channels in the plurality of receiving channels are the same. The plurality of receiving channels includes the at least one first channel and at least one third channel. In the above possible implementation, by receiving the second LLCF_PADs of the same length on the plurality of receiving channels, the first device can ensure the smooth switching of data between the first device and the second device in the plurality of receiving channels.
[0013] In a possible implementation of the first aspect, the method further includes: The first device receives a first LLCF_DS on a plurality of receiving channels. The plurality of receiving channels includes the at least one first channel and at least one third channel. In the above possible implementation, the first device can determine the position of the service data transmitted in the plurality of receiving channels according to the first LLCF_DS received on the plurality of receiving channels, thereby realizing the correct reception of the service data.
[0014] In a possible implementation of the first aspect, the method further includes: The first device simultaneously sends a third LLCF_PAD on at least one second channel, and the lengths of the third LLCF_PADs of different channels in the at least one second channel are the same. In the above possible implementation, by simultaneously sending the third LLCF_PADs of the same length on the at least one second channel, the first device can ensure the smooth switching of data between the first device and the second device in the at least one second channel.
[0015] In a possible implementation of the first aspect, the method further includes: The first device simultaneously sends a second LLCF_DS on the at least one second transmitting channel. In the above possible implementation, by simultaneously sending the second LLCF_DS on the at least one second transmitting channel, the first device can enable the second device to determine the position of the service data transmitted in the at least one second transmitting channel according to the received second LLCF_DS, thereby realizing the correct reception of the service data.
[0016] In a possible implementation of the first aspect, the method further includes: if the response message is lost or abnormal, the first device retransmits the channel direction adjustment message. In the above possible implementation, by retransmitting the channel direction adjustment message, the success rate of switching the channel direction can be increased, and the robustness of the process of switching the channel direction can be enhanced.
[0017] In a possible implementation of the first aspect, the method further includes: when the number of retransmissions of the channel direction adjustment message is greater than a preset threshold, the first device sends a first error report, and the first error report is used to initiate link retraining. In the above possible implementation, the robustness of the process of switching the channel direction can be enhanced by sending the error report.
[0018] In a possible implementation of the first aspect, the method further includes: the second device receives a second error report, and the second error report is triggered by the loss or abnormality of LLCF_EI or the failure of LLCF_DS detection, and the second error report is used to initiate link retraining or link recovery. In the above possible implementation, the robustness of the process of switching the channel direction can be enhanced by sending the error report.
[0019] In a possible implementation of the first aspect, the first device sends a channel direction adjustment message to the second device, including: the first device sends the channel direction adjustment message to the second device through the primary link; or, the first device sends the channel direction adjustment message to the second device through the secondary link. The above possible implementation can improve the flexibility of sending the channel direction adjustment message, and at the same time can improve the transmission efficiency when sending the channel direction adjustment message through the primary link.
[0020] In a second aspect, a method for switching the channel direction is provided. The method includes: the second device receives a channel direction adjustment message from the first device, and the channel direction adjustment message is used to indicate the channel numbers of at least one first channel to be switched, and the at least one first channel is the receiving channel of the second device; the second device sends a response message to the first device, and the response message is used to confirm that the second device supports switching the channel direction of the at least one first channel.
[0021] In a possible implementation of the second aspect, the channel direction adjustment message includes a plurality of direction adjustment request parameters corresponding to the plurality of receiving channels respectively. The at least one direction adjustment request parameter corresponding to the at least one first channel is used to indicate a channel direction adjustment request, and the at least one direction adjustment request parameter corresponding to the at least one second channel is used to indicate that the channel direction is not adjusted. The plurality of receiving channels include the at least one first channel and the at least one second channel.
[0022] In a possible implementation of the second aspect, the method further includes: the second device receives LLCF_EI on the at least one first channel; after a second preset duration, the second device switches the at least one first channel to a transmission channel and performs channel training on the at least one first channel.
[0023] In a possible implementation of the second aspect, the method further includes: the second device receives one or more of a channel lock feedback message LLFM, a clock lock feedback message CLFM, and an equalization feedback message EQFM from the first device.
[0024] In a possible implementation of the second aspect, the method further includes: the second device sends at least one first padding logical link control frame LLCF_PAD on the at least one first channel, and the at least one first LLCF_PAD is used to align multiple transmission channels, and the multiple transmission channels include the at least one first channel and at least one third channel.
[0025] In a possible implementation of the second aspect, the method further includes: the second device simultaneously sends second LLCF_PAD on multiple transmission channels, and the lengths of the second LLCF_PAD on different channels in the multiple transmission channels are the same, and the multiple transmission channels include the at least one first channel and at least one third channel.
[0026] In a possible implementation of the second aspect, the method further includes: the second device simultaneously sends a first data start logical link control frame LLCF_DS on multiple transmission channels, and the multiple transmission channels include the at least one first channel and at least one third channel.
[0027] In a possible implementation of the second aspect, the method further includes: the second device receives third LLCF_PAD on at least one second channel, and the lengths of the third LLCF_PAD on different channels in the at least one second channel are the same.
[0028] In a possible implementation of the second aspect, the method further includes: the second device receives second LLCF_DS on the at least one second channel.
[0029] In a possible implementation of the second aspect, the method further includes: the second device receives the retransmitted channel direction adjustment message from the first device, and the retransmission of the channel direction adjustment message is triggered by the loss or abnormality of the response message.
[0030] In a possible implementation of the second aspect, the method further includes: when the retransmission times of the channel direction adjustment message are greater than a preset threshold, the second device receives a first error report from the first device, and the first error report is used to initiate link retraining.
[0031] In a possible implementation of the second aspect, the method further includes: if LLCF_EI is lost or abnormal, or LLCF_DS detection fails, the second device sends a second error report, and the second error report is used to initiate link retraining or link recovery.
[0032] In a possible implementation of the second aspect, the second device receives a channel direction adjustment message from the first device, including: the second device receives the channel direction adjustment message from the first device through the primary link; or, the second device receives the channel direction adjustment message from the first device through the secondary link.
[0033] In a third aspect, a device for switching the channel direction is provided. The device can implement the functions performed by the first device in the above method. The functions can be implemented by hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions.
[0034] In a possible implementation of the third aspect, the device includes a sending unit, a receiving unit, and a processing unit; the processing unit is configured to support the device to perform the corresponding functions in the above method for switching the channel direction; the sending unit and the receiving unit are used to support the device to communicate with the second device.
[0035] In another possible implementation of the third aspect, the device includes a processor and a transmitter; the processor is configured to support the device to perform the corresponding functions in the above method; the transmitter is used to support the device to communicate with the second device. Optionally, the device further includes a memory, and the memory is used to be coupled with the processor and store the necessary program instructions and data of the device.
[0036] In a fourth aspect, a device for switching the channel direction is provided. The device can implement the functions performed by the second device in the above method. The functions can be implemented by hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions.
[0037] In a possible implementation of the fourth aspect, the device includes a receiving unit, a sending unit, and a processing unit; the processing unit is configured to support the device to perform the corresponding functions in the above method for switching the channel direction; the receiving unit and the sending unit are used to support the device to communicate with the first device.
[0038] In another possible implementation of the fourth aspect, the device includes a processor and a receiver; the processor is configured to support the device to perform the corresponding functions in the above method; the receiver is used to support the device to communicate with the first device. Optionally, the device further includes a memory, and the memory is used to be coupled with the processor and store the necessary program instructions and data of the device.
[0039] In another aspect of the present application, a chip is provided, which includes a processing circuit and a transmitter, and the processing circuit and the transmitter are configured to support the chip to execute the method for switching the channel direction provided in the first aspect or any possible implementation manner of the first aspect; or the chip includes a processing circuit and a receiver, and the processing circuit and the receiver are configured to support the chip to execute the method for switching the channel direction provided in the second aspect or any possible implementation manner of the second aspect.
[0040] In another aspect of the present application, a data transmission system is provided, which includes a first device and a second device. The first device is configured to execute the method for switching the channel direction provided in the first aspect or any possible implementation manner of the first aspect, and the second device is configured to execute the method for switching the channel direction provided in the second aspect or any possible implementation manner of the second aspect.
[0041] In another aspect of the present application, a computer-readable storage medium is provided, in which a computer program or instruction is stored. When the computer program or instruction is run, the method for switching the channel direction provided in the first aspect or any possible implementation manner of the first aspect is implemented.
[0042] In another aspect of the present application, a computer-readable storage medium is provided, in which a computer program or instruction is stored. When the computer program or instruction is run, the method for switching the channel direction provided in the second aspect or any possible implementation manner of the second aspect is implemented.
[0043] In another aspect of the present application, a computer program product is provided, which includes a computer program (which can also be referred to as code or instruction). When the computer program is run, the computer is caused to execute the method for switching the channel direction provided in the first aspect or any possible implementation manner of the first aspect.
[0044] In another aspect of the present application, a computer program product is provided, which includes a computer program (which can also be referred to as code or instruction). When the computer program is run, the computer is caused to execute the method for switching the channel direction provided in the second aspect or any possible implementation manner of the second aspect.
[0045] It can be understood that the beneficial effects of the method, device, data transmission system, computer-readable storage medium, and computer program product provided in the above-mentioned second aspect can all refer to the beneficial effects in the first aspect, and will not be elaborated here. Description of the Drawings
[0046] Figure 1 Structural schematic diagram of a data transmission system provided by an embodiment of the present application;
[0047] Figure 2 Structural schematic diagram of another data transmission system provided by an embodiment of the present application;
[0048] Figure 3 Schematic diagram of basic components of an electronic device provided by an embodiment of the present application;
[0049] Figure 4 Schematic diagram of transmission between interfaces provided by an embodiment of the present application;
[0050] Figure 5 Flow schematic diagram of a method for switching the channel direction provided by an embodiment of the present application;
[0051] Figure 6 Schematic diagram of switching the channel direction of a certain channel provided by an embodiment of the present application;
[0052] Figure 7 Flow schematic diagram of another method for switching the channel direction provided by an embodiment of the present application;
[0053] Figure 8 Flow schematic diagram of yet another method for switching the channel direction provided by an embodiment of the present application;
[0054] Figure 9 Flow schematic diagram of another method for switching the channel direction provided by an embodiment of the present application;
[0055] Figure 10 Structural schematic diagram of a first device provided by an embodiment of the present application;
[0056] Figure 11 Structural schematic diagram of another first device provided by an embodiment of the present application;
[0057] Figure 12 Structural schematic diagram of a second device provided by an embodiment of the present application;
[0058] Figure 13 Structural schematic diagram of another second device provided by an embodiment of the present application. Detailed implementation manners
[0059] The following will discuss in detail the fabrication and use of each embodiment. However, it should be understood that many applicable inventive concepts provided by the present application can be implemented in a variety of specific environments. The specific embodiments discussed merely illustrate the specific ways of implementing and using the present application and the present technology, and do not limit the scope of the present application.
[0060] Unless otherwise defined, all technical terms used herein shall have the same meaning as commonly understood by those of ordinary skill in the art.
[0061] Each circuit or other component may be described as or referred to as "configured to" perform one or more tasks. In such cases, "configured to" is used to imply structure by indicating that the circuit / component includes the structure (e.g., circuitry) that performs the one or more tasks during operation. Thus, even when the specified circuit / component is currently inoperable (e.g., not powered on), the circuit / component can still be referred to as being configured to perform the task. Circuits / components used in conjunction with the phrase "configured to" include hardware, such as circuitry that performs the operation, etc.
[0062] In the following, the technical solutions in the embodiments of the present application will be described in conjunction with the accompanying drawings in the embodiments of the present application. In the present application, "at least one" means one or more, and "a plurality" means two or more. "And / or" describes the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone, where A and B can be singular or plural. The character " / " generally represents an "or" relationship between the associated objects before and after. "At least one of the following" or its similar expressions refer to any combination of these items, including any combination of single item(s) or plural item(s). For example, at least one of a, b, or c can represent: a, b, c, a and b, a and c, b and c, a, b, and c; where a, b, and c can be single or multiple.
[0063] The embodiments of the present application use terms such as "first" and "second" to distinguish objects with similar names, functions, or roles. Those skilled in the art can understand that terms such as "first" and "second" do not limit the quantity and execution order. The term "coupled" is used to indicate an electrical connection, including being directly connected through wires or connection terminals or indirectly connected through other devices. Therefore, "coupled" should be regarded as a broad sense of electronic communication connection.
[0064] It should be noted that in the present application, words such as "exemplary" or "for example" are used to give examples, illustrations, or explanations. Any embodiment or design solution described as "exemplary" or "for example" in the present application should not be construed as being more preferred or having more advantages than other embodiments or design solutions. Rather, the use of words such as "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0065] Before introducing the embodiments of the present application below, first, the related terms involved in the present application will be introduced and explained.
[0066] Lane: It refers to the path for transmitting signals. This lane can be unidirectional or bidirectional. Among them, the unidirectional lane includes a pair of differential signal lines, and the bidirectional lane includes two pairs of differential signal lines.
[0067] Link: It is a collection of lanes or a conductor line for power supply. A link generally includes one or more lanes. When a lane is working, a transmitter and a receiver are respectively turned on at both ends, and data (or called signal) is only transmitted from the transmitter to the receiver. For a link, the side where the transmitter is located is called the transmitting end or the transmitting side (transmitter side, Tx side), and the side where the receiver is located is called the receiving end or the receiving side (receiver side, Rx side). Links can be divided into downlink and uplink. The uplink refers to the link when a device (such as a game controller) sends signals to the main device (such as a display), and the downlink refers to the link when the main device (such as a routing device) sends signals to the slave device (such as a display).
[0068] Main link (ML): It is used for the transmission of high-speed data, such as the transmission of high-speed data like audio-visual signals and third-party protocol data.
[0069] Sideband link (SL): It is used for the transmission of low-speed data, such as the transmission of low-speed data like device management signals, port management signals, bandwidth management signals, and power supply management signals, and is also used for the transmission of control messages. The reliability of the sideband link when transmitting data is higher than that of the main link when transmitting data.
[0070] Link training: For a lane that has just been opened in a link, through processes such as channel clock recovery and locking, channel equalization, channel locking, and lane-to-lane de-skew, so that the lane can perform normal data exchange. This process is called link training, and it can also be called the link establishment process.
[0071] Channel clock recovery and locking: During the link training process, the process of the channel receiving end extracting the received clock from the received data packet is called channel clock recovery and locking, or channel clock recovery.
[0072] Channel Equalization: During link training, a signal is sent from the transmitter and transmitted through the channel to reach the receiver. During transmission, due to factors such as transmission rate, electromagnetic interference, and channel quality, the signal will be distorted, affecting the correct decision of the receiver on the signal. The more severe the signal distortion, the higher the bit error rate (BER, also known as the error rate), which will lead to worse communication performance of the channel. In order to obtain a high-quality signal that is easy to judge at the receiver, the signal can be conditioned and improved at the transmitter, during the transmission link, or before signal decision at the receiver, thereby reducing the impact of signal distortion on communication performance. This process is called channel equalization, or signal compensation.
[0073] Channel Locking: During link training, the process by which the receiver determines when a bit symbol starts to be transmitted is called channel locking. This process can also be called determining the boundary of the data transmitted by the channel.
[0074] Multi-channel Alignment: During the data transmission process of multiple channels, there will be certain differences in the transmission delays of different channels, that is, the arrival times of the data of each channel are inconsistent, which will introduce the problem of delay skew (or phase offset). In order to ensure that the receivers of the channels can process the received data correctly and simultaneously, it is necessary to adjust and compensate each channel. This process is called the channel deskew (or delay skew elimination) process, and is also called the channel alignment process.
[0075] Logical Layer Control Frame (LLCF): Data used to implement link management functions such as link training and status update. Logical Layer Block (LLB), the basic unit of data transmission.
[0076] Exemplarily, as shown in Table 1 and Table 2 below, the frame format of the LLCF includes a frame header, which includes a frame type and a checksum. The frame type is used to indicate the frame type, and the checksum is the check bit for the frame type. Optionally, the frame format of the LLCF can also include a payload, which is the information carried by the control frame of the corresponding type. Among them, the LLCF can include one or more frame headers. The frame type and checksum in each frame header can each occupy one byte (B), that is, the lengths of the frame type and checksum can both be 1B; the payload in the LLCF can occupy one or more bytes, that is, the length of the payload is variable. Exemplarily, the LLCF includes multiple frame headers and a payload. Frame header 1 occupies bytes B0 and B1, frame header 2 occupies bytes B2 and B3, frame header 3 occupies bytes B4 and B5, and the payload occupies byte B6. The contents of frame header 1, frame header 2, and frame header 3 in the above frame structure are the same, constituting a repetition code.
[0077] Table 1
[0078]
[0079] Table 2
[0080] Field Segment Description Frame Type Indicates the frame type, with a length of 1B Checksum Checksum bit for the frame type, with a length of 1B Payload Information carried by the control frame of the corresponding type, with a variable length
[0081] The frame type, checksum, payload length, and description of the control frames involved in this application are as shown in Table 3 below and may include:
[0082] Logic layer training sequence 0 (LLCF_TS0), which is used for clock locking during the training phase.
[0083] Logic layer training sequence 1 (LLCF_TS1), which is used for channel parameter tuning calculation during the training phase.
[0084] Logic layer training sequence 2 (LLCF_TS2), which is used for transceiver acknowledgment synchronization status.
[0085] Logic layer electrical idle (LLCF_EI), which is used to mark the end of transmission of this lane, and the subsequent data should be discarded. LLCF_EI can also be called the electrical idle logic layer control frame.
[0086] Logic layer data start (LLCF_DS), which marks the start position of a new logical block, and the logical block data follows LLCF_DS for transmission. LLCF_DS can also be called the data start logic layer control frame.
[0087] Padding logic layer control frame (LLCF_PAD), which is used for padding. LLCF_PAD can also be called the padding logic layer control frame.
[0088] Table 3
[0089] Control Frame Frame Type Checksum Payload Length Description LLCF_TS0 -- -- Variable Length Clock Locking Sequence, with a payload of 01 sequence LLCF_TS1 -- -- Variable Length Training sequence with a payload of PRBS11 LLCF_TS2 0x6C x56 8B Payload is a PRBS11 sequence for transceiver synchronization confirmation LLCF_EI 0x65 0x69 0 Marks the end of frame data LLCF_DS 0x4B 0xA3 0 Marks the start of a new LLB transmission LLCF_PAD 0xD2 0x65 Variable Length Used for padding, discarded directly upon reception
[0090] The technical solution provided by this application can be applied to a data transmission system including multiple data transmission devices. The data transmission device can be a device, a chip applied to a device, or an interface device, etc. In this data transmission system, the data transmission devices (for example, data sending devices) and the data transmission devices (for example, data receiving devices) can be directly connected, or can be indirectly connected through a switching device such as a router, that is, the multiple data transmission devices can all be connected to the switching device. In this application, the multiple data transmission devices can perform data transmission in a wired manner or in a wireless manner. In addition, when the multiple data transmission devices perform data transmission, they can directly transmit signals, or can transmit signals through an interface device.
[0091] When the data transmission device is a chip in a device, the chips in the data transmission system can be interconnected in a wired or wireless manner. The chip can be a chip in a device, a chip in a docking station, or a chip in an adapter, etc. Among them, a gigabit network port, a video graphics array (VGA), an HDMI, a trans flash (TF) card, a secure digital (SD) card, a charging interface, and a USB interface, etc. can be plugged into the docking station.
[0092] Optionally, when the data transmission device is a chip, the chip can further include an interface module, that is, this application can be applied to the interface module for interconnection between chips. The interface module can be understood as an intellectual property (IP) module integrated inside the chip. Or, the interface module can also be independently sold as an IP module. For example, the chip can be a system on chip (SoC), a central processing unit (CPU), or a graphics processing unit (GPU), etc. The above interface module can be an interface module in an SoC, a CPU, or a GPU, etc. Optionally, the interface module can be a sending circuit and / or a receiving circuit.
[0093] The following takes the data transmission system including multiple devices as an example to illustrate the structure of the data transmission device by way of example.
[0094] Figure 1Schematic diagram of a data transmission system provided by an embodiment of the present application. The data transmission system includes a first device 110 and a second device 120, and the first device 110 and the second device 120 are connected by wired or wireless means, for example, connected by a cable. Among them, signals can be transmitted between the first device 110 and the second device 120, for example, audio-video data transmission or charging signal transmission, etc. In one example, the first device 110 can be a set-top box, and the second device 120 can be a TV. The set-top box and the TV can be connected by a cable, and the set-top box can transmit audio-video data to the TV through the cable. In another example, the first device 110 is a display, and the second device 120 is a game controller. The display and the game controller can be connected by a cable, and the game controller can transmit control information to the display through the cable.
[0095] Optionally, the first device 110 may include interface A, and the second device 120 may include interface B. The connection between the first device 110 and the second device 120 may specifically be the connection between interface A of the first device 110 and interface B of the second device 120. For example, interface A of the first device 110 and interface B of the second device 120 are connected by a cable.
[0096] Figure 2 Schematic diagram of another data transmission system provided by an embodiment of the present application. The data transmission system includes multiple devices 210 and a router 220. The multiple devices 210 can be connected to the router 220 by wired or wireless means. For example, the multiple devices 210 can all be connected to the router 220 by cables. Among them, signals can be transmitted between any two of the multiple devices 210 through the router 220, for example, audio-video data transmission or charging signal transmission, etc. In one example, the multiple devices 210 may include a display 211, a set-top box 212, and an audio player (such as an MP3) 213. The set-top box 212 can transmit audio-video data to the display 211 through the router 220, and the set-top box 212 can also transmit audio data to the audio player 213 through the router 220, etc. In addition, there may be two interconnected devices among the multiple devices 210. For example, the multiple devices 210 may also include a game controller 214, and the game controller 214 can be connected to the display 211 and transmit control information to the display 211.
[0097] Optionally, each of the multiple devices 210 may include an interface, the router 220 may include multiple interfaces, and the interface of each of the multiple devices 210 may be connected to one of the multiple interfaces of the router 220. For example, the multiple devices 210 include a display, a set-top box, a game controller, and an audio player, the multiple interfaces of the router 220 include a first interface to a fourth interface, the interface of the display is connected to the first interface of the router 220 through a cable, the interface of the set-top box is connected to the second interface of the router 220 through a cable, the interface of the game controller is connected to the third interface of the router 220 through a cable, and the interface of the audio player is connected to the fourth interface of the router 220 through a cable.
[0098] The devices in the above system with data transmission functions may be referred to as communication devices. The communication devices may be deployed on land, including indoor or outdoor, handheld or vehicle-mounted. The communication devices may also be deployed on water (such as ships, etc.), and may also be deployed in the air (such as airplanes, balloons, satellites, etc.). The communication devices may be applied to different scenarios. Exemplarily, the communication devices may include, but are not limited to: mobile phones, tablet computers, laptop computers, palmtop computers, mobile internet devices (MIDs), cameras, wearable devices (such as smart watches, smart bracelets, pedometers, etc.), audio devices, audio and video players, set-top boxes, game consoles, printers, mice, keyboards, vehicle-mounted devices (such as devices on vehicles such as cars, bicycles, electric vehicles, airplanes, ships, trains, and high-speed rails), virtual reality (VR) devices, augmented reality (AR) devices, wireless terminals in industrial control, smart home devices (such as refrigerators, TVs, air conditioners, electricity meters, etc.), smart robots, workshop devices, wireless terminals in self-driving, wireless terminals in remote medical surgery, wireless terminals in smart grid, wireless terminals in transportation safety, wireless terminals in smart city, or wireless terminals in smart home, flying devices (such as smart robots, hot air balloons, drones, airplanes), etc. Optionally, the signals transmitted between the above communication devices may include, but are not limited to: audio and video signals, radio frequency signals, Internet of Things data, and charging signals, etc.
[0099] In this application, the interface specifications adopted for signal transmission between devices in a data transmission system may include, but are not limited to: universal serial bus (USB) interface specification, high definition multimedia interface (HDMI) specification, display port (DP) specification, unified multimedia interconnection (UMI) interface specification, and peripheral component interconnect express (PCI-Express) interface specification, etc. Correspondingly, the interfaces may be HDMI, miniHDMI, micro HDMI, type-A interface, type-B interface, Micro-B, and type-C interface, etc.
[0100] For example, in the above example, the interface connection method between the set-top box and the TV, or the interface connection method between the game console and the monitor may be connected through a USB cable, and the interface standard followed is the USB interface specification. Or, this connection method may be connected through an HDMI cable, and the interface standard followed is the HDMI interface specification.
[0101] It can be understood that the interface specifications adopted for signal transmission between the above devices are only exemplary. In actual applications, the interface specifications may also include other or any interface specifications that may appear in the future, such as unified media interconnection (UMI) interface, etc. The embodiments of this application do not make specific limitations on this.
[0102] In this application, when the above device is an electronic device, such as Figure 3The figure shows a schematic diagram of the basic components of an electronic device. The electronic device includes an interface chip 300 (for example, a UMI interface), and the interface chip 300 includes one or more adapters 301, one or more management control adapters 302, and one or more ports 303; or when the electronic device is a routing device, the interface chip 300 only includes one or more ports 303. Each of the one or more adapters 301 can be coupled to an external component of the interface chip 300. One or the management control adapters 302 can be coupled to a component outside the interface chip 300 for management and control. The port 303 can be coupled to a connector 304 of the electronic device, and the connector 304 is used to couple an external device of the electronic device. Among them, one or more adapters 301 can be sending / receiving adapters. For example, when the adapter 301 is used for audio / video format adaptation, the adapter 301 can be an audio / video sending / receiving adapter. When the adapter 301 is used for third-party protocol adaptation, the adapter 301 can be a third-party protocol adapter.
[0103] For example, when the port 303 is a downstream port, the sending adapter can be used to adapt the service information to be sent into the service information to be transmitted on the port 303 of the interface chip, and send the service information through the port 303. When the port 303 is an upstream port, the receiving adapter 301 can be used to adapt the service information received from the port 303 into the service information for internal processing by the electronic device for internal processing. The management control adapter 302 can be used to adapt control information.
[0104] The basic components of different electronic devices can be combined to form various different device types. For example, a source device that includes at least one downstream port and at least one audio / video sending adapter, or a source device that includes at least one upstream port and includes an audio / video receiving adapter, or a docking station device that includes at least one upstream port, at least one audio / video receiving adapter, and at least one traditional audio / video interface, or a routing device that includes at least one downstream port and at least one upstream port, and has no audio / video sending adapter and audio / video receiving adapter, or a composite device that has both an upstream port and a downstream port.
[0105] As Figure 4 The figure shows a schematic diagram of inter-interface transmission provided by an embodiment of the present application. Between the upstream port and the downstream port between devices, there can be a main link ML and an auxiliary link SL. The main link can be used for the transmission of high-speed data, such as the transmission of audio / video signals. The auxiliary link can be used for management and control between devices, such as device discovery, capability query, device configuration, device control, etc., and can also be used for the transmission of low-speed data and control messages.
[0106] In a possible embodiment, the main link may include multiple channels, and each channel may support unidirectional transmission; the auxiliary link may include two unidirectional channels in different directions. In other possible embodiments, the main link may include multiple channels, a part of the multiple channels being unidirectional channels and another part being bidirectional channels; the auxiliary link may include a bidirectional channel. Exemplarily, a main link may include multiple channels. For example, the number of the multiple channels may be 2, 5, or 9, etc. Among them, the larger the number of channels included in the main link, the faster the corresponding data transmission speed. Exemplarily, as Figure 4 shown, for the upstream port, the main link may include n transmit channels TX1 - TXn (i.e., channels 1 to n) and m receive channels RX1 - RXm (i.e., channels n + 1 to n + m), and the auxiliary link includes a transmit channel SBTX and a receive channel SBRX, where n and m are positive integers; for the downstream port, the main link may include n receive channels RX1 - RXn and m transmit channels TX1 - TXm, and the auxiliary link includes a receive channel SBRX and a transmit channel SBTX.
[0107] Further, between the upstream port and the downstream port of the device, there may also be a power - bus link (PL) and a cable - information link (CL). The cable - information link can be used to transmit cable information, such as the model of the cable and cable - capacity information, etc. Figure 4 The power - bus link and the cable - information link are not shown in
[0108] It can be understood that for the ports between devices, whether it is an upstream port or a downstream port, it may include multiple pins, such as pins connecting to the ground wire, pins connecting to the power supply wire, pins connecting to the channels of the main link, and pins connecting to the channels of the auxiliary link, etc.
[0109] In a high - speed interconnect interface, the above - mentioned main link may also be referred to as a high - speed link, which may specifically include multiple channels supporting high - speed data transmission. For example, the transmission rate supported by the channels of the main link may be 2 Gbps, 4 Gbps, or 8 Gbps, etc.; the above - mentioned auxiliary link may also be referred to as a low - speed link, which may specifically include multiple channels supporting low - speed transmission. For example, the transmission rate supported by the channels of the auxiliary link may be 12.5 Mbps.
[0110] Currently, the channels in the transmission direction and the reception direction included in a high-speed interconnect interface (or referred to as the transmission channel and the reception channel) appear in pairs and are used to transmit and receive service data with the same or similar data rates. For an asymmetric service scenario, such as a service scenario with an upstream transmission rate of 4 Gbps and a downstream transmission rate of 200 Mbps, channels with a transmission rate of 4 Gbps need to be used in both the transmission direction and the reception direction, resulting in a problem of low channel bandwidth utilization.
[0111] Based on this, an embodiment of the present application provides a method for switching the channel direction. At least one first channel between a first device and a second device in this method can dynamically switch the channel direction through a lane direction adjust message (LDAM) and an acknowledgment message. For example, at least one transmission channel of the first device can be adjusted to at least one reception channel. In this way, when the first device and the second device are in an asymmetric service transmission scenario, the channel direction of some channels can be switched. For example, when the upstream transmission rate is 4 Gbps and the downstream transmission rate is 200 Mbps, some channels for downstream transmission can be switched to channels for upstream transmission to meet the transmission of asymmetric services and improve the utilization rate of the channel bandwidth. In addition, since the lane direction adjust message is initiated by the first device (i.e., the sending end of the at least one first channel), the link management complexity caused by transceiver coupling can also be reduced, that is, the link management complexity is reduced.
[0112] In the embodiments of the present application, the two words "switch" and "adjust" can be replaced with each other, or it can be said that the meanings expressed by the two are equivalent. For example, switching the channel direction in the present application can be replaced with adjusting the channel direction.
[0113] Figure 5 FIG. is a schematic flowchart of a method for switching the channel direction provided by an embodiment of the present application. This method can be applied to the data transmission system provided above. For example, the data transmission system includes a first device and a second device, and this method includes the following steps.
[0114] S401a: The first device sends a lane direction adjust message to the second device. This lane direction adjust message is used to indicate the channel numbers of at least one first channel that needs to be switched. Correspondingly, S401b: The second device receives this lane direction adjust message.
[0115] Among them, the at least one first channel can be a transmission channel (or referred to as a TX channel) of the first device, or a channel of the first device in the transmission direction. Correspondingly, the at least one first channel can also be referred to as a reception channel (or referred to as an RX channel) of the second device, or a channel of the second device in the reception direction. Optionally, the at least one channel is a channel in the main link.
[0116] Taking the first device as an example, the at least one first channel may be part or all of the multiple transmission channels of the first device. Optionally, when the first device determines that a channel direction switch is required, the first device may determine the at least one first channel from the multiple transmission channels of the first device. For example, the first device may determine the at least one first channel based on the service transmission conditions on the transmission channels and the reception channel. Exemplarily, as Figure 6 shown, the first device communicates with the second device through 3 transmission channels (denoted as channel 0 to channel 2) and 1 reception channel (denoted as channel 3). When the amount of service to be transmitted by the first device decreases and the amount of service to be received increases, the first device may determine to switch the channel direction of channel 2, that is, the first device may initiate a channel direction switch to switch channel 2 to a reception channel. Figure 6 TX and RX in
[0117] Optionally, the channel direction adjustment message includes multiple direction adjustment request parameters corresponding to the multiple transmission channels respectively. The at least one direction adjustment request parameter corresponding to the at least one first channel is used to indicate a channel direction adjustment request, and the at least one direction adjustment request parameter corresponding to the at least one second channel is used to indicate no channel direction adjustment. The multiple transmission channels include the at least one first channel and the at least one second channel. That is, the channel direction adjustment message can be used to indicate switching the channel directions of some transmission channels of the first device.
[0118] In a possible embodiment, the first device sends the channel direction adjustment message to the second device through the primary link. At this time, the second device receives the channel direction adjustment message through the primary link. In another possible embodiment, the first device sends the channel direction adjustment message to the second device through the secondary link. At this time, the second device receives the channel direction adjustment message through the secondary link.
[0119] In an example, when the first device sends the channel direction adjustment message through the primary link, the channel direction adjustment message may be carried in a logical layer main link management packet (LLMMP). For example, the arrangement format of the channel direction adjustment message LDAM in the LLMMP may be as shown in Table 4 below.
[0120] Table 4 Arrangement format of LDAM in LLMMP
[0121]
[0122] In another example, when the first device sends the channel direction adjustment message via the auxiliary link, the channel direction adjustment message may be carried in a logical layer sideband link management packet (LLSMP). For example, the arrangement format of the channel direction adjustment message LDAM in the LLSMP may be as shown in Table 5 below.
[0123] Table 5 Arrangement format of LDAM in LLSMP
[0124]
[0125] S402a: The second device sends a response message to the first device, and the response message is used to confirm that the second device supports switching the channel direction of the at least one first channel. Correspondingly, S402b: The first device receives the response message.
[0126] In a possible embodiment, when the port corresponding to the second device supports switching the channel direction, the second device sends the response message to the first device via the primary link or the auxiliary link. For example, the response message may be an acknowledgement (ACK) message; when the first device receives the response message via the primary link or the auxiliary link, the first device may confirm that the second device supports switching the channel direction of the at least one first channel according to the response message. Optionally, before receiving the response message, the first device may still normally send service data via the at least one first channel.
[0127] Optionally, when the port corresponding to the second device does not support switching the channel direction, the second device sends a negative response message to the first device. For example, the negative response message may be a negative acknowledgement (NACK) message; when the first device receives the negative response message, the first device may confirm that the second device does not support switching the channel direction of the at least one first channel according to the negative response message. Among them, when the second device sends a negative response message to the first device, the process ends, and the first device and the second device perform service reception and transmission based on the original channel direction (or called channel state).
[0128] Further, after the first device receives the response message fed back by the second device, the first device and the second device may manage the at least one first channel and use the at least one first channel for data transmission. The following is an example through Figure 7 for illustration.
[0129] Combined with Figure 5 , as Figure 7As shown, after S402a - S402b, the method further includes: one or more pairs of steps from S403a - S403b to S407a - S407b. Figure 7 In this example, the method further includes S403a - S403b to S407a - S407b. The embodiments of the present application do not specifically limit the sequence of the above - mentioned multiple pairs of steps. Figure 7 The sequence shown is only exemplary and does not limit the embodiments of the present application.
[0130] S403a: The first device sends LLCF_EI on the at least one first channel. Correspondingly, S403b: The second device receives LLCF_EI on the at least one first channel.
[0131] In a possible embodiment, when the first device receives the response message from the second device, the first device may send LLCF_EI on the at least one first channel. For example, send one LLCF_EI on each of the at least one first channels. The LLCF_EI of each channel can be used to mark the end of data transmission on that channel. In this way, when the second device receives the LLCF_EI on each of the at least one first channels, it can determine the end of data transmission on that channel according to the LLCF_EI of each channel. Optionally, after the first device sends LLCF_EI on the at least one first channel, the at least one first channel can enter the low - power state.
[0132] S404a: After a first preset duration, the first device switches the at least one first channel to a receiving channel and performs channel training on the at least one first channel. Correspondingly, S404b: After a second preset duration, the second device switches the at least one first channel to a transmitting channel and performs channel training on the at least one first channel.
[0133] Optionally, the first device executes S404a after receiving the above - mentioned response message or after S403a, and the second device may execute S404b after sending the response message or after S403b. The embodiments of the present application do not specifically limit this.
[0134] Among them, the first preset duration and the second preset duration may be equal or unequal. In one example, the first preset duration is equal to the second preset duration. In another example, the first preset duration is unequal to the second preset duration. For example, the first preset duration is equal to the sum of the second preset duration and the transmission delay of the LLCF_EI of the at least one first channel. In the embodiments of the present application, the first device and the second device respectively switch the channel directions of the at least one channel after the first preset duration and the second preset duration, that is, the first device and the second device can wait for a period of time and then switch the channel directions of the at least one channel, which can avoid the bidirectional driving of the at least one channel and ensure the switching time of the first device and the second device.
[0135] In addition, the first device switches the at least one first channel to a receiving channel, which can also be referred to as: the first device switches the at least one first channel from the TX mode to the RX mode, or the first device switches the channel direction of the at least one first channel from the transmitting direction to the receiving direction. After the first device switches the at least one first channel to a receiving channel, the at least one first channel can be referred to as the newly added receiving channel of the first device.
[0136] Similarly, the second device switches the at least one first channel to a transmitting channel, which can also be referred to as: the second device switches the at least one first channel from the RX mode to the TX mode, or the second device switches the channel direction of the at least one first channel from the receiving direction to the transmitting direction. After the second device switches the at least one first channel to a transmitting channel, the at least one first channel can be referred to as the newly added transmitting channel of the second device.
[0137] In a possible embodiment, for the at least one first channel, if the channel supports fast link establishment, the channel enters the channel locking process, and the second device continuously sends LLCF_TS2 on the channel to initiate channel locking; if the channel does not support fast link establishment, the channel enters the channel clock recovery and locking process, and the second device needs to send a training start message (TSM) to indicate the start of initial training for the corresponding channel. At the same time, the second device sends LLCF_TS0 on the channel, and then waits for the first device to send a clock lock feedback message (CLFM). After the channel clock locking is completed, the second device sends from LLCF_TS1 until it receives an equilibrium feedback message indication (EQFM) that the channel equalization is successful. After the channel equalization is successful, the second device sends LLCF_TS2 to perform the channel locking process. Then, the second device waits for the first device to feedback a lane lock feedback message (LLFM) to indicate that the channel is locked.
[0138] Further, when the at least one first channel of the first device is switched to a receiving channel, according to whether it supports the fast link establishment process, the at least one first channel receives at least one or more of LLCF_TS0, LLCF_TS1, and LLCF_TS2 from the second device to perform channel training (also known as link training). During the training process, the first device sends one or more channel training messages among the clock lock feedback message CLFM, the equilibrium feedback message EQFM, and the lane lock feedback message LLFM to the second device according to the specific process of the training; in this way, the second device can receive the one or more channel training messages fed back by the first device. Optionally, the first device can send the one or more channel training messages through the main link or the auxiliary link.
[0139] In a possible embodiment, for the at least one first channel, if the channel supports fast link establishment, the first device sends an LLFM to the second device; if the channel does not support fast link establishment, the first device sends a CLFM to the second device to indicate the channel clock recovery and locking result, sends an EQFM to indicate the channel equalization result, and sends an LLFM to indicate the channel locking result of the at least one first channel. If the CLFM indicates that the channel clock locking fails, or the EQFM indicates that the channel equalization fails, or the LLFM indicates that any channel is not locked successfully, the process ends. The first device and the second device perform receiving and sending of services based on the number of channels currently being transmitted. At this time, the number of transmitting channels of the first device has decreased.
[0140] It can be understood that for the detailed descriptions of the channel clock recovery and locking process, channel equalization process, channel locking process, and channel alignment process involved in the above channel training, reference can be made to the descriptions in the related technologies, and the embodiments of the present application will not provide specific descriptions here.
[0141] S405a: The second device sends at least one first LLCF_PAD on the at least one first channel. Correspondingly, S405b: When the first device receives the at least one first LLCF_PAD on the at least one first channel, aligns a plurality of receiving channels according to the at least one first LLCF_PAD, the plurality of receiving channels includes the at least one first channel and at least one third channel, and the at least one third channel is a receiving channel of the first device.
[0142] Among them, the at least one first channel may be a newly added receiving channel of the first device. The at least one third channel may be the original receiving channel (hereinafter referred to as the original receiving channel) of the first device in the high-speed state before the channel direction of the at least one first channel is switched. The plurality of receiving channels includes the newly added receiving channel of the first device and the original receiving channel of the first device, that is, the plurality of receiving channels are all the receiving channels of the first device currently in the high-speed state.
[0143] In a possible embodiment, the second device sends at least one first LLCF_PAD on the at least one first channel, and each channel in the at least one first channel may correspondingly send at least one first LLCF_PAD; the first device receives at least one first LLCF_PAD on each channel in the at least one first channel, and aligns the plurality of receiving channels according to the at least one first LLCF_PAD received in the at least one first channel. Exemplarily, during the channel switching process, communication in the at least one third channel of the first device has not been interrupted, and the at least one third channel is still transmitting data packets. The first device can align the positions of the logical layer control frames LLCF sent on the at least one first channel and the at least one third channel through the at least one first LLCF_PAD sent, that is, the first device aligns the positions of the LLCF sent on the newly added receiving channel and the original receiving channel.
[0144] S406a: The second device simultaneously sends second LLCF_PAD on a plurality of transmitting channels, and the lengths of the second LLCF_PAD of different channels in the plurality of transmitting channels are the same. The plurality of transmitting channels includes the at least one first channel and at least one third channel, and the at least one third channel is a transmitting channel of the second device. Correspondingly, S406b: The first device receives the second LLCF_PAD on the plurality of receiving channels.
[0145] Among them, the multiple transmission channels of the second device are the same as the multiple reception channels of the first device in the above text. Similarly, the at least one first channel can be a newly added transmission channel of the second device; the at least one third channel can be the original transmission channel (referred to as the original transmission channel) of the second device in the high-speed state before the channel direction of the at least one first channel is switched; the multiple transmission channels include the newly added transmission channels of the second device and the original transmission channels of the second device, that is, the multiple transmission channels are all the transmission channels of the second device currently in the high-speed state.
[0146] In addition, the lengths of the second LLCF_PAD of different channels in the multiple transmission channels are the same, that is, the lengths of the second LLCF_PAD sent by the second device in the multiple transmission channels are all the same. For example, the length can be expressed as cf_pad_length, and the corresponding maximum value can be 128 bytes (byte), and the minimum value can be 32 bytes.
[0147] In a possible embodiment, the second device simultaneously sends a second LLCF_PAD on all the transmission channels (i.e., the multiple transmission channels) in the high-speed state, so that the first device can receive a second LLCF_PAD on each of the corresponding multiple reception channels, so as to realize the smooth switching of the data between the second device and the first device through the second LLCF_PAD on the multiple transmission channels.
[0148] Optionally, after the first device receives the second LLCF_PAD on the multiple reception channels, the first device can reset the scrambling seeds corresponding to the multiple reception channels.
[0149] S407a: The second device simultaneously sends the first LLCF_DS on the multiple transmission channels. Correspondingly, S407b: The first device receives the first LLCF_DS on the multiple reception channels.
[0150] In a possible embodiment, the second device simultaneously sends a first LLCF_DS on all the transmission channels (i.e., the multiple transmission channels) in the high-speed state, and then sends service data on the multiple transmission channels; the first device can receive the first LLCF_DS on the multiple reception channels, and then receive service data on the multiple reception channels. In this way, the second device can transmit service data with the first device through the switched multiple transmission channels, so as to meet the transmission requirements in the asymmetric service scenario and improve the utilization rate of the channel bandwidth.
[0151] Furthermore, after the first device receives the response message fed back by the second device, the first device and the second device can manage the at least one second channel and use the at least one second channel for data transmission. The following is through Figure 8An example is given for illustration.
[0152] Combined with Figure 5 , such as Figure 8 shown, after S402a - S402b, the method further includes: one or more pairs of steps from S408a - S408b to S409a - S409b. Figure 8 In [reference], the method further including S408a - S408b to S409a - S409b is taken as an example for illustration. The embodiments of the present application do not specifically limit the sequence order between the above - mentioned multiple pairs of steps. Figure 8 The sequence order shown in [reference] is only exemplary and does not constitute a limitation to the embodiments of the present application.
[0153] S408a: The first device simultaneously sends a third LLCF_PAD on at least one second channel, and the lengths of the third LLCF_PADs on different channels in the at least one second channel are the same. Correspondingly, S408b: The second device receives the third LLCF_PAD on the at least one second channel.
[0154] Among them, the at least one second channel may be the remaining transmission channels when the first device is in the high - speed state. For the second device, the at least one second channel may be the remaining receiving channels when the second device is in the high - speed state. The at least one second channel may include one or more channels.
[0155] In addition, when the number of the at least one second channel is multiple, the lengths of the third LLCF_PADs on different channels in the at least one second channel are the same, that is, the lengths of the third LLCF_PADs sent by the first device on the at least one second channel are all the same. For example, the length can be expressed as cf_pad_length, and the corresponding maximum value can be 128 bytes and the minimum value can be 32 bytes. Optionally, the lengths of any two of the first LLCF_PAD, the second LLCF_PAD, and the third LLCF_PAD in the embodiments of the present application may be the same or different, and the embodiments of the present application do not specifically limit this. In a possible embodiment, the first device simultaneously sends a third LLCF_PAD on the remaining transmission channels (i.e., the at least one second channel) when in the high - speed state, so that the second device can receive a third LLCF_PAD on each channel in the at least one second channel to achieve smooth switching of the data between the first device and the second device on the at least one second channel through the third LLCF_PAD. Optionally, when the second device receives the third LLCF_PAD from the first device on the at least one second channel, the second device can reset the scrambling seeds corresponding to the multiple receiving channels.
[0156] S409a: The first device simultaneously sends the second LLCF_DS on the at least one second transmission channel. Correspondingly, S409b: The second device receives the second LLCF_DS on the at least one second channel.
[0157] Optionally, the lengths of the first LLCF_DS and the second LLCF_DS in the embodiments of the present application may be the same or different, and the embodiments of the present application do not make specific limitations thereto.
[0158] In a possible embodiment, the first device simultaneously sends a second LLCF_DS on the remaining transmission channels in the high-speed state (i.e., the at least one second channel), and then sends service data on the at least one second channel; the second device may receive the second LLCF_DS on the at least one second channel, and then receive service data on the at least one second channel. In this way, the first device can transmit service data with the second device through the remaining transmission channels after switching, so as to meet the transmission requirements in the asymmetric service scenario and improve the utilization rate of the channel bandwidth.
[0159] For ease of understanding, the following takes the first device as device A and the second device as device B to exemplify the solution for switching the channel direction provided by the embodiments of the present application.
[0160] As Figure 9 shown, the method includes: ①. Device A sends an LDAM indicating the channel direction switch, which is limited to indicating the channel direction switch of the TX channels of device A. For example, the LDAM is used to indicate that the channel directions of at least one TX channel of device A need to be switched; ②. Device B feeds back an ACK corresponding to the LDAM to confirm support for switching the channel direction; ③. Device A sends an LLCF_EI on the TX channels whose directions need to be switched and an LLCF_PAD on the remaining TX channels. For device B, after receiving the LLCF_EI on the channels to be switched, it performs: 1. Wait for the tDirChange time to avoid double driving of the high-speed channel line, 2. Switch from RX to TX, and then continuously send LLCF_TS2 (i.e., continuously send LLCF_TS2 on the newly added TX channels, and normally send services on other TX channels), and wait for the peer device A to feed back LLFM; ④. Device A sends an LLCF_DS on the remaining TX channels; ⑤. Device A sends normal service data on the remaining TX channels; ⑥. Device A sends LLFM to indicate that all the channels to be newly added (i.e., the above at least one TX channel) are successfully locked; ⑦. Device B sends several LLCF_PADs on the newly added TX channels; ⑧. Device B sends an LLCF_PAD on all TX channels; ⑨. Device B sends an LLCF_DS on all TX channels, and all the TX channels include the newly added TX channels and the original TX channels; ⑩. Device B sends normal service data on all TX channels.
[0161] Further, during the process of switching the channel direction provided above, if an abnormal situation occurs, the first device and the second device can also handle the abnormal situation through some processing mechanisms to improve the robustness of the channel direction switching process. In some embodiments, if the abnormal situation includes the loss or abnormality of the above-mentioned response message, the loss or abnormality of LLCF_EI, and the abnormal phenomenon of LLCF_DS detection failure, the corresponding processing mechanisms can be as shown in Table 6 below.
[0162] Table 6
[0163]
[0164]
[0165] In one example, if the response message fed back by the second device is lost or abnormal, for example, the first device does not receive the response message within a certain period of time, or the received response message is incorrect, the first device can retransmit the channel direction adjustment message to the second device; in this way, when the second device receives the retransmitted channel direction adjustment message, the second device can re-send the response message to the first device.
[0166] Optionally, when the retransmission count of the channel direction adjustment message is greater than a preset threshold, the first device sends a first error report to the second device, and the first error report is used to initiate link retraining; in this way, when the second device receives the first error report, the first device and the second device can initiate link retraining for all the transmission channels of the first device.
[0167] In another example, if the LLCF_EI sent by the first device on the at least one first channel is lost or abnormal, for example, the second device does not receive the LLCF_EI within a certain period of time, or the received LLCF_EI is incorrect, and at this time the second device detects an abnormal link error code, the second device can send a second error report to the first device, and the second error report is used to initiate link retraining or link recovery; in this way, when the first device receives the second error report, the first device and the second device can initiate link retraining or link recovery for all the transmission channels of the first device.
[0168] In yet another example, if the LLCF_DS detection in the above text fails, for example, the second device fails to detect the second LLCF_DS, then the second device sends a second error report to the first device, and the second error report is used to initiate link retraining. In this way, when the first device receives the second error report, the first device and the second device can initiate link retraining for all the transmission channels of the first device. If the first LLCF_DS or the detection fails in the above text, then the first device sends a second error report to the second device, and the second error report is used to initiate link retraining. In this way, when the second device receives the second error report, the first device and the second device can initiate link retraining for all the receiving channels of the second device.
[0169] In the embodiments of the present application, the channel direction of at least one first channel can be dynamically switched between the first device and the second device through channel direction adjustment messages and response messages. For example, at least one transmission channel of the first device can be adjusted to a receiving channel. In this way, when the first device and the second device are in an asymmetric service transmission scenario, the channel direction of some channels can be switched to meet the transmission of asymmetric services, thereby improving the utilization rate of the channel bandwidth. In addition, during the process of switching the channel direction, if an abnormal situation occurs, the first device and the second device can also handle the abnormal situation through some processing mechanisms to enhance the robustness of the process of switching the channel direction.
[0170] In a possible embodiment of the present application, after link training is completed, if the local transmission link bandwidth is excessive, but the receiving link bandwidth is insufficient, and the TX channels support dynamic switching of the channel direction, then the upper layer can control the switching of the channel direction of some TXs to compensate for the bandwidth of the receiving link.
[0171] The process of dynamically switching the channel direction is as Figure 9 shown:
[0172] 1. Device port A sends 1 LDAM to device B through a high-speed link, informing device B of the peer device of the channel numbers of the channels that need to be dynamically switched.
[0173] a) Note: The channels that need to be dynamically switched specified in the LDAW here must be the TX channels of device A.
[0174] 2. After the RX of device port B receives the LDAM, it sends back the ACK / Nack corresponding to the LDAM.
[0175] If the port of device B supports dynamic switching of the channel direction, then device B will feedback NACK, otherwise device B should feedback ACK.
[0176] If device B feedbacks a NACK response message, the process ends. Device A and device B perform service transmission and reception based on the original channel state.
[0177] After the port of Device A receives the ACK corresponding to the LDAM, after the channel to be closed by Device A sends one LLCF_EI, it enters the low-power state. All the remaining TX Lanes in the high-speed state simultaneously send one LLCF_PAD (the PAD lengths sent by all TX channels are cf_pad_length), which facilitates the smooth switching of data between the local and the peer during multi-Lane switching.
[0178] Note: Before the port of Device A receives the ACK of the LDAM, Device A still sends normal traffic through this port.
[0179] After the channel to be switched corresponding to the port of Device B receives the LLCF_EI, the following process is executed:
[0180] Wait for the tDirChange time to avoid double driving of the high-speed channel lines and ensure the switching time at both ends;
[0181] The RX channel to be switched switches from the RX mode to the TX mode, and then continuously sends LLCF_TS2 (Note: The wake-up channel in this example supports fast link establishment. If this channel does not support fast link establishment, then LLCF_TS0 needs to be sent here, and then wait for the channel clock lock handshake to complete and then send LLCF_TS1 and LLCF_TS2). At the same time, Device B also needs to send TSM to indicate that the corresponding channel starts initial training. Then wait for the peer Device A to feedback LLFM (or CLFM, EQFM).
[0182] 4. The port of Device A simultaneously sends one LLCF_DS on all the remaining TX Lanes in the high-speed state.
[0183] 5. The TX of the port of Device A sends normal traffic at the new link width.
[0184] 6. After the port of Device A detects that all the channels switched from TX to RX have completed training, it sends LLFM (Note: The wake-up channel in this example supports fast link establishment. If this channel does not support fast link establishment, then CLFM and EQFM need to be sent here for clock lock handshake), indicating that all the newly added channels are successfully locked.
[0185] If LLFM indicates that any newly added channel is not successfully locked, the process ends. Device A and Device B perform service transmission and reception based on the number of channels currently being transmitted (that is, the number of TX channels of Device A has decreased).
[0186] 7. After Device B receives the LLFM indicating that all the newly added channels are successfully locked, Device B sends several LLCF_PADs on the newly added TX channels to align the positions of sending CF between the newly added channels and the original channels in the high-speed state.
[0187] 8. Subsequently, Device B simultaneously sends one LLCF_PAD (with a PAD length of cf_pad_length) on all remaining TX Lanes in the high-speed state to facilitate smooth switching of local and peer data during multi-Lane switching.
[0188] a) Note that the RX channel of Device B needs to reset the scrambler seed after receiving the LLCF_PAD.
[0189] 9. Device B simultaneously sends one LLCF_DS on all TX Lanes in the high-speed state.
[0190] 10. The port of Device B sends normal services at the new link width.
[0191] The above channel direction adjustment message (lane direction adjust message, LDAM) is a set of channel direction adjustment request parameters, including the specific channel numbers that need to be adjusted for the channel direction.
[0192] LDAM is used when the link is in the service transmission state. It is initiated when the link bandwidth requirement needs to be adjusted and cannot be met by link width adjustment. Through negotiation with the peer, the specified channel direction adjustment between ports is achieved.
[0193] LDAM needs to be acknowledged. If the receiving end agrees to the channel direction adjustment request, it needs to reply with an Ack to LDAM; otherwise, it needs to reply with a Nack. The reply can refer to the reply information.
[0194] The message parameters of each channel are independent. If the channel is not enabled or does not exist, the corresponding message parameters are fixed at 0.
[0195] LDAM supports transmission through ML and SL. The corresponding LLMMP layout format for ML transmission is shown in Table 4. The corresponding LLSMP layout for SL transmission is shown in Table 5.
[0196] The above clock lock feedback message (clock lock feedback message, CLFM) is a set of clock lock result flags and Swing update request messages, including the clock lock results and Swing update requests of all receiving channels of the current port. CLFM_ACK is the acknowledgment message of CLFM and uses the same management message type as CLFM.
[0197] CLFM is used in the clock locking phase. It is used for the receiver to feedback the current clock locking result and initiate a request to update the Swing parameter for the channels with clock locking failure. Each channel can independently use different CLFMs to feedback clock locking information, or can also use the same CLFM to feedback the clock locking message together.
[0198] CLFM needs to be acknowledged. The transmitter switches the code pattern for the channels with clock locking, completes the Swing update for the channels that need to adjust the Swing parameter, and the channels that have completed the above operations reply with Ack, otherwise reply with Nack. The usage rule of CLFM_ACK is similar to that of CLFM. Each channel replies independently. Different CLFM_ACKs can be used for reply, or the same CLFM_ACK can also be used for reply together.
[0199] For example:
[0200] (1) CLFM0 feedbacks the clock locking information of multiple channels. CLFM_ACK0 and CLFM_ACK1 can be used to reply to some or all of the channel clock locking information feedback by CLFM0 respectively.
[0201] (2) CLFM0 feedbacks the clock locking information of some channels, and CLFM1 feedbacks the clock locking information of some channels. CLFM_ACK0 can be used to reply to some or all of the channel clock locking information feedback by CLFM0 and CLFM1 at the same time.
[0202] The message parameters of each channel are independent. If the channel is not enabled or does not exist, the corresponding message parameters are fixed to 0.
[0203] CLFM supports transmission through ML and SL. CLFM_ACK supports transmission through ML and SL.
[0204] The above equilibrium feedback message (EQFM) is a set of equilibrium result flags and FFE parameter update request messages, which contains the equilibrium results of all receiving channels of the current port and the FFE parameter update requests. EQFM_Ack is the acknowledgment message of EQFM and uses the same management message type as EQFM.
[0205] EQFM is used in the equalization phase. It is used for the receiver to feedback the current equalization result and initiate a request to update the FFE parameter for the channels with equalization failure. Each channel can independently use different EQFMs to feedback equalization information, or can also use the same EQFM to feedback the equalization message together.
[0206] The EQFM needs to respond. The sender switches the code pattern for the channels with successful equalization and updates the FFE for the channels that need to adjust the FFE parameters. The channels that have completed the above operations respond with Ack, otherwise they respond with Nack. The usage rules of EQFM_Ack can refer to CLFM_ACK. Each channel can respond independently or combined.
[0207] The message parameters of each channel are independent. If the channel is not enabled or does not exist, the corresponding message parameters are fixed at 0.
[0208] EQFM supports transmission through ML and SL. EQFM_Ack supports transmission through ML and SL.
[0209] The above-mentioned lane lock feedback message (LLFM) is a set of lane lock result flags, which contains the lane lock results of all receiving channels of the current port.
[0210] LLFM is used in the lane lock stage. It is used for the receiver to feedback the lane lock results of all current receiving channels. All channels must feedback the lane lock results simultaneously and use the same LLFM. The channels that determine the lane lock results first need to wait for other channels to clarify the lane lock results, that is, the lane lock is successful or the lane lock fails, before they can feedback LLFM.
[0211] LLFM does not need to respond. The sender switches the code pattern for the channels with successful lane lock.
[0212] The message parameters of each channel are independent. If the channel is not enabled or does not exist, the corresponding message parameters are fixed at 0.
[0213] LLFM supports transmission through ML and SL.
[0214] The above-mentioned training start message (TSM) is a set of training start flags, which contains the training start flags of all transmitting channels of the current port.
[0215] TSM is used when starting link training. The application scenarios include: in the initial link establishment scenario, after the port initialization is completed, send TSM to start link training; in the abnormal retraining scenario, send TSM to start link retraining; in the scenario of exiting the LP3 low-power state, send TSM to start link recovery. When starting training or recovery, send TSM; after receiving TSM, the receiver starts the training of the channels specified by TSM.
[0216] The message parameters of each channel are independent. If the channel is not enabled or does not exist, the corresponding message parameters are fixed at 0.
[0217] TSM does not need to respond, but the peer needs to feedback a clock lock feedback message within tTSMResponse.
[0218] TSM supports transmission through ML and SL.
[0219] The above mainly introduces the solution provided by the embodiments of the present application from the perspective of the interaction between the first device and the second device. It can be understood that in order to implement the above functions, the first device and the second device include the corresponding hardware structures and / or software modules for executing each function. Those skilled in the art should easily realize that, in combination with the units and algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed in the way of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.
[0220] The embodiments of the present application can divide the first device and the second device into functional modules according to the above method examples. For example, each functional module can be divided corresponding to each function, or two or more functions can be integrated into one module. The above integrated module can be implemented in the form of hardware or in the form of a software functional module. It should be noted that the division of modules in the embodiments of the present application is illustrative, only a logical function division, and there can be other division methods in actual implementation. The following takes the example of dividing each functional module corresponding to each function for illustration.
[0221] In the case of adopting an integrated unit, Figure 10 shows a possible structural schematic diagram of the device for switching the channel direction involved in the above embodiments. The device can be the first device or a chip applied to the first device. The device includes: a sending unit 501, a receiving unit 502, and a processing unit 503. Among them, the sending unit 501 can be used to support the device to execute one or more steps of S401a, S403a, S408a, or S409a in the above method embodiments; the receiving unit 502 can be used to support the device to execute the steps of receiving the first LLCF_PAD in S402b, S405b, S406b, or S407b in the above method embodiments; the processing unit 503 can be used to support the device to execute the step of determining at least one first channel in the above method embodiments, the step of aligning multiple receiving channels in S404a, S405b, and / or other technical processes described herein. All relevant contents of each step involved in the above method embodiments can be cited in the function descriptions of the corresponding functional modules, and the embodiments of the present application will not repeat them here.
[0222] Based on the hardware implementation, the processing unit 503 in the present application can be the processor of the device, the sending unit 501 can be the transmitter of the device (which can be called the sending port), and the receiving unit 502 can be the receiver of the device (which can be called the receiving port). Optionally, the transmitter and the receiver can usually be integrated together as a transceiver, and the specific transceiver can also be called a communication interface.
[0223] As Figure 11 shown, it is a schematic structural diagram of a device for switching the channel direction provided by an embodiment of the present application. The device can be a first device or a chip applied to the first device. The device includes: a processor 511, a transmitter 512, and a receiver 513. The processor 511 is used to support the device to execute the steps of determining at least one first channel in the above method embodiment, the step of aligning multiple receiving channels in S405b, and / or other technical processes described herein. In addition, the transmitter 512 and the receiver 513 can be used to support the device to communicate, for example, to support the device to communicate with a second device.
[0224] It can be understood that all relevant contents of the steps involved in the above method embodiment can be cited in the function descriptions of the corresponding functional modules, and the embodiments of the present application will not be elaborated herein.
[0225] In the case of adopting an integrated unit, Figure 12 shows a possible schematic structural diagram of the device for switching the channel direction involved in the above embodiment. The device can be a second device or a chip applied to the second device. The device includes: a receiving unit 601, a sending unit 602, and a processing unit 603. Among them, the receiving unit 601 can be used to support the device to execute one or more steps in S401b, S403b, S405a, S408b or S409a of the above method embodiment; the sending unit 602 can be used to support the device to execute one or more steps in S402a, S406a or S407a of the above method embodiment; the processing unit 603 can be used to support the device to execute S404b in the above method embodiment, and / or other technical processes described herein. All relevant contents of the steps involved in the above method embodiment can be cited in the function descriptions of the corresponding functional modules, and the embodiments of the present application will not be elaborated herein.
[0226] Based on the hardware implementation, the processing unit 603 in the present application can be the processor of the device, the receiving unit 601 can be the receiver of the device, and the sending unit 602 can be the transmitter of the device. Optionally, the receiver and the transmitter can usually be integrated together as a transceiver, and the specific transceiver can also be called a communication interface.
[0227] As shown Figure 13 in the figure, it is a schematic structural diagram of a device for switching the channel direction provided by an embodiment of the present application. The device can be a second device or a chip applied to the second device, and the device includes: a processor 611, a transmitter 612, and a receiver 613. The processor 611 is used to support the device to execute S404b in the above method embodiment and / or other technical processes described herein. In addition, the transmitter 612 and the receiver 613 can be used to support the device to communicate, for example, to support the device to communicate with the first device.
[0228] It can be understood that all relevant contents of each step involved in the above method embodiment can be cited to the function description of the corresponding functional module, and the embodiments of the present application will not be elaborated herein.
[0229] In another embodiment of the present application, a data transmission system is provided. The data transmission system includes a first device and a second device; the first device can be Figure 10 or Figure 11 the device provided above, specifically used to execute the steps of the first device in the method embodiment provided above; the second device can be Figure 12 or Figure 13 the device provided above, specifically used to execute the steps of the second device in the method embodiment provided above.
[0230] In several embodiments provided by the present application, it should be understood that the disclosed device and method can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the modules or units is only a logical function division, and there can be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed.
[0231] The units described as separate components may or may not be physically separated, and the components shown as units may be a physical unit or multiple physical units, that is, they can be located in one place or distributed to multiple different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0232] When the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium, which may include various media capable of storing program codes, such as USB flash drives, mobile hard disks, read-only memories, random access memories, magnetic disks, or optical discs. Based on such understanding, the technical solution of the embodiments of the present 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.
[0233] In another embodiment of the present application, a readable storage medium is further provided. Computer-executable instructions are stored in the readable storage medium. When a device (which may be a single-chip microcomputer, a chip, etc.) or a processor executes the steps of the first device in the above method embodiments.
[0234] In another embodiment of the present application, a readable storage medium is further provided. Computer-executable instructions are stored in the readable storage medium. When a device (which may be a single-chip microcomputer, a chip, etc.) or a processor executes the steps of the second device in the above method embodiments.
[0235] In yet another embodiment of the present application, a computer program product is further provided. The computer program product includes computer instructions, and the computer instructions are stored in a readable storage medium; at least one processor of the device can read the computer instructions from the readable storage medium, and at least one processor executes the computer instructions to enable the device to perform the steps of the first device in the above method embodiments.
[0236] In yet another embodiment of the present application, a computer program product is further provided. The computer program product includes computer instructions, and the computer instructions are stored in a readable storage medium; at least one processor of the device can read the computer instructions from the readable storage medium, and at least one processor executes the computer instructions to enable the device to perform the steps of the second device in the above method embodiments.
[0237] Finally, it should be noted that the above are only specific embodiments of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions within the technical scope disclosed in the present application should be covered by the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A method for switching the channel direction, characterized in that, The method includes: The first device sends a channel direction adjustment message to the second device, where the channel direction adjustment message is used to indicate the channel numbers of at least one first channel that needs to be switched, and the at least one first channel is a transmission channel of the first device; The first device receives an acknowledgment message from the second device, where the acknowledgment message is used to confirm that the second device supports switching the channel direction of the at least one first channel.
2. The method according to claim 1, characterized in that, The channel direction adjustment message includes a plurality of direction adjustment request parameters corresponding to a plurality of transmission channels respectively. The at least one direction adjustment request parameter corresponding to the at least one first channel is used to indicate a channel direction adjustment request, and the at least one direction adjustment request parameter corresponding to at least one second channel is used to indicate that the channel direction is not adjusted. The plurality of transmission channels include the at least one first channel and the at least one second channel.
3. The method according to claim 1 or 2, characterized in that, The method further includes: The first device sends an electrical idle logical link control frame LLCF_EI on the at least one first channel; After a first preset duration, the first device switches the at least one first channel to a receiving channel and performs channel training on the at least one first channel.
4. The method according to any one of claims 1 to 3, characterized in that, The method further includes: The first device sends one or more of a channel lock feedback message LLFM, a clock lock feedback message CLFM, and an equalization feedback message EQFM to the second device.
5. The method according to any one of claims 1-4, characterized in that, The method further includes: The first device receives at least one first padding logical link control frame LLCF_PAD on the at least one first channel, and aligns a plurality of receiving channels according to the at least one first LLCF_PAD. The plurality of receiving channels include the at least one first channel and at least one third channel, and the at least one third channel is a receiving channel of the first device.
6. The method according to any one of claims 1-5, characterized in that, The method further includes: The first device receives a second LLCF_PAD on a plurality of receiving channels, where the lengths of the second LLCF_PADs of different channels in the plurality of receiving channels are the same. The plurality of receiving channels include the at least one first channel and at least one third channel.
7. The method according to any one of claims 1-6, characterized in that The method further includes: The first device receives a first data start logical link control frame LLCF_DS on a plurality of receiving channels. The plurality of receiving channels include the at least one first channel and at least one third channel.
8. The method according to any one of claims 1 to 7, characterized in that The method further includes: The first device simultaneously sends a third LLCF_PAD on at least one second channel, where the lengths of the third LLCF_PADs of different channels in the at least one second channel are the same.
9. The method according to claim 8, wherein The method further includes: The first device simultaneously sends a second LLCF_DS on the at least one second transmission channel.
10. The method according to claim 1, characterized in that, The method further includes: If the acknowledgment message is lost or abnormal, the first device retransmits the channel direction adjustment message.
11. The method according to claim 10, wherein The method further includes: When the number of retransmissions of the channel direction adjustment message is greater than a preset threshold, the first device sends a first error report, and the first error report is used to initiate link retraining.
12. The method according to claim 3 or 7, characterized in that, The method further includes: The second device receives a second error report triggered by the loss or abnormality of LLCF_EI or the failure of LLCF_DS detection, and the second error report is used to initiate link retraining or link recovery.
13. The method according to any one of claims 1-12, characterized in that, The first device sends a channel direction adjustment message to the second device, including: The first device sends the channel direction adjustment message to the second device through the primary link.
14. The method according to any one of claims 1 to 12, characterized in that, The first device sends a channel direction adjustment message to the second device, including: The first device sends the channel direction adjustment message to the second device through the secondary link.
15. A method for switching the channel direction, characterized in that The method includes: The second device receives a channel direction adjustment message from the first device, and the channel direction adjustment message is used to indicate the channel numbers of at least one first channel that needs to be switched, and the at least one first channel is the receiving channel of the second device; The second device sends a response message to the first device, and the response message is used to confirm that the second device supports switching the channel directions of the at least one first channel.
16. The method according to claim 15, wherein The channel direction adjustment message includes a plurality of direction adjustment request parameters corresponding to a plurality of receiving channels respectively. The at least one direction adjustment request parameter corresponding to the at least one first channel is used to indicate a channel direction adjustment request, and the at least one direction adjustment request parameter corresponding to at least one second channel is used to indicate that the channel direction is not adjusted. The plurality of receiving channels include the at least one first channel and the at least one second channel.
17. The method according to claim 15 or 16, characterized in that, The method further includes: The second device receives an electrical idle logical link control frame LLCF_EI on the at least one first channel; After a second preset time period, the second device switches the at least one first channel to a transmitting channel and performs channel training on the at least one first channel.
18. The method according to any one of claims 15-17, characterized in that, The method further includes: The second device receives one or more of the channel lock feedback message LLFM, clock lock feedback message CLFM, and equalization feedback message EQFM from the first device.
19. The method according to any one of claims 15 - 18, characterized in that, The method further includes: The second device sends at least one first padding logical link control frame LLCF_PAD on the at least one first channel, and the at least one LLCF_PAD is used to align a plurality of transmitting channels, and the plurality of transmitting channels include the at least one first channel and at least one third channel.
20. The method according to any one of claims 15 - 19, characterized in that, The method further includes: The second device simultaneously sends second LLCF_PAD on a plurality of transmitting channels, and the lengths of the second LLCF_PAD on different channels in the plurality of transmitting channels are the same. The plurality of transmitting channels include the at least one first channel and at least one third channel.
21. The method according to any one of claims 15-20, characterized in that, The method further includes: The second device simultaneously sends a first data start logical link control frame LLCF_DS on a plurality of transmitting channels, and the plurality of transmitting channels include the at least one first channel and at least one third channel.
22. The method according to any one of claims 15 - 21, characterized in that, The method further includes: The second device receives third LLCF_PAD on at least one second channel, and the lengths of the third LLCF_PAD on different channels in the at least one second channel are the same.
23. The method according to claim 22, wherein The method further includes: The second device receives a second LLCF_DS on the at least one second channel.
24. The method according to claim 15, wherein The method further includes: The second device receives the channel direction adjustment message retransmitted by the first device, and the retransmission of the channel direction adjustment message is triggered by the loss or abnormality of the acknowledgment message.
25. The method according to claim 24, wherein The method further includes: When the number of retransmissions of the channel direction adjustment message is greater than a preset threshold, the second device receives a first error report from the first device, and the first error report is used to initiate link retraining.
26. The method according to claim 17 or 21, characterized in that, The method further includes: If the LLCF_EI is lost or abnormal, or the LLCF_DS detection fails, the second device sends a second error report, and the second error report is used to initiate link retraining or link recovery.
27. The method according to any one of claims 15-26, characterized in that, The second device receiving the channel direction adjustment message from the first device includes: The second device receives the channel direction adjustment message from the first device through the primary link.
28. The method according to any one of claims 15-27, characterized in that, The second device receiving the channel direction adjustment message from the first device includes: The second device receives the channel direction adjustment message from the first device through the secondary link.
29. A device for switching the channel direction, characterized in that, The apparatus includes: A sending unit, configured to send a channel direction adjustment message to a second device, where the channel direction adjustment message is used to indicate the channel numbers of at least one first channel to be switched, and the at least one first channel is a transmission channel of the apparatus; A receiving unit, configured to receive an acknowledgment message from the second device, where the acknowledgment message is used to confirm that the second device supports switching the channel direction of the at least one first channel.
30. The device according to claim 29, wherein, The channel direction adjustment message includes a plurality of direction adjustment request parameters corresponding to a plurality of transmission channels respectively. The at least one direction adjustment request parameter corresponding to the at least one first channel is used to indicate a channel direction adjustment request, and the at least one direction adjustment request parameter corresponding to at least one second channel is used to indicate that the channel direction is not adjusted. The plurality of transmission channels include the at least one first channel and the at least one second channel.
31. The device according to claim 29 or 30, characterized in that, The apparatus further includes a processing unit; The sending unit is further configured to send an electrical idle logical link control frame LLCF_EI on the at least one first channel; The processing unit is configured to, after a first preset duration, switch the at least one first channel to a receiving channel and perform channel training on the at least one first channel.
32. The apparatus according to any one of claims 29-31, wherein The sending unit is further configured to send one or more of a channel lock feedback message LLFM, a clock lock feedback message CLFM, and an equalization feedback message EQFM to the second device.
33. The device according to any one of claims 29 to 32, characterized in that, The apparatus further includes a processing unit; The receiving unit is further configured to receive at least one first padding logical link control frame LLCF_PAD on the at least one first channel; The processing unit is further configured to align a plurality of receiving channels according to the at least one first LLCF_PAD, where the plurality of receiving channels include the at least one first channel and at least one third channel, and the at least one third channel is a receiving channel of the apparatus.
34. The device according to any one of claims 29-33, characterized in that the receiving unit is further configured to receive a second LLCF_PAD on a plurality of receiving channels, the lengths of the second LLCF_PADs on different channels in the plurality of receiving channels being the same, and the plurality of receiving channels including the at least one first channel and at least one third channel.
35. The device according to any one of claims 29-34, characterized in that the receiving unit is further configured to receive a first data start logical layer control frame LLCF_DS on a plurality of receiving channels, the plurality of receiving channels including the at least one first channel and at least one third channel.
36. The device according to any one of claims 29-35, characterized in that the sending unit is further configured to simultaneously send a third LLCF_PAD on at least one second channel, the lengths of the third LLCF_PADs on different channels in the at least one second channel being the same.
37. The device according to claim 36, characterized in that the sending unit is further configured to simultaneously send a second LLCF_DS on the at least one second transmitting channel.
38. The device according to claim 29, characterized in that the sending unit is further configured to retransmit the channel direction adjustment message if the response message is lost or abnormal.
39. The device according to claim 38, characterized in that the sending unit is further configured to send a first error report when the retransmission times of the channel direction adjustment message are greater than a preset threshold, and the first error report is used to initiate link retraining.
40. The device according to claim 31 or 35, characterized in that the receiving unit is further configured to receive a second error report, which is triggered by the loss or abnormality of LLCF_EI or the failure of LLCF_DS detection, and the second error report is used to initiate link retraining or link recovery.
41. The device according to any one of claims 29-40, characterized in that the sending unit is further configured to send the channel direction adjustment message to the second device through the main link.
42. The device according to any one of claims 29-40, characterized in that the sending unit is further configured to send the channel direction adjustment message to the second device through the auxiliary link.
43. A device for switching the channel direction, characterized in that, The device includes: a receiving unit, configured to receive a channel direction adjustment message from a first device, the channel direction adjustment message being used to indicate the channel numbers of at least one first channel to be switched, and the at least one first channel being a receiving channel of the device; a sending unit, configured to send a response message to the first device, the response message being used to confirm that the second device supports switching the channel direction of the at least one first channel.
44. The device according to claim 43, characterized in that The channel direction adjustment message includes a plurality of direction adjustment request parameters corresponding to the plurality of receiving channels. The at least one direction adjustment request parameter corresponding to the at least one first channel is used to indicate a channel direction adjustment request, and the at least one direction adjustment request parameter corresponding to the at least one second channel is used to indicate that the channel direction is not adjusted. The plurality of receiving channels include the at least one first channel and the at least one second channel.
45. The device according to claim 43 or 44, characterized in that, The device further includes a processing unit; The receiving unit is further configured to receive an electrical idle logical link control frame LLCF_EI on the at least one first channel; The processing unit is configured to, after a second preset duration, switch the at least one first channel to a transmitting channel and perform channel training on the at least one first channel.
46. The device according to any one of claims 43-45, wherein The receiving unit is further configured to receive one or more of a channel lock feedback message LLFM, a clock lock feedback message CLFM, and an equalization feedback message EQFM from the first device.
47. The device according to any one of claims 43-46, wherein The transmitting unit is further configured to transmit at least one first padding logical link control frame LLCF_PAD on the at least one first channel. The at least one first LLCF_PAD is used to align a plurality of transmitting channels. The plurality of transmitting channels include the at least one first channel and at least one third channel.
48. The device according to any one of claims 43-47, wherein The transmitting unit is further configured to simultaneously transmit a second LLCF_PAD on a plurality of transmitting channels. The lengths of the second LLCF_PADs of different channels in the plurality of transmitting channels are the same. The plurality of transmitting channels include the at least one first channel and at least one third channel.
49. The device according to any one of claims 43-48, wherein The transmitting unit is further configured to simultaneously transmit a first data start logical link control frame LLCF_DS on a plurality of transmitting channels. The plurality of transmitting channels include the at least one first channel and at least one third channel.
50. The device according to any one of claims 43-49, wherein The receiving unit is further configured to receive a third LLCF_PAD on at least one second channel. The lengths of the third LLCF_PADs of different channels in the at least one second channel are the same.
51. The device according to claim 50, wherein The receiving unit is further configured to receive a second LLCF_DS on the at least one second channel.
52. The device according to claim 43, wherein The receiving unit is further configured to receive the channel direction adjustment message retransmitted by the first device. The retransmission of the channel direction adjustment message is triggered by the loss or abnormality of the response message.
53. The device according to claim 52, wherein The receiving unit is further configured to receive a first error report from the first device when the number of retransmissions of the channel direction adjustment message is greater than a preset threshold, where the first error report is used to initiate link retraining.
54. The apparatus according to claim 45 or 49, wherein The sending unit is further configured to send a second error report if LLCF_EI is lost or abnormal, or if the LLCF_DS detection fails, where the second error report is used to initiate link retraining or link recovery.
55. The apparatus according to any one of claims 43-54, wherein The receiving unit is further configured to receive the channel direction adjustment message from the first device through the primary link.
56. The apparatus according to any one of claims 43-54, wherein The receiving unit is further configured to receive the channel direction adjustment message from the first device through the secondary link.
57. A chip, characterized in that, The chip includes a processing circuit and a transmitter, and the processing circuit and the transmitter are configured to support the chip to execute the method according to any one of claims 1-14.
58. A chip, characterized in that, The chip includes a processing circuit and a receiver, and the processing circuit and the receiver are configured to support the chip to execute the method according to any one of claims 15-28.
59. A data transmission system, characterized in that, The data transmission system includes a first device and a second device. The first device includes the apparatus according to any one of claims 29-42 or the chip according to claim 57, and the second device includes the apparatus according to any one of claims 43-56 or the chip according to claim 58.
60. A readable storage medium, characterized in that, Instructions are stored in the readable storage medium, and when the instructions run on the device, the device is caused to execute the method according to any one of claims 1-14.
61. A readable storage medium, characterized in that, Instructions are stored in the readable storage medium, and when the instructions run on the device, the device is caused to execute the method according to any one of claims 15-28.