Faulty equipment locating method, computer equipment, storage medium and product

The function identifier and register address information of the extended device are obtained by preset target files, and the faulty device is judged in combination with bandwidth rate and register information, which solves the problem of inaccurate fault inspection at both ends of the integrated circuit equipment and improves maintenance efficiency.

CN120386661BActive Publication Date: 2025-08-22INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510867170.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-06-26
Publication Date
2025-08-22
Estimated Expiration
2045-06-26

AI Technical Summary

Technical Problem

In the prior art, the fault inspection of the extended equipment at both ends of the integrated circuit equipment is not accurate enough to quickly and accurately locate the faulty equipment, resulting in ineffective maintenance.

Method used

The preset target file saves the function identifier and register address information of the extension device, obtains the bandwidth rate information and register address information of each extension device, determines whether the preset fault positioning conditions are met, and determines the faulty device based on the register information of the candidate extension device pair and the extension device protocol table.

Benefits of technology

It realizes the extended equipment that quickly and accurately locates faults at both ends of integrated circuit equipment, improves the handling efficiency of maintenance personnel, and facilitates accurate replacement of abnormal equipment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120386661B_ABST
    Figure CN120386661B_ABST
Patent Text Reader

Abstract

The present application discloses a faulty device locating method, computer equipment, storage medium and product, and relates to the field of server technology. The method comprises: when determining that an extension device meets preset fault locating conditions through bandwidth rate information and / or register address information of extension devices connected at both ends of an integrated circuit device, matching the register information record values ​​of the extension devices connected at both ends of the integrated circuit device with a preset extension device protocol table respectively to accurately locate the faulty device from among the extension devices connected at both ends. The method solves the technical problems that the current method of detecting extension device faults is not accurate enough, and after determining that the extension device fault is caused, it is impossible to determine which end of the extension device is the cause, which is not conducive to the user's location of the problem device. The method achieves the technical effect of quickly and accurately locating the faulty extension devices at both ends of the integrated circuit device, facilitating the user to accurately replace the abnormal device, and improving processing efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of server technology, and in particular to a method for locating a faulty device, a computer device, a storage medium, and a product. Background Art

[0002] Integrated circuit devices (such as retimer cards) are crucial components for connecting server components and are increasingly used. Expansion devices are connected at both ends of an integrated circuit device. For example, a retimer card typically connects to a PCIE (Peripheral Component Interconnect Express) device as an expansion device. In actual applications, if the expansion devices at both ends of the integrated circuit device cannot connect properly or are randomly lost, it poses a risk to the normal operation of the server. Therefore, it is necessary to quickly and accurately locate the faulty expansion devices at both ends of the integrated circuit device.

[0003] In the related art, since the integrated circuit device itself does not have expansion device information, it is impossible to effectively detect expansion device failures. After determining that the expansion device failure is confirmed, it is impossible to determine which end of the expansion device is the cause, which is not conducive to maintenance personnel locating the problem device. Summary of the Invention

[0004] The present application provides a method for locating a faulty device, a computer device, a storage medium, and a product to at least solve the problem in the related art that the current method of detecting expansion device failure is not accurate enough, and after determining that the expansion device failure is caused, it is impossible to determine which end of the expansion device is the cause, which is not conducive to users locating the problem device.

[0005] The present application provides a faulty device locating method, comprising: applying the method to a server, the server comprising at least one integrated circuit device, one end of the integrated circuit device being connected to an expansion device, and the other end of the integrated circuit device being connected to another expansion device. The method comprises: in response to a detection instruction, obtaining a function identifier and register address information of each of the expansion devices from a preset file; obtaining bandwidth rate information of each of the expansion devices based on the function identifier, and determining whether each of the expansion devices meets preset fault locating conditions based on the bandwidth rate information and / or the register address information; when any target expansion device in each of the expansion devices meets the preset fault locating conditions, determining the target expansion device and the expansion device connected to the other end of the integrated circuit device to which the target expansion device is connected as a candidate expansion device pair, obtaining register information record values ​​based on register address information of the candidate expansion device pair; and determining a faulty device from the candidate expansion device pair based on the register information record values ​​and a preset expansion device protocol table.

[0006] The present application also provides a faulty device locating apparatus, comprising: the apparatus being applied to a server, the server comprising at least one integrated circuit device, one end of the integrated circuit device being connected to an expansion device, and the other end of the integrated circuit device being connected to another expansion device; the apparatus comprising: a first acquisition module, configured to, in response to a detection instruction, acquire a function identifier and register address information of each of the expansion devices from a preset file; a second acquisition module, configured to acquire bandwidth rate information of each of the expansion devices based on the function identifier; a determination module, configured to determine, based on the bandwidth rate information and / or the register address information, whether each of the expansion devices meets a preset fault locating condition; a third acquisition module, configured to, when any target expansion device in each of the expansion devices meets the preset fault locating condition, select the target expansion device and the expansion device connected to the other end of the integrated circuit device to which the target expansion device is connected as a candidate expansion device pair; a fourth acquisition module, configured to acquire a register information record value based on the register address information of the candidate expansion device pair; and a determination module, configured to determine a faulty device from the candidate expansion device pair based on the register information record value and a preset expansion device protocol table.

[0007] The present application also provides a computer device, comprising: a memory for storing a computer program; and a processor for implementing the steps of any of the above-mentioned faulty device locating methods when executing the computer program.

[0008] The present application also provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above-mentioned methods for locating a faulty device are implemented.

[0009] The present application also provides a computer program product, including a computer program, which implements the steps of any of the above-mentioned faulty device locating methods when executed by a processor.

[0010] According to the present application, since the function identifiers and register address information of the extension devices are stored in a preset target file, when detection is required, the function identifier and register address information of each extension device are obtained from the preset file, and the bandwidth rate information of each extension device is obtained based on the function identifier. When it is determined based on the bandwidth rate information of each extension device and / or the register address information that any target extension device in each extension device meets the preset fault location conditions, the target extension device and the extension device connected to the other end of the integrated circuit device to which the target extension device is connected are used as candidate extension device pairs, and the register information record values ​​corresponding to the candidate extension device pairs are obtained and matched with the preset extension device protocol table to accurately locate the faulty device from the candidate extension device pairs. Therefore, the technical problems that the current method of detecting extension device faults is not accurate enough and that it is impossible to determine which end of the extension device caused the fault after determining that the extension device fault is determined, which is not conducive to maintenance personnel locating the faulty device, can be solved. The faulty extension devices at both ends of the integrated circuit device can be quickly and accurately located, which facilitates maintenance personnel to accurately replace the abnormal device and improves processing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] In order to more clearly illustrate the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0012] Figure 1 This is an application scenario diagram of a faulty device locating method provided in an embodiment of the present application;

[0013] Figure 2 A flowchart of a method for locating a faulty device provided in an embodiment of the present application;

[0014] Figure 3 An example diagram of device connections provided in an embodiment of the present application;

[0015] Figure 4 This is an example diagram of a method for locating a faulty device provided in an embodiment of the present application;

[0016] Figure 5 A schematic structural diagram of a faulty equipment locating device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0017] The following will be combined with the accompanying drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

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

[0019] In order to enable those skilled in the art to better understand the present application, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.

[0020] In conjunction with the specific application environment architecture or specific hardware architecture on which the execution of the faulty device locating method depends, the specific application environment architecture or specific hardware architecture is described herein.

[0021] Specifically, integrated circuit devices are important components for connecting server components and are increasingly used. Expansion devices are connected at both ends of the integrated circuit devices. Since the integrated circuit devices themselves do not have expansion device information, expansion device failures cannot be quickly and accurately detected in the server. In addition, even after an expansion device abnormality is detected, it is impossible to determine which end of the expansion device is the cause, which is not conducive to locating the problem device. Maintenance personnel can only try to replace the expansion devices one by one for verification and elimination, resulting in low maintenance efficiency. Therefore, there is an urgent need for a method that can accurately determine which end of the expansion device of the integrated circuit device has a fault.

[0022] To address the above-mentioned issues, the present application proposes a method for locating a faulty device. This method uses a pre-set target file to store the function identifiers and register address information of extension devices. Thus, when testing is required, the function identifier and register address information of each extension device are obtained from the pre-set file, and the bandwidth rate information of each extension device is obtained based on the function identifier. When it is determined based on the bandwidth rate information of each extension device and / or the register address information that any target extension device in each extension device meets the pre-set fault locating conditions, the target extension device and the extension device connected to the other end of the integrated circuit device to which the target extension device is connected are used as candidate extension device pairs. The register information records corresponding to the candidate extension device pairs are obtained and matched with a pre-set extension device protocol table to accurately locate the faulty device within the candidate extension device pairs. This method solves the technical problems of current methods for detecting extension device faults being inaccurate and, after determining that an extension device fault is faulty, being unable to determine which extension device is the cause, hindering maintenance personnel from locating the faulty device. This method achieves the technical effect of quickly and accurately locating the faulty extension devices at both ends of the integrated circuit device, facilitating maintenance personnel to accurately replace the faulty device, and improving processing efficiency.

[0023] The faulty device location method of the present application can be applied to Figure 1 In the application environment shown. The faulty device locating method is applied to a server. The server includes at least one integrated circuit device 101, one end of the integrated circuit device 101 is connected to an expansion device 102, and the other end of the integrated circuit device 101 is connected to the expansion device 102. In response to a detection instruction, the server obtains the function identifier and register address information of each expansion device 102 from a preset file; obtains the bandwidth rate information of each expansion device 102 based on the function identifier, and determines whether each expansion device 102 meets the preset fault locating condition based on the bandwidth rate information and / or register address information; when any target expansion device in each expansion device 102 meets the preset fault locating condition, the target expansion device and the expansion device 102 connected to the other end of the integrated circuit device 101 connected to the target expansion device are used as candidate expansion device pairs, and register information record values ​​are obtained based on the register address information of the candidate expansion device pairs; and the faulty device is determined from the candidate expansion device pairs based on the register information record values ​​and a preset expansion device protocol table.

[0024] Integrated circuit device 101 may be a retimer card, used to extend the transmission distance of PCIE, USB (Universal Serial Bus), or other high-speed signals. It enhances signal quality by retiming signals, preventing errors caused by signal attenuation during transmission. It is typically used to extend high-bandwidth devices, such as PCIE signal paths, ensuring that high-bandwidth devices can function properly even when away from the motherboard. Expansion device 102 may be a PCIE device, a standard high-speed serial computer expansion bus. PCIE can achieve high data transmission rates.

[0025] Figure 2 This is a flow chart of a method for locating a faulty device provided in an embodiment of the present application. The method for locating a faulty device can be executed by a faulty device locating device, wherein the faulty device locating device can be implemented using software and / or hardware and can generally be integrated into a server. Figure 2 As shown, the faulty device locating method is applied to a server, which includes at least one integrated circuit device, one end of which is connected to an expansion device, and the other end of which is connected to another expansion device. The method includes:

[0026] Step 201: In response to a detection instruction, obtain the function identifier and register address information of each extended device from a preset file.

[0027] In the embodiment of the present application, each expansion device is understood to be an expansion device connected at both ends of all integrated circuit devices in the server.

[0028] In an embodiment of the present application, a file is pre-set. Specifically, the function identifiers of all expansion devices in the server can be pre-queried, and the corresponding register addresses can be queried based on the function identifiers. The function identifiers and register addresses are then associated and stored in the file. The function identifier uniquely identifies an expansion device, and one expansion device corresponds to one function identifier. For example, if the expansion device is a PCIE device, the BDF (Bus, Device, Function) address can be used as the function identifier. The register address refers to the physical layer register location corresponding to the function identifier. Each function identifier has one or more corresponding register addresses.

[0029] In an embodiment of the present application, a detection instruction can be triggered according to a preset frequency or timing, as well as manually, so that in response to the detection instruction, all expansion devices in the server are obtained, and the function identifier and register address information corresponding to each expansion device are obtained from a preset file; wherein the register address information refers to one or more register addresses corresponding to each expansion device. In an embodiment of the present application, the register address information generally includes three register addresses.

[0030] Step 102: Obtain bandwidth rate information of each extension device based on the function identifier, and determine whether each extension device meets a preset fault location condition based on the bandwidth rate information and / or register address information.

[0031] In the embodiment of the present application, the bandwidth rate information can be obtained according to actual application selection and may include bandwidth and / or rate.

[0032] In an embodiment of the present application, after obtaining the function identifier, the bandwidth rate information of each extension device can be obtained based on the function identifier. In some embodiments, a bandwidth rate query command including the function identifier is generated and executed to obtain the current bandwidth and current rate of each extension device as the bandwidth rate information; in other embodiments, a real-time bandwidth rate database is queried based on the function identifier to obtain the current bandwidth and current rate of each extension device as the bandwidth rate information.

[0033] In an embodiment of the present application, after obtaining the bandwidth rate information of each expansion device, it is further determined whether each expansion device meets the preset fault location condition based on the bandwidth rate information and / or register address information; in some embodiments, it is determined whether the current bandwidth of each expansion device is within a preset bandwidth range and / or whether the current rate is within a preset rate range to determine whether each expansion device meets the preset fault location condition.

[0034] In other embodiments, it is determined that the current bandwidth of each expansion device is not within a preset bandwidth range and / or the current rate is not within a preset rate range, and each register of each expansion device is polled based on the register address information of each expansion device to obtain the register return value, and whether each expansion device meets the preset fault location conditions is determined based on whether the register return value of each expansion device includes a non-zero value.

[0035] The above is only an example, and the present application does not impose any specific restrictions on the method of determining whether each extension device meets the preset fault location condition based on the bandwidth rate information and / or register address information.

[0036] Step 103: When any target expansion device in each expansion device meets a preset fault location condition, the target expansion device and the expansion device connected to the other end of the integrated circuit device connected to the target expansion device are taken as a candidate expansion device pair, and register information record values ​​are obtained based on register address information of the candidate expansion device pair.

[0037] Step 104: Determine the faulty device from the candidate expansion device pairs based on the register information record value and the preset expansion device protocol table.

[0038] In an embodiment of the present application, after determining whether each expansion device meets the preset fault location condition based on the bandwidth rate information and / or register address information, it can be understood that one or more expansion devices may meet the preset fault location condition, that is, the expansion device that meets the preset fault location condition is used as the target expansion device; or no expansion device may meet the preset fault location condition.

[0039] It should be noted that when no expansion devices meet the preset fault location conditions, you can continue to determine whether each expansion device meets the preset fault location conditions based on bandwidth rate information and / or register address information, or you can end the detection. The specific settings are selected according to the actual application scenario.

[0040] In an embodiment of the present application, for a scenario in which one or more expansion devices satisfy preset fault locating conditions, the expansion device satisfying the preset fault locating conditions is used as a target expansion device, and the expansion device connected to the other end of the integrated circuit device to which the target expansion device is connected and the target expansion device are obtained together as a candidate expansion device pair. That is, after detecting an abnormality in the target expansion device, the abnormality may be caused by a fault in the target expansion device or by a fault in the expansion device connected to the other end of the integrated circuit device to which the target expansion device is connected. It is necessary to further determine whether the fault is in the target expansion device or in the expansion device connected to the other end of the integrated circuit device to which the target expansion device is connected.

[0041] Furthermore, a register information record value is obtained based on register address information of the candidate expansion device pair, and a faulty device is determined from the candidate expansion device pair according to the register information record value and a preset expansion device protocol table.

[0042] In an embodiment of the present application, obtaining a register information record value based on the register address information of a candidate expansion device pair can be understood as obtaining, for each candidate expansion device, one or more register addresses corresponding to the candidate expansion device according to the register address information corresponding to the candidate expansion device, polling the corresponding register according to the register address, obtaining the return value of the register, determining the register state according to the register return value, and marking the register state by the record value, so that the register information record value of each candidate expansion device can be obtained.

[0043] In an embodiment of the present application, an extended device protocol table is pre-set. Specifically, a normal or faulty mapping table of a proximal device or a distal device corresponding to different register information record values ​​is set as the extended device protocol table.

[0044] Specifically, determining the faulty device from the candidate expansion device pair based on the register information record value and the expansion device protocol table can be understood as, for one candidate expansion device, matching the corresponding register information record value in the expansion device protocol table to determine a faulty device matching result, and then, for another candidate expansion device, matching the corresponding register information record value in the expansion device protocol table to determine another faulty device matching result, and determining the final faulty device based on the two faulty device matching results.

[0045] In summary, the device fault locating method of the present application stores the function identifiers and register address information of extension devices in a preset target file. Therefore, when detection is required, the function identifier and register address information of each extension device are obtained from the preset file, and the bandwidth rate information of each extension device is obtained based on the function identifier. When it is determined based on the bandwidth rate information of each extension device and / or the register address information that any target extension device in each extension device meets the preset fault locating conditions, the target extension device and the extension device connected to the other end of the integrated circuit device to which the target extension device is connected are used as candidate extension device pairs, and the register information record values ​​corresponding to the candidate extension device pairs are obtained and matched with the preset extension device protocol table to accurately locate the faulty device from the candidate extension device pairs. Therefore, the method solves the technical problems of current methods for detecting extension device faults being inaccurate and the inability to determine which end of the extension device caused the fault after determining that the extension device fault occurred, which hinders maintenance personnel from locating the faulty device. The method achieves the technical effect of quickly and accurately locating the faulty extension devices at both ends of the integrated circuit device, facilitating maintenance personnel to accurately replace the faulty device, and improving processing efficiency.

[0046] In some embodiments, before responding to the detection instruction, the method of the present application also includes: obtaining the function identifiers to be stored corresponding to all expansion devices in the server; obtaining the register addresses to be stored corresponding to each function identifier to be stored; and associating the function identifiers to be stored and the register addresses to be stored in a preset file.

[0047] In an embodiment of the present application, it is necessary to obtain the function identifier to be stored corresponding to each expansion device of all expansion devices of the server. Specifically, a target instruction is input, which is used to list the detailed information of all expansion devices in the server (including the bus number, device number, function number, device type, etc. of the device), and display the device information in a tree structure, so that the bus number, device number and function number combination corresponding to each expansion device can be obtained as the function identifier to be stored. That is, by inputting the target instruction, the associated information of all expansion devices in the current server can be queried, thereby obtaining the function identifier to be stored upstream and downstream of the integrated circuit device, and saving the function identifier to be stored corresponding to each expansion device into a preset file; the format of the preset file can be selected and set according to actual application needs.

[0048] For example, the preset file shown in Table 1 includes functional identifiers of the expansion devices at both ends of the integrated circuit device. The expansion device A1 and the expansion device B1 are connected to the same integrated circuit device. Similarly, the expansion devices A2 to A5 are connected to the same integrated circuit device with the expansion devices B2 to B5 respectively.

[0049] Table 1

[0050]

[0051] Furthermore, the corresponding register address to be stored is queried and obtained according to the identifier of the function to be stored of each expansion device; wherein the register address to be stored refers to the register address corresponding to the expansion device, which can be obtained by querying the physical layer register position corresponding to each function identifier to be stored.

[0052] In some embodiments, obtaining the register address to be stored corresponding to each function identifier to be stored includes: generating and executing a register address query instruction including the function identifier to be stored, obtaining the register address to be adjusted, performing address offset processing on the register address to be adjusted based on a preset extension device protocol, and obtaining the register address to be stored.

[0053] Specifically, to query the physical layer register position corresponding to each storage function identifier, first generate the register address query command "lspci-vvv-s${bdf}|grep'Capabilities'|grep'Physical Layer'|awk'{print $2}'|awk-F'[''{print$2}'"; taking the storage function identifier "0000:07:00.0" as an example, you can replace "bdf" in the register address query command with "0000:07:00.0" to query the corresponding register address to be adjusted for the storage function identifier "0000:07:00.0".

[0054] Furthermore, the address of the register to be adjusted is offset according to the expansion device protocol corresponding to the expansion device to obtain the register address to be stored. Taking "0000:07:00.0" and the expansion device being a PICE device as an example, according to the PCIE protocol, "Local Data Parity Mismatch Status Register", "First Retimer Data Parity Mismatch Status Register", and "Second Retimer Data Parity Mismatch Status Register" are offset by 10H, 14H, and 18H respectively relative to the physical layer address. Therefore, the register addresses to be monitored for "0000:07:00.0" are: 260H, 264H, and 268H. The obtained register addresses to be stored are stored in the preset file. By repeating the above steps, all the register addresses to be stored that need to be monitored on the server can be queried and recorded in the preset file.

[0055] Illustratively, the preset file shown in Table 2 includes a mapping relationship table between function identifiers and register addresses; wherein, the register addresses corresponding to different expansion devices may be the same or different, which is determined according to the actual deployment of the expansion devices.

[0056] Table 2

[0057]

[0058] In the above scheme, the function identifiers and corresponding register addresses of all expansion devices that need to be monitored in the server are pre-queried, associated and stored in a preset file, so that when responding to the detection instruction, the function identifier and the corresponding register address can be directly obtained from the preset file to judge the abnormal situation of the expansion device, and in the event of an abnormality, the relevant register information record value can be obtained according to the register address to quickly and accurately locate the expansion devices with faults at both ends of the integrated circuit device, thereby improving the efficiency and effect of device abnormality detection and the subsequent rapid and accurate positioning of the expansion devices with faults at both ends of the integrated circuit device; in addition, the register address can be flexibly determined according to the expansion device protocol to further improve the accuracy of device fault positioning.

[0059] In some embodiments, obtaining bandwidth rate information of each extension device based on the function identifier includes: generating and executing a bandwidth rate query command including the function identifier, and obtaining the current bandwidth and current rate of each extension device as bandwidth rate information.

[0060] Specifically, to check whether the current bandwidth and current rate of the extended device meet the standards, a bandwidth rate query command including a function identifier can be generated and executed, for example, a rate acquisition command "lspci-vv-s ${bdf}|grep-A0-w'LnkSta'|awk-F"Speed|,"'{{print$2}}'|awk'{{print $1}}'|sed-e 's / / / g'" can be generated; a bandwidth acquisition command "lspci-vv-s${bdf}|grep-A0-w'LnkSta'|awk-F"Width|," '{{print $3}}'|awk'{{print$1}}'|sed-e's / / / g'" can be generated; wherein "bdf" can be replaced with a specific function identifier to obtain the current bandwidth and current rate of the corresponding extended device as bandwidth rate information.

[0061] In some embodiments, determining whether each expansion device meets a preset fault location condition based on bandwidth rate information includes: determining whether the current bandwidth is within a preset bandwidth range and whether the current rate is within a preset rate range to determine whether each expansion device meets the preset fault location condition.

[0062] Specifically, the preset fault location conditions may include a preset bandwidth range and a preset rate range. It is understandable that different extension devices have different bandwidth ranges and rate ranges set, which can be determined based on the benchmark rate and benchmark bandwidth of each extension device. For example, a command for obtaining the benchmark rate is generated: "lspci -vv -s ${bdf} | grep -A 0 -w 'LnkCap' | awk -F "Speed|," '{{print $3}}' | sed -e 's / / / g'" and a command for obtaining the benchmark bandwidth is generated: "lspci-vv-s${bdf}|grep-A0-w'LnkCap'|awk-F "Width|,"'{{print$4}}'|sed-e's / / / g'"; wherein "bdf" can be replaced with a specific function identifier to obtain the benchmark bandwidth and benchmark rate of the corresponding extension device, and the preset bandwidth range and preset rate range can be set based on the benchmark bandwidth and benchmark rate.

[0063] Furthermore, it is determined whether the current bandwidth is within a preset bandwidth range and whether the current rate is within a preset rate range. If the current bandwidth is not within the preset bandwidth range and / or the current rate is not within the preset rate range, the expansion device whose current bandwidth is not within the preset bandwidth range and / or whose current rate is not within the preset rate range is selected as a target expansion device. That is, it is possible that the target expansion device has failed, or it is possible that the expansion device connected to the other end of the integrated circuit device connected to the target expansion device has failed. Therefore, the expansion device whose current bandwidth is not within the preset bandwidth range and / or whose current rate is not within the preset rate range is selected as a target expansion device to facilitate subsequent location of the specific faulty device.

[0064] In the above solution, the rate and bandwidth can be used to quickly determine whether the expansion device is normal or abnormal, that is, the abnormality of the expansion device can be quickly and accurately detected, further improving the detection efficiency.

[0065] Based on the description of the above embodiment, when the current bandwidth is within the preset bandwidth range and the current rate is within the preset rate range, it indicates that the rate and bandwidth of the expansion device are normal, and the expansion device can be further detected according to the register address information.

[0066] In some embodiments, when the current bandwidth is within a preset bandwidth range and the current rate is within a preset rate range, each register of each expansion device is polled based on the register address information of each expansion device to obtain a register return value; when the register return value of any target expansion device in each expansion device includes a non-zero value, it is determined that the target expansion device meets the preset fault location condition.

[0067] Specifically, after determining that the current bandwidth is within the preset bandwidth range and the current rate is within the preset rate range, each register of each expansion device is polled based on the register address information obtained from the preset file according to the function identifier of each expansion device to obtain the register return value. In other words, the corresponding register is polled in sequence according to each register address in the register address information to obtain the return value of each register. Whether the register return value includes a non-zero value is then used to determine whether it is normal or abnormal. Abnormal indicates that the preset fault location conditions are met and further fault location needs to be performed. The non-zero value is typically 1.

[0068] It should be noted that when the register return values ​​of all expansion devices are all 0, it is determined that each expansion device does not meet the preset fault location condition, that is, the expansion devices are all normal and do not need to perform fault location processing.

[0069] Specifically, according to the register address information recorded in the preset file, each register is polled according to the register address to query the information in the register, for example, the query command is generated as "setpci -s ${BDF} ${register}"; wherein, "register" is the register address, so that the return value of each register can be obtained, such as "00000000", if all are 0, the status is normal; for example, if "00000001" is not all 0, the status is abnormal, so the expansion device with abnormal detection status is used as the target expansion device, that is, it may be that the target expansion device fails or the expansion device connected to the other end of the integrated circuit device connected to the target expansion device fails. Therefore, the expansion device with abnormal detection status is used as the target expansion device for subsequent specific fault device location.

[0070] Therefore, when all expansion device register checks are normal, it means that the expansion device information connection of the current server is robust and reliable. When an abnormality occurs in the register, it indicates that the expansion device has a potential connection risk and the abnormal expansion device needs to be accurately located.

[0071] In the above scheme, when the current bandwidth is within the preset bandwidth range and the current rate is within the preset rate range, each register of each expansion device is further polled according to the register address information of the expansion device to obtain the register return value, and when the register return value includes a non-zero value, it is determined that the expansion device is abnormal, thereby improving the diversity of expansion device abnormality detection, thereby further ensuring the accuracy of the detection result.

[0072] In some embodiments, obtaining a register information record value based on register address information of a candidate expansion device pair includes: obtaining a register address of each register corresponding to each candidate expansion device in the candidate expansion device pair based on the register address information; polling each register based on the register address to obtain a return value of each register corresponding to each candidate expansion device; setting a record value of each register based on whether the return value of each register includes a non-zero value, and arranging the record value of each register in a preset arrangement order to obtain a register information record value.

[0073] Specifically, when the return value of the register includes a non-zero value, the record value of the register is set to 1; or, when the return value of the register is all 0, the record value of the register is set to 0.

[0074] In actual applications, each expansion device usually includes multiple registers. Taking any expansion device connected at both ends of an integrated circuit device as an example, the expansion device corresponds to multiple registers. The record value of each register is set based on whether the return value of each register includes a non-zero value, and the record value of each register is arranged according to a preset arrangement order to obtain the record value of the candidate expansion device as the register information record value.

[0075] For example, for example, the expansion device corresponds to three registers, and the return value of each register is all 0, then the record value of each register is 0, and the obtained register information record value is "000"; for another example, the expansion device corresponds to three registers, and the return values ​​of two registers are all 0, then the record values ​​of the two registers are 0, and the return value of the other register includes a non-zero value, such as 1, then the record value of the register is 1, and according to the preset arrangement order, the obtained register information record value is "001"; wherein, the arrangement order can be set according to information such as the register address or serial number identifier, and the specific setting is selected according to the application scenario.

[0076] In some embodiments, the candidate expansion device pair includes: a first candidate expansion device and a second candidate expansion device, the first candidate expansion device corresponds to a plurality of first registers, and the second candidate expansion device corresponds to a plurality of second registers; setting a record value of each register based on whether a return value of each register includes a non-zero value, and arranging the record value of each register according to a preset arrangement order to obtain a register information record value, including: setting a record value of each first register based on whether the return value of each first register includes a non-zero value, and arranging the record value of each first register according to a preset arrangement order, to obtain a first record value of the first candidate expansion device as the register information record value; setting a record value of each second register based on whether the return value of each second register includes a non-zero value, and arranging the record value of each second register according to a preset arrangement order, to obtain a second record value of the second candidate expansion device as the register information record value.

[0077] Specifically, in order to ensure that the data bits have not been changed during transmission or storage, each register can implement parity checking by adding a check bit after the data bit, so that the total number of "1"s in the data bits is odd (odd parity) or even (even parity).

[0078] In an embodiment of the present application, the expansion device typically includes three registers, namely, a "Local Data Parity Mismatch Status Register". The local data parity mismatch status register typically appears in computer hardware, especially when involving storage systems (such as memory, hard drives, etc.), and is used to detect and report parity errors that occur during data transmission; a "First Retimer Data Parity Mismatch Status Register", the first retimer data parity mismatch status register is a 32-bit vector, in which each bit indicates whether the first retimer of the path is correct, and each bit indicates whether the corresponding channel has detected a data parity mismatch; a "Second Retimer Data Parity Mismatch Status Register", the second retimer data parity mismatch status register is a 32-bit vector, in which each bit indicates whether the first retimer of the path is correct, and each bit indicates whether the corresponding channel has detected a data parity mismatch.

[0079] Specifically, each register can obtain the corresponding data bit and calculate a check value by adding a numerical value to the data, thereby generating a return value for each register to further ensure the accuracy of the register state.

[0080] In the above scheme, the register information record value can be obtained according to the register address information of the expansion device pair, so that the faulty device can be located subsequently according to the register information record value, further improving the efficiency and accuracy of faulty device location; in addition, determining the register information record value according to the return value of each register can accurately reflect the status information of the expansion device, thereby ensuring the accuracy of detection.

[0081] In some embodiments, the register information record value includes a first record value corresponding to the first candidate expansion device and a second record value corresponding to the second candidate expansion device. Determining the faulty device from the candidate expansion device pair based on the register information record value and a preset expansion device protocol table includes: querying the expansion device protocol table based on the first record value to obtain the proximal device or the distal device of the first candidate expansion device as the first candidate faulty device; querying the expansion device protocol table based on the second record value to obtain the proximal device or the distal device of the second candidate expansion device as the second candidate faulty device; and determining the faulty device based on the first candidate faulty device and the second candidate faulty device.

[0082] Specifically, when an expansion device is abnormal, it is necessary to query all register states of the integrated circuit device connected to the expansion device, such as the expansion device at the other end of the Retimer card (such as a PCIE device).

[0083] For example, the case where the extended device at position "0000:07:00.0" is detected to have an abnormal register status is used for explanation. The function identifier of the opposite device of the integrated circuit device is found to be "0000:08:00.0". The status information of the respective registers of "0000:07:00.0" and "0000:08:00.0", such as "Local Data Parity Mismatch Status Register", "First Retimer Data Parity Mismatch Status Register" and "Second Retimer Data Parity Mismatch Status Register", are queried for each register respectively. If the return value of each register is all 0, it is recorded as 0, and if non-zero information appears, it is recorded as 1, as shown in Table 3.

[0084] Table 3

[0085]

[0086] Furthermore, based on the calculated register information record value of each expansion device, the accurate expansion device is determined by searching whether it is at the near end or the far end of the integrated circuit device according to the expansion device protocol (such as PCIE protocol).

[0087] For example, the integrated circuit device is a retimer connected to the expansion devices PCIE A and PCIE B respectively, such as Figure 3 As shown, the proximal device of PCIE A is itself, namely PCIE A RX (Receive, device that receives data), and the remote device of PCIE A is PCIE B; the proximal device of PCIE B is itself, namely PCIE B RX, and the remote device of PCIE B is PCIE A. The register information record value of PCIE A is 101. The result obtained by querying Table 4 is that the remote-end: PCIE B to Retimer fault is located on PCIE B; the register information record value of PCIE B is 111. The result obtained by querying Table 4 is that the proximal-end: Retimer to PCIE B fault is located on PCIE B. Therefore, it can be determined that the query results are all PCIE B faults.

[0088] Therefore, if Figure 3 As shown in Table 4, based on the above register information record values ​​(expansion device "0000:07:00.0" is 101, expansion device "0000:08:00.0" is 111), it is determined that the faulty expansion device is "0000:08:00.0".

[0089] Table 4

[0090]

[0091] In the above scheme, according to the register information record value of each candidate expansion device and the pre-set expansion device protocol table query, the faulty device can be quickly and accurately located, thereby saving maintenance personnel time in troubleshooting and facilitating maintenance personnel to accurately replace abnormal devices.

[0092] Based on the description of the above embodiment, when an abnormality occurs in the expansion devices connected to the two ends of the integrated circuit device, the faulty expansion devices at both ends of the integrated circuit device can be quickly and accurately located; thereby saving maintenance personnel time in troubleshooting the problem and facilitating maintenance personnel to accurately replace the abnormal device.

[0093] Specifically, the to-be-stored function identifiers corresponding to all expansion devices in the server are obtained, the to-be-stored register address corresponding to each to-be-stored function identifier is obtained, and the to-be-stored function identifiers and the to-be-stored register addresses are associated and stored in a preset file.

[0094] In an embodiment of the present application, obtaining the register address to be stored corresponding to each function identifier to be stored includes: generating a register address query instruction including the function identifier to be stored and executing it to obtain the register address to be adjusted; performing address offset processing on the register address to be adjusted based on a preset extended device protocol to obtain the register address to be stored.

[0095] Furthermore, in response to the detection instruction, the function identifier and register address information of each extension device are obtained from the preset file, a bandwidth rate query command including the function identifier is generated and executed, and the current bandwidth and current rate of each extension device are obtained as bandwidth rate information; it is determined whether the current bandwidth is within the preset bandwidth range and whether the current rate is within the preset rate range to determine whether each extension device meets the preset fault location condition.

[0096] Thus, if the current bandwidth of any target expansion device in each expansion device is not within the preset bandwidth range and / or the current rate is not within the preset rate range, it is determined that the target expansion device meets the preset fault location condition; when the current bandwidth is within the preset bandwidth range and the current rate is within the preset rate range, each register of each expansion device is polled based on the register address information of each expansion device to obtain the register return value; when the register return value of any target expansion device in each expansion device includes a non-zero value, it is determined that the target expansion device meets the preset fault location condition; when the register return values ​​of all expansion devices are all 0, it is determined that each expansion device does not meet the preset fault location condition.

[0097] Thus, a target expansion device and an expansion device connected to the other end of the integrated circuit device connected to the target expansion device are taken as a candidate expansion device pair, and the register address of each register corresponding to each candidate expansion device in the candidate expansion device pair is obtained based on the register address information; each register is polled based on the register address to obtain the return value of each register corresponding to each candidate expansion device; a record value of each register is set based on whether the return value of each register includes a non-zero value, and the record value of each register is arranged in a preset arrangement order to obtain a register information record value.

[0098] In an embodiment of the present application, a candidate expansion device pair includes: a first candidate expansion device and a second candidate expansion device; the first candidate expansion device corresponds to a plurality of first registers, and the second candidate expansion device corresponds to a plurality of second registers; setting a record value of each register based on whether a return value of each register includes a non-zero value, and arranging the record value of each register according to a preset arrangement order to obtain a register information record value, including: setting a record value of each first register based on whether the return value of each first register includes a non-zero value, and arranging the record value of each first register according to a preset arrangement order, to obtain a first record value of the first candidate expansion device as the register information record value; setting a record value of each second register based on whether the return value of each second register includes a non-zero value, and arranging the record value of each second register according to a preset arrangement order, to obtain a second record value of the second candidate expansion device as the register information record value.

[0099] In an embodiment of the present application, the record value of each register is set based on whether the return value of each register includes a non-zero value, including: when the return value of the register includes a non-zero value, setting the record value of the register to 1; or, when the return value of the register is all 0, setting the record value of the register to 0.

[0100] Finally, the register information record value includes a first record value corresponding to the first candidate expansion device and a second record value corresponding to the second candidate expansion device. Based on the first record value, the expansion device protocol table is queried to obtain the proximal device or the distal device of the first candidate expansion device as the first candidate fault device; based on the second record value, the expansion device protocol table is queried to obtain the proximal device or the distal device of the second candidate expansion device as the second candidate fault device; and the fault device is determined based on the first candidate fault device and the second candidate fault device.

[0101] For example, take the case where the integrated circuit device is a Retimer card with PCIE devices connected at both ends. Figure 4As shown, it includes step 4.1 configuring the BDF information of the PCIE devices at both ends of the Retimer card as a functional identifier, that is, using "lspci-vt" to query all PCIE device association information in the current server, and finding the BDF information of the upstream and downstream Retimer cards and saving it to a preset file such as the "bdfinfo" file; step 4.2 finding the register address corresponding to each BDF information, that is, according to the content in the "bdfinfo" file, querying the physical layer register position corresponding to each BDF, and obtaining the register address according to the PCIE protocol is the offset address relative to the physical layer address, so that the register address that the BDF needs to monitor is stored in the "bdfinfo" file; step 4.3 polling each PCIE device Bandwidth rate; Step 4.4 determines whether the bandwidth rate is abnormal; that is, use the "lspci" command to check whether the bandwidth rate in the BDF information to be checked meets the standard. When the rate is consistent with the benchmark rate and the bandwidth is consistent with the benchmark bandwidth, the PCIE device is considered normal, otherwise, the PCIE device is considered abnormal; if it is abnormal, execute step 4.5 to find the PCIE abnormal device information according to the PICE protocol; if it is normal, execute step 4.6 to query the PCIE device parity bit register information; step 4.7 determines whether the register information is abnormal; if it is abnormal, execute step 4.5; if it is normal, execute step 4.3; Therefore, when the register is abnormal, it indicates that the PCIE has a potential connection risk, and it is necessary to accurately locate the abnormal PCIE device through step 4.5.

[0102] This allows for stricter verification of whether the PCIE device connections at both ends of the Retimer card are robust and reliable. When an obvious or potential risk is detected in the device connection, the specific PCIE device information at both ends of the Retimer can be accurately located, making it easier for maintenance personnel or operation and maintenance personnel to perform replacements. This avoids cross-verification steps, saves verification time, and improves maintenance efficiency.

[0103] In the above example, the retimer card connectivity diagnosis not only uses bandwidth and rate queries but also checks the status of three registers on the PCIE physical layer: the "Local Data Parity Mismatch Status Register," the "First Retimer Data Parity Mismatch Status Register," and the "Second Retimer Data Parity Mismatch Status Register." If a PCIE connection anomaly is detected between the two ends of the retimer, the faulty PCIE device can be accurately located based on the PCIE device register status. This allows maintenance personnel to promptly address or replace the PCIE device, saving them time-consuming verification. This method can be applied to situations where a faulty PCIE component must be accurately located, saving maintenance personnel time.

[0104] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus the necessary general hardware platform, and of course it can also be implemented by hardware, but in many cases the former is a better implementation method.

[0105] Figure 5 This is a schematic diagram of the structure of a faulty device locating device provided in an embodiment of the present application. The device can be implemented by software and / or hardware and can generally be integrated into an electronic device. Figure 5 As shown, the device is applied to a server, the server includes at least one integrated circuit device, one end of the integrated circuit device is connected to an expansion device, and the other end of the integrated circuit device is connected to another expansion device, and the device includes:

[0106] The first acquisition module 501 is configured to acquire the function identifier and register address information of each extended device from a preset file in response to a detection instruction.

[0107] The second acquisition module 502 is configured to acquire bandwidth rate information of each extension device based on the function identifier.

[0108] The judgment module 503 is configured to judge whether each extension device meets a preset fault location condition based on the bandwidth rate information and / or the register address information.

[0109] The third acquisition module 504 is configured to, when any target expansion device in each expansion device meets a preset fault location condition, use the target expansion device and the expansion device connected to the other end of the integrated circuit device connected to the target expansion device as a candidate expansion device pair.

[0110] The fourth acquisition module 505 is configured to acquire a register information record value based on the register address information of the candidate extension device pair.

[0111] The determination module 506 is configured to determine a faulty device from the candidate expansion device pairs based on the register information record value and a preset expansion device protocol table.

[0112] Optionally, the device of the present application also includes: a fifth acquisition module, used to obtain the function identifiers to be stored corresponding to all expansion devices in the server; a sixth acquisition module, used to obtain the register address to be stored corresponding to each function identifier to be stored; and a storage module, used to associate the function identifiers to be stored and the register addresses to be stored and store them in a preset file.

[0113] Optionally, the sixth acquisition module is used to: generate and execute a register address query instruction including a function identifier to be stored to obtain the register address to be adjusted; and perform address offset processing on the register address to be adjusted based on a preset extended device protocol to obtain the register address to be stored.

[0114] Optionally, the second acquisition module 502 is specifically configured to generate and execute a bandwidth rate query command including a function identifier, and acquire the current bandwidth and current rate of each extension device as bandwidth rate information.

[0115] Optionally, the judgment module 503 is specifically configured to: judge whether the current bandwidth is within a preset bandwidth range and whether the current rate is within a preset rate range to judge whether each extension device meets a preset fault location condition.

[0116] Optionally, the judgment module 503 is further configured to: determine that the target expansion device meets the preset fault location condition if the current bandwidth and / or the current rate of any target expansion device in each expansion device is not within the preset bandwidth range and / or the current rate is not within the preset rate range.

[0117] Optionally, the judgment module 503 is also specifically used to poll each register of each expansion device based on the register address information of each expansion device when the current bandwidth is within the preset bandwidth range and the current rate is within the preset rate range, and obtain the register return value. When the register return value of any target expansion device in each expansion device includes a non-zero value, it is determined that the target expansion device meets the preset fault location condition.

[0118] Optionally, the judgment module 503 is further configured to determine that each expansion device does not meet a preset fault location condition when all register return values ​​of all expansion devices are 0.

[0119] Optionally, the fourth acquisition module 505 is specifically used to: obtain the register address of each register corresponding to each candidate expansion device in the candidate expansion device pair based on the register address information; poll each register based on the register address to obtain the return value of each register corresponding to each candidate expansion device; set the record value of each register based on whether the return value of each register includes a non-zero value, and arrange the record value of each register in a preset arrangement order to obtain the register information record value.

[0120] Optionally, the fourth acquisition module 505 is specifically configured to: wherein the candidate expansion device pair includes: a first candidate expansion device and a second candidate expansion device; the first candidate expansion device corresponds to a plurality of first registers, and the second candidate expansion device corresponds to a plurality of second registers; set a record value for each register based on whether the return value of each register includes a non-zero value, and arrange the record values ​​of each register in a preset arrangement order to obtain register information record values, including:

[0121] Optionally, the fourth acquisition module 505 is specifically used to: set the record value of each first register based on whether the return value of each first register includes a non-zero value, and arrange the record value of each first register according to a preset arrangement order, to obtain the first record value of the first candidate expansion device as the register information record value; set the record value of each second register based on whether the return value of each second register includes a non-zero value, and arrange the record value of each second register according to a preset arrangement order, to obtain the second record value of the second candidate expansion device as the register information record value.

[0122] Optionally, the fourth acquisition module 505 is specifically configured to: when the return value of the register includes a non-zero value, set the record value of the register to 1; or, when the return value of the register is all 0, set the record value of the register to 0.

[0123] Optionally, the register information record value includes a first record value corresponding to the first candidate expansion device and a second record value corresponding to the second candidate expansion device. The determination module 506 is specifically used to: query the expansion device protocol table based on the first record value to obtain the proximal device or the distal device of the first candidate expansion device as the first candidate fault device; query the expansion device protocol table based on the second record value to obtain the proximal device or the distal device of the second candidate expansion device as the second candidate fault device; and determine the fault device based on the first candidate fault device and the second candidate fault device.

[0124] For the description of the features in the embodiment corresponding to the faulty device locating apparatus provided in the embodiments of the present application, reference can be made to the relevant description of the embodiment corresponding to the faulty device locating method, which will not be repeated here.

[0125] An embodiment of the present application further provides an electronic device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the steps in any of the above-mentioned embodiments of the method for locating a faulty device.

[0126] An embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored. The computer program is configured to execute the steps of any of the above-mentioned embodiments of the method for locating a faulty device when running.

[0127] In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to, various media that can store computer programs, such as a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk, or an optical disk.

[0128] An embodiment of the present application further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps in any of the above-mentioned embodiments of the method for locating a faulty device are implemented.

[0129] An embodiment of the present application further provides another computer program product, including a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of any of the above-mentioned embodiments of the method for locating a faulty device are implemented.

[0130] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the above description has generally described the components and steps of each example according to their functions. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0131] The above is a detailed introduction to a method for locating a faulty device, a computer device, a storage medium, and a product provided by the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method and core idea of ​​the present application. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the claims of the present application.

Claims

1. A method for locating a faulty device, characterized in that: The method is applied to a server, the server including at least one integrated circuit device, one end of the integrated circuit device being connected to an expansion device, and the other end of the integrated circuit device being connected to another expansion device, the method comprising: In response to the detection instruction, obtaining the function identifier and register address information of each of the extension devices from a preset file; Acquire bandwidth rate information of each of the extension devices based on the function identifier, and determine whether each of the extension devices meets a preset fault location condition based on the bandwidth rate information and / or the register address information; When any target expansion device in each of the expansion devices meets a preset fault locating condition, the target expansion device and the expansion device connected to the other end of the integrated circuit device connected to the target expansion device are used as a candidate expansion device pair, and register information record values ​​are obtained based on register address information of the candidate expansion device pair; A faulty device is determined from the candidate expansion device pairs based on the register information record value and a preset expansion device protocol table.

2. The method for locating a faulty device according to claim 1, wherein: Before responding to the detection instruction, the method further includes: Obtaining the to-be-stored function identifiers corresponding to all the extended devices in the server; Obtaining a register address to be stored corresponding to each of the function identifiers to be stored; The function identifier to be stored and the register address to be stored are associated and stored in the preset file.

3. The method for locating a faulty device according to claim 2, wherein: The acquiring the to-be-stored register address corresponding to each to-be-stored function identifier includes: Generate a register address query instruction including the function identifier to be stored and execute it to obtain the register address to be adjusted; An address offset process is performed on the register address to be adjusted based on a preset extended device protocol to obtain the register address to be stored.

4. The method for locating a faulty device according to claim 1, wherein: The acquiring the bandwidth rate information of each of the extension devices based on the function identifier includes: A bandwidth rate query command including the function identifier is generated and executed, and the current bandwidth and current rate of each extension device are obtained as the bandwidth rate information.

5. The method for locating a faulty device according to claim 4, wherein: The determining, based on the bandwidth rate information, whether each of the extension devices meets a preset fault location condition includes: It is determined whether the current bandwidth is within a preset bandwidth range and whether the current rate is within a preset rate range to determine whether each of the extension devices meets a preset fault location condition.

6. The method for locating a faulty device according to claim 5, characterized in that: Any target expansion device in each of the expansion devices meets the preset fault location condition, including: If the current bandwidth of any target expansion device in each of the expansion devices is not within the preset bandwidth range and / or the current rate is not within the preset rate range, it is determined that the target expansion device meets the preset fault locating condition.

7. The method for locating a faulty device according to claim 6, wherein: The method further comprises: When the current bandwidth is within the preset bandwidth range and the current rate is within the preset rate range, polling each register of each extension device based on the register address information of each extension device to obtain a register return value; When the register return value of any target expansion device in each of the expansion devices includes a non-zero value, it is determined that the target expansion device meets the preset fault locating condition.

8. The method for locating a faulty device according to claim 7, wherein: The method further comprises: When the register return values ​​of all the expansion devices are 0, it is determined that each of the expansion devices does not meet the preset fault locating condition.

9. The method for locating a faulty device according to claim 1, wherein: The acquiring of the register information record value based on the register address information of the candidate expansion device pair includes: acquiring a register address of each register corresponding to each candidate expansion device in the candidate expansion device pair based on the register address information; Polling each register based on the register address to obtain a return value of each register corresponding to each candidate expansion device; The record value of each register is set based on whether the return value of each register includes a non-zero value, and the record value of each register is arranged according to a preset arrangement order to obtain the register information record value.

10. The method for locating a faulty device according to claim 9, wherein: The candidate expansion device pair includes: a first candidate expansion device and a second candidate expansion device; the first candidate expansion device corresponds to a plurality of first registers, and the second candidate expansion device corresponds to a plurality of second registers; setting a record value of each register based on whether the return value of each register includes a non-zero value, and arranging the record value of each register in a preset arrangement order to obtain the register information record value, includes: setting a record value of each first register based on whether the return value of each first register includes the non-zero value, and arranging the record values ​​of each first register according to the preset arrangement order to obtain a first record value of the first candidate expansion device as the register information record value; The record value of each second register is set based on whether the return value of each second register includes the non-zero value, and the record value of each second register is arranged according to a preset arrangement order to obtain the second record value of the second candidate expansion device as the register information record value.

11. The method for locating a faulty device according to claim 9, wherein: The step of setting the record value of each register based on whether the return value of each register includes the non-zero value includes: When the return value of the register includes a non-zero value, setting the record value of the register to 1; or, When the return values ​​of the registers are all 0, the record value of the register is set to 0.

12. The method for locating a faulty device according to claim 1, wherein: The register information record value includes a first record value corresponding to the first candidate expansion device and a second record value corresponding to the second candidate expansion device, and determining the faulty device from the candidate expansion device pair based on the register information record value and a preset expansion device protocol table includes: Based on the first record value, query the extension device protocol table to obtain the proximal device or the distal device of the first candidate extension device as the first candidate faulty device; Based on the second record value, query the extension device protocol table to obtain the proximal device or the distal device of the second candidate extension device as the second candidate fault device; The faulty device is determined based on the first faulty device candidate and the second faulty device candidate.

13. A computer device, characterized in that: include: memory for storing computer programs; A processor is configured to implement the steps of the faulty equipment locating method according to any one of claims 1 to 12 when executing the computer program.

14. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, wherein when the computer program is executed by a processor, the steps of the faulty equipment locating method according to any one of claims 1 to 12 are implemented.

15. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the faulty equipment locating method according to any one of claims 1 to 12 are implemented.

Citation Information

Patent Citations

  • Method and device for detecting PCIE hardware faults

    CN103440188A

  • Fault processing method and device for high-speed extension link

    CN119690756A