Misinsertion detection method for external device, and computing device

By introducing controllers and adapter connectors into the computing device, determining the connection relationship of the dock and outputting alarm information, the server error problem caused by cable connection errors between the Switch chip and the dock is solved, ensuring the normal use of hardware resources.

WO2025102717A1PCT designated stage expired Publication Date: 2025-05-22XFUSION DIGITAL TECH CO LTD

Patent Information

Application Number
PCT/CN2024/099306
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-11-15
Filing Date
2024-06-14
Publication Date
2025-05-22

AI Technical Summary

Technical Problem

When increasing the server hardware resources, the cable connection between the Switch chip and the docking station is incorrect, causing the server system to report an error and the hardware resources to be expanded cannot be used normally.

Method used

A computing device is designed including a controller, a plurality of adapter connectors and at least two docking stations. The controller obtains the identification of the extension connector through the adapter connector, determines the current connection relationship, and outputs alarm information when the connection relationship is different from the preset relationship to ensure the correct connection of the dock.

Benefits of technology

By correctly detecting and correcting the connection relationship of the dock, ensuring that the server can use the hardware resources to be expanded normally, solving the problem of errors reported by the server system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024099306_22052025_PF_FP_ABST
    Figure CN2024099306_22052025_PF_FP_ABST
Patent Text Reader

Abstract

A misinsertion detection method for an external device, and a computing device, relating to the technical field of servers, for use in ensuring the correct connection between a docking station and a computing device, so that the computing device can normally use a hardware device to be expanded that is inserted on the docking station. The computing device comprises a controller, a plurality of adapter connectors, and at least two docking stations; each docking station comprises at least two expansion connectors; one of the plurality of adapter connectors is connected to one expansion connector; the plurality of adapter connectors are separately connected to the controller; and the controller is configured to: determine a current connection relationship of each docking station, the connection relationship comprising a connection relationship between each expansion connector of the docking station and the corresponding adapter connector; and output alarm information when the current connection relationship of the docking station is different from a preset connection relationship of the docking station, the alarm information being used for indicating that the current connection relationship of the docking station is incorrect.
Need to check novelty before this filing date? Find Prior Art

Description

Method for detecting misinsertion of external device and computing device

[0001] This application claims priority to the Chinese patent application filed with the State Intellectual Property Office of China on November 15, 2023, with application number 202311525586.9 and application name “A method for detecting misinsertion of an external device and a computing device”, the entire contents of which are incorporated by reference into this application. Technical Field

[0002] The embodiments of the present application relate to the field of server technology, and in particular to a method for detecting misinsertion of an external device and a computing device. Background Art

[0003] With the rapid development of the Internet industry, the complexity of Internet business needs is also increasing. In order to meet these complex business needs, it is necessary to increase the hardware resources in the server.

[0004] Common ways to increase hardware resources in a server include: connecting a switch chip in the server to an expansion dock via a cable, and then inserting the hardware resources to be expanded into the slots provided by the expansion dock, thereby increasing the total amount of hardware resources to be expanded in the server.

[0005] However, when the cable connection between the Switch chip and the expansion dock is incorrect, the server system will report an error, thereby preventing the server from normally using the hardware resources to be expanded.

[0006] Summary of the Invention

[0007] The embodiments of the present application provide a method for detecting mis-insertion of an external device and a computing device, for ensuring the correct connection between an expansion dock and a computing device, so that the computing device can normally use the hardware device to be expanded installed on the expansion dock.

[0008] To achieve the above objectives, the embodiments of the present application adopt the following technical solutions:

[0009] In a first aspect, an embodiment of the present application provides a computing device, which includes: a controller, multiple adapter connectors and at least two expansion docks, each expansion dock including at least two expansion connectors; one adapter connector among the multiple adapter connectors is connected to an expansion connector; the multiple adapter connectors are respectively connected to the above-mentioned controller; the controller is used to determine the current connection relationship of the expansion dock, and the connection relationship includes: the connection relationship between each expansion connector of the expansion dock and the adapter connector; and, when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, output an alarm message, and the alarm message is used to indicate that the current connection relationship of the expansion dock is wrong.

[0010] An embodiment of the present application provides a computing device, wherein an adapter connector in the computing device is connected to an expansion connector in an expansion dock, and the multiple adapter connectors are respectively connected to a controller in the computing device; the controller is used to determine the current connection relationship of the expansion dock, and the connection relationship includes: the connection relationship between each expansion connector of the expansion dock and the adapter connector; the controller is also used to output an alarm message indicating that the current connection relationship of the expansion dock is incorrect when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock. It can be seen that the above-mentioned controller will compare the current connection relationship of the expansion dock with the preset connection relationship of the expansion dock and determine the correctness of the current connection relationship of the expansion dock; when the current connection relationship of the expansion dock is incorrect, the controller outputs an alarm message so that the user can promptly know that the current connection relationship of the expansion dock is incorrect and correct the incorrect connection relationship, thereby ensuring the correct connection of the expansion dock, thereby solving the problem that the server cannot normally use the hardware resources to be expanded.

[0011] In one possible implementation, the controller is used to determine the current connection relationship of the expansion dock, including: the controller is used to obtain the identifier of the expansion connector connected to the adapter connector through each adapter connector; the controller is used to determine the current connection relationship of the expansion dock based on the obtained identifiers of multiple expansion connectors.

[0012] In one possible implementation, the identifier of the expansion connector includes: a first position identifier and a second position identifier; the expansion connector includes: a first pin and a second pin; the first pin is configured with a first position identifier, the first position identifier is used to indicate position information of the expansion connector on a target expansion dock, and the target expansion dock is the expansion dock where the expansion connector is located; the second pin is configured with a second position identifier, the second position identifier is used to indicate position information of the target expansion dock in at least two expansion docks.

[0013] By using the first position identifier and the second position identifier of the expansion connector as the identifier of the expansion connector, the controller can determine the target expansion dock where the expansion connector is located and the position information of the expansion connector within the target expansion dock based on the identifier of the expansion connector. In other words, based on the identifier of the expansion connector, the controller can not only determine the target expansion dock to which the adapter connector is connected, but also determine which specific expansion connector within the target expansion dock the adapter connector is connected to. This improves the accuracy of the controller in determining the expansion connector.

[0014] In a possible implementation, the identifier of the expansion connector further includes: a type identifier of the target expansion dock; the expansion connector further includes: a third pin; the third pin is configured with the type identifier of the target expansion dock.

[0015] In the above embodiment, a first pin, a second pin, and a third pin are provided on each expansion connector, and a first position identifier of the expansion connector is configured on the first pin, the first position identifier being used to indicate the position information of the expansion connector in the expansion dock (i.e., the target expansion dock) in which it is located; a second position identifier of the expansion connector is configured on the second pin, the second position identifier being used to indicate the position information of the target expansion dock in at least two expansion docks in the computing device; and a type identifier of the target expansion dock is configured on the third pin, and the first position identifier, the second position identifier, and the type identifier of the target expansion dock are used as identifiers of the expansion connector. On this basis, the controller obtains the identifier of the expansion connector connected to it through each adapter connector, and determines the current connection relationship of the expansion dock based on the identifiers of the multiple expansion connectors; if the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, the controller outputs an alarm message, thereby ensuring that the type of the connected expansion dock is correct while ensuring that the expansion dock cable is correctly connected, thereby solving the problem of the server being unable to normally use the hardware resource to be expanded.

[0016] In one possible implementation, the computing device further includes a plurality of processors, and any one of the plurality of processors is connected to at least two adapter connectors among the plurality of adapter connectors; the processor sends communication resources to the expansion dock connected to the processor through the adapter connector connected to the processor.

[0017] In one possible implementation, the computing device includes a mainboard and an adapter board, and the adapter connector is provided on the adapter board;

[0018] The controller includes a programmable logic device and a baseboard management controller. The programmable logic device is arranged on the adapter board, and the baseboard management controller is arranged on the main board. The baseboard management controller is connected to a plurality of adapter connectors through the programmable logic device.

[0019] The programmable logic device is used to determine the current connection relationship of the expansion dock; the baseboard management controller is used to output an alarm message when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock.

[0020] In a possible implementation, the controller further includes a storage unit connected to the baseboard management controller, wherein the storage unit stores a preset connection relationship of the expansion dock.

[0021] The controller in the above embodiment, in addition to including a programmable logic device (CPLD) and a baseboard management controller (BMC), also includes a storage unit connected to the BMC. The storage unit is used to store the preset connection relationship of the expansion dock. Therefore, before the BMC determines whether the preset connection relationship of the expansion dock is the same as the current connection relationship of the expansion dock, the BMC can obtain the preset connection relationship of the expansion dock from the storage unit. Compared with the solution in which the preset connection relationship of the expansion dock is stored in the BMC, this saves storage space of the BMC.

[0022] In a possible implementation, the types of the above-mentioned docking station include at least: a first type and a second type, the first type of docking station is a docking station for providing a slot for a hard disk, and the second type of docking station is a docking station for providing a slot for a network card.

[0023] In a second aspect, an embodiment of the present application provides a method for detecting misinsertion of an external device, which is applied to a computing device, comprising: a controller, multiple adapter connectors, and at least two expansion docks, each expansion dock comprising at least two expansion connectors; one of the multiple adapter connectors is connected to an expansion connector, and the multiple adapter connectors are respectively connected to the controller; the method comprises: the controller determining a current connection relationship of the above-mentioned expansion dock, the connection relationship comprising: a connection relationship between each expansion connector in the expansion dock and the adapter connector; when the current connection relationship of the expansion dock is different from a preset connection relationship of the expansion dock, the controller outputs an alarm message, which is used to indicate that the current connection relationship of the expansion dock is wrong.

[0024] In an embodiment of the present application, a method for detecting mis-insertion of an external device is provided. In this method, a controller obtains the current connection relationship of the expansion dock, where the connection relationship includes: the connection relationship between the expansion connector and the adapter connector on the expansion dock; then, when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, the controller outputs an alarm message indicating that the current connection relationship of the expansion dock is incorrect, so that the user can be informed of the current connection relationship error of the expansion dock in a timely manner and correct the incorrect connection relationship, thereby ensuring the correct connection of the expansion dock, thereby solving the problem that the server cannot normally use the hardware resources to be expanded.

[0025] In one possible implementation, the controller determines the current connection relationship of the expansion dock, specifically including: the controller obtains the identifier of the expansion connector connected to each adapter connector through each adapter connector; the controller determines the current connection relationship of the expansion dock based on the obtained identifiers of multiple expansion connectors.

[0026] In one possible implementation, the identifier of the expansion connector includes: a first position identifier and a second position identifier of the expansion connector, the first position identifier being used to indicate position information of the expansion connector on a target expansion dock, and the second position identifier being used to indicate position information of the target expansion dock in the at least two expansion docks, where the target expansion dock is the expansion dock where the expansion connector is located.

[0027] The controller uses the first position identifier and the second position identifier of the expansion connector as the identifier of the expansion connector, allowing the controller to determine the target expansion dock where the expansion connector is located and the position information of the expansion connector within the target expansion dock based on the identifier of the expansion connector. In other words, based on the identifier of the expansion connector, the controller can not only determine the target expansion dock to which the target adapter connector (i.e., the adapter connector connected to the expansion connector) is connected, but can also determine which specific expansion connector in the target expansion dock the target adapter connector is connected to. This improves the accuracy of the controller in determining the expansion connector.

[0028] In a possible implementation, the identifier of the expansion connector further includes: a type identifier of the target expansion dock.

[0029] In the above embodiment, the first position identifier, the second position identifier, and the type identifier of the target expansion dock are used as the identifier of the expansion connector, so that the controller can determine the type of the target expansion dock based on determining the position of the expansion connector. Therefore, based on the identifier of the expansion connector, the controller can not only determine the specific position of the expansion connector but also determine the type of the target expansion dock where the expansion connector is located, thereby improving the accuracy of the controller in determining the expansion connector.

[0030] In one possible implementation, the controller includes a programmable logic device and a baseboard management controller; the method specifically includes: the programmable logic device determines the current connection relationship of the expansion dock and sends the current connection relationship of the expansion dock to the baseboard management controller; the baseboard management controller receives the current connection relationship of the expansion dock and outputs an alarm message when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock.

[0031] In the above embodiment, the BMC receives the current docking station connection relationship from the CPLD and determines whether the current docking station connection relationship is the same as the preset docking station connection relationship. If the current docking station connection relationship is different from the preset docking station connection relationship, the BMC outputs an alarm message. As can be seen, the CPLD is only used to obtain the current docking station connection relationship, while the BMC performs the actions of determining whether the current docking station connection relationship is the same as the preset docking station connection relationship and outputting the alarm message. This reduces the utilization of processing resources in the CLPD.

[0032] In one possible implementation, the controller includes a programmable logic device and a baseboard management controller; the method specifically includes: the programmable logic device determines the current connection relationship of the expansion dock; when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, sending alarm indication information to the baseboard management controller; the baseboard management controller outputs the alarm information in response to the alarm indication information.

[0033] In the above embodiment, the CPLD obtains the current connection relationship of the docking station and determines whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station. If the current connection relationship of the docking station is different from the preset connection relationship of the docking station, the CPLD sends an alarm indication to the BMC, and the BMC outputs an alarm message in response to the alarm indication. It can be seen that the above BMC is only used to output the alarm message and does not need to determine whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station. Therefore, the utilization rate of processing resources in the BMC is reduced.

[0034] In a possible implementation, the controller further includes a storage unit storing a preset connection relationship of the expansion dock; and the method further includes: the baseboard management controller obtaining the preset connection relationship of the expansion dock from the storage unit.

[0035] In a third aspect, an embodiment of the present application provides a controller comprising: a determination unit and an output unit, wherein the determination unit is used to determine the current connection relationship of the expansion dock, the connection relationship including: the connection relationship between each expansion connector and the adapter connector in the expansion dock; the output unit is used to output an alarm message when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, and the alarm message is used to indicate that the current connection relationship of the expansion dock is wrong.

[0036] In one possible implementation, the controller further includes: an acquisition unit; the acquisition unit is used to acquire the identification of the expansion connector connected to the adapter connector through each adapter connector; and the determination unit is specifically used to determine the current connection relationship of the expansion dock based on the acquired identifications of the multiple expansion connectors.

[0037] In one possible implementation, the controller includes: a first processing unit and a second processing unit; the first processing unit is used to determine the current connection relationship of the expansion dock and send the current connection relationship of the expansion dock to the second processing unit; the second processing unit is used to receive the current connection relationship of the expansion dock and output an alarm message when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock.

[0038] In one possible implementation, the first processing unit is used to determine the current connection relationship of the expansion dock; when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, an alarm indication information is sent to the second processing unit; and the second processing unit is used to output an alarm information in response to the alarm indication information.

[0039] In a possible implementation, the acquiring unit is specifically configured to acquire the preset connection relationship of the expansion dock from the storage unit.

[0040] In a fourth aspect, an embodiment of the present application provides a computing device cluster, which includes the computing device of any one of the first aspect and its possible implementations. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] FIG1 is a schematic diagram of a computing device according to an embodiment of the present application;

[0042] FIG2 is a second schematic diagram of a computing device provided in an embodiment of the present application;

[0043] FIG3 is a third schematic diagram of a computing device provided in an embodiment of the present application;

[0044] FIG4 is a fourth schematic diagram of a computing device provided in an embodiment of the present application;

[0045] FIG5 is a flowchart of a method for detecting mis-insertion of an external device according to an embodiment of the present application;

[0046] FIG6 is a second flow chart of a method for detecting mis-insertion of an external device provided in an embodiment of the present application;

[0047] FIG7 is a third flow chart of a method for detecting mis-insertion of an external device provided in an embodiment of the present application;

[0048] FIG8 is a fourth flow chart of a method for detecting mis-insertion of an external device provided in an embodiment of the present application;

[0049] FIG9 is a schematic diagram of the structure of a controller provided in an embodiment of the present application. DETAILED DESCRIPTION

[0050] The term "and / or" in this article is merely a description of the association relationship between associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone.

[0051] In the description and claims of the embodiments of this application, the terms "first" and "second" are used to distinguish different objects rather than to describe a specific order of objects. For example, "first position pin" and "second position pin" are used to distinguish different position pins rather than to describe a specific order of the position pins.

[0052] In the embodiments of this application, words such as "exemplary" or "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of this application should not be interpreted as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "for example" is intended to present the relevant concepts in a concrete manner.

[0053] In the description of the embodiments of this application, unless otherwise specified, "multiple" means two or more. For example, "multiple processors" means two or more processors; "multiple adapters" means two or more adapters.

[0054] First, some concepts involved in a method for detecting misinsertion of an external device and a computing device provided in an embodiment of the present application are explained as follows:

[0055] Pins: Also called pins, they are the connections that lead from the internal circuitry of an integrated circuit (chip) to the peripheral circuitry. All pins constitute the interface of the chip. The end of the lead is soldered to the pad on the printed circuit board to form a solder joint.

[0056] Single-host: Also called single-host, it indicates a scenario where a device (such as a network card) is connected to a single processor or device at the same time.

[0057] Multi-host: Also called multi-host, it is used to indicate a scenario where a device (such as a network card) is connected to multiple processors or devices at the same time.

[0058] Based on the above background technology, an embodiment of the present application provides a computing device, wherein a controller in the computing device is connected to multiple adapter connectors in the computing device; the adapter connector is connected to an expansion connector in an expansion dock. The controller is configured to determine the current connection relationship of the expansion dock, wherein the connection relationship includes: the connection relationship between each expansion connector in the expansion dock and the adapter connector; and, if the current connection relationship of the expansion dock differs from the preset connection relationship of the expansion dock, output an alarm indicating that the current connection relationship of the expansion dock is incorrect. This allows the user to promptly be notified of the current connection relationship error of the expansion dock and correct the incorrect connection relationship, thereby ensuring the correct connection of the cable between the expansion dock and the adapter connector, thereby resolving the issue of the server being unable to properly use the hardware resources to be expanded.

[0059] An embodiment of the present application provides a computing device, comprising: a controller, a plurality of adapter connectors, and at least two expansion docks, each of which includes at least two expansion connectors. For example, the computing device comprises: one controller, four adapter connectors, and two expansion docks, each of which includes two expansion connectors. For ease of description, the embodiment of the present application is described using an example in which the number of controllers in the computing device is one, the number of adapter connectors is four, the number of expansion docks is two, and the number of expansion connectors in each expansion dock is two. In this case, the computing device is shown in FIG1 .

[0060] The four adapter connectors are respectively connected to a controller, namely, adapter connector_1, adapter connector_2, adapter connector_3, and adapter connector_4 are respectively connected to the controller; wherein the controller can be at least one of a baseboard management controller (BMC), a complex programmable logic device (CPLD), an FPGA, a DSP, and other devices with processing capabilities.

[0061] One of the four adapter connectors is connected to one of the expansion connectors in the two expansion docks (e.g., adapter connector_1 is connected to expansion connector_1, adapter connector_2 is connected to expansion connector_2, adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4).

[0062] It should be noted that the connection between any two devices in the computing device in the embodiment of the present application is an electrical connection (ie, a cable connection), which will not be described in detail later.

[0063] The aforementioned expansion dock is a device that provides a slot for the computing device to be expanded. It can be understood as a circuit board with connection slots. For example, if the expansion device is a network card, the expansion dock is a riser card that provides a network card slot; if the expansion device is a hard drive, the expansion dock is a hard drive backplane that provides a hard drive slot.

[0064] It should be understood that only one type of device to be expanded can be plugged into an expansion dock, and different types of devices to be expanded correspond to different expansion docks. For example, the expansion dock corresponding to the OCP (open compute project) network card is different from the expansion dock corresponding to the DPU (data processing unit) network card, and the expansion dock corresponding to the solid-state drive is different from the expansion dock corresponding to the mechanical hard drive.

[0065] It should be noted that the types of the above-mentioned adapter connector and the expansion connector are the same, such as: when the adapter connector is a unified bus connector (UBC) connector, the expansion connector is also a UBC connector; when the adapter connector is a slimline_x8 connector, the expansion connector is also a slimline_x8 connector. The embodiment of this application is explained by taking the adapter connector and the expansion connector as UBC connectors as an example, and will not be repeated later.

[0066] The controller is configured to determine the current connection relationship between the docking stations (i.e., docking station_1 and docking station_2). The current connection relationship between the docking stations includes the connection relationship between each expansion connector and the adapter connector in the docking station. In other words, the current connection relationship between the docking stations indicates which adapter connectors the expansion connectors in the docking station are actually connected to. For example, as shown in FIG1 , the current connection relationship between docking station_1 includes the connection between expansion connector_1 and adapter connector_1, and the connection between expansion connector_2 and adapter connector_2.

[0067] It should be noted that the positions of the above-mentioned adapter connectors_1 to adapter connector_4 inside the computing device are fixed; and which pin on the controller an adapter connector is connected to is also fixed, so the controller has determined (or has learned) the adapter connector connected to each pin on it.

[0068] Based on the controller having learned the adapter connector connected to each pin on the controller, a specific implementation of the controller determining the current connection relationship of an expansion dock includes: the controller obtains, through each adapter connector (e.g., adapter connector_1), identifiers of multiple expansion connectors connected to each adapter connector (e.g., adapter connector_1 is connected to expansion connector_1), wherein the identifiers of the expansion connectors are used to indicate the expansion dock where the expansion connector is located and the position of the expansion connector on the expansion dock. Furthermore, based on the identifiers of the multiple expansion connectors, the controller can determine which expansion connector on which expansion dock each adapter connector is connected to; and then, based on the identifiers of the multiple expansion connectors, the controller determines the current connection relationship between the expansion connector on the expansion dock and each adapter connector.

[0069] For example, as shown in FIG1 , assume that adapter connector_1 in a computing device is connected to expansion connector_1, adapter connector_2 is connected to expansion connector_2, adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4. Since expansion dock_1 includes expansion connector_1 and expansion connector_2, the current connection relationship of expansion dock_1 includes: adapter connector_1 is connected to expansion connector_1, and adapter connector_2 is connected to expansion connector_2. Since expansion dock_2 includes expansion connector_3 and expansion connector_4, the current connection relationship of expansion dock_2 includes: adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4.

[0070] Optionally, in one implementation, the identifier of the expansion connector in the computing device shown in FIG1 includes: a first position identifier and a second position identifier, and the expansion connector includes: a first pin and a second pin; wherein the first pin is configured with a first position identifier, and the first position identifier is used to indicate the position information of the expansion connector in a target expansion dock, and the target expansion dock is the expansion dock where the expansion connector is located. The second pin is configured with a second position identifier, and the second position identifier is used to indicate the position information of the target expansion dock in at least two expansion docks; that is, the first position identifier is the position identifier of the expansion connector in the target expansion dock, and the second position identifier is the position identifier of the target expansion dock in multiple expansion docks; then, the controller can determine the target expansion dock from the multiple expansion docks in the computing device based on the second position identifier, and then, based on the first position identifier, can determine the expansion connector from the multiple expansion connectors in the target expansion dock, so the controller can determine the specific position of the expansion connector based on the first position identifier and the second position identifier.

[0071] For example, assume that the expansion connector is expansion connector 1 in Figure 1. Expansion connector 1 includes a first pin and a second pin. The first pin is configured with a first position marker "0," which indicates that expansion connector 1 is located on the left side of the docking station. The second pin is configured with a second position marker "0," which indicates that the docking station where expansion connector 1 is located is the left-side docking station between expansion connector 1 and expansion connector 2. Since expansion connector 1 is located to the left of expansion connector 2, the docking station where expansion connector 1 is located is expansion connector 1. Furthermore, since expansion connector 1 is located on the left side of expansion connector 1, it is determined to be expansion connector 1 in expansion connector 1.

[0072] Based on the first pin and the second pin on the expansion connector, the controller obtains an identifier of a connected expansion connector (e.g., the identifier of expansion connector_1) through an adapter connector (e.g., adapter connector_1), where the identifier of expansion connector_1 includes a first position identifier and a second position identifier of expansion connector_1. The controller then determines the connection relationship between the adapter connector and the expansion connector having the same second position identifier among the obtained multiple expansion connector identifiers as the connection relationship with the expansion dock indicated by the second position identifier.

[0073] By using the first position identifier and the second position identifier of the expansion connector as the identifier of the expansion connector, the controller can determine the target expansion dock where the expansion connector is located and the position information of the expansion connector within the target expansion dock based on the identifier of the expansion connector. In other words, based on the identifier of the expansion connector, the controller can not only determine the target expansion dock to which the adapter connector is connected, but also determine which specific expansion connector within the target expansion dock the adapter connector is connected to. This improves the accuracy of the controller in determining the expansion connector.

[0074] For example, assuming that when an expansion connector in an expansion dock is located at the left position in the expansion dock, the first position of the expansion connector is identified as "0", and when an expansion connector in an expansion dock is located at the right position in the expansion dock, the first position of the expansion connector is identified as "1"; when an expansion dock is located at the left position in the computing device, the second position of the expansion connector in the expansion dock is identified as "0", and when an expansion dock is located at the right position in the computing device, the second position of the expansion connector in the expansion dock is identified as "1".

[0075] In the computing device shown in Figure 1, the expansion connector identifier obtained by the controller through adapter connector_1 is {extension connector_1 identifier: (0, 0)}; wherein the first "0" in (0, 0) is the position identifier of expansion connector_1 in its docking station (i.e., docking station_1), i.e., the first "0" is the first position identifier of expansion connector_1; the second "0" is the position identifier of docking station_1, i.e., the second "0" is the second position identifier of expansion connector_1. The expansion connector identifier obtained by the controller through adapter connector_2 is {extension connector_2 identifier: (1, 0)}; the expansion connector identifier obtained by the controller through adapter connector_3 is {extension connector_3 identifier: (0, 1)}; and the expansion connector identifier obtained by the controller through adapter connector_4 is {extension connector_4 identifier: (1, 1)}. The controller obtains the identifier (0, 0) of adapter connector_1 through adapter connector_1, indicating that adapter connector_1 is connected to expansion connector_1 in docking station_1. That is, the expansion connector identifier obtained by the controller through adapter connector_1 indicates that adapter connector_1 is connected to the expansion connector.

[0076] Since the second position identifiers in the identifier (0, 0) of the expansion connector_1 obtained by the adapter connector_1 and the identifier (1, 0) of the expansion connector_2 obtained by the adapter connector_2 are both "0", and the first position identifier in the identifier (0, 0) of the expansion connector_1 is "0", and the first position identifier in the identifier (1, 0) of the expansion connector_2 is "1", the controller determines that the current connection relationship of the expansion dock_1 is that the expansion dock_1 is connected to the adapter connector_1 and the adapter connector_2 based on the identifiers {(0, 0) and (1, 0)} of the expansion connector transmitted to it by the adapter connector_1 and the adapter connector_2 respectively, and can further confirm that the expansion connector_1 on the expansion dock_1 is connected to the adapter connector_1, and the expansion connector_2 on the expansion dock_2 is connected to the adapter connector_2. In the same way, the controller determines that the current connection relationship of docking station_2 is that docking station_2 is connected to adapter connector_3 and adapter connector_4, and can further confirm that expansion connector_3 on docking station_2 is connected to adapter connector_3, and expansion connector_4 on docking station_2 is connected to adapter connector_4.

[0077] The controller is further configured to output an alarm message when the current connection relationship of the docking station is different from the preset connection relationship of the docking station, wherein the alarm message is configured to indicate that the current connection relationship of the docking station is incorrect.

[0078] It should be noted that the preset connection relationship of the above-mentioned expansion dock can be obtained by the controller locally, or it can be obtained by the controller from other devices or equipment. The specific embodiment of the present application does not limit the specific implementation method of the controller obtaining the preset connection relationship of the expansion dock.

[0079] For example, assuming that the current connection relationship of docking station_1 is as shown in FIG1 , the current connection relationship of docking station_1 is single-host mode. Specifically, the current connection relationship of docking station_1 includes: expansion connector_1 is connected to adapter connector_1, and expansion connector_2 is connected to adapter connector_2. Furthermore, assuming that the preset connection relationship of docking station_1 is multi-host mode, as shown in FIG2 , specifically includes: expansion connector_1 is connected to adapter connector_1, and expansion connector_2 is connected to adapter connector_4. Since the preset connection relationship of docking station_1 includes the connection of expansion connector_2 to adapter connector_4, if the current connection relationship of docking station_1 includes the connection of expansion connector_2 to adapter connector_2, then the current connection relationship of docking station_1 is different from the preset connection relationship of docking station_1. At this time, the controller outputs an alarm message, the content of which is "The current connection relationship of docking station_1 is incorrect. Please correct it in time!!!"

[0080] An embodiment of the present application provides a computing device, wherein an adapter connector in the computing device is connected to an expansion connector in an expansion dock, and the multiple adapter connectors are respectively connected to a controller in the computing device; the controller is used to determine the current connection relationship of the expansion dock, and the connection relationship includes: the connection relationship between each expansion connector of the expansion dock and the adapter connector; the controller is also used to output an alarm message indicating that the current connection relationship of the expansion dock is incorrect when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock. It can be seen that the above-mentioned controller will compare the current connection relationship of the expansion dock with the preset connection relationship of the expansion dock and determine the correctness of the current connection relationship of the expansion dock; when the current connection relationship of the expansion dock is incorrect, the controller outputs an alarm message so that the user can promptly know that the current connection relationship of the expansion dock is incorrect and correct the incorrect connection relationship, thereby ensuring the correct connection of the expansion dock, thereby solving the problem that the server cannot normally use the hardware resources to be expanded.

[0081] Optionally, the identifier of the above-mentioned expansion connector also includes a type identifier of the target expansion dock where the expansion connector is located. In this case, when the expansion connector includes: a first pin and a second pin, the above-mentioned expansion connector also includes: a third pin; the third pin is configured with the type identifier of the target expansion dock.

[0082] The types of the above-mentioned expansion docks include at least: a first type and a second type, wherein the first type of expansion dock is an expansion dock for providing a slot for a hard disk, and the second type of expansion dock is an expansion dock for providing a slot for a network card.

[0083] Based on the first pin, the second pin, and the third pin on the expansion connector, the controller obtains an identifier of the expansion connector _1 connected thereto through an adapter connector (e.g., adapter connector_1), where the identifier of the expansion connector _1 includes a first position identifier, a second position identifier of the expansion connector _1, and a type identifier of the expansion dock _1 where the expansion connector _1 is located. The controller then determines the connection relationship between the expansion connector, having the same second position identifier and the same expansion dock type identifier among the obtained multiple expansion connector identifiers, and the adapter connector as the connection relationship with the expansion dock _1.

[0084] For example, the connection relationship between adapter connectors 1 to 4 and the expansion connectors is shown in FIG1 , where adapter connector 1 is connected to expansion connector 1 in docking station 1, adapter connector 2 is connected to expansion connector 2 in docking station 1, adapter connector 3 is connected to expansion connector 3 in docking station 2, and adapter connector 4 is connected to expansion connector 4 in docking station 2; wherein, the first position mark of expansion connector 1 is “0” (i.e., on the left), and the first position mark of expansion connector 2 is “1” (i.e., on the right); if the position mark of expansion dock 1 is “0”, then the expansion connector 2 is “1”. The second position identifiers of expansion connector_1 and expansion connector_2 are both "0"; the type identifier of the expansion dock_1 is "0"; the type identifier "0" indicates that the expansion dock_1 is an expansion dock for providing a slot for a network card; the first position identifier of the expansion connector_3 is "0", and the first position identifier of the expansion connector_4 is "1"; the position identifier of the expansion dock_2 is "1", then the second position identifiers of the expansion connector_3 and the expansion connector_4 are "1"; the type identifier of the expansion dock_2 is "1"; the type identifier "1" indicates that the expansion dock_2 is an expansion dock for providing a slot for a hard disk (such as NVME).

[0085] At this point, the controller obtains the identifier {Extension connector_1 identifier: (0, 0, 0)} through adapter connector_1, where the first "0" in the identifier (0, 0, 0) is the first position identifier of expansion connector_1, the second "0" is the second position identifier of expansion connector_1, and the third "0" is the type identifier of the docking station_1 where expansion connector_1 is located. The controller obtains the identifier {Extension connector_2 identifier: (1, 0, 0)} through adapter connector_2; the controller obtains the identifier {Extension connector_3 identifier: (0, 1, 1)} through adapter connector_3; and the controller obtains the identifier {Extension connector_4 identifier: (1, 1, 1)} through adapter connector_4.

[0086] Since the second position identifiers of the identifier (0, 0, 0) of the expansion connector_1 obtained by the adapter connector_1 and the identifier (1, 0, 0) of the expansion connector_2 obtained by the adapter connector_2 are both "0", and the type identifiers of the expansion dock are also both 0; and the first position identifier of the identifier (0, 0, 0) of the expansion connector_1 is "0", and the first position identifier of the identifier (1, 0, 0) of the expansion connector_2 is "1", the controller determines that the current connection relationship of the expansion dock_1 is that the expansion dock_1 is connected to the adapter connector_1 and the adapter connector_2; and it can be further confirmed that the expansion connector_1 on the expansion dock_1 is connected to the adapter connector_1, the expansion connector_2 on the expansion dock_2 is connected to the adapter connector_2, and the type of the expansion dock_1 is a network card. In the same way, the controller determines that the current connection relationship of docking station_2 is that docking station_2 is connected to adapter connector_3 and adapter connector_4, and can further confirm that expansion connector_3 on docking station_2 is connected to adapter connector_3, and expansion connector_4 on docking station_2 is connected to adapter connector_4.

[0087] In the above embodiment, a first pin, a second pin, and a third pin are provided on each expansion connector, and a first position identifier of the expansion connector is configured on the first pin, the first position identifier being used to indicate the position information of the expansion connector in the expansion dock (i.e., the target expansion dock) in which it is located; a second position identifier of the expansion connector is configured on the second pin, the second position identifier being used to indicate the position information of the target expansion dock in at least two expansion docks in the computing device; and a type identifier of the target expansion dock is configured on the third pin, and the first position identifier, the second position identifier, and the type identifier of the target expansion dock are used as identifiers of the expansion connector. On this basis, the controller obtains the identifier of the expansion connector connected to it through each adapter connector, and determines the current connection relationship of the expansion dock based on the identifiers of the multiple expansion connectors; if the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, the controller outputs an alarm message, thereby ensuring that the type of the connected expansion dock is correct while ensuring that the expansion dock cable is correctly connected, thereby solving the problem of the server being unable to normally use the hardware resource to be expanded.

[0088] Optionally, based on the computing device shown in Figure 1, the computing device also includes multiple processors (central processing unit, CPU). As shown in Figure 3, the computing device includes 2 CPUs; any one of the 2 CPUs is connected to 2 adapter connectors among the above-mentioned 4 adapter connectors (for example: CPU1 is respectively connected to adapter connector_1 and adapter connector_2, and CPU2 is respectively connected to adapter connector_3 and adapter connector_4); one of the above-mentioned 4 adapter connectors is connected to an expansion connector among the above-mentioned 2 expansion docks (for example: adapter connector_1 is connected to expansion connector_1, adapter connector_2 is connected to expansion connector_2, adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4).

[0089] The CPU sends communication resources to the docking station connected to the CPU via the adapter connector connected to it. The communication resources may include bandwidth resources, high-speed signals, etc. required for communication between the CPU and the docking station. For example, CPU1 sends communication resources to docking station 1 via adapter connector 1 and adapter connector 2; CPU2 sends communication resources to docking station 2 via adapter connector 3 and adapter connector 4.

[0090] In one embodiment, as shown in FIG4 , based on the computing device shown in FIG3 , the computing device further includes: a mainboard and an adapter board, wherein the multiple processors in the computing device are arranged on the mainboard, and the multiple adapter connectors in the computing device are arranged on the adapter board.

[0091] The controller includes: a CPLD and a BMC; wherein the CPLD is arranged on the adapter board, the BMC is arranged on the main board, and the BMC is connected to the plurality of adapter connectors via the CPLD.

[0092] It should be noted that the above-mentioned CPLD is used to determine the current connection relationship of the expansion dock, and its specific implementation method is similar to the implementation method of the above-mentioned controller determining the current connection relationship of the expansion dock. For details, please refer to the relevant description in the computing device shown in Figure 1, which will not be repeated here.

[0093] It should be understood that the position of each of the multiple adapter connectors on the adapter board is fixed, and the connection between a pin on the controller and the adapter connector among the multiple adapter connectors is also fixed (i.e., preset); therefore, after the controller obtains the identifier of the expansion connector connected to the adapter connector through the adapter connector, the controller can determine that the expansion connector indicated by the identifier of the expansion connector is the expansion connector connected to the adapter connector. Based on this, the controller determines multiple connection relationships between the multiple adapter connectors and the multiple expansion connectors, and determines all connection relationships among the multiple connection relationships that have the same expansion dock as the current connection relationship of the expansion dock.

[0094] The above-mentioned BMC is used to output an alarm message when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock. The alarm message can be output by the BMC in the BMC management interface, or the BMC can send the alarm message to other devices, which then output the alarm message. The specific embodiment of the present application does not limit the specific output method of the alarm message.

[0095] It should be noted that the above is an exemplary description of the functions of the CPLD and BMC. For example, in one implementation, the CPLD is used to determine the current connection relationship of the docking station and send this connection relationship to the BMC; the BMC is used to determine whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station, and output an alarm message if it is not the same; see Example 1 below for details, which will not be repeated here. In another implementation, the CPLD is used to determine the current connection relationship of the docking station and send an alarm indication message to the BMC if the current connection relationship of the docking station is different from the preset connection relationship of the docking station; the BMC outputs an alarm message in response to the alarm indication message; see Example 2 below for details, which will not be repeated here.

[0096] Optionally, each of the above-mentioned CPUs is connected to the above-mentioned adapter connector _1 to adapter connector _4 through a retimer card (not shown in the figure); specifically, CPU1 is connected to retimer_1, and retimer_1 is connected to adapter connector _1 and adapter connector _2 respectively; CPU2 is connected to retimer_2, and retimer_2 is connected to adapter connector _3 and adapter connector _4 respectively; the retimer card is used to enhance the signal of the CPU sending communication resources to the expansion dock.

[0097] Optionally, the above-mentioned controller also includes a storage unit connected to the BMC, which is used to store the preset connection relationship of the expansion dock; that is, the BMC is specifically used to obtain the preset connection relationship of the expansion dock from the storage unit, and output the above-mentioned alarm information when the preset connection relationship of the expansion dock is different from the current connection relationship of the expansion dock.

[0098] The above-mentioned storage unit can be a device with storage function such as a solid-state drive, a field replaceable unit (FRU) and a non-volatile memory express (NVME); the specific embodiment of the present application does not limit the specific form of the above-mentioned storage unit.

[0099] The controller in the above embodiment, in addition to including the CPLD and the BMC, further includes a storage unit connected to the BMC. The storage unit is used to store the preset connection relationship of the expansion dock. Therefore, before the BMC determines whether the preset connection relationship of the expansion dock is the same as the current connection relationship of the expansion dock, the BMC can obtain the preset connection relationship of the expansion dock from the storage unit. Compared with the solution in which the preset connection relationship of the expansion dock is stored in the BMC, this saves storage space of the BMC.

[0100] Based on the above-mentioned computing device, the embodiments of the present application provide two methods for detecting mis-insertion of external devices, which are specifically described through schemes 1 and 2.

[0101] Option 1

[0102] An embodiment of the present application provides a method for detecting mis-insertion of an external device. The method is applied to any computing device as shown in FIG. 1 to FIG. 3 , and as shown in FIG. 5 , includes: S110 - S130 .

[0103] S110: The controller determines the current connection relationship of the docking station.

[0104] The current connection relationship of the expansion dock includes: the connection relationship between each expansion connector and the adapter connector in the expansion dock.

[0105] For example, as shown in Figure 1, a computing device includes an expansion dock 1, an expansion connector 1, and an expansion connector 2. The expansion connector 1 is connected to the adapter connector 1, and the expansion connector 2 is connected to the adapter connector 2. The current connection relationship of the expansion dock 1 is: the expansion connector 1 is connected to the adapter connector 1, and the expansion connector 2 is connected to the adapter connector 2.

[0106] The specific implementation of the above S110, as shown in FIG6 , includes: S110a - S110b.

[0107] S110a: The controller obtains, through each adapter connector, an identifier of an expansion connector connected to each adapter connector.

[0108] The identifier of the expansion connector is used to indicate the expansion connector connected to the adapter connector. That is, when the controller obtains the identifier of the expansion connector through the adapter connector_1, it indicates that the adapter connector_1 is connected to the expansion connector_1. The identifier of the expansion connector includes pin information of the expansion connector. The pin information is used to determine whether the expansion connector actually connected to the adapter connector is the preset expansion connector, thereby determining whether the cable between the adapter connector and the expansion connector is correctly connected. For example, assume that the expansion connector indicated by the pin information obtained by the controller through the adapter connector_1 is the expansion connector_2; and assume that the preset adapter connector_1 is connected to the expansion connector_1; then, the controller determines that the adapter connector_1 is connected to the wrong expansion connector.

[0109] It should be understood that the above-mentioned controller is respectively connected to multiple adapter connectors in the computing device where the controller is located, wherein the multiple adapter connectors are respectively connected one-to-one with different expansion connectors; based on this, the above-mentioned controller obtains the identification of the expansion connector connected to each adapter connector through multiple adapter connectors.

[0110] Illustratively, when the adapter connector_1 and the expansion connector_1 in the computing device shown in FIG1 are connected, the identifier of the expansion connector obtained by the controller through the adapter connector_1 includes the pin information of the expansion connector_1.

[0111] In one implementation, the identifier of the expansion connector includes: a first position identifier and a second position identifier of the expansion connector; wherein the first position identifier is used to indicate position information of the expansion connector in a target expansion dock, where the target expansion dock is the expansion dock where the expansion connector is located; and the second position identifier is used to indicate position information of the target expansion dock in at least two expansion docks in the computing device.

[0112] It should be noted that the above-mentioned expansion connector includes: a first pin and a second pin, wherein the first pin is configured with the above-mentioned first position identifier, and the second pin is configured with the above-mentioned second position identifier; the above-mentioned controller obtains the first position identifier from the first pin of the expansion connector and the second position identifier from the second pin of the expansion connector through the above-mentioned adapter connector, and determines the first position identifier and the second position identifier as the identifiers of the expansion connector.

[0113] For example, assume that adapter connector_1 in the computing device shown in FIG1 is connected to expansion connector_1 in docking station_1, adapter connector_2 is connected to expansion connector_2 in docking station_1, adapter connector_3 is connected to expansion connector_3 in docking station_2, and adapter connector_4 is connected to expansion connector_4 in docking station_2. Specifically, a first position marker "0" is configured on the first pin of expansion connector_1, a second position marker "0" is configured on the second pin of expansion connector_1, a first position marker "1" is configured on the first pin of expansion connector_2, and a second position marker "0" is configured on the second pin of expansion connector_2; a first position marker "0" is configured on the first pin of expansion connector_3, a second position marker "1" is configured on the second pin of expansion connector_3, a first position marker "1" is configured on the first pin of expansion connector_4, and a second position marker "1" is configured on the second pin of expansion connector_4.

[0114] Then, at this time, the identifier obtained by the controller through the adapter connector_1 is {identifier of expansion connector_1: (0, 0)}, where the first "0" in the identifier (0, 0) of expansion connector_1 represents the first position identifier of expansion connector_1, and the second "0" represents the second position identifier of expansion connector_1; the identifier obtained through the adapter connector_2 is {identifier of expansion connector_2: (1, 0)}, the identifier obtained through the adapter connector_3 is {identifier of expansion connector_3: (0, 1)}, and the identifier obtained through the adapter connector_4 is {identifier of expansion connector_4: (1, 1}.

[0115] The controller uses the first position identifier and the second position identifier of the expansion connector as the identifier of the expansion connector, allowing the controller to determine the target expansion dock where the expansion connector is located and the position information of the expansion connector within the target expansion dock based on the identifier of the expansion connector. In other words, based on the identifier of the expansion connector, the controller can not only determine the target expansion dock to which the target adapter connector (i.e., the adapter connector connected to the expansion connector) is connected, but can also determine which specific expansion connector in the target expansion dock the target adapter connector is connected to. This improves the accuracy of the controller in determining the expansion connector.

[0116] In another implementation, the identifier of the expansion connector includes not only the first position identifier and the second position identifier of the expansion connector, but also includes: a type identifier of a target expansion dock, where the target expansion dock is the expansion dock where the expansion connector is located.

[0117] It should be noted that, in addition to the first and second pins, the expansion connector further includes a third pin, on which the type identifier of the target expansion dock is configured; the controller obtains the type identifier of the target expansion dock from the third pin of the expansion connector via the adapter connector, and determines the first position identifier, the second position identifier, and the type identifier of the target expansion dock as the identifier of the expansion connector.

[0118] The types of the above-mentioned target expansion docks include: a first type and a second type; wherein the first type of expansion dock is an expansion dock for providing a slot for a hard disk, and the second type of expansion dock is an expansion dock for providing a slot for a network card; or, the first type of expansion dock is a riser card for providing a slot for an OCP network card, and the second type of expansion dock is an NVME backplane for providing a slot for NVME.

[0119] For example, assuming that an expansion connector in a docking station is located on the left side of the docking station, the first position of the expansion connector is identified as "0", and when an expansion connector in a docking station is located on the right side of the docking station, the first position of the expansion connector is identified as "1"; when a docking station is located on the left side of the computing device, the second position of the expansion connector in the docking station is identified as "0", and when a docking station is located on the right side of the computing device, the second position of the expansion connector in the docking station is identified as "1"; when a docking station is of the first type, the type of the docking station is identified as "0", and when a docking station is of the second type, the type of the docking station is identified as "1". Furthermore, assuming that the type of the docking station_1 in the computing device shown in FIG1 is identified as "0", and the type of the docking station_2 is identified as "1".

[0120] As shown in Figure 1 , when the adapter connector in the computing device is connected to the expansion connector via the cable shown by the dashed line, the identifier obtained by the controller in the computing device through adapter connector_1 is {ID of expansion connector_1: (0, 0, 0)}, where the first "0" in (0, 0, 0) is the first position identifier of expansion connector_1, the second "0" is the second position identifier of expansion connector_1, and the third "0" is the type identifier of the expansion dock_1 where expansion connector_1 is located. The identifier obtained through adapter connector_2 is {ID of expansion connector_2: (1, 0, 0)}, the identifier obtained through adapter connector_3 is {ID of expansion connector_3: (0, 1, 1)}, and the identifier obtained through adapter connector_4 is {ID of expansion connector_4: (1, 1, 1)}.

[0121] In the above embodiment, the first position identifier, the second position identifier, and the type identifier of the target expansion dock are used as the identifier of the expansion connector, so that the controller can determine the type of the target expansion dock based on determining the position of the expansion connector. Therefore, based on the identifier of the expansion connector, the controller can not only determine the specific position of the expansion connector but also determine the type of the target expansion dock where the expansion connector is located, thereby improving the accuracy of the controller in determining the expansion connector.

[0122] S110b: The controller determines the current connection relationship of the expansion dock according to the obtained identifiers of the multiple expansion connectors.

[0123] In a case where the identifier of the expansion connector includes the first position identifier and the second position identifier of the expansion connector, a specific implementation of S110b includes: the controller determines, as the current connection relationship of the expansion dock, connection relationships between all expansion connectors and the adapter connector having the same second position identifier among the acquired multiple expansion connector identifiers.

[0124] The current connection relationship of the expansion dock includes the connection relationship between all expansion connectors and adapter connectors on the expansion dock.

[0125] Exemplarily, as shown in FIG1 , when the adapter connector in the computing device is connected to the expansion connector via a cable represented by a dotted line, the identifiers of multiple expansion connectors obtained by the controller include: {identifier of expansion connector_1: (0, 0)}, wherein the first “0” in the identifier (0, 0) of expansion connector_1 represents the first position identifier of expansion connector_1, and the second “0” represents the second position identifier of expansion connector_1; {identifier of expansion connector_2: (1, 0)}, {identifier of expansion connector_3: (0, 1)}, and {identifier of expansion connector_4: (1, 1)}. Since the controller obtains the identifier (0, 0) of expansion connector_1 through adapter connector_1, it determines that adapter connector_1 is connected to expansion connector_1. Similarly, adapter connector_2 is connected to expansion connector_2, adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4. Furthermore, since the second position identifiers in the identifiers (0, 0) and (1, 0) obtained by the controller through adapter connector_1 and adapter connector_2, respectively, are both "0," and the position identifier of expansion dock_1 is also "0," the controller determines that the current connection relationship of expansion dock_1 includes: adapter connector_1 is connected to expansion connector_1, and adapter connector_2 is connected to expansion connector_2. Similarly, the controller determines that the current connection relationship of expansion dock_2 includes: adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4.

[0126] In a case where the identifier of the expansion connector includes a first position identifier and a second position identifier of the expansion connector, and a type identifier of a target expansion dock where the expansion connector is located, a specific implementation of S110b includes: the controller determining, as a current connection relationship of the expansion dock, a connection relationship between an expansion connector and an adapter connector having the same second position identifier and the same expansion dock type identifier among multiple expansion connector identifiers.

[0127] Exemplarily, as shown in FIG1 , when the adapter connector in the computing device is connected to the expansion connector via a cable represented by a dotted line, the multiple expansion connector identifiers obtained by the controller in the computing device include: {identifier of expansion connector_1: (0, 0, 0)}, where the first “0” in (0, 0, 0) is the first position identifier of expansion connector_1, the second “0” is the second position identifier of expansion connector_1, and the third “0” is the type identifier of expansion dock_1 where expansion connector_1 is located; {identifier of expansion connector_2: (1, 0, 0)}, {identifier of expansion connector_3: (0, 1, 1)}, and {identifier of expansion connector_4: (1, 1, 1)}.

[0128] Because the identifier obtained by the controller through adapter connector_1 is the identifier (0, 0, 0) of expansion connector_1, adapter connector_1 is determined to be connected to expansion connector_1. Similarly, adapter connector_2 is connected to expansion connector_2, adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4. Furthermore, because the second position identifiers in the identifiers (0, 0, 0) and (1, 0, 0) obtained by adapter connector_1 and adapter connector_2 are both "0" and the third position identifiers are both "0," and the second position identifier of expansion dock_1 is "0," and the type identifier of expansion dock_1 is also "0," the controller determines that the current connection relationship of expansion dock_1 includes: adapter connector_1 is connected to expansion connector_1, adapter connector_2 is connected to expansion connector_2, and the type of expansion dock_1 is a network card. Similarly, the controller determines that the current connection relationship of expansion dock_2 includes: adapter connector_3 is connected to expansion connector_3, and adapter connector_4 is connected to expansion connector_4.

[0129] S120: The controller determines whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station.

[0130] It should be noted that the preset connection relationship of the above-mentioned expansion dock can be obtained by the controller directly from the local, or obtained by the controller from other devices in the computing device, or obtained by the controller from other devices. The specific embodiment of the present application does not limit the specific method of obtaining the preset connection relationship of the expansion dock.

[0131] For example, it is assumed that in the preset connection relationship of the expansion dock_1, the adapter connector_1 is connected to the extension connector_1, that is, the identifier obtained by the controller through the adapter connector_1 is (0, 0, 0), and the (0, 0, 0) is the identifier of the extension connector_1, where the first "0" in (0, 0, 0) is the first position identifier of the extension connector_1, the second "0" is the second position identifier of the extension connector_1, and the third "0" is the type identifier of the expansion dock_1 where the extension connector_1 is located.

[0132] Then, when the adapter connector_1 is connected to the expansion connector_1 in the current connection relationship of the expansion dock_1, that is, the expansion connector identifier actually obtained by the controller through the adapter connector_1 is (0, 0, 0), the controller determines that the current connection relationship of the expansion dock_1 is the same as the preset connection relationship of the expansion dock_1.

[0133] In the case of a cable connection error between the adapter connector and the expansion connector, for example, adapter connector_1 is connected to expansion connector_2, the expansion connector identifier obtained by the controller through adapter connector_1 is (1, 0, 0). Since the expansion connector identifier (1, 0, 0) currently obtained through adapter connector_1 is different from the expansion connector identifier (0, 0, 0) preset by adapter connector_1, the controller determines that the current connection relationship of expansion dock_1 is different from the preset connection relationship of expansion dock_1.

[0134] When the cable connection between the adapter connector and the expansion connector is correct, but the type of the connected expansion dock is incorrect, for example, when the identifier of the expansion connector obtained by the controller through the adapter connector_1 is (0, 0, 1), the expansion dock represented by the type identifier "1" of the expansion dock_1 in the identifier of the expansion connector currently obtained through the adapter connector_1 is an NVME backplane, while the third bit of the identifier of the expansion connector obtained through the adapter connector_1 preset inside the controller is "0", and the expansion dock represented by "0" is a riser card; the NVME backplane and the riser card are expansion docks that provide different types of slots, so the controller determines that the current connection relationship of the expansion dock_1 is different from the preset connection relationship of the expansion dock_1.

[0135] When the current connection relationship of the docking station is the same as the preset connection relationship of the docking station, the controller executes an ending action to end the current method.

[0136] When the current connection relationship of the docking station is different from the preset connection relationship of the docking station, the controller executes the following S130.

[0137] S130: The controller outputs an alarm message.

[0138] The warning information is used to indicate that the current connection relationship of the expansion dock is incorrect.

[0139] Exemplarily, as shown in FIG1 , when the adapter connector in the computing device is connected to the expansion connector via a cable represented by a dotted line, the current connection relationship of the expansion dock 1 is a single-host mode. Specifically, the current connection relationship of the expansion dock 1 includes: the expansion connector 1 is connected to the adapter connector 1, and the expansion connector 2 is connected to the adapter connector 2. Assume that the preset connection relationship of the expansion dock 1 is a multi-host mode as shown in FIG2 , which specifically includes: the expansion connector 1 is connected to the adapter connector 1, and the expansion connector 2 is connected to the adapter connector 4. Since the preset connection relationship of the expansion dock 1 includes the connection of the expansion connector 2 to the adapter connector 4, while the current connection relationship of the expansion dock 1 includes the connection of the expansion connector 2 to the adapter connector 2, the current connection relationship of the expansion dock 1 is different from the preset connection relationship of the expansion dock 1. At this time, the controller outputs an alarm message, the content of which is “The current connection relationship of the expansion dock 1 is incorrect. Please correct it in time!!!”

[0140] In an embodiment of the present application, a method for detecting mis-insertion of an external device is provided. In this method, a controller obtains the current connection relationship of the expansion dock, where the connection relationship includes: the connection relationship between the expansion connector and the adapter connector on the expansion dock; then, when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, the controller outputs an alarm message indicating that the current connection relationship of the expansion dock is incorrect, so that the user can be informed of the current connection relationship error of the expansion dock in a timely manner and correct the incorrect connection relationship, thereby ensuring the correct connection of the expansion dock, thereby solving the problem that the server cannot normally use the hardware resources to be expanded.

[0141] Option 2

[0142] It should be noted that the computing device shown in Figure 4 includes a motherboard and an adapter board. The motherboard houses multiple processors, while the adapter board houses multiple adapters. The controller in the computing device includes a CPLD and a BMC. The CPLD is located on the adapter board, while the BMC is located on the motherboard. The BMC is connected to the adapters via the CPLD.

[0143] The present application provides a method for detecting mis-insertion of an external device. The method is applied to a computing device as shown in FIG4 . The following two embodiments are used to illustrate the method.

[0144] Example 1

[0145] An embodiment of the present application provides a method for detecting mis-insertion of an external device. As shown in FIG7 , the method includes: S210 - S240 .

[0146] S210: The CPLD determines the current connection relationship of the expansion dock.

[0147] It should be noted that the implementation of the above S210 is similar to the implementation of S110. For the specific description of S210, please refer to the above description of S110, which will not be repeated here.

[0148] S220: The CPLD sends the current connection relationship of the expansion dock to the BMC.

[0149] The CPLD is connected to the BMC, so the CPLD in S220 sends the current connection relationship of the expansion dock to the BMC through the connection.

[0150] S230: The BMC determines whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station.

[0151] The preset connection relationship of the expansion dock may be obtained locally by the BMC, or may be obtained from other devices or equipment.

[0152] Optionally, when the preset connection relationship of the expansion dock is stored in a storage unit connected to the BMC, the BMC further includes, before executing S230 : the BMC obtains the preset connection relationship of the expansion dock from the storage unit.

[0153] When the current connection relationship of the docking station is the same as the preset connection relationship of the docking station, the BMC performs an ending action to end the current method.

[0154] In a case where the current connection relationship of the docking station is different from the preset connection relationship of the docking station, the BMC executes the following S240 .

[0155] S240 : The BMC outputs alarm information in response to the alarm indication information.

[0156] It should be noted that the implementation of the above S240 is similar to the implementation of S130. For the specific description of S240, please refer to the above description of S130, which will not be repeated here.

[0157] In the above embodiment, the BMC receives the current docking station connection relationship from the CPLD and determines whether the current docking station connection relationship is the same as the preset docking station connection relationship. If the current docking station connection relationship is different from the preset docking station connection relationship, the BMC outputs an alarm message. As can be seen, the CPLD is only used to obtain the current docking station connection relationship, while the BMC performs the actions of determining whether the current docking station connection relationship is the same as the preset docking station connection relationship and outputting the alarm message. This reduces the utilization of processing resources in the CLPD.

[0158] Example 2

[0159] An embodiment of the present application provides a method for detecting mis-insertion of an external device. As shown in FIG8 , the method includes: S310 - S340 .

[0160] S310: The CPLD determines the current connection relationship of the expansion dock.

[0161] It should be noted that the implementation of the above S310 is similar to the implementation of S110. For the specific description of S310, please refer to the above description of S110, which will not be repeated here.

[0162] S320: The CPLD determines whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station.

[0163] The preset connection relationship of the expansion dock may be obtained locally by the CPLD, or may be obtained from other devices or equipment by the CPLD.

[0164] Optionally, when the preset connection relationship of the expansion dock is stored in a storage unit connected to the BMC, before executing S320, the process further includes: the BMC obtaining the preset connection relationship of the expansion dock from the storage unit, and sending the preset connection relationship of the expansion dock to the CPLD.

[0165] When the current connection relationship of the docking station is the same as the preset connection relationship of the docking station, the CPLD executes an ending action to end the current method.

[0166] When the current connection relationship of the docking station is different from the preset connection relationship of the docking station, the CPLD executes the following S330.

[0167] S330: The CPLD sends alarm indication information to the BMC.

[0168] S340: The BMC outputs alarm information in response to the alarm indication information.

[0169] It should be noted that the implementation method of the above S340 is similar to the implementation method of S130. For the specific description of S340, please refer to the above description of S130, which will not be repeated here.

[0170] In the above embodiment, the CPLD obtains the current connection relationship of the docking station and determines whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station. If the current connection relationship of the docking station is different from the preset connection relationship of the docking station, the CPLD sends an alarm indication to the BMC, and the BMC outputs an alarm message in response to the alarm indication. It can be seen that the above BMC is only used to output the alarm message and does not need to determine whether the current connection relationship of the docking station is the same as the preset connection relationship of the docking station. Therefore, the utilization rate of processing resources in the BMC is reduced.

[0171] The above mainly introduces the solution provided by the embodiment of the present application from the perspective of the method. In order to realize the above functions, the controller includes hardware structures and / or software modules corresponding to the execution of each function. Those skilled in the art should easily realize that, in combination with the units and algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0172] In the embodiment of the present application, the functional modules of the controller can be divided according to the above method. For example, the controller can include functional modules corresponding to the functional divisions, or two or more functions can be integrated into one processing module. The integrated modules can be implemented in the form of hardware or software functional modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical functional division. In actual implementation, there may be other division methods.

[0173] FIG9 shows a schematic structural diagram of a controller, which includes a determining unit 901 and an output unit 902 .

[0174] The determining unit 901 is configured to determine the current connection relationship of the docking station, for example, by executing step S110 in the above method embodiment.

[0175] The output unit 902 is configured to cause the controller to output an alarm message when the current connection relationship of the docking station is different from the preset connection relationship of the docking station, for example, executing step S130 in the above method embodiment.

[0176] Optionally, the controller further includes: an acquiring unit 903, configured to acquire, through each adapter connector, an identifier of an expansion connector connected to the adapter connector, for example, by executing step S110a in the above method embodiment.

[0177] The determining unit 901 is specifically configured to determine the current connection relationship of the expansion dock according to the acquired identifiers of the multiple expansion connectors, for example, by executing step S110b in the above method embodiment.

[0178] Optionally, the controller further includes a first processing unit 904 and a second processing unit 905; the first processing unit 904 is used to determine the current connection relationship of the docking station and send the current connection relationship of the docking station to the second processing unit 905, for example, executing steps S210-S220 in the above method embodiment.

[0179] The second processing unit 905 is configured to receive the current connection relationship of the docking station, and output an alarm message when the current connection relationship of the docking station is different from the preset connection relationship of the docking station, for example, executing step S240 in the above method embodiment.

[0180] Optionally, the first processing unit 904 is used to determine the current connection relationship of the docking station; when the current connection relationship of the docking station is different from the preset connection relationship of the docking station, an alarm indication information is sent to the second processing unit 905, for example, steps S310-S330 in the above method embodiment are executed.

[0181] The second processing unit 905 is configured to output alarm information in response to the alarm indication information, for example, executing step S340 in the above method embodiment.

[0182] Optionally, the acquiring unit 903 is specifically configured to acquire a preset connection relationship of the docking station from a storage unit.

[0183] Each unit of the above-mentioned controller can also be used to perform other actions in the above-mentioned method embodiment. All relevant contents of each step involved in the above-mentioned method embodiment can be referred to the functional description of the corresponding functional unit and will not be repeated here.

[0184] An embodiment of the present application further provides a computing device, which is any one of the computing devices shown in Figures 1 to 4 above.

[0185] An embodiment of the present application further provides a computing device cluster, which includes any one of the computing devices shown in Figures 1 to 4 above.

[0186] An embodiment of the present application further provides a computer-readable storage medium having a computer program stored thereon. When the computer program is run on a computer, the computer is caused to execute any of the methods executed by the computer devices provided above.

[0187] For explanations of the relevant contents and descriptions of the beneficial effects of any of the computer-readable storage media provided above, reference may be made to the corresponding embodiments described above, and no further details will be given here.

[0188] In the above embodiments, all or part of the embodiments may be implemented by software, hardware, firmware, or any combination thereof. When implemented using a software program, all or part of the embodiments may be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, all or part of the processes or functions in accordance with the embodiments of the present application are generated. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from one website, computer, computing device, or data center to another website, computer, computing device, or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) method. The computer-readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a computing device or data center that includes one or more available media integrated therein. The available medium may be a magnetic medium (eg, a floppy disk, a magnetic disk, a magnetic tape), an optical medium (eg, a digital video disc (DVD)), or a semiconductor medium (eg, a solid state drive (SSD)).

[0189] Through the description of the above embodiments, those skilled in the art will clearly understand that for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. The specific working processes of the above-described systems, devices, and units can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0190] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

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

[0192] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0193] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for enabling a computer device (which can be a personal computer, a computing device, or a network device, etc.) or a processor to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as flash memory, mobile hard disk, read-only memory, random access memory, magnetic disk or optical disk.

[0194] The above is only a specific embodiment of the present application, but the scope of protection of this application is not limited to this. Any changes or substitutions within the technical scope disclosed in this application should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.

Claims

1. A computing device, characterized in that: The computing device comprises: a controller, a plurality of transfer connectors and at least two expansion docks, each of the expansion docks comprising at least two expansion connectors; One of the plurality of adapter connectors is connected to one of the expansion connectors; The multiple adapter connectors are respectively connected to the controller; The controller is used to determine a current connection relationship of the expansion dock, the connection relationship including: a connection relationship between each expansion connector of the expansion dock and an adapter connector; and, when the current connection relationship of the expansion dock is different from a preset connection relationship of the expansion dock, output an alarm message, wherein the alarm message is used to indicate that the current connection relationship of the expansion dock is wrong.

2. The computing device according to claim 1, wherein: The controller is used to determine the current connection relationship of the docking station, including: The controller is used to obtain the identification of the expansion connector connected to the adapter connector through each adapter connector; The controller is used to determine the current connection relationship of the expansion dock according to the acquired identifiers of the plurality of expansion connectors.

3. The computing device according to claim 2, characterized in that The identifier of the expansion connector includes: a first position identifier and a second position identifier; the expansion connector includes: a first pin and a second pin; the first pin is configured with the first position identifier, and the first position identifier is used to indicate the position information of the expansion connector on a target expansion dock, and the target expansion dock is the expansion dock where the expansion connector is located; the second pin is configured with the second position identifier, and the second position identifier is used to indicate the position information of the target expansion dock in the at least two expansion docks.

4. The computing device according to claim 3, characterized in that The identifier of the expansion connector also includes: a type identifier of the target expansion dock; The expansion connector further includes: a third pin; the third pin is configured with a type identification of the target expansion dock.

5. The computing device according to any one of claims 1 to 4, characterized in that: The computing device comprises a mainboard and an adapter board, and the adapter connector is arranged on the adapter board; The controller includes a programmable logic device and a baseboard management controller, the programmable logic device is arranged on the adapter board, the baseboard management controller is arranged on the main board, and the baseboard management controller is connected to the plurality of adapter connectors through the programmable logic device; The programmable logic device is used to determine the current connection relationship of the expansion dock; The baseboard management controller is used for outputting the alarm information when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock.

6. The computing device according to claim 5, characterized in that The controller further comprises a storage unit connected to the baseboard management controller, wherein the storage unit stores a preset connection relationship of the expansion dock.

7. The computing device according to any one of claims 1 to 6, characterized in that: The types of the expansion dock include at least a first type and a second type. The first type of expansion dock is a docking station for providing a slot for a hard disk, and the second type of expansion dock is a docking station for providing a slot for a network card.

8. A method for detecting misinsertion of an external device, characterized in that: The method is applied to a computing device, the computing device comprising: a controller, a plurality of adapter connectors and at least two expansion docks, each of the expansion docks comprising at least two expansion connectors; one of the plurality of adapter connectors is connected to one of the expansion connectors, and the plurality of adapter connectors are respectively connected to the controller; the method comprises: The controller determines a current connection relationship of the expansion dock, wherein the connection relationship includes: a connection relationship between each expansion connector and a transfer connector in the expansion dock; In a case where the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock, the controller outputs an alarm message, where the alarm message is used to indicate that the current connection relationship of the expansion dock is wrong.

9. The method according to claim 8, characterized in that The controller determines the current connection relationship of the docking station, specifically including: The controller obtains, through each of the adapter connectors, an identification of an expansion connector connected to the adapter connector; The controller determines a current connection relationship of the expansion dock according to the acquired identifiers of the plurality of expansion connectors.

10. The method according to claim 9, characterized in that The identifier of the expansion connector includes: a first position identifier and a second position identifier of the expansion connector, the first position identifier is used to indicate position information of the expansion connector on a target expansion dock, and the second position identifier is used to indicate position information of the target expansion dock in the at least two expansion docks, and the target expansion dock is the expansion dock where the expansion connector is located.

11. The method according to claim 10, characterized in that The identifier of the expansion connector also includes: a type identifier of the target expansion dock.

12. The method according to any one of claims 8 to 11, characterized in that: The controller includes a programmable logic device and a baseboard management controller; the method specifically includes: The programmable logic device determines a current connection relationship of the expansion dock, and sends the current connection relationship of the expansion dock to the baseboard management controller; The baseboard management controller receives the current connection relationship of the expansion dock, and outputs the alarm information when the current connection relationship of the expansion dock is different from the preset connection relationship of the expansion dock.

13. The method according to any one of claims 8 to 11, characterized in that: The controller includes a programmable logic device and a baseboard management controller; the method specifically includes: The programmable logic device determines a current connection relationship of the expansion dock; and when the current connection relationship of the expansion dock is different from a preset connection relationship of the expansion dock, sends an alarm indication message to the baseboard management controller; The baseboard management controller outputs the alarm information in response to the alarm indication information.

14. The method according to any one of claims 12 to 13, characterized in that: The controller further includes a storage unit, in which a preset connection relationship of the docking station is stored; and the method further includes: The baseboard management controller obtains the preset connection relationship of the expansion dock from the storage unit.

Citation Information

Patent Citations

  • Portable mobile device, mainframe and docking station

    CN104516399A

  • System and method for automatically checking connection relation of communication cables

    CN114443552A

  • Cabinet server cable connection detection method and related device

    CN116048889A

  • Node misplug detection method and server

    CN116361088A

  • Cable connection correctness identification system, method, device and equipment and storage medium

    CN116820193A

Cited By

  • Server mainboard and link management method

    CN120596425A

  • Cable connection detection circuit and server

    CN121029542A