A method, device and equipment for identifying FRU in place and a readable storage medium

By recording the bus number and slave address of the FRU storage chip in the kernel device tree and sending commands in a targeted manner, the problems of bus congestion and device malfunction in the prior art are solved, ensuring the normal operation of the server.

CN115599716BActive Publication Date: 2026-07-24INSPUR BUSINESS MACHINE CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INSPUR BUSINESS MACHINE CO LTD
Filing Date
2022-10-26
Publication Date
2026-07-24

AI Technical Summary

Technical Problem

In existing technologies, sending FRU commands to each device by traversing all devices on the bus can cause the bus to become busy and devices to malfunction, affecting the normal operation of other server functions.

Method used

By pre-entering the bus number and slave address of the storage chip for the storage FRU into the kernel device tree, instructions are sent to the storage chip in a targeted manner, avoiding traversing all devices on the bus.

Benefits of technology

This avoids bus congestion and device malfunctions, ensuring the normal operation of other server functions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115599716B_ABST
    Figure CN115599716B_ABST
Patent Text Reader

Abstract

The application discloses a method for identifying FRU in place, and relates to the field of servers, and the method comprises the following steps: reading the bus number and slave address of a storage chip for storing FRU which are pre-recorded in a kernel device tree; locating the address of the storage chip through the bus number and the slave address; sending an initialization command to the storage chip according to the address; and determining that the FRU is in place when information about the initialization success of the storage chip is received. The method reads the bus number and slave address of the storage chip for storing FRU which are pre-recorded in the kernel device tree, thereby sending instructions to the storage chip directionally, and the problem that the functions of the server run abnormally due to the fact that all devices on the bus are traversed, instructions are sent to each device, the bus is busy, and the devices work abnormally in the prior art is avoided. The application also discloses a device for identifying FRU in place, equipment and a computer readable storage medium, which have the beneficial effects mentioned above.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of servers, and in particular to a method, apparatus, device, and computer-readable storage medium for identifying the presence of an FRU. Background Technology

[0002] FRUs (Field Replaceable Units) record information such as model and serial number of various server components. They are primarily used for asset management and after-sales maintenance and are typically stored in EEPROM (Electrically Erasable Programmable Read-Only Memory) chips. The BMC (Baseboard Management Controller) in a server generally needs to manage a large number of FRUs, but not every FRU is necessarily present. Currently, the solution for identifying FRU presence is for the BMC to traverse all devices connected to the bus, sending a specific FRU command to each device and waiting for data returns. If the returned result matches the FRU interaction logic, it is considered a valid FRU. This method of sending specific FRU commands to each device via the bus can cause bus congestion and lead to malfunctions in other devices, affecting the normal operation of other server functions. Summary of the Invention

[0003] The purpose of this invention is to provide a method, apparatus, device, and computer-readable storage medium for identifying the presence of an FRU, applicable to the server field. This invention determines the presence of an FRU by sending a targeted instruction to the storage chip, avoiding the problem of affecting the normal operation of server functions by sending specific FRU instructions to each device via the bus.

[0004] To achieve the above objectives, the present invention provides a method for identifying the presence of an FRU, comprising:

[0005] Read the bus number and slave address of the storage chip of the storage FRU that were pre-entered in the kernel device tree;

[0006] The address of the memory chip is located using the bus number and the slave address;

[0007] Send an initialization command to the memory chip according to the address;

[0008] When the information indicating successful initialization of the memory chip is received, it is determined that the FRU is in place.

[0009] Optionally, the step of determining that the FRU is in place when the information indicating successful initialization of the memory chip is received further includes:

[0010] Send a udev signal to the device manager. When the device manager detects the udev signal, it starts a script to call the FRU information display program to display the information of the FRU.

[0011] Optionally, reading the bus number and slave address of the storage chip of the storage FRU pre-entered in the kernel device tree includes:

[0012] Read the bus number and slave address of the EEPROM chip storing the FRU, which are pre-entered in the kernel device tree;

[0013] Accordingly, locating the address of the memory chip using the bus number and the slave address includes:

[0014] The address of the EEPROM chip is located using the bus number and the slave address;

[0015] Accordingly, sending an initialization command to the memory chip based on the address includes:

[0016] The initialization command is sent to the EEPROM chip according to the address.

[0017] Optionally, reading the bus number and slave address of the storage chip of the storage FRU pre-entered in the kernel device tree includes:

[0018] Read the IIC bus number and IIC slave address of the storage chip storing the FRU, which are pre-entered in the kernel device tree;

[0019] Accordingly, locating the address of the memory chip using the bus number and the slave address includes:

[0020] The address of the memory chip is located using the IIC bus number and the IIC slave address.

[0021] To achieve the above objectives, the present invention also provides a device for identifying the presence of an FRU, comprising:

[0022] The read module is used to read the bus number and slave address of the storage chip of the storage FRU that are pre-entered in the kernel device tree;

[0023] A positioning module is used to locate the address of the memory chip using the bus number and the slave address;

[0024] The instruction sending module is used to send an initialization command to the memory chip according to the address;

[0025] The presence determination module is used to determine that the FRU is in place when it receives information that the memory chip has been successfully initialized.

[0026] Optional, also includes:

[0027] The information display module is used to send a udev signal to the device manager, so that when the device manager detects the udev signal, it starts a script to call the FRU information display program to display the information of the FRU.

[0028] Optionally, the reading module includes:

[0029] The first reading unit is used to read the IIC bus number and IIC slave address of the storage chip storing the FRU, which are pre-entered in the kernel device tree;

[0030] Accordingly, the positioning module includes:

[0031] The first positioning unit is used to locate the address of the EEPROM chip using the bus number and the slave address;

[0032] Accordingly, the instruction sending module includes:

[0033] The first instruction sending unit is used to send the initialization command to the EEPROM chip according to the address.

[0034] Optionally, the reading module includes:

[0035] The second reading module is used to read the IIC bus number and IIC slave address of the storage chip storing the FRU, which are pre-entered in the kernel device tree;

[0036] Accordingly, the positioning module includes:

[0037] The second positioning unit is used to locate the address of the memory chip using the IIC bus number and the IIC slave address.

[0038] To achieve the above objectives, the present invention also provides a device for identifying the presence of an FRU, comprising:

[0039] Memory, used to store computer programs;

[0040] A processor is configured to implement the aforementioned method for identifying the presence of an FRU when executing the computer program.

[0041] To achieve the above objectives, the present invention also provides a computer-readable storage medium, characterized in that the computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, implement the above-described method for identifying the presence of an FRU.

[0042] This invention provides a method for identifying the presence of an FRU, comprising: reading the bus number and slave address of the storage chip storing the FRU pre-entered in the kernel device tree; locating the address of the storage chip using the bus number and slave address; sending an initialization command to the storage chip according to the address; and determining that the FRU is present when a message indicating successful initialization of the storage chip is received.

[0043] As can be seen, this invention pre-enters the bus number and slave address of the storage chip storing the FRU in the kernel device tree, and locates the chip by reading the bus number and slave address, thereby sending instructions to the storage chip in a targeted manner. This avoids the problem in existing related technologies where sending instructions to each device by traversing all devices on the bus causes the bus to become busy and devices to malfunction, resulting in abnormal operation of other server functions. Attached Figure Description

[0044] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0045] Figure 1 A flowchart illustrating a method for identifying the presence of FRUs provided in an embodiment of the present invention;

[0046] Figure 2 A specific embodiment of a method for identifying the presence of FRUs is shown in the figure provided by this invention.

[0047] Figure 3 A schematic diagram of a method for identifying the presence of FRUs provided in an embodiment of the present invention;

[0048] Figure 4 This is a structural block diagram of an FRU in-situ identification device provided in an embodiment of the present invention. Detailed Implementation

[0049] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0050] Baseboard Management Controller (BMC) is typically a small system integrated onto the motherboard of a server or other device, responsible for monitoring and managing the server. From the moment a server powers on, all its components are managed and controlled by the BMC. Currently, BMC software solutions mainly include traditional commercial closed-source solutions and open-source OpenBMC (Open Baseboard Management Controller) solutions. Free Root Units (FRUs) record information such as the model and serial number of each server component, primarily used for asset management and after-sales maintenance. They are usually stored in an EEPROM chip. A server's BMC typically needs to manage a large number of FRUs, but not every FRU is always present; therefore, the BMC needs to dynamically identify whether an FRU is present.

[0051] Current related technologies identify the presence of a FRU by having the BMC traverse all devices connected to the IIC (Inter-Integrated Circuit) bus, sending a specific FRU command to each device and waiting for data return. If the data matches the FRU's interaction logic, it is considered a valid FRU. This approach has significant drawbacks. For example, the BMC's IIC bus is typically connected to sensors such as temperature and voltage sensors. Probingly sending data to each IIC bus can easily overload the bus, preventing the BMC from processing sensor data promptly. Furthermore, probing data to all devices on the IIC bus may cause some sensors to malfunction. This approach can lead to malfunctions in various server functions during the FRU presence identification process. Therefore, this invention addresses this issue by pre-entering the bus number and slave address of the memory chip storing the FRU into the kernel device tree. By locating the FRU using the read bus number and slave address, it can send commands to the memory chip in a targeted manner. This avoids the problems of existing technologies that involve traversing all devices on the bus and sending commands to each device, causing bus overload and device malfunctions, which can lead to other server malfunctions.

[0052] The following combination Figure 1 , Figure 1 A flowchart of a method for identifying the presence of an FRU provided in an embodiment of the present invention, the method may include:

[0053] S101: Read the bus number and slave address of the storage chip of the storage FRU that are pre-entered in the kernel device tree.

[0054] Understandably, the kernel device tree is a data structure within the system kernel that describes hardware resources. It can consist of the CPU (Central Processing Unit), buses, and devices on the circuit board. The bootloader passes the contents of this tree to the system kernel, which then identifies the tree. FRUs are stored in memory chips. The bus number and slave address of the memory chip containing the FRU are pre-entered into the kernel device tree, allowing the system kernel to locate the memory chip by reading the information in the kernel device tree.

[0055] The execution entity in this embodiment can generally be a server. Compared to ordinary computer equipment, servers play a crucial role and have higher requirements for the performance and operational status of their components. Therefore, this method is generally applied to servers. Furthermore, in this embodiment, the server kernel can generally be a Linux system kernel under the OpenBMC framework. The BMC plays the role of monitoring and managing the server. Currently, there are commercial closed-source solutions and the open-source solution OpenBMC. With the development of the server industry, OpenBMC, as an open-source solution, offers better access and control over the BMC. In a typical computer, the CPU can manage temperature and power, but for devices with high system requirements, such as servers with more powerful hardware, the BMC is used to monitor the health status of the server's main components in real time, including fan speed, CPU and motherboard temperature, core voltage, and power module status.

[0056] Furthermore, this embodiment does not limit the type of server. It can be classified according to chassis structure, such as desktop servers, rack servers, cabinet servers, and blade servers; it can also be classified according to purpose, such as general-purpose servers and special-purpose servers; it can also be classified according to processor architecture, such as CISC (Complex Instruction Set Computer) servers, RISC (Reduced Instruction Set Computing) servers, and VLIW (Very Long Instruction Word) servers; it can also be classified according to application level, such as entry-level servers, workgroup-level servers, department-level servers, and enterprise-level servers.

[0057] This embodiment does not limit the type of storage chip used to store the FRU. Since EEPROM chips are more stable than other storage chips, data is not lost after power failure, and any byte can be randomly accessed and modified, the FRU is generally stored in an EEPROM chip. Furthermore, this embodiment does not limit the type of bus used to connect the storage chip. A bus is an internal structure; it is a common channel for information transmission between the CPU, memory, input, and output devices. Various components of the host are connected via the bus, and external devices are connected to the bus through corresponding interface circuits, thus forming a computer hardware system. In a computer system, the common path for transmitting information between various components is called a bus. Microcomputers use a bus structure to connect various functional components. The main advantages of the IIC bus are its simplicity and efficiency. Because the interface is directly on the component, the IIC bus occupies very little space, reducing the space on the circuit board and the number of chip pins, thus lowering interconnection costs. Another advantage of the IIC bus is that it supports multiple masters, where any device capable of sending and receiving can become a master bus. Therefore, in this embodiment, the IIC bus can be used to connect the storage chip.

[0058] This embodiment does not limit the timing of starting to read the kernel device tree. It can be done automatically after the server powers on, or it can be done after receiving a read command.

[0059] S102: Locate the address of the memory chip using the bus number and slave address.

[0060] Understandably, in current related technologies, the presence of the FRU is generally identified by traversing all devices on the bus. This step directly locates the address of the memory chip that stores the FRU using the bus number and slave address.

[0061] S103: Send an initialization command to the memory chip according to the address.

[0062] Understandably, sending initialization commands to the memory chip based on the address avoids the problem in existing related technologies where sending commands to each device on the bus by traversing all devices on the bus causes the bus to become busy and devices to malfunction, leading to abnormal operation of other server functions.

[0063] S104: When the information that the memory chip initialization is successful is received, it is determined that the FRU is in place.

[0064] Understandably, after determining the address of the storage chip that stores the FRU, an initialization command is sent to the storage chip. When the system kernel receives the returned initialization success information, it can determine that the storage chip exists, and thus the FRU stored in it is identified as being in place.

[0065] Furthermore, to allow users to intuitively understand the presence of the FRU, FRU information can be displayed after its presence is confirmed. This can be achieved by the system kernel sending a udev signal to the Device Manager. The udev signal is a signal that triggers the Device Manager's startup script to call the FRU information display program. This udev signal contains information such as the bus type connecting the storage chip, the storage chip type, the bus number, and the slave address. When a process in the Device Manager monitors this udev signal, it starts a script and uses the information contained in the udev signal to call the FRU information display program, displaying the FRU information through information management interfaces such as IPMI.

[0066] This embodiment pre-enters the bus number and slave address of the storage chip storing the FRU in the kernel device tree, and locates the chip by reading the bus number and slave address, thereby sending instructions to the storage chip in a targeted manner. This avoids the problem in existing related technologies where sending instructions to each device on the bus by traversing all devices on the bus can cause the bus to become busy and devices to malfunction, resulting in abnormal operation of other server functions.

[0067] The following combination Figure 2 , Figure 2 This invention provides a specific embodiment diagram for identifying the presence of an FRU, wherein the execution entity can be a server, or a Linux system kernel under the OpenBMC open-source framework; the storage chip used to store the FRU can be an EEPROM chip; and the bus connecting the storage chip can be an IIC bus. This specific embodiment may include:

[0068] 1. The user pre-enters the IIC bus number and IIC slave address of the EEPROM chip storing the FRU into the kernel device tree.

[0069] 2. Read the IIC bus number and IIC slave address of the EEPROM chip in the kernel device tree.

[0070] 3. Locate the IIC bus where the EEPROM chip is located using the IIC bus number, and then locate the EEPROM chip's position on the IIC bus using the IIC slave address.

[0071] 4. Send an initialization command to the located EEPROM chip.

[0072] 5. When the initialization success message is received, send the udev signal to the device manager.

[0073] 6. After the Device Manager detects the udev signal, it starts a script to call the FRU information display program.

[0074] The following combination Figure 3 , Figure 3This is a schematic diagram of a method for identifying the presence of an FRU according to an embodiment of the present invention. The executing entity can be a general-purpose server, and the software can be divided into three modules: an FRU information display program, a Linux kernel, and a device manager. In this scheme, the address information of the storage chip storing the FRU, also known as the FRU hardware basic information, needs to be pre-entered into the kernel device tree before operation. The server reads the FRU hardware basic information from the kernel device tree through the Linux kernel and uses this information to identify whether the FRU is present. When the FRU is present, the Linux kernel sends a udev signal to the device manager. When the device manager matches the corresponding udev signal, it calls the FRU information display program to display the FRU information to the user.

[0075] The following describes a device, apparatus, and storage medium for identifying the presence of an FRU provided by an embodiment of the present invention. The device, apparatus, and storage medium for identifying the presence of an FRU described below can be referred to in correspondence with the method for identifying the presence of an FRU described above.

[0076] The following combination Figure 4 , Figure 4 A structural block diagram of an FRU presence identification device provided in an embodiment of the present invention is provided. The device may include:

[0077] The read module 100 is used to read the bus number and slave address of the storage chip of the storage FRU that are pre-entered in the kernel device tree;

[0078] The positioning module 200 is used to locate the address of the memory chip by means of the bus number and the slave address;

[0079] The instruction sending module 300 is used to send initialization commands to the memory chip according to the address.

[0080] The presence determination module 400 is used to determine that the FRU is in place when it receives information that the memory chip has been successfully initialized.

[0081] Based on the above embodiments, the present invention reads the bus number and slave address of the storage chip that stores FRU in the kernel device tree in advance, and then sends instructions to the storage chip in a targeted manner. This avoids the problem in the existing related technologies of sending instructions to each device by traversing all devices on the bus, which causes the bus to be busy and the devices to work abnormally, resulting in abnormal operation of various functions of the server.

[0082] Based on the above embodiments, the device may further include:

[0083] The information display module is used to send a udev signal to the device manager, so that when the device manager detects the udev signal, it starts a script to call the FRU information display program to display the information of the FRU.

[0084] Based on the above embodiments, the reading module 100 may include:

[0085] The first reading unit is used to read the IIC bus number and IIC slave address of the storage chip storing the FRU, which are pre-entered in the kernel device tree;

[0086] Accordingly, the positioning module 200 may include:

[0087] The first positioning unit is used to locate the address of the EEPROM chip using the bus number and the slave address;

[0088] Accordingly, the instruction sending module 300 may include:

[0089] The first instruction sending unit is used to send the initialization command to the EEPROM chip according to the address.

[0090] Based on the above embodiments, the reading module 100 may include:

[0091] The second reading module is used to read the IIC bus number and IIC slave address of the storage chip storing the FRU, which are pre-entered in the kernel device tree;

[0092] Accordingly, the positioning module 200 may include:

[0093] The second positioning unit is used to locate the address of the memory chip using the IIC bus number and the IIC slave address.

[0094] Based on the above embodiments, the present invention also provides a device for identifying the presence of an FRU. This device may include a memory and a processor. The memory stores a computer program, and when the processor invokes the computer program in the memory, it can implement the steps provided in the above embodiments. Of course, the device may also include various necessary network interfaces, power supplies, and other components.

[0095] The present invention also provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by an execution terminal or processor, it can implement the method for identifying the presence of an FRU provided in the embodiments of the present invention. The storage medium may include various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0096] This document uses specific examples to illustrate the principles and implementation methods of the present invention, and the various embodiments are progressively related. Each embodiment focuses on the differences from other embodiments, and similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, please refer to the corresponding method section. The above description of the embodiments is only for the purpose of helping to understand the method and core ideas of the present invention. For those skilled in the art, several improvements and modifications can be made to the present invention without departing from the principles of the present invention, and these improvements and modifications also fall within the protection scope of the claims of the present invention.

[0097] It should also be noted that, in this specification, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes the element.

Claims

1. A method for identifying the presence of an FRU, characterized in that, include: After the server is powered on, it reads the bus number and slave address of the storage chip of the storage FRU that are pre-entered in the Linux system kernel device tree under the OpenBMC framework; Read the bus number and slave address of the EEPROM chip storing the FRU, which are pre-entered in the kernel device tree; read the IIC bus number and IIC slave address of the storage chip storing the FRU, which are pre-entered in the kernel device tree; The address of the memory chip is located using the bus number and the slave address; the address of the EEPROM chip is located using the bus number and the slave address; the address of the memory chip is located using the IIC bus number and the IIC slave address. An initialization command is sent to the memory chip according to the address; the initialization command is sent to the EEPROM chip according to the address; When the information indicating successful initialization of the storage chip is received, it is determined that the FRU is in place; a udev signal is sent to the device manager, and when the device manager detects the udev signal, a script is started to call the FRU information display program to display the information of the FRU.

2. A device for identifying the presence of an FRU, characterized in that, include: The read module is used to read the bus number and slave address of the storage chip of the storage FRU in the Linux system kernel device tree under the OpenBMC framework after the server is powered on. The first reading unit is used to read the IIC bus number and IIC slave address of the storage chip storing the FRU, which are pre-entered in the kernel device tree; The second reading unit is used to read the bus number and slave address of the EEPROM chip storing the FRU, which are pre-entered in the kernel device tree; A positioning module is used to locate the address of the memory chip using the bus number and the slave address; a first positioning unit is used to locate the address of the EEPROM chip using the bus number and the slave address; a second positioning unit is used to locate the address of the memory chip using the IIC bus number and the IIC slave address. The instruction sending module is used to send an initialization command to the memory chip according to the address; The first instruction sending unit is used to send the initialization command to the EEPROM chip according to the address; The presence determination module is used to determine that the FRU is in place when it receives information indicating that the memory chip has been successfully initialized; The information display module is used to send a udev signal to the device manager, so that when the device manager detects the udev signal, it starts a script to call the FRU information display program to display the information of the FRU.

3. A device for identifying the presence of an FRU, characterized in that, include: Memory, used to store computer programs; A processor for implementing the method for identifying the presence of an FRU as described in claim 1 when executing the computer program.

4. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, implement the method for identifying the presence of an FRU as described in claim 1.