CN115687217A - Method and system for managing hot plug of backplane equipment - Google Patents

Method and system for managing hot plug of backplane equipment Download PDF

Info

Publication number
CN115687217A
CN115687217A CN202211393381.5A CN202211393381A CN115687217A CN 115687217 A CN115687217 A CN 115687217A CN 202211393381 A CN202211393381 A CN 202211393381A CN 115687217 A CN115687217 A CN 115687217A
Authority
CN
China
Prior art keywords
interrupt
equipment
configuration space
backboard
host
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211393381.5A
Other languages
Chinese (zh)
Inventor
王殿卫
刘宝阳
赵凤鸣
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202211393381.5A priority Critical patent/CN115687217A/en
Publication of CN115687217A publication Critical patent/CN115687217A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention belongs to the technical field of backboard hot plug management, and particularly provides a method, a system and a server for managing hot plug of backboard equipment, wherein the method comprises the following steps: after the equipment on the back plate is hot plugged, the back plate sends interruption to the main control chip; the master control chip reads the in-place state of the equipment on the backboard after receiving the backboard interrupt, sets the in-place state of the equipment in the configuration space, and sends the interrupt to the host; after receiving the interruption of the main control chip, the host reads the in-place state of the equipment in the configuration space, controls the power supply of the equipment on the backboard according to the in-place state of the equipment and changes the position of the control LED in the corresponding configuration space; after the host computer finishes processing, sending an interrupt to the main control chip; and the main control chip receives the host interruption, and operates the LED on the corresponding backboard through the I2C after the control LED in the configuration space is found to be modified. The code amount in the implementation process is less, and the hardware implementation is simple.

Description

Method and system for managing hot plug of backplane equipment
Technical Field
The invention relates to the technical field of backboard hot plug management, in particular to a method and a system for managing hot plug of backboard equipment.
Background
The hard disk backplane is a circuit board used for accessing more hard disks, is generally applied to the field of servers, and is also used for building a personal storage system. The NVMe backboard can be used for mounting the hard disk of the NVMe protocol.
Hot plugging of a hard disk on a server is a normal phenomenon. PCIe hardware can support hot plug and realize basic functions of basic BAR space, application release of configuration space and the like.
Most of the existing manufacturers support these basic functions with hardware, but some auxiliary functions, such as power management of the backplane device, control of the LED lamp, and the like, are implemented only by the main control chip logic, and the Adaptor (referred to as a host in this application) cannot directly control the power, the LED lamp, and the like of the backplane slot. Some manufacturers register the main control chip as an SES device, so as to control the power supply and the LED lamps of the backplane slot by the host, but this will increase a lot of codes and complicate hardware design.
Disclosure of Invention
The invention discloses a method and a system for managing hot plug of a backboard device, which aim to solve the problems that auxiliary functions of power management of the backboard device, control of an LED lamp and the like are realized only by a main control chip, and a host cannot directly control a power supply and the LED lamp of a backboard slot.
The first aspect of the present invention provides a method for managing hot plug of a backplane device, comprising the following steps:
after the equipment on the back plate is hot plugged, the back plate sends interruption to the main control chip;
the master control chip reads the in-place state of the equipment on the backboard after receiving the backboard interrupt, sets the in-place state of the equipment in the configuration space, and sends the interrupt to the host;
after receiving the interruption of the main control chip, the host reads the in-place state of the equipment in the configuration space, controls the power supply of the equipment on the backboard according to the in-place state of the equipment and changes the position of the control LED in the corresponding configuration space;
after the host computer finishes processing, sending an interrupt to the main control chip;
and the main control chip receives the host interrupt, and operates the LED on the corresponding backboard through I2C after the main control chip finds that the position for controlling the LED in the configuration space is modified.
As a further limitation of the technical solution of the present invention, the step of the main control chip reading the in-place state of the device on the backplane after receiving the interrupt of the backplane, setting the in-place state of the device in the configuration space, and sending the interrupt to the host includes:
the main control chip receives the backboard interrupt;
setting a global bitmap according to an input interface with an interrupt, and clearing the received interrupt;
and after receiving the interrupt, reading the in-place state of the equipment on the backboard, setting the in-place state of the equipment in the configuration space, and sending the interrupt to the host.
As a further limitation of the technical solution of the present invention, the step of reading the in-place state of the device on the backplane, setting the in-place state of the device in the configuration space, and sending an interrupt to the host includes:
analyzing the interrupt input interface number according to the bitmap and finding a corresponding connector;
acquiring the in-place state of equipment mounted on the connector through I2C;
setting a register corresponding to the configuration space according to the portId of the hot plug equipment;
an interrupt is sent to the host.
As a further limitation of the technical solution of the present invention, after the step of receiving the host interrupt by the main control chip, the method includes:
setting a global bitmap according to an input interface with an interrupt, and clearing the received interrupt;
a configuration space found to be altered is detected.
As a further limitation of the technical solution of the present invention, the step of detecting and finding the modified configuration space includes:
analyzing the interrupted port group according to the bitmap; all ports in one port group have a shared configuration space;
and acquiring the port with the interrupt by reading the port state register in the configuration space.
As a further limitation of the technical solution of the present invention, the step of operating the LEDs on the corresponding back plate includes:
reading an LED state bit in a slot _ ctrl register in a configuration space where a port with an interrupt is located;
judging whether the status bit changes;
if yes, calling a callback function corresponding to the equipment and used for setting the state of the LED lamp to light;
if not, selecting the next device, and executing the following steps: and reading the LED state bit in the slot _ ctrl register in the configuration space where the port with the interrupt is located.
As a further limitation of the technical solution of the present invention, the method further comprises:
creating an interrupt service processing thread and initializing; the interrupt service processing thread is used for processing the backboard interrupt and the host interrupt;
and creating an LED control thread, wherein the LED control thread is used for controlling the state of the LED lamp.
As a further limitation of the technical solution of the present invention, the step of initializing the interrupt service processing thread includes:
reading a configuration file from a non-volatile storage medium;
converting the configuration file related to the connector into a structural body and mounting the structural body in a connector linked list;
converting the equipment-related configuration file into a structural body and mounting the structural body under a corresponding connector;
traversing all the connectors to call corresponding backboard initialization according to the backboard type hung on the connector and register various callback functions
Traversing all the devices to set the configuration space of the ports of the devices so that the devices support hot plug and unplug;
determining the in-place state of the equipment mounted on each connector through the I2C;
setting slot _ status and link _ status registers of a configuration space according to the in-place state of the equipment;
recording an event log according to an initialization result; finally, the next stage is entered, and the backboard interrupt and the host interrupt are processed.
In a second aspect, the technical solution of the present invention provides a system for managing hot plug of a backplane device, including a host, a main control chip, and a backplane, where the backplane is provided with a plurality of slots for connecting a hard disk;
the host is connected with the main control chip;
the main control chip is provided with a plurality of ports which are respectively connected with the slots on the back plate;
the system is managed by a method as described in the first aspect.
The interrupt service processing thread and the LED control thread are arranged in the main control chip.
In a third aspect, a technical solution of the present invention provides a server, where the server includes the system for managing hot plug of a backplane device according to the second aspect.
According to the technical scheme, the invention has the following advantages: after the hard disk is hot plugged and unplugged, the backboard can send an interrupt to inform the main control chip. The main control chip can access the back board through the I2C bus to acquire which hard disk is subjected to hot plug and then send the hard disk to the host through interruption. The host may perform power up and down operations on the slot, operate the LEDs, etc. after receiving the interrupt. The host process is completed and then the host chip is notified by an interrupt. The code amount in the implementation process is less, and the hardware implementation is simple. UBM, VPP, and even self-developed protocol backplanes can be supported, and multiple backplanes can be supported.
In addition, the invention has reliable design principle, simple structure and very wide application prospect.
Therefore, compared with the prior art, the invention has prominent substantive features and remarkable progress, and the beneficial effects of the implementation are also obvious.
Drawings
In order to more clearly illustrate the embodiments or technical solutions in the prior art of the present invention, the drawings used in the description of the embodiments or prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained based on these drawings without creative efforts.
FIG. 1 is a schematic flow diagram of a method of one embodiment of the invention.
Fig. 2 is a system architecture diagram of one embodiment of the present invention.
FIG. 3 is an overall flow diagram of a process device hot plug.
FIG. 4 is a flow chart for handling backplane interrupts.
FIG. 5 is a flow diagram of handling an adapter interrupt.
FIG. 6 is a flow diagram of initializing a hotPlugHdr thread.
Fig. 7 is a connector profile and effect diagram.
FIG. 8 is a Drive profile and effect diagram.
Detailed Description
Most of the existing manufacturers support these basic functions with hardware, but some auxiliary functions, such as power management of the backplane device, control of the LED lamp, and the like, are implemented only by the main control chip, and the Adaptor (referred to as a host in this application) cannot directly control the power, the LED lamp, and the like of the backplane slot. Some manufacturers register the main control chip as SES equipment, so as to control the power supply and the LED lamps of the backplane slot by the host, but this will increase a lot of codes and complicate the hardware design. In order to make those skilled in the art better understand the technical solution of the present invention, the technical solution in the embodiment of the present invention will be clearly and completely described below with reference to the drawings in the embodiment of the present invention, and it is obvious that the described embodiment is only a part of the embodiment of the present invention, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The Chinese and English notes are as follows:
PCIe (Peripheral Component Interconnect Express): a high speed serial computer expansion bus standard.
NVMe (Non Volatile Memory Express): is a logical device interface specification. For accessing non-volatile memory media attached via a PCIe bus.
BAR (Base Address Register): and a base address register storing a base address of the PEIe inner space.
Adaptor: this document refers specifically to hosts.
SES (Scsi Enclose Services): the chassis management protocol using the SCSI protocol.
Drive: the device inserted into the slot on the backplane is a Drive in the present application.
SlimeLane: a connection line has integrated therein a signal line for transmitting PEIe data and sideband signals such as I2C, interrupt signals, etc.
connector: a connector is provided.
I2C (Inter-Integrated Circuit): a simple, bi-directional two-wire synchronous serial bus developed by Philips corporation. It requires only two wires to transfer information between devices connected to the bus.
UBM (Universal Backplane Management): a backplane management protocol developed by blosson corporation.
VPP (visual pin port): a backplane management protocol developed by Intel corporation.
slot: this document refers specifically to the slots in the backplane that connect to the disks.
GPIO (General port input Output): the general purpose input/output, which only uses its input function in this document, is used to receive the interrupt sent from the backplane, and the input interface in this application is a GPIO.
Lane: a set of PCIe differential signal lines.
port: PCIe port, which is a logical concept having its own PCIe configuration space, may be composed of multiple lanes, and how many lanes may be configured through the configuration space, is specified herein.
DP (downlinks port): and (4) downloading a port.
group: herein, a logical combination of one or more ports, specifically PCIe group, is composed of 16 lanes, and has a common configuration space.
As shown in fig. 1, an embodiment of the present invention provides a method for managing hot plug of a backplane device, including the following steps:
step 1: after the equipment on the back plate is hot plugged, the back plate sends an interrupt to the main control chip;
step 2: the master control chip reads the in-place state of the equipment on the backboard after receiving the backboard interrupt, sets the in-place state of the equipment in the configuration space, and sends the interrupt to the host;
and 3, step 3: after receiving the interruption of the main control chip, the host reads the in-place state of the equipment in the configuration space, controls the power supply of the equipment on the backboard according to the in-place state of the equipment and changes the position of the control LED in the corresponding configuration space;
and 4, step 4: after the host processing is finished, sending an interrupt to the main control chip;
and 5: and the main control chip receives host interruption, and operates the LED on the corresponding backboard through I2C after the main control chip finds that the position for controlling the LED in the configuration space is modified.
After the hard disk is hot plugged and unplugged, the backboard can send an interrupt to inform the main control chip. The main control chip can access the back board through the I2C bus to acquire which hard disk is subjected to hot plug and then send the hard disk to the host through interruption. The host computer can control the power on and off of the slots on the backboard after receiving the interrupt, and change the state of the corresponding configuration space register, the host computer can inform the main control chip through the interrupt after processing, and the main control chip operates the corresponding LED on the backboard through the I2C when finding that the state of the configuration space register changes.
In some embodiments, the step of the main control chip reading the in-place state of the device on the backplane after receiving the backplane interrupt, setting the in-place state of the device in the configuration space, and sending the interrupt to the host includes:
step 21: the master control chip receives the backboard interrupt;
step 22: setting a global bitmap according to the GPIO with the interrupt, and clearing the received interrupt;
step 23: reading the in-place state of the equipment on the backboard, setting the in-place state of the equipment in the configuration space, and sending an interrupt to the host.
It should be further noted that the step of reading the in-place status of the device on the backplane, setting the in-place status of the device in the configuration space, and sending an interrupt to the host includes:
step 231: analyzing the interrupt GPIO number according to the bitmap and finding a corresponding connector;
step 232: acquiring the in-place state of equipment mounted on the connector through I2C;
step 233: setting a register corresponding to the configuration space according to the portId of the hot plug equipment;
step 234: an interrupt is sent to the host.
In some embodiments, the step 5, after the step of the master control chip receiving the host interrupt, includes:
step 51: setting a global bitmap according to the GPIO with the interrupt, and clearing the received interrupt;
step 52: a configuration space found to be altered is detected.
Accordingly, the step of detecting that the configuration space is found to be changed comprises:
step 521: analyzing the interrupted port group according to the bitmap; all ports in one port group have a common configuration space;
step 522: and acquiring the port with the interrupt by reading the port state register in the configuration space.
In step 5, the step of operating the LEDs on the corresponding back plate includes:
step 53: reading an LED state bit in a slot _ ctrl register in a configuration space where a port with an interrupt is located; judging whether the status bit changes;
if yes, go to step 54, if no, select the next equipment, go to step 53;
step 54: calling a callback function corresponding to the equipment and used for setting the state of the LED lamp to light;
it should be noted that, in some embodiments, the method further includes:
creating an interrupt service processing thread and initializing; the interrupt service processing thread is used for processing backboard interrupt and host interrupt;
and creating an LED control thread, wherein the LED control thread is used for controlling the state of the LED lamp.
Here, the step of initializing the interrupt service processing thread includes:
s01: reading a configuration file from a non-volatile storage medium;
s02: converting the configuration file related to the connector into a structural body and mounting the structural body in a linked list;
s03: converting the relevant configuration files of the equipment into structural bodies and mounting the structural bodies under the corresponding connectors;
s04: judging whether the connector is the last connector;
if yes, executing step S05, otherwise, executing step S06;
s05: circularly processing the backboard interrupt and the host interrupt;
s06: calling a corresponding back panel initialization function according to the back panel type of the connector;
s07: calling and registering various callback functions according to the type of the back plate of the connector;
s08: traversing all the devices to set the configuration space of the ports of the devices so that the devices support hot plug and unplug;
s09: determining the in-place state of the equipment mounted on each connector through I2C;
s10: setting slot _ status and link _ status registers of a configuration space according to the in-place state of the equipment;
s11: registering host interrupts of all devices;
s12: setting attribute information of GPIOs corresponding to the connectors;
s13: registering a backplane interrupt;
s14: recording an event log, and executing the step S04;
as shown in fig. 2, an embodiment of the present invention provides a system for managing hot plug of a backplane device, including an adapter, a main control chip, and a backplane, where the backplane is provided with a plurality of slots for connecting a hard disk;
the adapter is connected with the main control chip;
the main control chip is respectively connected with the slots on the back plate;
as shown in fig. 3, the hot plug management process of the system is as follows:
(1) The starting end of the whole process is hot plugging of equipment on the backboard. After hot plug, the backplane sends an interrupt (interrupt 1 in fig. 3) to the main control chip through GPIO;
(2) After receiving the interrupt, the main control chip reads the in-place state of the device on the backplane through the I2C. Then, the status of the bit is set by setting the status in the configuration space register, and an interrupt is sent to the Adaptor (interrupt 2 in fig. 3);
(3) The Adaptor reads the in-place state of the equipment in the configuration space after receiving the interrupt sent by the main control chip, and then controls the power supply of the equipment on the back plate and sets the state of a corresponding configuration space register according to the in-place state of the equipment;
(4) After the Adaptor completes the processing, an interrupt (interrupt 3 in fig. 3) is sent to the main control chip to tell the main control chip that the processing is completed;
(5) And the main control chip receives the interrupt sent by the adapter, and after the condition of the configuration space register is found to be changed, the LED on the corresponding backboard is operated through I2C.
In the management method provided by the application, the Adaptor controls the LED by changing a slot _ ctrl register, namely a slot _ ctrl register, in a configuration space of the device, and the main control chip finds that the slot _ ctrl register is changed and can operate the LED on the backplane through the I2C.
The Adaptor controls the power supply of the back panel slot to be directly controlled through a SlimeLane cable without passing through a main control chip.
In step (2), the main control chip is provided with an interrupt service processing thread, as shown in fig. 4, the flow of the main control chip processing the backplane interrupt is as follows:
(21) The master control chip receives the backboard interrupt;
(22) The interrupt service function sets a global bitmap according to the GPIO with the interrupt, and clears the received interrupt; waking up an interrupt service processing thread, wherein the interrupt service processing thread is a hotPlugHdr thread;
(23) Copying a global bitmap by the interrupt service processing thread;
(24) Clearing the global bitmap according to the copied bitmap;
(25) Analyzing the interrupt GPIO number according to the bitmap and finding a corresponding connector structure;
(26) Acquiring the in-place situation of a Drive hung by a connector through I2C according to the type of the backboard of the connector;
(27) Setting slot _ status and link _ status registers corresponding to PCIe configuration space according to the pirtID of the hot plug Drive;
(28) An interrupt is sent to the Adaptor.
It should be noted that (1) the hotPlugHdr thread is a resident thread and will always loop to wait for the backboard and the Adaptor interrupt service function to wake up and process the transaction;
(2) In the interrupt service function, only the global bitmap bit is set, the interrupt is cleared, and the hotPlugHdr thread is awakened without doing the same, so that the running time of the interrupt service function can be effectively reduced.
(3) The bitmap is an unsigned number of two 32 BITs, wherein each BIT of one 32-BIT number represents one GPIO interrupt, if a BIT is 0, the GPIO represented by the BIT does not receive the interrupt, and if the BIT is 1, the GPIO represented by the BIT receives the interrupt and needs to be processed. And the bitmap can merge multiple hot plug interrupts together for processing — when the same connector interrupts too much, all the interrupt service functions of the connector change the same bitmap bit. Another 32-digit number each bit represents an interrupt sent by the Adaptor;
(4) Because the bitmap is changed before the thread is awakened, and the hot plug Hdr firstly copies the global bitmap, the global bitmap is cleared according to the copied bitmap, if multiple hot plug interrupts occur in the running process of the hot plug Hdr, the hot plug Hdr can be ensured to execute the operation of inquiring the live state once again after the last interrupt, the final state of the Drive is ensured to be correct, the middle state is not ensured, and the guarantee is not needed. The interruption of other connectors caused by error cleaning can be effectively prevented by cleaning the global bitmap according to bits instead of completely clearing the whole bitmap. The Drive profile is shown in fig. 7.
As shown in fig. 5, in step (5), the interaction flow between the main control chip and the adapter is as follows:
(51) The main control chip receives an adapter interrupt;
(52) The interrupt service function sets a global bitmap according to the GPIO with the interrupt, and clears the received interrupt; waking up a hotPlugHdr thread;
(53) The hotPlugHdr thread copies the global bitmap;
(54) Clearing the global bitmap according to the copied bitmap;
(55) Analyzing the interrupted port group according to the bitmap; all ports in one port group have a shared configuration space; that is, which group has been interrupted is analyzed according to bitmap;
(56) Acquiring a port with interruption by reading a port state register in a configuration space; that is, which port has been interrupted is obtained through the port _ intr _ status register;
(57) A callback function provided by the OEM or a default logging event function is executed.
It should be noted that all ports in a group have a common configuration space, and the interrupt flag bit generated by the Adaptor and the port _ intr _ status register are all in the configuration space.
In step (57), the purpose of executing the OEM-provided callback function is actually a more control process for the backplane LEDs; an LEDCtrl thread is arranged in the main control chip, and the LED control process is as follows:
reading an LED state bit in a slot _ ctrl register in a configuration space where a port with an interrupt is located;
judging whether the status bit changes;
if yes, calling a callback function corresponding to the equipment and used for setting the state of the LED lamp to light;
if not, selecting the next device, and executing the step to judge whether the state bit changes;
it should be noted that, through the above, the state of the lamp on the backplane is set in the Adaptor processing process, that is, the LED state bit in the slot _ ctrl register in the configuration space is set, the LEDCtrl thread trains the bit in turn, and if the bit is changed, the set LED state callback function corresponding to the connector is called to light. Here, drive is stored in the circular linked list, so there is no case where the next Drive is empty.
During actual application, an interrupt service processing thread is established and initialized; the interrupt service processing thread is used for processing the backboard interrupt and the host interrupt; and creating an LED control thread, wherein the LED control thread is used for controlling the state of the LED lamp. The interrupt service processing thread, i.e. the hotlughdr thread and the LED control thread, i.e. the LEDCtrl thread, are disposed in the main control chip, and during initialization, as shown in fig. 6, the step of initializing the interrupt service processing thread includes:
s01: reading a configuration file from a nonvolatile storage medium;
s02: converting the configuration file related to the connector into a structural body and mounting the structural body in a linked list;
s03: converting the relevant configuration files of the equipment into structural bodies and mounting the structural bodies under the corresponding connectors;
s04: judging whether the connector is the last connector;
if yes, executing step S05, otherwise, executing step S06;
s05: circularly processing the backboard interrupt and the host interrupt;
s06: calling a corresponding back panel initialization function according to the back panel type of the connector;
s07: calling and registering various callback functions according to the type of the back plate of the connector;
s08: traversing all the devices to set the configuration space of the port of the device to enable the device to support hot plug;
s09: determining the in-place state of the equipment mounted on each connector through I2C;
s10: setting a slot state and a connection state register of a configuration space according to the in-place state of the equipment;
s11: registering host interrupts of all devices;
s12: setting attribute information of GPIOs corresponding to the connector;
s13: registering a backplane interrupt;
s14: recording an event log, and executing the step S04;
it should be noted that the reason why the partial initialization flow is placed in the hotPlugHdr thread is that the partial initialization requires a long time for using the I2C bus; the main control chip is much quicker than the starting time of the Adaptor, a slot _ status register and a link _ status register are arranged after the Drive state, and the host can read the two registers after starting, so that the Adaptor can conveniently display the in-place state; the reason why the GPIO supports the interrupt mask is that if the level is unstable, a large number of interrupts may occur at the same time, which causes a core of the main control chip to be always in the interrupt service function, and causes other threads to fail to work normally.
The related configuration file of the initialization thread is divided into two parts: the connector, drive configuration file and function are shown in fig. 7 and 8.
The partial implementation data structure is as follows:
Figure BDA0003932898220000181
Figure BDA0003932898220000191
wherein: the bplanemontornotor functions realize functions of obtaining Drive states, setting lamp states, obtaining disk types and the like of all back plate protocols.
Figure BDA0003932898220000192
Figure BDA0003932898220000201
The embodiment of the invention also provides a server, which comprises the system for managing the hot plug of the backplane device.
Although the present invention has been described in detail by referring to the drawings in connection with the preferred embodiments, the present invention is not limited thereto. Various equivalent modifications or substitutions can be made on the embodiments of the present invention by those skilled in the art without departing from the spirit and scope of the present invention, and these modifications or substitutions should be within the scope of the present invention/any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present disclosure and the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the appended claims.

Claims (10)

1. A method for managing hot plug of a backboard device is characterized by comprising the following steps:
after the equipment on the back plate is hot plugged, the back plate sends interruption to the main control chip;
the main control chip reads the in-place state of the equipment on the backboard after receiving the backboard interrupt, sets the in-place state of the equipment in the configuration space, and sends the interrupt to the host;
after receiving the interruption of the main control chip, the host reads the in-place state of the equipment in the configuration space, controls the power supply of the equipment on the backboard according to the in-place state of the equipment and changes the position of the control LED in the corresponding configuration space;
after the host computer finishes processing, sending an interrupt to the main control chip;
and the main control chip receives host interruption, and operates the LED on the corresponding backboard through I2C after the main control chip finds that the position for controlling the LED in the configuration space is modified.
2. The method of claim 1, wherein the step of the main control chip reading the in-place status of the device on the backplane after receiving the backplane interrupt, setting the in-place status of the device in the configuration space, and sending the interrupt to the host comprises:
the master control chip receives the backboard interrupt;
setting a global bitmap according to an input interface with an interrupt, and clearing the received interrupt;
reading the in-place state of the equipment on the backboard, setting the in-place state of the equipment in the configuration space, and sending an interrupt to the host.
3. The method of claim 2, wherein reading the in-place status of the devices on the backplane, setting the in-place status of the devices in the configuration space, and sending an interrupt to the host comprises:
analyzing the interrupt input interface number according to the bitmap and finding a corresponding connector;
acquiring the in-place state of equipment mounted on the connector through I2C;
setting a register corresponding to the configuration space according to the portId of the hot plug equipment;
an interrupt is sent to the host.
4. The method for managing hot plug of a backplane device as claimed in claim 1, wherein the step of the master chip receiving the host interrupt is followed by:
setting a global bitmap according to an input interface with an interrupt, and clearing the received interrupt;
a configuration space found to be altered is detected.
5. The method of claim 4, wherein the step of detecting the discovery of the changed configuration space comprises:
analyzing the interrupted port group according to the bitmap; all ports in one port group have a shared configuration space;
and acquiring the port with the interrupt by reading the port state register in the configuration space.
6. The method for managing hot plug of a backplane device according to claim 5, wherein the step of operating the LEDs on the corresponding backplane comprises:
reading an LED state bit in a slot _ ctrl register in a configuration space where a port with an interrupt is located;
judging whether the status bit changes;
if yes, calling a callback function corresponding to the equipment and used for setting the state of the LED lamp to light;
if not, selecting the next device, and executing the following steps: and reading the LED state bit in the slot _ ctrl register in the configuration space where the port with the interrupt is located.
7. The method for managing hot plug of a backplane device according to claim 1, further comprising:
creating an interrupt service processing thread and initializing; the interrupt service processing thread is used for processing the backboard interrupt and the host interrupt;
and creating an LED control thread, wherein the LED control thread is used for controlling the state of the LED lamp.
8. The method for managing hot plug of a backplane device according to claim 7, wherein the step of initiating the interrupt service handling thread comprises:
reading a configuration file from a nonvolatile storage medium;
converting the configuration file related to the connector into a structural body and mounting the structural body in a connector linked list;
converting the equipment related configuration files into structural bodies and mounting the structural bodies under the corresponding connector structural bodies;
calling a corresponding back panel initialization function according to the type of the back panel hung below the connector, registering various callback functions, and setting GPIO attribute information of the back panel initialization function and the callback functions;
traversing all the devices to set the configuration space of the port of the device to enable the device to support hot plug;
determining the in-place state of the equipment mounted on each connector through I2C;
setting slot _ status and link _ status registers of a configuration space according to the in-place state of the equipment;
recording an event log according to an initialization result, and finally entering the next stage: and circularly processing the backboard interrupt and the host interrupt.
9. A system for managing hot plug of backboard equipment is characterized by comprising a host, a main control chip and a backboard;
the back plate is provided with a plurality of slots for connecting the hard disk;
the host is connected with the main control chip;
the main control chip is provided with a plurality of ports which are respectively connected with the slots on the back plate;
the system performs backplane device hot plug management by the method of any of claims 1-8.
10. A server, comprising the system for managing hot plug of a backplane device of claim 9.
CN202211393381.5A 2022-11-08 2022-11-08 Method and system for managing hot plug of backplane equipment Pending CN115687217A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211393381.5A CN115687217A (en) 2022-11-08 2022-11-08 Method and system for managing hot plug of backplane equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211393381.5A CN115687217A (en) 2022-11-08 2022-11-08 Method and system for managing hot plug of backplane equipment

Publications (1)

Publication Number Publication Date
CN115687217A true CN115687217A (en) 2023-02-03

Family

ID=85049596

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211393381.5A Pending CN115687217A (en) 2022-11-08 2022-11-08 Method and system for managing hot plug of backplane equipment

Country Status (1)

Country Link
CN (1) CN115687217A (en)

Similar Documents

Publication Publication Date Title
US5802269A (en) Method and apparatus for power management of distributed direct memory access (DDMA) devices
US6813688B2 (en) System and method for efficient data mirroring in a pair of storage devices
US7412544B2 (en) Reconfigurable USB I/O device persona
CN107870882B (en) Data protocol for managing peripheral devices
RU2559765C2 (en) Using extended asynchronous data mover indirect data address words
US20090106471A1 (en) Apparatus and method for enumeration of processors during hot-plug of a compute node
US20050228924A1 (en) Expander device capable of persistent reservations and persistent affiliations
US20150074323A1 (en) Data bus host and controller switch
US20070005828A1 (en) Interrupts support for the KCS manageability interface
WO2021244194A1 (en) Register reading/writing method, chip, subsystem, register group, and terminal
US5454081A (en) Expansion bus type determination apparatus
EP0775959B1 (en) Method and apparatus for optimizing PCI interrupt binding and associated latency in extended/bridged PCI busses
US10846256B2 (en) Multi-endpoint device sideband communication system
CN213365380U (en) Server mainboard and server
US6799278B2 (en) System and method for processing power management signals in a peer bus architecture
JPH1069455A (en) Method for performing slave dma emulation on computer system bus
CN107145198B (en) Method for improving compatibility of server to hard disk and mainboard thereof
US11341076B2 (en) Hot-plugged PCIe device configuration system
US20060047858A1 (en) ROM scan memory expander
CN117349212A (en) Server main board and solid state disk insertion detection method thereof
CN115687217A (en) Method and system for managing hot plug of backplane equipment
JP4359618B2 (en) Configuration register access method, setting method, integrated circuit parts, computer system, product
US6108723A (en) System for implementing hardware automated control of burst mode data transfer over a communication link between devices operating in a block mode
CN115061958A (en) Hard disk identification method, identification system, storage medium and computer equipment
CN213365438U (en) Double-circuit server mainboard and server

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination