Endpoint device transmission performance recovery method and electronic device

By dynamically selecting the link retraining strategy for PCIe devices in the BIOS, the problem of reduced speed or bandwidth of PCIe devices is solved, improving recovery efficiency and flexibility, and reducing hardware overhead and communication interruptions.

CN121597486BActive Publication Date: 2026-04-21INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INSPUR SUZHOU INTELLIGENT TECH CO LTD
Filing Date
2026-01-20
Publication Date
2026-04-21

AI Technical Summary

Technical Problem

In existing technologies, PCIe devices in servers are prone to speed or bandwidth reduction issues, and the fixed method of retraining a PCIe link for recovery is inefficient and lacks flexibility.

Method used

By acquiring register data on the point-to-point communication link during BIOS initialization, transmission performance issues can be identified. Based on the current operating status of the computing device, a target strategy is selected from multiple link retraining strategies for retraining, including TxEQ Redo, Link Retrain, and SBR strategies. The training method is dynamically adjusted to restore transmission performance.

Benefits of technology

It enables flexible selection of PCIe device retraining methods based on actual conditions, improving recovery efficiency and flexibility, reducing hardware overhead and communication interruption time, and enhancing user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121597486B_ABST
    Figure CN121597486B_ABST
Patent Text Reader

Abstract

This application discloses a method and electronic device for restoring the transmission performance of endpoint devices, relating to the field of computer technology. The method includes, when an initialization module initializes a computing device, if initial training of a point-to-point communication link is completed, acquiring register data of the root port on the point-to-point communication link and register data of the endpoint devices to determine if the endpoint devices have transmission performance problems; for any endpoint device, if the endpoint device has transmission performance problems, determining the target point-to-point communication link where the endpoint device is located; based on the current operating state of the computing device, determining a target link retraining strategy from multiple link retraining strategies, and retraining the target point-to-point communication link to restore the transmission performance of the endpoint device. This solves the technical problems of poor flexibility and low efficiency in related technologies, achieving the technical effect of improving flexibility and recovery efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to methods and electronic devices for restoring the transmission performance of endpoint devices. Background Technology

[0002] The Basic Input / Output System (BIOS) acts as a bridge between server hardware and the operating system, responsible for server hardware self-test initialization during server startup. This initialization includes loading drivers for Peripheral Component Interconnect Express (PCIe) devices. PCIe devices play a crucial role in servers due to their high bandwidth and low latency. However, PCIe devices are prone to speed or bandwidth reduction issues during operation. Common technologies address this by retraining the PCIe link via BIOS triggering the retraining process.

[0003] The relevant technologies use a fixed method of retraining the PCIe link to recover from the rate reduction or bandwidth reduction problem of PCIe devices. This method cannot be adapted to different retraining methods based on the actual situation, resulting in poor flexibility and low recovery efficiency. Summary of the Invention

[0004] This application provides a method and electronic device for restoring the transmission performance of an endpoint device, which at least solves the problems of poor flexibility and low recovery efficiency caused by the fixed use of a PCIe link retraining method to restore the rate reduction or bandwidth reduction of PCIe devices in the related art.

[0005] This application provides a method for restoring the transmission performance of an endpoint device, including:

[0006] When the initialization module initializes the computing device, if the initial training of the point-to-point communication link is completed, the register data of the root port and the register data of the endpoint device on the point-to-point communication link are obtained.

[0007] Based on the register data of the root port and the register data of the endpoint device, determine whether there is a transmission performance problem in the endpoint device;

[0008] For any endpoint device, if the endpoint device has a transmission performance problem, the target point-to-point communication link where the endpoint device is located is determined; based on the current operating state of the computing device, the target link retraining strategy is determined from multiple link retraining strategies; the target point-to-point communication link is retrained based on the target link retraining strategy to restore the transmission performance of the endpoint device.

[0009] This application also provides an endpoint device transmission performance recovery apparatus, comprising:

[0010] The acquisition module is used to acquire the register data of the root port and the register data of the endpoint devices on the point-to-point communication link if the initial training of the point-to-point communication link is completed when the computing device is initialized by the initialization module.

[0011] The determination module is used to determine whether there are transmission performance problems on the endpoint devices based on the register data of the root port and the register data of the endpoint devices;

[0012] The recovery module is used to determine the target point-to-point communication link of any endpoint device if the endpoint device has a transmission performance problem; based on the current operating state of the computing device, determine the target link retraining strategy from multiple link retraining strategies; and retrain the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device.

[0013] This application also provides an electronic device, including: a memory for storing a computer program; and a processor for implementing the steps of any of the endpoint device transmission performance recovery methods described above when executing the computer program.

[0014] This application also provides a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, it implements the steps of any of the endpoint device transmission performance recovery methods described above.

[0015] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of any of the endpoint device transmission performance recovery methods described above.

[0016] This application addresses the following issues: When the computing device is initialized in the initialization module, if the initial training of the point-to-point communication link is completed, the register data of the root port and the register data of the endpoint devices on the point-to-point communication link are obtained. Based on the register data of the root port and the endpoint devices, it is determined whether the endpoint devices have transmission performance problems. For any endpoint device, if the endpoint device has transmission performance problems, the target point-to-point communication link where the endpoint device is located is determined. Based on the current operating state of the computing device, a target link retraining strategy is determined from multiple link retraining strategies. The target point-to-point communication link is retrained based on the target link retraining strategy to restore the transmission performance of the endpoint device. By determining the target link retraining strategy from multiple link retraining strategies according to the current operating state of the computing device, and using the target link retraining strategy to restore the transmission performance of the endpoint devices, this application achieves the goal of using different retraining methods to restore the transmission performance of endpoint devices according to actual conditions. Therefore, it solves the technical problems of poor flexibility and low recovery efficiency caused by using a fixed PCIe link retraining method to restore the rate reduction or bandwidth reduction problem of PCIe devices in related technologies, achieving the technical effects of improving flexibility and recovery efficiency. Attached Figure Description

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

[0018] Figure 1 This application provides a schematic diagram of the structure of an endpoint device transmission performance recovery system according to an embodiment of the present application.

[0019] Figure 2 A flowchart illustrating a method for restoring the transmission performance of an endpoint device, provided in an embodiment of this application;

[0020] Figure 3 A flowchart illustrating another endpoint device transmission performance recovery method provided in this application embodiment;

[0021] Figure 4 A flowchart illustrating a method for restoring the transmission performance of another endpoint device provided in an embodiment of this application;

[0022] Figure 5 This is a schematic diagram of the structure of an endpoint device transmission performance recovery device provided in an embodiment of this application;

[0023] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0024] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of this application.

[0025] It should be noted that, in the description of this application, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. The terms "first," "second," etc., in this application are used to distinguish similar objects and are not used to describe a specific order or sequence.

[0026] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0027] In server systems, the BIOS plays a crucial role in hardware management and system booting. As the low-level interface between hardware and the operating system, the BIOS first performs a self-test and initialization of the server hardware during the server startup phase. This includes self-testing of devices such as the Central Processing Unit (CPU), memory, motherboard, and serial / parallel ports, as well as loading drivers for PCIe devices and input / output (I / O) devices. After completing the self-test and initialization of the server hardware, the BIOS loads the boot entries and boots the system into the operating system, allowing users to perform the necessary operations.

[0028] PCIe devices play a crucial role in servers due to their high bandwidth, low latency, support for multi-channel configurations, and hot-swapping capabilities. Graphics Processing Unit (GPU) accelerators, Non-Volatile Memory Express (NVMe) hard drives, and smart network interface cards (NICs) are all examples of PCIe devices. PCIe devices are key players in artificial intelligence, cloud computing, and data center computing scenarios, continuously driving improvements in computing efficiency and system scalability.

[0029] However, during the research and development and use of servers, PCIe devices are prone to issues such as reduced speed or bandwidth. These issues can affect the performance of PCIe devices, impact the coordination of multiple PCIe devices in a shared PCIe channel, affect scalability, and cause resource waste, ultimately leading to a decline in user experience. Therefore, when PCIe devices experience reduced speed or bandwidth, it is necessary to address these issues promptly.

[0030] In related technologies, the reduction in PCIe speed or bandwidth is typically addressed by retraining the PCIe link via BIOS triggering the process. This reduction in speed or bandwidth can be caused by temporary signal integrity issues, unstable link conditions, temperature fluctuations, or power supply variations.

[0031] However, the relevant technologies use a fixed method of retraining the PCIe link to recover from the rate reduction or bandwidth reduction problem of PCIe devices. This method cannot be adapted to different retraining methods based on the actual situation, resulting in poor flexibility and low recovery efficiency.

[0032] To address the aforementioned technical problems, this application provides an endpoint device transmission performance recovery method and electronic device. The endpoint device transmission performance recovery method includes: when an initialization module initializes a computing device, if initial training of the point-to-point communication link is completed, acquiring the register data of the root port on the point-to-point communication link and the register data of the endpoint device; determining whether the endpoint device has a transmission performance problem based on the root port register data and the endpoint device register data; for any endpoint device, if the endpoint device has a transmission performance problem, determining the target point-to-point communication link where the endpoint device is located; determining a target link retraining strategy from multiple link retraining strategies based on the current operating state of the computing device; and retraining the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device. The method provided above, by determining a target link retraining strategy from multiple link retraining strategies according to the current operating state of the computing device, and utilizing the target link retraining strategy to restore the transmission performance of the endpoint device, achieves the technical effect of improving flexibility and recovery efficiency by using different retraining methods according to the actual situation to recover the transmission performance problem of the endpoint device.

[0033] The specific application environment architecture or specific hardware architecture on which the execution of the endpoint device transmission performance recovery method depends is described here.

[0034] The endpoint device transmission performance recovery method and electronic device provided in this application are applicable to restoring the transmission performance of endpoint devices. Figure 1 The diagram shows the structure of the endpoint device transmission performance recovery system based on this application. This system includes: an initialization module, a central processing unit (CPU), a target point-to-point communication link controller, a link training state machine, and endpoint devices on the target point-to-point communication link. The initialization module, which may be a BIOS, is used to initialize the computing device, including performing self-test initialization on the computing device's hardware. It is also used, when initializing the computing device, to acquire the register data of the root port and the register data of the endpoint devices on the point-to-point communication link if the initial training of the point-to-point communication link is completed; based on the register data of the root port and the register data of the endpoint devices, determine whether the endpoint devices have transmission performance problems; for any endpoint device, if the endpoint device has a transmission performance problem, determine the target point-to-point communication link where the endpoint device is located; based on the current operating state of the computing device, determine the target link retraining strategy from multiple link retraining strategies; based on the target link retraining strategy, generate the target register configuration instruction corresponding to the target link retraining strategy, and send the target register configuration instruction to the CPU. The CPU receives the target register configuration instruction and forwards it to the target point-to-point communication link controller. The target point-to-point communication link controller configures the target register based on the target register configuration instruction. The link training state machine responds to the target register configuration and performs the corresponding link training. After link training is complete, the training results are displayed to the endpoint devices on the target point-to-point communication link to determine whether the transmission performance issues of the endpoint devices on the target point-to-point communication link have been resolved.

[0035] Embodiments of this application provide a method for restoring the transmission performance of an endpoint device, applied to an initialization module, which is a BIOS. Figure 2 This is a flowchart illustrating the endpoint device transmission performance recovery method provided in an embodiment of this application, as shown below. Figure 2 As shown, the method for restoring the transmission performance of the endpoint device includes the following steps:

[0036] In step S201, if the initialization module initializes the computing device, and the initial training of the point-to-point communication link is completed, the register data of the root port and the register data of the endpoint device on the point-to-point communication link are obtained.

[0037] The computing device can be a server. Specifically, when the BIOS initializes the server, if the initial training of the point-to-point communication link is completed during the BIOS self-test initialization of the server, the register data of the root port and the register data of the endpoint devices on the point-to-point communication link are obtained.

[0038] It should be noted that point-to-point communication links are PCIe links. Endpoint devices are PCIe devices.

[0039] If the initial training of the point-to-point communication link is completed, then the root port and endpoint devices on all point-to-point communication links are traversed to obtain the register data of the root port and the register data of the endpoint devices.

[0040] Step S202: Based on the register data of the root port and the register data of the endpoint device, determine whether there is a transmission performance problem in the endpoint device.

[0041] Among these, transmission performance issues include rate reduction and bandwidth reduction.

[0042] Step S203: For any endpoint device, if the endpoint device has a transmission performance problem, determine the target point-to-point communication link where the endpoint device is located; based on the current operating state of the computing device, determine the target link retraining strategy from multiple link retraining strategies; retrain the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device.

[0043] Various link retraining strategies can include Transmitter Equalization Redo (TxEQ Redo), Secondary Bus Reset (SBR), and link parameter renegotiation. The link parameter renegotiation strategy is essentially the link retraining strategy.

[0044] Link Retraining is a process of renegotiation of PCIe link parameters (rate, bandwidth, etc.). Its main purpose is to restore link stability or adapt to new link parameters (such as rate switching). It is widely used and applicable to most high-speed serial interfaces. It can effectively solve the problem of physical layer signal degradation and is relatively simple to implement. However, using Link Retraining requires renegotiation of link parameters, which may introduce significant latency. For frequent retraining, it may affect performance, and under some protocols, retraining may reduce the link rate.

[0045] The TxEQ Redo strategy optimizes signal integrity by reconfiguring transmitter equalization parameters (Pre-cursor / Post-cursor), primarily addressing signal quality issues such as high bit error rate and eye diagram closure. It only retransmits data from the faulty transmission queue, resulting in low latency, no physical layer adjustments, and no performance degradation. It can be used at higher layers of the protocol stack (such as NVMe and RDMA) to enhance data reliability. However, TxEQ Redo is typically used for queue management and cannot solve physical layer problems. Furthermore, not all interfaces support it, requiring additional queue management and retransmission logic when implementing TxEQ Redo.

[0046] The SBR (Short-Terminal Reset) strategy uses software-triggered hardware reset to reset the downstream bus and device states. Its main function is to force downstream devices back to their initial state (e.g., unresponsive devices or misconfigured devices). It can optimize retraining timing based on historical data and link status, reducing unnecessary retraining. It can dynamically adjust training parameters (e.g., equalization, pre-emphasis) to improve link stability, reducing latency and throughput loss compared to traditional link retraining. However, its drawbacks include the need for additional state monitoring and machine learning / prediction algorithms, higher hardware costs (potentially requiring dedicated circuitry or more complex circuit designs), and the possibility that some traditional devices may not support the SBR optimization strategy.

[0047] Link Retraining, TxEQ Redo, and SBR strategies are all methods used to address stability or functional issues in PCIe links, and all require hardware PCIe capability register support. Triggering for any of them can be done indirectly via firmware BIOS or directly via hardware. Their advantages and disadvantages are summarized below: Link Retraining: Basic but effective, suitable for most physical layer recoveries, but may impact performance. TxEQ Redo: Quickly recovers queue errors, but does not address physical layer issues and relies on protocol support. SBR: Most advanced, optimizes retraining strategies, but is complex to implement and costly.

[0048] In this embodiment, three policy control options can be set on the BIOS: Link Retrain control option, TxEQ Redo control option, and SBR control option. The BIOS can determine the target link retraining policy from multiple link retraining policies based on the current operating state of the computing device, and enable the corresponding control option to retrain the target point-to-point communication link based on the target link retraining policy. The BIOS can also respond to user selection based on the current operating state of the computing device by enabling or disabling the corresponding policy control option, thus determining the policy. It is understood that enabling the policy control option indicates that the policy is the target link retraining policy.

[0049] Understandably, users can also determine the retraining strategy for the target link based on the current transmission performance issues and their tolerance for the consequences of the current strategy selection.

[0050] The endpoint device transmission performance recovery method provided in this application determines the target link retraining strategy from multiple link retraining strategies based on the current operating state of the computing device, and uses the target link retraining strategy to recover the transmission performance of the endpoint device. This achieves the technical effect of improving flexibility and recovery efficiency by using different retraining methods according to the actual situation to recover the transmission performance problem of the endpoint device.

[0051] By creating three new control options in the BIOS, software-triggered link recovery was achieved, which greatly reduced the overhead of troubleshooting, lowered the cost of hardware problem solving, reduced unnecessary hardware and link overhead, and improved link recovery efficiency.

[0052] By providing a convenient visual interface that allows users to directly set the target link retraining strategy, flexibility and user experience are improved.

[0053] Embodiments of this application provide a method for restoring the transmission performance of an endpoint device, applied to BIOS. Figure 3 This is a flowchart illustrating the endpoint device transmission performance recovery method provided in an embodiment of this application, as shown below. Figure 3 As shown, the method for restoring the transmission performance of the endpoint device includes the following steps:

[0054] Step S301: If the initialization module initializes the computing device, and the initial training of the point-to-point communication link is completed, then the register data of the root port and the register data of the endpoint devices on the point-to-point communication link are obtained. For details, please refer to [link to relevant documentation]. Figure 2 Step S201 of the illustrated embodiment will not be described again here.

[0055] Step S302: Based on the register data of the root port and the register data of the endpoint device, determine whether there is a transmission performance problem in the endpoint device.

[0056] The register data includes data from the first link control register, the link capability register, and the link status register. The first link control register is the Link Control 2 register. The link capability register is the LinkCapability register. The link status register is the Link Status register.

[0057] Specifically, step S302 includes:

[0058] Step S3021: Determine the target rate for each point-to-point communication link based on the first link control register data of the root port and the first link control register data of the endpoint device.

[0059] Step S3022: Determine the target bandwidth for each point-to-point communication link based on the link capability register data of the root port and the link capability register data of the endpoint devices.

[0060] Step S3023: Determine the current rate and current bandwidth of the endpoint device based on the link status register data of the endpoint device.

[0061] The data in bits 0 to 3 of the endpoint device's Link Status register represents the current rate of the endpoint device. The data in bits 4 to 9 of the endpoint device's Link Status register represents the current bandwidth of the endpoint device.

[0062] Step S3024: Based on the target rate of each point-to-point communication link, the target bandwidth of each point-to-point communication link, the current rate and current bandwidth of the endpoint device, determine whether there is a transmission performance problem in the endpoint device.

[0063] Step S303: For any endpoint device, if the endpoint device has a transmission performance problem, determine the target point-to-point communication link where the endpoint device is located; based on the current operating state of the computing device, determine the target link retraining strategy from multiple link retraining strategies; retrain the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device.

[0064] Specifically, step S303 includes:

[0065] Step S3031: Determine the service tolerance of the computing device based on its current operating status.

[0066] Specifically, the service tolerance of the computing device is determined based on the number of services currently running on the device. Service tolerance characterizes the extent of performance degradation that services can tolerate.

[0067] Step S3032: If the service tolerance of the computing device is lower than the first tolerance threshold, then the target link retraining strategy is determined to be the transmitter equalization reconfiguration strategy.

[0068] If the number of services currently running on the computing device exceeds a first threshold, it indicates that the computing device has high performance requirements and low service tolerance. Therefore, it is determined that the computing device's service tolerance is lower than the first tolerance threshold, and the target link retraining strategy is determined to be the transmitter equalization reconfiguration strategy. This is because the transmitter equalization reconfiguration strategy has less impact on server performance than the link parameter renegotiation strategy, and the link parameter renegotiation strategy has less impact on server performance than the secondary bus reset strategy.

[0069] Step S3033: If the service tolerance of the computing device is not lower than the first tolerance threshold and is lower than the second tolerance threshold, then the target link retraining strategy is determined to be the link parameter renegotiation strategy.

[0070] If the number of services currently running on the computing device is not greater than the first threshold but greater than the second threshold, then the service tolerance of the computing device is determined to be not lower than the first tolerance threshold and lower than the second tolerance threshold.

[0071] The second quantity threshold is less than the first quantity threshold, and the first and second quantity thresholds are set by technical personnel.

[0072] Step S3034: If the service tolerance of the computing device is not lower than the second tolerance threshold, then the target link retraining strategy is determined to be the secondary bus reset strategy. The first tolerance threshold is less than the second tolerance threshold.

[0073] If the number of services currently running on the computing device is less than the second threshold, then the computing device's service tolerance is determined to be no lower than the second tolerance threshold. It should be noted that the SBR strategy has a significant impact on server performance and is generally used in scenarios where the server is not running any services.

[0074] The endpoint device transmission performance recovery method provided in this application realizes rapid and accurate diagnosis of endpoint device transmission performance problems by accurately comparing the negotiation target and the current operation status of the PCIe link.

[0075] By employing a dynamic policy selection mechanism based on business tolerance, the technical effect of intelligently restoring PCIe link performance while minimizing service interruption is achieved, under the premise of ensuring business continuity.

[0076] In some optional implementations, step S3021 above includes:

[0077] Step a1: Determine the target rate of the root port based on the data in the first link control register of the root port.

[0078] The data in bits 0 to 3 of the Link Control 2 register at the root port represents the target rate of the root port.

[0079] Step a2: Determine the target rate of the endpoint device based on the first link control register data of the endpoint device.

[0080] The data in bits 0 through 3 of the Link Control 2 register of the endpoint device represents the target rate of the endpoint device.

[0081] Step a3: For any point-to-point communication link, obtain the target rate of the target root port and the target rate of the target endpoint device on that point-to-point communication link.

[0082] Step a4: Determine the target rate of the point-to-point communication link based on the target rate of the target root port and the target rate of the target endpoint device.

[0083] The endpoint device transmission performance recovery method provided in this application determines the target rate of the point-to-point communication link by using the target rate of the target root port and the target rate of the target endpoint device, thus ensuring the accuracy of the target rate of the point-to-point communication link.

[0084] In some alternative implementations, step a4 above includes:

[0085] Step a41: Determine the minimum target rate between the target rate of the target root port and the target rate of the target endpoint device as the target rate of the point-to-point communication link.

[0086] In other words, the target rate of a point-to-point communication link is the minimum of the target rate of the root port on the point-to-point communication link and the target rate of the endpoint devices on the point-to-point communication link.

[0087] In some optional implementations, step S3022 above includes:

[0088] Step b1: Determine the maximum bandwidth of the root port based on the link capability register data of the root port.

[0089] The data in bits 0 to 3 of the Link Capability register of the root port represents the maximum bandwidth of the root port.

[0090] Step b2: Determine the maximum bandwidth of the endpoint device based on the link capability register data of the endpoint device.

[0091] The data in bits 0 to 3 of the Link Capability register of the endpoint device represents the maximum bandwidth of the endpoint device.

[0092] Step b3: For any point-to-point communication link, obtain the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device on that point-to-point communication link.

[0093] Step b4: Determine the target bandwidth of the point-to-point communication link based on the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device.

[0094] The endpoint device transmission performance recovery method provided in this application determines the target bandwidth of the point-to-point communication link by using the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device, thus ensuring the accuracy of the target bandwidth of the point-to-point communication link.

[0095] In some alternative implementations, step b4 above includes:

[0096] Step b41: Determine the minimum value between the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device as the target bandwidth of the point-to-point communication link.

[0097] In other words, the target bandwidth of a point-to-point communication link is the minimum of the maximum bandwidth of the root port on the point-to-point communication link and the maximum bandwidth of the endpoint devices on the point-to-point communication link.

[0098] In some optional implementations, step S3024 above includes:

[0099] Step c1: For any endpoint device, determine the target rate of the first point-to-point communication link where the endpoint device is located, based on the target rate of each point-to-point communication link.

[0100] Step c2: If the current rate of the endpoint device is less than the target rate of the first point-to-point communication link, then it is determined that the endpoint device has a rate reduction problem.

[0101] Step c3: If the current rate of the endpoint device is not less than the target rate of the first point-to-point communication link, then it is determined that the endpoint device does not have a rate reduction problem.

[0102] Transmission performance issues include rate reduction problems.

[0103] The endpoint device transmission performance recovery method provided in this application compares the current rate of the endpoint device with the target rate of the first point-to-point communication link to determine whether the endpoint device has a rate reduction problem, thus achieving accurate detection of the rate reduction problem of the endpoint device.

[0104] In some optional implementations, step S3024 above includes:

[0105] Step d1: For any endpoint device, determine the target bandwidth of the first point-to-point communication link where the endpoint device is located, based on the target bandwidth of each point-to-point communication link.

[0106] Step d2: If the current bandwidth of the endpoint device is less than the target bandwidth of the first point-to-point communication link, then it is determined that the endpoint device has a bandwidth reduction problem.

[0107] Step d3: If the current bandwidth of the endpoint device is not less than the target bandwidth of the first point-to-point communication link, then it is determined that the endpoint device does not have a bandwidth reduction problem.

[0108] Transmission performance issues include bandwidth reduction.

[0109] The endpoint device transmission performance recovery method provided in this application compares the current bandwidth of the endpoint device with the target bandwidth of the first point-to-point communication link to determine whether the endpoint device has a bandwidth reduction problem, thus achieving accurate detection of the bandwidth reduction problem of the endpoint device.

[0110] In some optional implementations, step S303 above includes:

[0111] Step e1: If the target link retraining strategy is the link parameter renegotiation strategy, set the retraining bit of the second link control register of the root port on the target point-to-point communication link to 1 to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

[0112] Understandably, when the target link retraining strategy is a link parameter renegotiation strategy, the Link Retrain control option is enabled, and the corresponding code function is executed. When this code function detects that the Link Retrain control option is enabled, the BIOS sets the retraining bit of the second link control register on the root port of the target point-to-point communication link to 1, thereby triggering Link Retraining and retraining the target point-to-point communication link.

[0113] The second link control register is the Link Control register. Bit 5 of the Link Control register is the retraining bit.

[0114] Understandingly, the process essentially involves the BIOS sending the target register configuration instruction corresponding to the link parameter renegotiation strategy to the central processing unit (CPU). The CPU receives the instruction and forwards it to the target point-to-point communication link controller. The target point-to-point communication link controller then configures the target registers based on the instruction to trigger Link Retraining. This target register configuration includes setting the retraining bit of the second link control register on the root port of the target point-to-point communication link to 1.

[0115] The endpoint device transmission performance recovery method provided in this application can quickly trigger the retraining process on the target point-to-point communication link by setting the retraining bit of the second link control register of the root port on the target point-to-point communication link to 1, thereby rapidly restoring the normal transmission performance of the endpoint device and reducing communication interruption time.

[0116] In some optional implementations, step S303 above includes:

[0117] Step f1: When the target link retraining strategy is the transmitter equalization reconfiguration strategy, obtain the target rate of the endpoint device, update the target rate bit of the first link control register of the root port of the target point-to-point communication link based on the target rate of the endpoint device, set the equalization execution bit of the third link control register of the root port of the target point-to-point communication link to 1, and set the retraining bit of the second link control register of the root port of the target point-to-point communication link to 1 to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

[0118] When the target link retraining strategy is the transmitter equalization reconfiguration strategy, the TxEQ Redo control option is enabled, and the corresponding code function is executed. When this code function detects that the TxEQ Redo control option is enabled, the BIOS obtains the target rate of the endpoint device. Based on the target rate of the endpoint device, it updates the target rate bit of the first link control register of the root port of the target point-to-point communication link; sets the equalization execution bit of the third link control register of the root port of the target point-to-point communication link to 1; and sets the retraining bit of the second link control register of the root port of the target point-to-point communication link to 1 to trigger TxEQ Redo and achieve retraining of the target point-to-point communication link.

[0119] Specifically, the target rate bits (Bits 0-3) of the Link Control 2 register at the root port of the target point-to-point communication link are updated to the target rate of the endpoint device. In other words, the target rate of the root port on the target point-to-point communication link is updated to the target rate of the endpoint device. The third link control register is the Link Control 3 register. The Perform Equalization bit of the third link control register is Bit 0 of the Link Control 3 register. The second link control register is the Link Control register. The Retrain Link bit of the second link control register is Bit 5 of the Link Control register.

[0120] Understandingly, the process essentially involves the BIOS sending the target register configuration instruction corresponding to the transmitter equalization reconfiguration strategy to the central processing unit (CPU). The CPU receives the instruction and forwards it to the target point-to-point communication link controller. The target point-to-point communication link controller then configures the target registers based on the instruction to trigger TxEQ Redo. This target register configuration includes: updating the target rate bit of the first link control register at the root port of the target point-to-point communication link based on the target rate of the endpoint device; setting the equalization execution bit of the third link control register at the root port of the target point-to-point communication link to 1; and setting the retraining bit of the second link control register at the root port of the target point-to-point communication link to 1.

[0121] In some optional implementations, step S303 above includes:

[0122] Step g1: If the target link retraining strategy is the secondary bus reset strategy, set the secondary bus reset strategy control bit of the bridge control register of the root port on the target point-to-point communication link to 1 to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

[0123] When the target link retraining strategy is a secondary bus reset strategy, the SBR control option is enabled, and the corresponding code function is executed. When this code function detects that the SBR control option is enabled, the BIOS sets the secondary bus reset strategy control bit of the bridge control register of the root port on the target point-to-point communication link to 1 to trigger SBR and retrain the target point-to-point communication link.

[0124] The Bridge Control register is the same as the Bridge Control register. The Secondary Bus Reset bit of the Bridge Control register is bit 6.

[0125] Understandingly, the process essentially involves the BIOS sending the target register configuration instruction corresponding to the secondary bus reset policy to the central processing unit (CPU). The CPU receives the instruction and forwards it to the target point-to-point communication link controller (SBR). The SBR then configures the target registers based on the configuration instruction to trigger the SBR. This configuration includes setting the secondary bus reset policy control bit in the bridge control register of the root port on the target point-to-point communication link to 1.

[0126] In some optional implementations, the above-mentioned endpoint device transmission performance recovery method further includes:

[0127] Step h1: If the transmission performance of the endpoint device does not recover after retraining the target point-to-point communication link based on the target link retraining strategy, then return to the step of retraining the target point-to-point communication link based on the target link retraining strategy.

[0128] If, after retraining the target point-to-point communication link based on the target link retraining strategy, the current bandwidth of the endpoint device is still less than the target bandwidth of its corresponding point-to-point communication link, or the current rate of the endpoint device is still less than the target rate of its corresponding point-to-point communication link, then it is determined that the transmission performance of the endpoint device has not been restored.

[0129] Step h2: If the number of times the step of retraining the target point-to-point communication link based on the target link retraining strategy exceeds the preset threshold, and the transmission performance of the endpoint device has not yet recovered, an alarm is issued.

[0130] The preset threshold number of attempts is set by technical personnel.

[0131] The endpoint device transmission performance recovery method provided in this application does not immediately determine failure when the initial link retraining fails to restore transmission performance. Instead, it repeats the retraining process based on the same strategy. This retry mechanism can significantly improve the success rate of link recovery and enhance the fault tolerance and self-healing capabilities of the communication system.

[0132] If multiple retraining attempts fail, it likely indicates a deeper problem. In this case, triggering an alert helps to promptly remind operations and maintenance personnel to intervene and investigate, avoiding unnecessary retrying that could lead to resource waste or accumulated business delays.

[0133] In some optional implementations, the above-mentioned endpoint device transmission performance recovery method further includes:

[0134] Step i1: If the transmission performance of the endpoint device does not recover after retraining the target point-to-point communication link based on the target link retraining strategy, when the target link retraining strategy is the transmitter equalization reconfiguration strategy, then update the target link retraining strategy to the link parameter renegotiation strategy and return to the step of retraining the target point-to-point communication link based on the target link retraining strategy.

[0135] The endpoint device transmission performance recovery method provided in this application significantly improves the overall success rate of link recovery by using a more comprehensive link parameter renegotiation strategy to retrain the target point-to-point communication link if the transmission performance of the endpoint device is not restored after retraining the target point-to-point communication link using a transmitter equalization reconfiguration strategy.

[0136] In some optional implementations, the above-mentioned endpoint device transmission performance recovery method further includes:

[0137] Step j1: If the target link retraining strategy is a link parameter renegotiation strategy, and the transmission performance of the endpoint device does not recover after retraining the target point-to-point communication link based on the target link retraining strategy, then update the target link retraining strategy to a secondary bus reset strategy, and return to the step of retraining the target point-to-point communication link based on the target link retraining strategy.

[0138] The endpoint device transmission performance recovery method provided in this application significantly improves the overall success rate of link recovery by using a more comprehensive secondary bus reset strategy to retrain the target point-to-point communication link if the transmission performance of the endpoint device is not restored after retraining the target point-to-point communication link using a link parameter renegotiation strategy.

[0139] In some optional implementations, the above-mentioned endpoint device transmission performance recovery method further includes:

[0140] Step K1: If the transmission performance of the endpoint device does not recover after the target point-to-point communication link is retrained based on the target link retraining strategy when the target link retraining strategy is the secondary bus reset strategy, an alarm is issued.

[0141] Secondary bus reset is a more thorough link reset method. If the transmission performance of the endpoint device still fails to recover after such a strong recovery operation, it means that the problem may have exceeded the self-healing range. At this time, triggering an alarm can quickly locate the potential serious fault and avoid the system from continuing to run ineffectively.

[0142] It should be noted that when a PCIe link experiences other link problems besides the transmission performance issues of the endpoint device, these problems can also be resolved by retraining the PCIe link with the other link issues. Specifically, if any PCIe link experiences other link problems, a target link retraining strategy is determined from multiple link retraining strategies based on the current operating state of the computing device. The PCIe link is then retrained based on the target link retraining strategy to resolve the other link problems of that PCIe link.

[0143] If retraining fails to resolve the link issues for PCIe links experiencing other link problems, an alarm will be issued.

[0144] It should be further noted that the embodiments of this application are described using the server architecture of the Intel platform, but the endpoint device transmission performance recovery method provided in this application is not limited to the server architecture of the Intel platform, nor is it limited to the server system. It is still applicable to server systems on other platforms or other computer systems.

[0145] Embodiments of this application provide a method for restoring the transmission performance of an endpoint device, applied to an initialization module. Figure 4 This is a flowchart illustrating the endpoint device transmission performance recovery method provided in an embodiment of this application, as shown below. Figure 4 As shown, the method for restoring the transmission performance of the endpoint device includes the following steps:

[0146] Three control options are set in the initialization module. These three control options are Link Retrain control option, TxEQ Redo control option, and SBR control option.

[0147] Iterate through all point-to-point communication links and obtain the register data of the root port on each point-to-point communication link.

[0148] Iterate through all point-to-point communication links and obtain the register data of the endpoint devices on each point-to-point communication link.

[0149] The target rate for each point-to-point communication link is determined based on the first link control register data of the root port and the first link control register data of the endpoint devices.

[0150] The target bandwidth for each point-to-point communication link is determined based on the link capability register data of the root port and the link capability register data of the endpoint devices.

[0151] Based on the link status register data of the endpoint device, determine the current rate and current bandwidth of the endpoint device.

[0152] By comparing the current rate of the endpoint device with the target rate of the corresponding point-to-point communication link, and comparing the current bandwidth of the endpoint device with the target bandwidth of the corresponding point-to-point communication link, if the current rate of the endpoint device is less than the target rate of the corresponding point-to-point communication link or the current bandwidth of the endpoint device is less than the target bandwidth of the corresponding point-to-point communication link, it is determined that the endpoint device has experienced a rate reduction or bandwidth reduction problem.

[0153] When a rate reduction or bandwidth reduction problem occurs on the endpoint device, the three control options are enabled or disabled according to the current operating status of the computing device.

[0154] When the first control option corresponding to the link parameter renegotiation strategy is enabled, the retraining bit of the second link control register of the root port on the target point-to-point communication link is set to 1 to trigger link parameter renegotiation and realize the retraining of the target point-to-point communication link.

[0155] When the second control option corresponding to the transmitter equalization reconfiguration strategy is enabled, the target rate of the endpoint device is obtained. Based on the target rate of the endpoint device, the target rate bit of the first link control register of the root port of the target point-to-point communication link is updated. The uniform execution bit of the third link control register of the root port of the target point-to-point communication link is set to 1. The retraining bit of the second link control register of the root port of the target point-to-point communication link is set to 1 to trigger transmitter equalization reconfiguration and realize the retraining of the target point-to-point communication link.

[0156] When the third control option corresponding to the secondary bus reset strategy is enabled, the secondary bus reset strategy control bit of the bridge control register of the root port on the target point-to-point communication link is set to 1 to trigger the secondary bus reset and realize the retraining of the target point-to-point communication link.

[0157] The endpoint device transmission performance recovery method provided in this application determines the target link retraining strategy from multiple link retraining strategies based on the current operating state of the computing device when a rate reduction or bandwidth reduction problem occurs in any endpoint device. The target link retraining strategy is then used to restore the transmission performance of the endpoint device. This achieves the technical effect of improving flexibility and recovery efficiency by using different retraining methods according to the actual situation to restore the transmission performance problem of the endpoint device.

[0158] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method.

[0159] Embodiments of this application also provide an endpoint device transmission performance recovery device, such as... Figure 5 As shown, the endpoint device transmission performance restoration device includes:

[0160] The acquisition module 501 is used to acquire the register data of the root port and the register data of the endpoint devices on the point-to-point communication link if the initial training of the point-to-point communication link is completed when the initialization module initializes the computing device.

[0161] The determination module 502 is used to determine whether there is a transmission performance problem in the endpoint device based on the register data of the root port and the register data of the endpoint device.

[0162] The recovery module 503 is used to determine the target point-to-point communication link where any endpoint device is located if the endpoint device has a transmission performance problem; determine the target link retraining strategy from multiple link retraining strategies based on the current operating state of the computing device; and retrain the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device.

[0163] In some alternative implementations, the determining module 502 includes:

[0164] The first determining unit is used to determine the target rate of each point-to-point communication link based on the first link control register data of the root port and the first link control register data of the endpoint device.

[0165] The second determining unit is used to determine the target bandwidth of each point-to-point communication link based on the link capability register data of the root port and the link capability register data of the endpoint device.

[0166] The third determining unit is used to determine the current rate and current bandwidth of the endpoint device based on the link status register data of the endpoint device.

[0167] The fourth determining unit is used to determine whether there is a transmission performance problem in the endpoint device based on the target rate of each point-to-point communication link, the target bandwidth of each point-to-point communication link, the current rate and current bandwidth of the endpoint device.

[0168] In some optional implementations, the first determining unit includes:

[0169] The fifth determining unit is used to determine the target rate of the root port based on the data in the first link control register of the root port.

[0170] The sixth determining unit is used to determine the target rate of the endpoint device based on the first link control register data of the endpoint device.

[0171] The first acquisition unit is used to acquire the target rate of the target root port and the target rate of the target endpoint device on any point-to-point communication link.

[0172] The seventh determining unit is used to determine the target rate of the point-to-point communication link based on the target rate of the target root port and the target rate of the target endpoint device.

[0173] In some optional implementations, the seventh determining unit includes:

[0174] The eighth determining unit is used to determine the minimum target rate between the target rate of the target root port and the target rate of the target endpoint device as the target rate of the point-to-point communication link.

[0175] In some optional implementations, the second determining unit includes:

[0176] The ninth determining unit is used to determine the maximum bandwidth of the root port based on the link capability register data of the root port.

[0177] The tenth determining unit is used to determine the maximum bandwidth of the endpoint device based on the link capability register data of the endpoint device.

[0178] The second acquisition unit is used to acquire the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device on any point-to-point communication link.

[0179] The eleventh determining unit is used to determine the target bandwidth of the point-to-point communication link based on the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device.

[0180] In some optional implementations, the eleventh determining unit includes:

[0181] The twelfth determining unit is used to determine the minimum value between the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device as the target bandwidth of the point-to-point communication link.

[0182] In some optional implementations, the fourth determining unit includes:

[0183] The thirteenth determining unit is used to determine the target rate of the first point-to-point communication link where any endpoint device is located, based on the target rate of each point-to-point communication link.

[0184] The fourteenth determining unit is used to determine that the endpoint device has a rate reduction problem if the current rate of the endpoint device is less than the target rate of the first point-to-point communication link.

[0185] The fifteenth determining unit is used to determine that the endpoint device does not have a rate reduction problem if the current rate of the endpoint device is not less than the target rate of the first point-to-point communication link.

[0186] Transmission performance issues include rate reduction problems.

[0187] In some optional implementations, the fourth determining unit includes:

[0188] The sixteenth determining unit is used to determine the target bandwidth of the first point-to-point communication link where any endpoint device is located, based on the target bandwidth of each point-to-point communication link.

[0189] The seventeenth determining unit is used to determine that the endpoint device has a bandwidth reduction problem if the current bandwidth of the endpoint device is less than the target bandwidth of the first point-to-point communication link.

[0190] The eighteenth determining unit is used to determine that the endpoint device does not have a bandwidth reduction problem if the current bandwidth of the endpoint device is not less than the target bandwidth of the first point-to-point communication link.

[0191] Transmission performance issues include bandwidth reduction.

[0192] In some alternative implementations, the recovery module 503 includes:

[0193] The nineteenth determining unit is used to determine the service tolerance of the computing device based on the current operating status of the computing device.

[0194] The twentieth determining unit is used to determine the target link retraining strategy as the transmitter equalization reconfiguration strategy if the service tolerance of the computing device is lower than the first tolerance threshold.

[0195] The twenty-first determining unit is used to determine the target link retraining strategy as the link parameter renegotiation strategy if the service tolerance of the computing device is not lower than the first tolerance threshold and is lower than the second tolerance threshold.

[0196] The 22nd determining unit is used to determine the target link retraining strategy as the secondary bus reset strategy if the service tolerance of the computing device is not lower than the second tolerance threshold.

[0197] In some alternative implementations, the recovery module 503 includes:

[0198] The first recovery unit is used to set the retraining bit of the second link control register of the root port on the target point-to-point communication link to 1 when the target link retraining strategy is the link parameter renegotiation strategy, so as to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

[0199] In some alternative implementations, the recovery module 503 includes:

[0200] The second recovery unit is used to obtain the target rate of the endpoint device when the target link retraining strategy is the transmitter equalization reconfiguration strategy, and based on the target rate of the endpoint device, update the target rate bit of the first link control register of the root port of the target point-to-point communication link; set the equalization execution bit of the third link control register of the root port of the target point-to-point communication link to 1; and set the retraining bit of the second link control register of the root port of the target point-to-point communication link to 1 to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

[0201] In some alternative implementations, the recovery module 503 includes:

[0202] The third recovery unit is used to set the secondary bus reset policy control bit of the bridge control register of the root port on the target point-to-point communication link to 1 when the target link retraining policy is the secondary bus reset policy, so as to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

[0203] In some optional embodiments, the above-mentioned endpoint device transmission performance recovery device further includes:

[0204] The return execution unit is used to return to the step of retraining the target point-to-point communication link based on the target link retraining strategy if the transmission performance of the endpoint device has not recovered after retraining the target point-to-point communication link based on the target link retraining strategy.

[0205] The first alarm unit is used to issue an alarm if the number of times the step of retraining the target point-to-point communication link based on the target link retraining strategy exceeds a preset threshold, and the transmission performance of the endpoint device has not yet recovered.

[0206] In some optional embodiments, the above-mentioned endpoint device transmission performance recovery device further includes:

[0207] The first update unit is used to update the target link retraining strategy to a link parameter renegotiation strategy if the transmission performance of the endpoint device does not recover after retraining the target point-to-point communication link based on the target link retraining strategy, when the target link retraining strategy is the transmitter equalization reconfiguration strategy. Then, it returns to the step of retraining the target point-to-point communication link based on the target link retraining strategy.

[0208] In some optional embodiments, the above-mentioned endpoint device transmission performance recovery device further includes:

[0209] The second update unit is used to update the target link retraining strategy to a secondary bus reset strategy if the transmission performance of the endpoint device does not recover after retraining the target point-to-point communication link based on the target link retraining strategy, when the target link retraining strategy is a link parameter renegotiation strategy. Then, it returns to the step of retraining the target point-to-point communication link based on the target link retraining strategy.

[0210] In some optional embodiments, the above-mentioned endpoint device transmission performance recovery device further includes:

[0211] The second alarm unit is used to issue an alarm if the transmission performance of the endpoint device is not restored after the target point-to-point communication link is retrained based on the target link retraining strategy when the target link retraining strategy is the secondary bus reset strategy.

[0212] For a description of the features in the embodiment corresponding to the endpoint device transmission performance recovery device, please refer to the relevant description of the embodiment corresponding to the endpoint device transmission performance recovery method, which will not be repeated here.

[0213] Embodiments of this application also provide an electronic device, such as... Figure 6 As shown, it includes a processor 601 and a memory 602, in which a computer program is stored. The processor 601 is configured to run the computer program to perform the steps in any of the above embodiments of the endpoint device transmission performance recovery method.

[0214] Embodiments of this application also provide a computer-readable storage medium storing a computer program, wherein the computer program is configured to execute the steps in any of the above embodiments of the endpoint device transmission performance recovery method when running.

[0215] In one exemplary embodiment, the aforementioned computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard disk, magnetic disk, or optical disk.

[0216] Embodiments of this application also provide a computer program product, which includes a computer program that, when executed by a processor, implements the steps in any of the above embodiments of the endpoint device transmission performance recovery method.

[0217] Embodiments of this application also provide another computer program product, including a non-volatile computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps in any of the above embodiments of the endpoint device transmission performance recovery method.

[0218] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0219] The present application provides a detailed description of an endpoint device transmission performance recovery method and electronic device. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the embodiments above are only intended to help understand the method and core ideas of this application. It should be noted that those skilled in the art can make various improvements and modifications to this application without departing from its principles, and these improvements and modifications also fall within the protection scope of the claims of this application.

Claims

1. A method for restoring the transmission performance of an endpoint device, characterized in that, include: When the initialization module initializes the computing device, if the initial training of the point-to-point communication link is completed, the register data of the root port and the register data of the endpoint device on the point-to-point communication link are obtained. Based on the register data of the root port and the register data of the endpoint device, determine whether the endpoint device has a transmission performance problem; For any endpoint device, if the endpoint device has a transmission performance problem, then determine the target point-to-point communication link where the endpoint device is located; Based on the current operating state of the computing device, a target link retraining strategy is determined from multiple link retraining strategies. The target point-to-point communication link is retrained based on the target link retraining strategy to restore the transmission performance of the endpoint device. The register data includes first link control register data, link capability register data, and link status register data. Determining whether the endpoint device has a transmission performance problem based on the register data of the root port and the register data of the endpoint device includes: Based on the first link control register data of the root port and the first link control register data of the endpoint device, the target rate of each point-to-point communication link is determined; Based on the link capability register data of the root port and the link capability register data of the endpoint devices, the target bandwidth of each point-to-point communication link is determined. Based on the link status register data of the endpoint device, determine the current rate and current bandwidth of the endpoint device; Based on the target rate of each point-to-point communication link, the target bandwidth of each point-to-point communication link, the current rate and current bandwidth of the endpoint device, determine whether the endpoint device has a transmission performance problem; The step of determining the target link retraining strategy from multiple link retraining strategies based on the current operating state of the computing device includes: Based on the current operating status of the computing device, determine the service tolerance of the computing device; If the service tolerance of the computing device is lower than the first tolerance threshold, then the target link retraining strategy is determined to be the transmitter equalization reconfiguration strategy. If the service tolerance of the computing device is not lower than the first tolerance threshold and is lower than the second tolerance threshold, then the target link retraining strategy is determined to be the link parameter renegotiation strategy. If the service tolerance of the computing device is not lower than the second tolerance threshold, then the target link retraining strategy is determined to be the secondary bus reset strategy. The first tolerance threshold is less than the second tolerance threshold.

2. The method according to claim 1, characterized in that, The determination of the target rate for each point-to-point communication link based on the first link control register data of the root port and the first link control register data of the endpoint device includes: Based on the first link control register data of the root port, determine the target rate of the root port; The target rate of the endpoint device is determined based on the first link control register data of the endpoint device; For any point-to-point communication link, obtain the target rate of the target root port and the target rate of the target endpoint device on that point-to-point communication link. The target rate of the point-to-point communication link is determined based on the target rate of the target root port and the target rate of the target endpoint device.

3. The method according to claim 2, characterized in that, Determining the target rate of the point-to-point communication link based on the target rate of the target root port and the target rate of the target endpoint device includes: The minimum target rate between the target rate of the target root port and the target rate of the target endpoint device is determined as the target rate of the point-to-point communication link.

4. The method according to claim 1, characterized in that, The target bandwidth for each point-to-point communication link is determined based on the link capability register data of the root port and the link capability register data of the endpoint devices, including: Based on the link capability register data of the root port, determine the maximum bandwidth of the root port; The maximum bandwidth of the endpoint device is determined based on the link capability register data of the endpoint device; For any point-to-point communication link, obtain the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device on that point-to-point communication link. The target bandwidth of the point-to-point communication link is determined based on the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device.

5. The method according to claim 4, characterized in that, Determining the target bandwidth of the point-to-point communication link based on the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device includes: The minimum value between the maximum bandwidth of the target root port and the maximum bandwidth of the target endpoint device is determined as the target bandwidth of the point-to-point communication link.

6. The method according to claim 1, characterized in that, The determination of whether the endpoint device has a transmission performance problem based on the target rate of each point-to-point communication link, the target bandwidth of each point-to-point communication link, and the current rate and current bandwidth of the endpoint device includes: For any endpoint device, the target rate of the first point-to-point communication link to which the endpoint device is located is determined based on the target rate of each point-to-point communication link; If the current rate of the endpoint device is less than the target rate of the first point-to-point communication link, then it is determined that the endpoint device has a rate reduction problem. If the current rate of the endpoint device is not less than the target rate of the first point-to-point communication link, then it is determined that the endpoint device does not have a rate reduction problem. The transmission performance issues include the rate reduction problem.

7. The method according to claim 1, characterized in that, The determination of whether the endpoint device has a transmission performance problem based on the target rate of each point-to-point communication link, the target bandwidth of each point-to-point communication link, and the current rate and current bandwidth of the endpoint device includes: For any endpoint device, the target bandwidth of the first point-to-point communication link where the endpoint device is located is determined based on the target bandwidth of each point-to-point communication link; If the current bandwidth of the endpoint device is less than the target bandwidth of the first point-to-point communication link, then it is determined that the endpoint device has a bandwidth reduction problem; If the current bandwidth of the endpoint device is not less than the target bandwidth of the first point-to-point communication link, then it is determined that the endpoint device does not have a bandwidth reduction problem; The transmission performance issues include bandwidth reduction.

8. The method according to claim 1, characterized in that, The retraining of the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device includes: When the target link retraining strategy is a link parameter renegotiation strategy, the retraining bit of the second link control register of the root port on the target point-to-point communication link is set to 1 to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

9. The method according to claim 1, characterized in that, The retraining of the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device includes: When the target link retraining strategy is a transmitter equalization reconfiguration strategy, the target rate of the endpoint device is obtained. Based on the target rate of the endpoint device, the target rate bit of the first link control register of the root port of the target point-to-point communication link is updated. The equalization execution bit of the third link control register of the root port of the target point-to-point communication link is set to 1. The retraining bit of the second link control register of the root port of the target point-to-point communication link is set to 1 to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

10. The method according to claim 1, characterized in that, The retraining of the target point-to-point communication link based on the target link retraining strategy to restore the transmission performance of the endpoint device includes: When the target link retraining strategy is a secondary bus reset strategy, the secondary bus reset strategy control bit of the bridge control register of the root port on the target point-to-point communication link is set to 1 to trigger the retraining of the target point-to-point communication link and restore the transmission performance of the endpoint device.

11. The method according to claim 1, characterized in that, The method further includes: If the target link retraining strategy is a transmitter equalization reconfiguration strategy, and the transmission performance of the endpoint device does not recover after retraining the target point-to-point communication link based on the target link retraining strategy, then the target link retraining strategy is updated to a link parameter renegotiation strategy, and the process returns to the step of retraining the target point-to-point communication link based on the target link retraining strategy.

12. The method according to claim 1, characterized in that, The method further includes: If the target link retraining strategy is a link parameter renegotiation strategy, and the transmission performance of the endpoint device does not recover after retraining the target point-to-point communication link based on the target link retraining strategy, then the target link retraining strategy is updated to a secondary bus reset strategy, and the process returns to the step of retraining the target point-to-point communication link based on the target link retraining strategy.

13. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor, configured to implement the steps of the endpoint device transmission performance recovery method as described in any one of claims 1 to 12 when executing the computer program.

Citation Information

Patent Citations

  • PCIE (Peripheral Component Interface Express) equipment link training control method and system, electronic equipment and medium

    CN116009975A

  • Data transmission method and device, electronic equipment, program product and medium

    CN120067022A