WO2015078215A1 - Device resource control method and apparatus - Google Patents

Device resource control method and apparatus Download PDF

Info

Publication number
WO2015078215A1
WO2015078215A1 PCT/CN2014/086100 CN2014086100W WO2015078215A1 WO 2015078215 A1 WO2015078215 A1 WO 2015078215A1 CN 2014086100 W CN2014086100 W CN 2014086100W WO 2015078215 A1 WO2015078215 A1 WO 2015078215A1
Authority
WO
WIPO (PCT)
Prior art keywords
processor
interrupt request
hot
offline
idle
Prior art date
Application number
PCT/CN2014/086100
Other languages
French (fr)
Chinese (zh)
Inventor
周超
陈奔
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2015078215A1 publication Critical patent/WO2015078215A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/40Bus structure
    • G06F13/4063Device-to-bus coupling
    • G06F13/4068Electrical coupling
    • G06F13/4081Live connection to bus, e.g. hot-plugging

Definitions

  • the processor needs to periodically receive an interrupt request to invoke the firmware program to perform hot swap operation of the device, and the current execution service of the processor needs to be repeated. Interruption, resulting in reduced processor efficiency.
  • a device resource control method is provided, which is applied to a multiprocessor system, wherein the multiprocessor system includes a first processor, and the method includes:
  • a request receiving module configured to receive a device hot plug request
  • a first interrupt generating module configured to: when the request receiving module receives the hot plug request of the device, generate a hot plug first interrupt request, and send the device to the first processor, so as to be
  • the first processor responds to the hot plugging of the first interrupt request by the device, invokes and executes the firmware program, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
  • the device hot plugging second interrupt request is used to trigger the idle processor to invoke and execute the firmware program to perform a hot plug operation of the device, where the idle processor is currently not executed in the multiprocessor system The processor of the business.
  • the processor online module is configured to detect an operation execution result of the hot swap operation of the device, or the operation execution result of the hot plug operation of the device is not detected within a preset time, generate a processor online interrupt request, and the processor goes online to interrupt the request.
  • the third processor is any processor in the multi-processor system capable of processing the processor online interrupt request .
  • a hot plug execution module configured to perform a device hot swap operation when the idle processor responds to the device hot plug second interrupt request sent by the first processor; the device hot plug second interrupt request is When the first processor receives the device hot plug first interrupt request, it responds to the device hot plugging the first interrupt request, and invokes and executes the firmware program generation.
  • the first operation execution module is configured to perform an operation of hot plugging the device when detecting that the device is offline successfully;
  • a second device online module configured to generate a device online interrupt request when the hot plug operation of the device is successfully performed, where the device online interrupt request is used to trigger the first processor or the fifth processor to The device is online, and the fifth processor is any processor in the multi-processor system capable of processing the device uplink request.
  • the present application provides a device resource control method and apparatus compared to the prior art.
  • the first processor receives the device hot plug first interrupt request, responding to the hot plugging of the first interrupt request by the device, by calling and executing the firmware program, generating a device hot plug second interrupt request is sent to the idle processor, idle
  • the processor responds to the device hot plugging the second interrupt request, and implements hot swap operation of the device by calling and executing the firmware program.
  • the hot swap operation of the device is performed by the idle processor, and the current execution of the service does not need to be repeatedly interrupted, thereby improving the operating efficiency of the processor.
  • the idle processor does not currently perform service execution, the hot swap operation of the device that is performed does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
  • FIG. 2 is a flowchart of another embodiment of a device resource control method according to an embodiment of the present application.
  • FIG. 6 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present disclosure.
  • FIG. 8 is a schematic structural diagram of another embodiment of a device resource control apparatus according to an embodiment of the present disclosure.
  • FIG. 9 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure.
  • FIG. 10 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure.
  • FIG. 11 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure.
  • FIG. 12 is a schematic structural diagram of an embodiment of a substrate management controller according to an embodiment of the present disclosure.
  • One of the main ideas of the present application may include:
  • the first processor When the first processor receives the device hot plug first interrupt request, responding to the hot plugging of the first interrupt request by the device, by calling and executing the firmware program, generating a device hot plug second interrupt request is sent to the idle processor, idle The processor responds to the device hot plugging the second interrupt request, and implements hot swap operation of the device by calling and executing the firmware program.
  • the hot swap operation of the device is performed by the idle processor. Therefore, the current execution of the service by the first processor does not need to be repeatedly interrupted, the service execution efficiency is ensured, the operating efficiency of the processor is improved, and the idle processor currently has no service execution, so the execution thereof is performed.
  • the hot swap operation of the device does not need to be interrupted repeatedly, so the efficiency of the processor is ensured, and the execution efficiency of the hot swap of the device is ensured.
  • the method can include the following steps:
  • Step 101 The first processor, in response to the device hot plugging the first interrupt request, receives the device hot plug first interrupt request.
  • the interrupt generation can be triggered by a hardware structure such as a south bridge hardware chip.
  • each processor can receive an interrupt request, and each processor can select whether to process an interrupt request according to its own operation.
  • the first processor is a processor in the multi-processing system that can process the device to hot plug the first interrupt request.
  • the first processor is a main processor that processes the device hot swap.
  • the first processor When receiving the hot interrupt first interrupt request, the first processor responds to the first interrupt request, that is, interrupts the current execution service, and performs interrupt processing.
  • the first processor performs interrupt processing, and other processors may also enter the interrupt until the first processor exits the interrupt processing.
  • Hot swapping refers to allowing users to remove and replace damaged devices without shutting down the system and cutting off the power, thus improving the system's ability to recover disasters in a timely manner, scalability, and flexibility.
  • the system needs to add or remove the device to control the device resources.
  • the types of hot plug mainly include heat addition and heat removal.
  • the first processor invokes and executes the firmware program, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
  • the second interrupt request is used to trigger the idle processor to invoke and execute the firmware program, and perform an operation of hot plugging of the device, where the idle processor is currently not processed in the multiprocessor system. Device.
  • the idle processor After receiving the hot plug second interrupt request, the idle processor responds to the hot swapping of the second interrupt request by the device, and performs a hot swap operation by calling and executing the firmware program.
  • the hot swap operation of the device executed by the idle processor includes the device power-on initialization or device power-off.
  • the firmware program refers to the program code that is solidified inside the integrated circuit, and is responsible for controlling and coordinating the functions of the integrated circuit, such as a BIOS (Basic Input Output System) program, which is a program that is solidified onto a chip on the main board of the computer. It includes an interrupt handler for handling device hot plug interrupt requests.
  • BIOS Basic Input Output System
  • the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
  • FIG. 2 is a flowchart of another embodiment of a device resource control method according to an embodiment of the present application.
  • the technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, and the method is The following steps can be included:
  • the board management controller sends a device hot plug first interrupt request to the first processor.
  • the device hot plugging first interrupt request may be generated after the baseboard manager or the service manager receives the device hot plug request.
  • the Baseboard Management Controller is a microcontroller on a computer motherboard, and may also be called a Service Processor (SP).
  • the baseboard manager is independent of the operating system and can monitor the hardware status of the multiprocessor system at any time.
  • the hot swapping of the first interrupt request of the device may also be triggered by a user operating a button on the motherboard or a button on the chassis, through a hardware structure such as a south bridge hardware chip.
  • the first processor invokes and executes a firmware program to generate a processor offline interrupt request.
  • the processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle processor.
  • the first processor or the second processor is a processor in the multiprocessor system capable of processing a processor offline interrupt request.
  • the processor that does not include any processor offline is used as an idle processor.
  • the processor that does not include itself and the service processing pressure is relatively small is taken as an idle processor.
  • the processor offline interrupt request is processed by any processor of the multiprocessor system capable of processing the processor offline interrupt request, and the processor capable of processing the processor offline interrupt request may be the first processor or the multiprocessor
  • the processor is not included in the system, and is defined as a second processor in the embodiment of the present application.
  • the offline line refers to the service migration. If any processor is offline, the service of any processor is migrated, and the processor can be migrated to another processor or device for execution, so that the processor is in an idle state in which the service is not executed. That is, as an idle processor.
  • the type of the interrupt triggered by the processor offline interrupt request may be SCI (System Configuration Interrupt).
  • the first processor when detecting that the idle processor is offline, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
  • the device When the idle processor is offline, the device generates a hot swap second interrupt request and sends it to the idle processor. At this time, the first processor exits the current interrupt processing, and when the device receives the hot plug first interrupt request, the breakpoint of the currently executed service continues to be executed.
  • the first processor generates a processor offline interrupt request, and generates a device hot swap second interrupt request, which can be understood as a process in which the first processor performs a nested interrupt. That is, the first processor responds to the device hot plugging the first interrupt request, that is, calls the firmware program, and generates a processor offline interrupt request by executing the firmware program. At this time, if the interrupt is generated, the first processor can process the processor.
  • the line interrupt request suspends the processing device hot swap interrupt request, and the processing processor offline interrupt request does not include any processor of its own offline, after which the first processor exits the processor offline interrupt request.
  • the interrupt processing continues the interrupt processing of the device hot swap interrupt request, thereby generating a device hot swap second interrupt request.
  • the first processor can also send the processor offline interrupt request to the second processor that can process the processor offline interrupt request for processing.
  • the processing of the processor offline interrupt request is performed by the operating system control processor of the multiprocessor system.
  • the first processor or the second processor uses any processor that does not include its own processor as the idle processor, it may first determine whether the current execution service meets the preset condition to determine whether the current execution service is not busy, when the current execution is performed. When the business is not busy, choose any processor to go offline.
  • the idle processor receives the device hot plug second interrupt request, responds to the device hot plugging the second interrupt request, invokes and executes the firmware program, and implements hot swap operation of the device.
  • the idle processor has no other service execution, so the hot swap operation of the device does not need to be interrupted repeatedly.
  • the hot swap operation of the device performed by the idle processor includes the device power-on initialization or device power-off operation, which is determined according to the hot plug type.
  • the hot-swap type When the hot-swap type is hot-removed, when the idle processor performs the hot-swap operation of the device, you need to ensure that the device is offline and the services in the device are migrated.
  • the device offline can be executed by the first processor or any processor, and will not be described again in the same way as the prior art.
  • the device When the hot-swap type is hot-added, when the device is hot-swapped, the device needs to be powered on, that is, the device is added to the device resource.
  • the device can be online by the first processor or any processor. The same technology will not be described again.
  • the device may also send a hot swap third interrupt request to the first processor.
  • the first processor in response to the device hot plugging the third interrupt request, invoking and executing the firmware program, can generate a processor online interrupt request.
  • the processor uplink interrupt request is used to trigger the first processor or the third processor to bring the idle processor online.
  • the first processor or the third processor is a processor in the multiprocessor system capable of processing the processor's online interrupt request.
  • the processor online interrupt request is processed by any processor of the multiprocessor system capable of processing the processor offline interrupt request, and the processor capable of processing the processor online interrupt request may be the first processor or the multiprocessor system.
  • the processor is not included in the first processor.
  • the embodiment of the present application is defined as a third processor.
  • the third processor and the second processor may be the same processor or different processors.
  • the type of the interrupt triggered by the device hot plugging the first interrupt request may be PMI or SMI.
  • the type of interrupt triggered by the processor's offline interrupt request can be SCI.
  • the operation of the first processor to invoke and execute the firmware program may further include determining whether the hot plug operation of the device is successfully executed, and the like, and identifying the user to notify the user. For example, it is marked by the on/off of the diode on the main board or the chassis.
  • the processor when the first processor responds to the hot plugging of the first interrupt request, the processor may generate a processor offline interrupt request, and trigger any processor that does not include the first processor to be an idle processor. Therefore, when the first processor generates the device hot plugging second request by executing the firmware program, the device hot plugging second request may be sent to the idle processor, because the device hot plug operation is performed by the idle processor, The current execution of a processor by a processor does not need to be repeatedly interrupted, thereby improving the efficiency of the processor.
  • the idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
  • the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
  • the idle processor Since the idle processor has no service execution and avoids the interrupt processing error, the processor is interrupted and cannot be exited, and the interrupt service is suspended indefinitely.
  • FIG. 3 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present application.
  • the technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, and the method The following steps can be included:
  • the first processor receives a processor offline interrupt request sent by the baseboard management controller.
  • the substrate management controller can be used to visually monitor the device resource configuration process.
  • the first processor responds to the processor offline interrupt request and will not include any of its own The processor is offline as an idle processor.
  • the first processor responds to the processor offline interrupt request and performs an interrupt handler such that any processor that does not include itself is taken offline as an idle processor.
  • the first processor can process the processor offline interrupt request as an example. In an actual application, the first processor may not process the processor offline interrupt request due to the current running condition. Interrupt processing is performed by any processor that can handle the processor's offline interrupt request.
  • the first processor receives the device hot plug first interrupt request sent by the baseboard management controller, and responds to the device hot plugging the first interrupt request.
  • the first processor when the first processor responds to the processor offline interrupt request, it may determine whether the current execution service meets a preset condition to determine whether the current execution service is not busy, when the current execution service is not busy, Take any processor that does not include itself as an idle processor.
  • the baseboard management controller can monitor the processing result of the processor offline interrupt request, and when the idle processor is offline, send the device hot plug first interrupt request to the first processor.
  • the first processor invokes and executes the firmware program, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
  • the device hot plugging a second interrupt request is used to trigger the idle processor to perform a hot swap operation of the device.
  • the device may be hot swapped for the third interrupt request to the first processor.
  • the first processor responds to the hot plugging of the third interrupt request by the device, invokes and executes the firmware program, and can detect the hot plug execution result of the device, determine whether the hot plug operation is successful, and identify.
  • the substrate management controller may obtain the hot plug execution result of the device identified by the first processor, and output prompt information through the visual interface to notify the user.
  • the processor online interrupt request may be generated.
  • the idle processor is brought online by the first processor or the third processor.
  • the first processor or the third processor is a processor in the multiprocessor system capable of processing the processor's online interrupt request.
  • the baseboard management controller may first generate a processor offline interrupt request, trigger the first processor to take any processor offline as an idle processor, and then generate a device hot plug first interrupt request.
  • the first processor is in response to the device hot plugging the first interrupt request, and the firmware program is invoked and executed as an interrupt handler of the device hot plugging the first interrupt request, thereby causing the first processor to generate the device hot swap second interrupt
  • the request is sent to the idle processor, and the idle processor calls and executes the firmware program to implement hot swap operation of the device. Since the device hot plug operation is performed by the idle processor, the current execution of the processor does not need to be repeatedly interrupted, thereby improving the operating efficiency of the processor.
  • the hot swap operation of the device can be controlled by the baseboard management controller, which facilitates the monitoring of the processing flow and enables visual monitoring.
  • the idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
  • the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
  • FIG. 4 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present application.
  • the technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, and the method The following steps can be included:
  • the first processor when receiving the device hot plug first interrupt request, responds to the device hot plugging the first interrupt request.
  • the device hot plug first interrupt request may be generated by the baseboard management controller.
  • the first processor is a processor in the multi-processing system that can process the device to hot plug the first interrupt request.
  • the first processor calls and executes the firmware program.
  • the first processor generates a device offline interrupt request when determining that the hot plug type is hot removal.
  • the device offline interrupt request is used to trigger the first processor or the fourth processor to bring the device offline.
  • the first processor or the fourth processor is a processor in the multiprocessor system capable of processing the device offline interrupt request.
  • the device offline interrupt request is processed by any processor in the multiprocessor system capable of being requested to go offline.
  • the processor capable of processing the processor offline interrupt request may be the first processor or the multiprocessor system. Does not include any processor of the first processor, in order to The description is convenient, and is defined as a fourth processor in the embodiment of the present application.
  • the fourth processor and the third processor or the second processor may be the same processor or different processors.
  • the device When the first processor detects that the device is offline, the device generates a hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
  • the idle processor responds to the device hot plugging the second interrupt request, calls and executes the firmware program, and performs device hot swap operation.
  • the device offline interrupt request may also be generated when the idle processor responds to the device hot plugging the second interrupt request, and when the device is offline, the device hot plug operation is performed.
  • the first processor when determining that the hot plug type is hot add, generates a device hot plug second interrupt request, and sends a second interrupt request to the idle processor.
  • the device online interrupt request is used to trigger the first processor or the fifth processor to bring the device online.
  • the first processor or the fifth processor is a processor in the multiprocessor system capable of processing the device's online interrupt request.
  • the device online interrupt request is processed by any processor of the multiprocessor system capable of processing the device online interrupt request, the processor capable of processing the device online interrupt request may be the first processor, or the first processor is not included in the multiprocessor system Any one of the processors is defined as a fifth processor in the embodiment of the present application for convenience of description.
  • the device resources can be used after the device is online.
  • the device online interrupt request may also be generated when the idle processor performs the device hot plug operation successfully.
  • the idle processor may be the first processor call When the firmware program is executed, a processor offline interrupt request is generated, and the first processor or the second processor responds to the processor offline interrupt request, and the processor is not included in any of its own processors.
  • the first processor determines that the idle processor is offline, the operation of step 403 or step 405 is performed.
  • the first processor may also generate a processor online interrupt request when detecting that the device of the idle processor is hot plugged with the third interrupt request.
  • the processor online interrupt request may be generated after determining that the device is successfully online.
  • the idle processor may be a baseboard management controller that generates a processor offline request, and the first processor or the second processor responds to the processor offline interrupt request, and does not include any of its own The processor is offline.
  • the baseboard management controller determines that the idle processor is offline, the generating device hot plugs the first interrupt request.
  • the substrate management controller may also generate a processor online interrupt request when detecting the operation execution result of the device hot plugging or the operation execution result of the device hot plugging is not detected within a preset time.
  • the processor online interrupt request may be generated by the first processor after receiving the device hot plug third interrupt request sent by the idle processor, in response to the device hot plugging the third interrupt request.
  • the type of interrupt triggered by the device online interrupt request and the device offline interrupt request may be PMI or SMI.
  • FIG. 5 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present application.
  • the technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the processor system includes a first processor, and the method includes The following steps can be included:
  • the baseboard management controller receives the device hot plug request.
  • the baseboard management controller generates a device hot plug first interrupt request and sends the first interrupt request to the first processor.
  • the first processor is responsive to the device hot plugging the first interrupt request, invoking and executing the firmware program, generating a device hot plug second interrupt request, and transmitting the device hot plug second interrupt request to the idle processor,
  • the device hot plugging a second interrupt request is used to trigger the idle processor to invoke and execute the firmware program to perform a hot plug operation of the device, where the idle processor is currently not executing services in the multiprocessor system Processor.
  • the processor management controller may also generate a processor offline interrupt request before receiving the device hot plug request.
  • the processor offline interrupt request may trigger the first processor or the second processor to not include Any processor that includes itself is offline as an idle processor.
  • the device hot plug third interrupt request may be generated to notify the first processor, and the first processor responds to the device hot plugging the third interrupt request to obtain the idle processor.
  • the execution result of the hot swap operation of the device and can be identified.
  • the operation result of the hot plug operation of the device detected by the substrate management controller may be obtained according to the identification result of the first processor, for example, the first processor indicates whether the execution result is illuminated by the LED, and the substrate management controller determines whether the LED is based on the LED When lit, the execution result of the hot plug operation of the device can be obtained.
  • the timeout mechanism can also be set. If the operation result of the hot plug operation of the device is not detected within the preset time, it can be determined that the operation of the hot plug operation of the device fails, and at this time, the idle processor of the first processor can be triggered. Wake up and trigger the idle processor to go online.
  • the baseboard management controller When the baseboard management controller detects the execution result of the hot plugging of the device, it can also output a prompt message.
  • the idle processor is responsive to the device hot plugging the second interrupt request.
  • the fifth processor is any processor in the multi-processor system capable of processing the device-on-line interrupt request.
  • the device can be triggered to go online, so that the system can use the device.
  • the first processor When the idle processor is obtained after the device resource control is performed, the first processor responds to the hot plugging of the third interrupt request by the device, and may also invoke and execute the solid state.
  • the program executes the operation that triggers the idle processor to go online.
  • the interrupt request sending module 702 is configured to send the device hot plug second interrupt request to the idle processor.
  • the interrupt request sending module 802 is configured to send the device hot plug second interrupt request to the idle processor.
  • the device When the hot-swap type is hot-added, when the device is hot-swapped, the device needs to be powered on, that is, the device is added to the device resource.
  • the device can be online by the first processor or any processor. The same technology will not be described again.
  • the device hot plug third interrupt request can also be generated.
  • the processor uplink interrupt request is used to trigger the first processor or the third processor to bring the idle processor online.
  • the idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
  • the idle processor can perform hot swap operation on the device at one time, and does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
  • the substrate management controller can detect the hot plug execution result of the device.
  • the interrupt request generating module 901 is configured to receive the device hot plugging first interrupt request.
  • the first device offline module 9011 is configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device.
  • the interrupt request generation sub-module 9012 is configured to: when detecting that the device is offline, generate a device hot plug second interrupt request, and send the device hot plug second interrupt to the idle processor request.
  • a processor offline module for generating a processor offline interrupt request.
  • the processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle processor.
  • the device offline module 9011 may specifically generate a device offline interrupt request when detecting that the idle processor is offline, or the interrupt request generation submodule 9012 Specifically, when it is detected that the device is offline, and the idle processor is offline, the device generates a hot plug second interrupt request.
  • the idle processor may be a baseboard management controller that generates a processor offline request, and the first processor or the second processor responds to the processor offline interrupt request, and does not include any of its own The processor is offline.
  • the baseboard management controller determines that the idle processor is offline, the generating device hot plugs the first interrupt request.
  • the interrupt request sending module 902 is configured to send the device hot plug second interrupt request to the idle processor.
  • the idle processor responds to the device hot plugging the second interrupt request, calls and executes the firmware program, and performs device hot swap operation.
  • the interrupt request generating module 1001 is configured to receive the device hot plugging first interrupt request.
  • the interrupt request sending module 1002 is configured to send the device hot plug second to the idle processor Interrupt the request.
  • the device when the hot plug type is hot added, the device may further include:
  • the first device online module 1003 is configured to generate a device online interrupt request when determining that the idle processor performs hot swap operation of the device, and the device online interrupt request is used to trigger the first processor or the first The five processors bring the device online.
  • the interrupt request generating module 1002 can include:
  • the processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle processor.
  • the interrupt request generation submodule is configured to generate a device hot plug second interrupt request when detecting that the idle processor is offline successfully.
  • the device can also include:
  • the substrate management controller may also generate a processor online interrupt request when detecting the operation execution result of the device hot plugging or the operation execution result of the device hot plugging is not detected within a preset time.
  • the processor uplink interrupt request may be after the first processor receives the device hot plug third interrupt request sent by the idle processor, and generates and sends the third interrupt request to the baseboard management controller in response to the hot swapping of the device. .
  • the device resource control device corresponding to the above FIG. 7 to FIG. 10 can be integrated into the solid in practical applications.
  • the firmware program is called and executed by the first processor, so that the device performs hot plug operation by the idle processor, and the current execution service of the first processor does not need to be repeatedly interrupted, thereby ensuring the operating efficiency of the processor.
  • the device hot swap operation performed by the idle processor does not need to be repeatedly interrupted, which ensures the execution efficiency of the device hot plug operation.
  • the embodiment of the present application further provides a firmware program, which includes the device resource control device described in any of the embodiments of FIG. 7 to FIG.
  • the request receiving module 1101 is configured to receive a device hot plug request
  • the first processor in response to the device hot plugging the first interrupt request, generates a device hot plug second interrupt request by calling and executing the firmware program, and sends the device hot plug second interrupt request to the idle processor.
  • the idle processor performs a hot plug operation of the device by calling and executing the firmware program in response to the device hot plugging the second interrupt request.
  • the device hot plug third interrupt request may be generated to notify the first processor, and the first processor responds to the device hot swap third interrupt.
  • the result of the operation of the hot swap operation of the idle processor device is obtained, and can be identified.
  • the operation result of the hot plug operation of the device detected by the processor online module may be obtained according to the identification result of the first processor, for example, the first processor displays the execution result with whether the LED is lit, and the substrate management controller is based on whether the LED is When lit, the execution result of the hot plug operation of the device can be obtained.
  • an embodiment of the present invention further provides a substrate management controller, where the substrate management controller may include:
  • a receiver 1201, configured to receive a device hot plug request
  • the controller 1202 is configured to generate a device hot plug first interrupt request, and send the first interrupt request to the first processor.
  • the first processor in response to the device hot plugging the first interrupt request, generates a device hot plug second interrupt request by calling and executing the firmware program, and sends the device hot plug second interrupt request to the idle processor.
  • the idle processor performs a hot plug operation of the device by calling and executing the firmware program in response to the device hot plugging the second interrupt request.
  • the idle processor is a processor in the multi-processor system that currently has no service to perform.
  • FIG. 13 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure.
  • the technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, where The device can include:
  • the hot plug execution module 1301 is configured to perform a hot plug operation of the device when the idle server responds to the device hot plug second interrupt request sent by the first processor.
  • the device hot plugging the second interrupt request is configured to: when the first processor receives the device hot plug first interrupt request, in response to the device hot plugging the first interrupt request, invoking and executing the firmware program generation.
  • the hot plug execution module performs hot swap operation of the device according to the type of hot plug.
  • the hot plug execution module 1301 may include:
  • the second device offline module 1311 is configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device, and the fourth processing
  • the processor is any processor in the multiprocessor system capable of processing the device offline interrupt request.
  • the first operation execution module 1321 is configured to perform an operation of hot plugging the device when detecting that the device is offline successfully.
  • the hot plug execution operation may include:
  • a second operation execution module 1331 configured to perform an operation of hot plugging of the device
  • the device may further send a device hot plug third interrupt request to the first processor.
  • the first processor responds to the hot plugging of the third interrupt request by the device, and may perform an interrupt processing such as obtaining an operation execution result of the device hot plug and performing identification, etc., by calling and executing the firmware program.
  • the first processor When the idle processor is obtained after the device resource control is performed, the first processor responds to the hot plugging of the third interrupt request by the device, and may also execute the trigger idle process by calling and executing the firmware program. The operation of the line.
  • the hot swap operation of the device is performed. Since the device hot plug operation is controlled by the idle processor, the first processor currently performs the service. There is no need to be interrupted repeatedly, which improves the operating efficiency of the processor, and the idle processor does not currently perform the service. Therefore, the hot swap operation of the device that is performed does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
  • the device resource control device corresponding to FIG. 13 above may be integrated into a firmware program in an actual application, and the firmware program is invoked and executed by an idle processor, thereby implementing a hot plug operation of the execution device, so that the current execution service of the first processor is performed.
  • the operation efficiency of the processor can be ensured without repeated interruptions, and the hot plug operation of the device is not required to be repeatedly interrupted, thereby ensuring the execution efficiency of the hot plug operation of the device.
  • the embodiment of the present application further provides a firmware program, which includes the device resource control device described in FIG.
  • the present application can be implemented by means of software plus a necessary general hardware platform. Based on such understanding, the technical solution of the present application may be embodied in the form of a software product in essence or in the form of a software product, which may be stored in a storage medium such as a ROM/RAM or a disk. , an optical disk, etc., includes instructions for causing a computer device (which may be a personal computer, server, or network device, etc.) to perform the methods described in various embodiments of the present application or portions of the embodiments.
  • a computer device which may be a personal computer, server, or network device, etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

Provided are a device resource control method and apparatus, which are applied to a multiprocessor system. The multiprocessor system comprises a first processor. The method comprises: when receiving a first interrupt request of a hot plug of a device, responding, by the first processor, to the first interrupt request of the hot plug of the device; invoking and executing, by the first processor, a firmware program, generating a second interrupt request of the hot plug of the device, and sending the second interrupt request of the hot plug of the device to an idle processor, wherein the second interrupt request of the hot plug of the device is used for triggering the idle processor to invoke and execute the firmware program, so as to execute an operation of the hot plug of the device, and the idle processor being a processor which is not currently executing a service in the multiprocessor system. By means of the embodiments of the present application, the operating efficiency of processors is increased.

Description

设备资源控制方法和装置Device resource control method and device
本申请要求于2013年11月27日提交中国专利局、申请号201310617818.3、发明名称为“设备资源控制方法和装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。The present application claims priority to Chinese Patent Application No. 201310617818.3, filed on Jan.
技术领域Technical field
本申请涉及计算机处理技术领域,更具体的说是涉及一种控制方法和装置。The present application relates to the field of computer processing technology, and more particularly to a control method and apparatus.
背景技术Background technique
在计算机系统中,设备资源包括内存、处理器、I/O卡、控制器以及其他节点等硬件资源,设备资源配置主要是指设备的添加、替换或升级等操作,其中,热插拔即是一种设备资源配置方式。In a computer system, a device resource includes a hardware resource such as a memory, a processor, an I/O card, a controller, and other nodes. The device resource configuration mainly refers to operations such as adding, replacing, or upgrading a device, wherein hot plugging is A device resource configuration method.
多处理器系统统是指包含多个处理器的计算机系统,由于多处理器系统规模庞大,对于设备的热插拔有更高的要求。A multi-processor system refers to a computer system that includes multiple processors. Due to the large size of a multi-processor system, there is a higher requirement for hot plugging of devices.
在进行设备热插拔时,系统中能够处理设备热插拔的处理器会中断当前执行业务,通过调用并执行固件程序来执行设备热插拔操作。但是由于多处理器系统中,对于热插拔要求很高,不能影响当前执行业务,因此处理器当前执行的业务不能中断时间太长。现有技术中是将处理器调用并执行固件程序执行设备热插拔的操作进行分片,切换成多个分片执行。处理器每接收到一个中断请求,即执行一个分片的操作。执行完成一个分片的操作后,保存当前执行进度并退出该中断,此时处理器可以恢复当前执行业务,同时由定时器控制,当到达预设时间后再向处理器发送中断请求,处理器则再次中断当前执行业务,继续调用固件程序以执行下一个分片的操作,如此循环往复,直至设备热插拔的操作执行完成。When the device is hot swapped, the processor in the system that can handle hot swapping of the device interrupts the current execution of the service, and performs hot plugging operation by calling and executing the firmware program. However, in a multi-processor system, the hot-swap requirement is high and cannot affect the current execution service, so the current execution of the processor cannot be interrupted for too long. In the prior art, the processor invoking and executing the firmware program execution device hot swap operation is sliced and switched into multiple slice executions. Each time the processor receives an interrupt request, it performs a slice operation. After performing a fragmentation operation, the current execution progress is saved and the interrupt is exited. At this time, the processor can resume the current execution service, and is controlled by the timer. After reaching the preset time, the processor sends an interrupt request to the processor. Then the current execution service is interrupted again, and the firmware program is continuously called to perform the operation of the next fragmentation, so that the operation of the hot plugging of the device is completed.
但是,在实现本发明的过程中,发明人发现,现有技术的这种控制方式,处理器需要定时接收中断请求以调用固件程序执行设备热插拔的操作,处理器当前执行业务需要被反复打断,导致处理器运行效率降低。However, in the process of implementing the present invention, the inventors have found that in the prior art control mode, the processor needs to periodically receive an interrupt request to invoke the firmware program to perform hot swap operation of the device, and the current execution service of the processor needs to be repeated. Interruption, resulting in reduced processor efficiency.
发明内容 Summary of the invention
有鉴于此,本申请提供了一种设备资源控制方法和装置,用以解决现有技术中处理器运行效率较低的技术问题。In view of this, the present application provides a device resource control method and apparatus for solving the technical problem that the processor is less efficient in the prior art.
为实现上述目的,本申请提供如下技术方案:To achieve the above objective, the present application provides the following technical solutions:
第一方面,提供了一种设备资源控制方法,应用于多处理器系统中,其中,所述多处理器系统包括第一处理器,所述方法包括:The first aspect provides a device resource control method, which is applied to a multiprocessor system, where the multiprocessor system includes a first processor, and the method includes:
所述第一处理器接收到设备热插拔第一中断请求,响应所述设备热插拔第一中断请求时,调用并执行固件程序,生成设备热插拔第二中断请求;Receiving, by the first processor, a device hot plugging first interrupt request, in response to the device hot plugging the first interrupt request, invoking and executing a firmware program, and generating a device hot plugging second interrupt request;
所述第一处理器向空闲处理器发送所述设备热插拔第二中断请求,其中,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The first processor sends the device hot plug second interrupt request to the idle processor, wherein the device hot plug second interrupt request is used to trigger the idle processor call and execute the firmware program, Performing a hot plug operation of the device, wherein the idle processor is a processor in the multiprocessor system that currently has no service execution.
在所述第一方面的第一种可能实现方式中,所述设备热插拔第一中断请求具体为基板管理控制器接收到设备热插拔请求时发送的。In the first possible implementation manner of the first aspect, the device hot plugging first interrupt request is specifically sent when the baseboard management controller receives the device hot plug request.
结合所述第一方面或所述第一方面的第一种可能实现方式,还提供了所述第一方面的第三种可能实现方式,所述调用并执行固件程序,生成设备热插拔第二中断请求,包括:In conjunction with the first aspect or the first possible implementation of the first aspect, a third possible implementation manner of the first aspect is further provided, the calling and executing a firmware program, generating a device hot plug Two interrupt requests, including:
调用并执行固件程序,生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;Calling and executing a firmware program to generate a processor offline interrupt request, the processor offline interrupt request for triggering the first processor or the second processor to disconnect any processor that does not include itself as idle processing The second processor is any processor in the multi-processor system capable of processing the processor offline interrupt request;
当检测到所述空闲处理器下线成功时,生成设备热插拔第二中断请求。When it is detected that the idle processor is offline, the generating device hot plugs the second interrupt request.
第二方面,提供了一种设备资源控制方法,应用于多处理器系统中,其中,所述多处理器系统包括第一处理器,所述方法包括:In a second aspect, a device resource control method is provided, which is applied to a multiprocessor system, wherein the multiprocessor system includes a first processor, and the method includes:
基板管理控制器接收设备热插拔请求;The baseboard management controller receives the device hot plug request;
所述基板管理控制器生成设备热插拔第一中断请求,并发送至所述第一处理器,以便于所述第一处理器响应该设备热插拔第一中断请求时,调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。 The baseboard management controller generates a device hot plug first interrupt request, and sends the first interrupt request to the first processor, so that the first processor invokes and executes the firmware when the first interrupt request is hot plugged in response to the device a program, the device hot plugs the second interrupt request, and sends the device hot plug second interrupt request to the idle processor, the device hot plugging the second interrupt request for triggering the idle processor call and executing The firmware program performs an operation of hot plugging of the device, wherein the idle processor is a processor in the multiprocessor system that currently has no service to perform.
在所述第二方面的第一种可能实现方式中,所述生成设备热插拔第一中断请求之前,所述方法还包括:In a first possible implementation of the second aspect, before the generating device hot plugs the first interrupt request, the method further includes:
所述基板管理控制器生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;The baseboard management controller generates a processor offline interrupt request, and the processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle process. The second processor is any processor in the multi-processor system capable of processing the processor offline interrupt request;
则所述生成设备热插拔第一中断请求后,所述方法还包括:After the generating device hot plugs the first interrupt request, the method further includes:
所述基板管理控制器检测到设备热插拔的操作执行结果,或者在预设时间内未检测到设备热插拔的操作执行结果,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线,所述第三处理器为所述多处理器系统中能够处理所述处理器上线中断请求的任一处理器。The substrate management controller detects an operation execution result of hot plugging of the device, or does not detect an operation execution result of hot plugging of the device within a preset time, generates a processor online interrupt request, and the processor performs an online interrupt request. The first processor or the third processor is triggered to bring the idle processor online, and the third processor is any processor in the multi-processor system capable of processing the processor online interrupt request.
第三方面,提供了一种设备资源控制方法,应用于多处理器系统中,其中,所述多处理器系统包括第一处理器,所述方法包括:In a third aspect, a device resource control method is provided, which is applied to a multiprocessor system, wherein the multiprocessor system includes a first processor, and the method includes:
空闲处理器响应所述第一处理器发送的设备热插拔第二中断请求,所述设备热插拔第二中断请求为所述第一处理器接收到设备热插拔第一中断请求,响应所述设备热插拔第一中断请求后,调用并执行固件程序生成的;The idle processor responds to the device hot plugged second interrupt request sent by the first processor, and the device hot plugs the second interrupt request to the first processor to receive the device hot plug first interrupt request, and the response After the device hot plugs the first interrupt request, the device is invoked and executed by the firmware program;
所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作。The idle processor invokes and executes the firmware program to perform a hot plug operation of the device.
第四方面,提供了一种设备资源控制装置,应用于多处理器系统中,其中,所述多处理系统包括第一处理器,所述装置包括:In a fourth aspect, a device resource control apparatus is provided for use in a multiprocessor system, wherein the multiprocessing system includes a first processor, and the apparatus includes:
中断请求生成模块,用于当所述第一处理器接收并响应设备热插拔第一中断请求时,生成设备热插拔第二中断请求;An interrupt request generating module, configured to: when the first processor receives and responds to the device hot plugging the first interrupt request, generating a device hot plugging second interrupt request;
中断请求发送模块,用于向空闲处理器发送所述中断请求生成模块生成的所述设备热插拔第二中断请求;An interrupt request sending module, configured to send, to the idle processor, the device hot plug second interrupt request generated by the interrupt request generating module;
其中,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The device hot plugging a second interrupt request is used to trigger the idle processor to invoke and execute a firmware program, and perform a device hot swap operation, where the idle processor is in the multiprocessor system, currently no The processor that performs the business.
在所述第四方面的第一种可能实现方式中,所述中断请求生成模块包括:In a first possible implementation manner of the fourth aspect, the interrupt request generating module includes:
处理器下线模块,用于生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器 下线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;a processor offline module for generating a processor offline interrupt request, the processor offline interrupt request for triggering the first processor or the second processor to not include any processor of its own The offline line is an idle processor, and the second processor is any processor in the multi-processor system capable of processing the processor offline interrupt request;
中断请求生成子模块,用于当检测到所述空闲处理器下线成功时,生成设备热插拔第二中断请求。The interrupt request generation submodule is configured to generate a device hot plug second interrupt request when detecting that the idle processor is offline successfully.
结合所述第四方面的第一种可能实现方式,还提供了所述第四方面的第二种可能实现方式,所述装置还包括:In conjunction with the first possible implementation of the fourth aspect, a second possible implementation manner of the fourth aspect is further provided, where the apparatus further includes:
处理器上线模块,用于当响应所述空闲处理器执行设备热插拔的操作结束时发送的设备热插拔第三中断请求时,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线,所述第三处理器为所述多处理器系统中能够处理所述处理器上线中断请求的任一处理器。a processor online module, configured to generate a processor online interrupt request when the device is hot plugged with a third interrupt request sent in response to the idle processor performing a hot plug operation of the device, where the processor is online for an interrupt request The first processor or the third processor is triggered to bring the idle processor online, and the third processor is any processor in the multi-processor system capable of processing the processor online interrupt request.
结合所述第四方面的上述任一种可能实现方式,还提供了所述第四方面的第三种可能实现方式,当热插拔类型为热移除时,所述中断请求生成模块包括:In conjunction with any of the foregoing possible implementations of the fourth aspect, a third possible implementation manner of the foregoing fourth aspect is further provided. When the hot plug type is hot removed, the interrupt request generating module includes:
第一设备下线模块:用于生成设备下线中断请求,所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线,所述第四处理器为所述多处理器系统中能够处理所述设备下线中断请求的任一处理器;a first device offline module: configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device, the fourth processor Any processor in the multiprocessor system capable of processing the device offline interrupt request;
中断请求生成子模块,用于当检测到所述设备下线成功时,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求。The interrupt request generation submodule is configured to: when detecting that the device is offline, generate a device hot plug second interrupt request, and send the device hot plug second interrupt request to the idle processor.
结合所述第四方面的上述任一种可能实现方式,还提供了所述第四方面的第四种可能实现方式,当热插拔类型为热添加时,所述装置还包括:In conjunction with any of the foregoing possible implementations of the fourth aspect, the fourth possible implementation manner of the fourth aspect is further provided. When the hot plug type is hot add, the device further includes:
第一设备上线模块,用于当确定所述空闲处理器执行设备热插拔的操作执行成功时,生成设备上线中断请求,所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线,所述第五处理器为所述多处理器系统中能够处理所述设备上线中断请求的任一处理器。a first device online module, configured to generate a device online interrupt request when determining that the idle processor performs hot swap operation of the device, the device online interrupt request is used to trigger the first processor or the fifth The processor brings the device online, and the fifth processor is any processor in the multiprocessor system capable of processing the device online interrupt request.
第五方面,提供了一种设备资源控制装置,应用于多处理器系统中,其中,所述多处理器系统包括第一处理器,所述装置包括:In a fifth aspect, a device resource control apparatus is provided for use in a multiprocessor system, wherein the multiprocessor system includes a first processor, and the apparatus includes:
请求接收模块,用于接收设备热插拔请求;a request receiving module, configured to receive a device hot plug request;
第一中断生成模块,用于当所述请求接收模块接收到所述设备热插拔请求时,生成设备热插拔第一中断请求,并发送至第一处理器,以便于所 述第一处理器响应该设备热插拔第一中断请求,调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。a first interrupt generating module, configured to: when the request receiving module receives the hot plug request of the device, generate a hot plug first interrupt request, and send the device to the first processor, so as to be The first processor responds to the hot plugging of the first interrupt request by the device, invokes and executes the firmware program, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor. The device hot plugging second interrupt request is used to trigger the idle processor to invoke and execute the firmware program to perform a hot plug operation of the device, where the idle processor is currently not executed in the multiprocessor system The processor of the business.
在所述第五方面的第一种可能实现方式中,所述装置还包括:In a first possible implementation manner of the fifth aspect, the device further includes:
处理器下线模块,用于生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;a processor offline module, configured to generate a processor offline interrupt request, where the processor offline interrupt request is used to trigger the first processor or the second processor to take off any processor that does not include itself An idle processor, the second processor being any processor in the multiprocessor system capable of processing the processor offline interrupt request;
处理器上线模块,用于检测到设备热插拔的操作执行结果,或者在预设时间内未检测到设备热插拔的操作执行结果,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线,所述第三处理器为所述多处理器系统中能够处理所述处理器上线中断请求的任一处理器。The processor online module is configured to detect an operation execution result of the hot swap operation of the device, or the operation execution result of the hot plug operation of the device is not detected within a preset time, generate a processor online interrupt request, and the processor goes online to interrupt the request. For triggering the first processor or the third processor to bring the idle processor online, and the third processor is any processor in the multi-processor system capable of processing the processor online interrupt request .
第六方面,提供一种设备资源控制装置,应用于多处理器系统中,其中,所述多处理系统包括第一处理器,所述装置包括:According to a sixth aspect, a device resource control apparatus is provided for use in a multiprocessor system, wherein the multiprocessing system includes a first processor, and the apparatus includes:
热插拔执行模块,用于当空闲处理器响应第一处理器发送的设备热插拔第二中断请求时,执行设备热插拔的操作;所述设备热插拔第二中断请求为所述第一处理器接收到设备热插拔第一中断请求时,响应所述设备热插拔第一中断请求,调用并执行固件程序生成的。a hot plug execution module, configured to perform a device hot swap operation when the idle processor responds to the device hot plug second interrupt request sent by the first processor; the device hot plug second interrupt request is When the first processor receives the device hot plug first interrupt request, it responds to the device hot plugging the first interrupt request, and invokes and executes the firmware program generation.
在所述第六方面的第一种可能实现方式中,当热插拔类型为热移除时,所述热插拔执行模块包括:In a first possible implementation manner of the sixth aspect, when the hot plug type is hot removal, the hot plug execution module includes:
第二设备下线模块,用于生成设备下线中断请求,所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线,所述第四处理器为所述多处理器系统中能够处理所述述设备下线中断请求的任一处理器;a second device offline module, configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device, the fourth processor Any processor in the multiprocessor system capable of processing the device offline interrupt request;
第一操作执行模块,用于当检测到设备下线成功时,执行设备热插拔的操作;或者,The first operation execution module is configured to perform an operation of hot plugging the device when detecting that the device is offline successfully; or
当热插拔类型为热添加时,所述第二中断响应模块包括:When the hot plug type is hot add, the second interrupt response module includes:
第二操作执行模块,用于执行设备热插拔的操作; a second operation execution module, configured to perform an operation of hot plugging of the device;
第二设备上线模块,用于当所述设备热插拔的操作执行成功时,生成设备上线中断请求,所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线,所述第五处理器为所述多处理器系统中能够处理所述述设备上线中断请求的任一处理器。a second device online module, configured to generate a device online interrupt request when the hot plug operation of the device is successfully performed, where the device online interrupt request is used to trigger the first processor or the fifth processor to The device is online, and the fifth processor is any processor in the multi-processor system capable of processing the device uplink request.
经由上述的技术方案可知,与现有技术相比,本申请提供了一种设备资源控制方法和装置。第一处理器接收到设备热插拔第一中断请求时,响应该设备热插拔第一中断请求,通过调用并执行固件程序,生成设备热插拔第二中断请求发送至空闲处理器,空闲处理器响应该设备热插拔第二中断请求,通过调用并执行固件程序,实现设备热插拔的操作。设备热插拔操作由空闲处理器执行,当前执行业务无需被反复中断,从而提高了处理器运行效率。且由于空闲处理器当前无业务执行,因此其执行的设备热插拔的操作无需被反复打断,保证了设备热插拔的执行效率。According to the technical solution described above, the present application provides a device resource control method and apparatus compared to the prior art. When the first processor receives the device hot plug first interrupt request, responding to the hot plugging of the first interrupt request by the device, by calling and executing the firmware program, generating a device hot plug second interrupt request is sent to the idle processor, idle The processor responds to the device hot plugging the second interrupt request, and implements hot swap operation of the device by calling and executing the firmware program. The hot swap operation of the device is performed by the idle processor, and the current execution of the service does not need to be repeatedly interrupted, thereby improving the operating efficiency of the processor. Moreover, since the idle processor does not currently perform service execution, the hot swap operation of the device that is performed does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
附图说明DRAWINGS
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据提供的附图获得其他的附图。In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings to be used in the embodiments or the prior art description will be briefly described below. Obviously, the drawings in the following description are only It is an embodiment of the present application, and those skilled in the art can obtain other drawings according to the provided drawings without any creative work.
图1为本申请实施例提供的一种设备资源控制方法一个实施例的流程图;FIG. 1 is a flowchart of an embodiment of a device resource control method according to an embodiment of the present application;
图2为本申请实施例提供的一种设备资源控制方法另一个实施例的流程图;2 is a flowchart of another embodiment of a device resource control method according to an embodiment of the present application;
图3为本申请实施例提供的一种设备资源控制方法又一个实施例的流程图;FIG. 3 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present disclosure;
图4为本申请实施例提供的一种设备资源控制方法又一个实施例的流程图;FIG. 4 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present disclosure;
图5为本申请实施例提供的一种设备资源控制方法又一个实施例的流程图;FIG. 5 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present disclosure;
图6为本申请实施例提供的一种设备资源控制方法又一个实施例的流程图; FIG. 6 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present disclosure;
图7为本申请实施例提供的一种设备资源控制装置一个实施例的结构示意图;FIG. 7 is a schematic structural diagram of an apparatus resource control apparatus according to an embodiment of the present disclosure;
图8为本申请实施例提供的一种设备资源控制装置另一个实施例的结构示意图;FIG. 8 is a schematic structural diagram of another embodiment of a device resource control apparatus according to an embodiment of the present disclosure;
图9为本申请实施例提供的一种设备资源控制装置又一个实施例的结构示意图;FIG. 9 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure;
图10为本申请实施例提供的一种设备资源控制装置又一个实施例的结构示意图;FIG. 10 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure;
图11为本申请实施例提供的一种设备资源控制装置又一个实施例的结构示意图;FIG. 11 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure;
图12为本申请实施例提供的一种基板管理控制器一个实施例的结构示意图;FIG. 12 is a schematic structural diagram of an embodiment of a substrate management controller according to an embodiment of the present disclosure;
图13为本申请实施例提供的一种设备资源控制装置又一个实施例的结构示意图。FIG. 13 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure.
具体实施方式detailed description
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application are clearly and completely described in the following with reference to the drawings in the embodiments of the present application. It is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments of the present application without departing from the inventive scope are the scope of the present application.
本申请的主要思想之一可以包括:One of the main ideas of the present application may include:
第一处理器接收到设备热插拔第一中断请求时,响应该设备热插拔第一中断请求,通过调用并执行固件程序,生成设备热插拔第二中断请求发送至空闲处理器,空闲处理器响应该设备热插拔第二中断请求,通过调用并执行固件程序,实现设备热插拔的操作。设备热插拔操作由空闲处理器执行,因此第一处理器当前执行业务无需被反复中断,保证了业务执行效率,提高了处理器运行效率,且空闲处理器当前无业务执行,因此其执行的设备热插拔的操作也无需被反复打断,因此在保证处理器运行效率的同时,保证了设备热插拔的执行效率。When the first processor receives the device hot plug first interrupt request, responding to the hot plugging of the first interrupt request by the device, by calling and executing the firmware program, generating a device hot plug second interrupt request is sent to the idle processor, idle The processor responds to the device hot plugging the second interrupt request, and implements hot swap operation of the device by calling and executing the firmware program. The hot swap operation of the device is performed by the idle processor. Therefore, the current execution of the service by the first processor does not need to be repeatedly interrupted, the service execution efficiency is ensured, the operating efficiency of the processor is improved, and the idle processor currently has no service execution, so the execution thereof is performed. The hot swap operation of the device does not need to be interrupted repeatedly, so the efficiency of the processor is ensured, and the execution efficiency of the hot swap of the device is ensured.
图1为本申请实施例提供的一种设备资源控制方法一个实施例的流程 图,本申请实施例技术方案具体应用于多处理器系统中,多处理器系统包含两台或多台功能相近的处理器,处理器之间彼此可以交换数据,所有处理器共享内存,I/O设备,控制器,及外部设备等设备资源,整个多处理器系统由统一的操作系统控制,该多处理器系统中包括第一处理器。FIG. 1 is a flowchart of an embodiment of a device resource control method according to an embodiment of the present disclosure The technical solution of the embodiment of the present application is specifically applied to a multi-processor system. The multi-processor system includes two or more processors with similar functions, and the processors can exchange data with each other, and all processors share memory, I/. O device, controller, and external device resources, the entire multiprocessor system is controlled by a unified operating system, and the multiprocessor system includes a first processor.
该方法可以包括以下几个步骤:The method can include the following steps:
101:第一处理器接收到设备热插拔第一中断请求时,响应所述设备热插拔第一中断请求。Step 101: The first processor, in response to the device hot plugging the first interrupt request, receives the device hot plug first interrupt request.
当需要进行设备热插拔操作时,可以通过例如南桥硬件芯片等硬件结构触发中断产生。When a device hot swap operation is required, the interrupt generation can be triggered by a hardware structure such as a south bridge hardware chip.
在多处理器系统中,每一处理器均可以接收到中断请求,各个处理器可以根据自身运行情况,选择是否处理中断请求。In a multiprocessor system, each processor can receive an interrupt request, and each processor can select whether to process an interrupt request according to its own operation.
因此第一处理器即为多处理系统中可以处理设备热插拔第一中断请求的处理器。Therefore, the first processor is a processor in the multi-processing system that can process the device to hot plug the first interrupt request.
该第一处理器即是处理设备热插拔的主处理器。The first processor is a main processor that processes the device hot swap.
第一处理器接收到设备热插拔第一中断请求时,响应该第一中断请求,即中断当前执行业务,进行中断处理。When receiving the hot interrupt first interrupt request, the first processor responds to the first interrupt request, that is, interrupts the current execution service, and performs interrupt processing.
第一处理器进行中断处理,其他处理器也可能进入中断,直至第一处理器退出该中断处理。The first processor performs interrupt processing, and other processors may also enter the interrupt until the first processor exits the interrupt processing.
热插拔是指允许用户在不关闭系统,不切断电源的情况下取出和更换损坏的设备,从而提高系统对灾难的及时恢复能力、扩展性和灵活性等。而设备进行热插拔时,系统需要在设备资源中添加或移除该设备,实现对设备资源的控制。Hot swapping refers to allowing users to remove and replace damaged devices without shutting down the system and cutting off the power, thus improving the system's ability to recover disasters in a timely manner, scalability, and flexibility. When the device is hot swapped, the system needs to add or remove the device to control the device resources.
本实施例中,热插拔的类型主要包括热添加和热移除。In this embodiment, the types of hot plug mainly include heat addition and heat removal.
102:第一处理器调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送该设备热插拔第二中断请求。102: The first processor invokes and executes the firmware program, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
所述第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The second interrupt request is used to trigger the idle processor to invoke and execute the firmware program, and perform an operation of hot plugging of the device, where the idle processor is currently not processed in the multiprocessor system. Device.
本实施例中,第一处理器进行中断处理时,是调用固件程序进行。第一处理器通过执行该固件程序,触发第一处理器生成第二设备热插拔第二中断请求,并向空闲处理器发送设备热插拔第二中断请求。第一处理器向 空闲处理器发送设备热插拔第二中断请求后,即会退出当前中断处理,恢复当前执行业务。In this embodiment, when the first processor performs the interrupt processing, the firmware program is called. The first processor, by executing the firmware program, triggers the first processor to generate a second device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor. First processor After the idle processor sends the device hot swap second interrupt request, it will exit the current interrupt processing and resume the current execution service.
空闲处理器接收到该设备热插拔第二中断请求后,响应该设备热插拔第二中断请求,通过调用并执行固件程序,执行设备热插拔的操作。After receiving the hot plug second interrupt request, the idle processor responds to the hot swapping of the second interrupt request by the device, and performs a hot swap operation by calling and executing the firmware program.
空闲处理器执行的设备热插拔的操作包括设备上电初始化或设备下电等操作。The hot swap operation of the device executed by the idle processor includes the device power-on initialization or device power-off.
固件程序是指固化在集成电路内部的程序代码,负责控制和协调集成电路的功能,例如BIOS(Basic Input Output System,基本输入输出系统)程序,是固化到计算机内主板上一个芯片上的程序,其包括用于处理设备热插拔中断请求的中断处理程序。The firmware program refers to the program code that is solidified inside the integrated circuit, and is responsible for controlling and coordinating the functions of the integrated circuit, such as a BIOS (Basic Input Output System) program, which is a program that is solidified onto a chip on the main board of the computer. It includes an interrupt handler for handling device hot plug interrupt requests.
其中,本申请实施例中,该设备热插拔第一中断请求触发的中断的类型可以是PMI(Platform Management Interrupt,平台管理中断)或SMI(System Management Interrupt,系统管理中断),该设备热插拔第二中断请求触发的中断的类型可以为IPI(Inter-Processor Interrupt,处理器间中断)。In the embodiment of the present application, the type of the interrupt triggered by the hot plugging of the first interrupt request may be a PMI (Platform Management Interrupt) or an SMI (System Management Interrupt), and the device is hot plugged. The type of interrupt triggered by the second interrupt request may be IPI (Inter-Processor Interrupt).
在本实施例中,第一处理器响应设备热插拔第一中断请求时,调用并执行固件程序,此时并不是由第一处理器执行设备热插拔操作,而是生成设备热插拔第二中断请求,发送至空闲处理器。由空闲处理器响应该设备热插拔第二中断请求,执行设备热插拔操作,第一处理器即退出中断处理,可以恢复其中断的执行业务。由于设备热插拔操作由空闲处理器执行,第一处理器当前执行业务无需被反复中断,从而提高了处理器运行效率。In this embodiment, when the first processor responds to the hot plugging of the first interrupt request by the device, the firmware program is invoked and executed. At this time, the hot swap operation of the device is not performed by the first processor, but the device is hot swapped. The second interrupt request is sent to the idle processor. The idle processor responds to the hot plugging of the second interrupt request by the idle processor to perform a hot swap operation of the device, and the first processor exits the interrupt processing, and the interrupted execution service can be resumed. Since the device hot plug operation is performed by the idle processor, the first processor currently performs the service without being repeatedly interrupted, thereby improving the processor operating efficiency.
空闲处理器没有业务执行,不会影响整个系统的运行效率,因此还可以提高整个系统运行效率。The idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
且由于空闲处理器没有业务执行,因此可以一次执行完成对设备热插拔的操作,也无需被反复打断,保证了设备热插拔的执行效率。Because the idle processor has no service execution, the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
图2为本申请实施例中一种设备资源控制方法另一个实施例的流程图,本申请实施例技术方案具体应用于多处理器系统中,该多处理器系统包括第一处理器,该方法可以包括以下几个步骤:2 is a flowchart of another embodiment of a device resource control method according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, and the method is The following steps can be included:
201:第一处理器接收到设备热插拔第一中断请求时,响应所述设备热插拔第一中断请求。201: When the first processor receives the device hot plug first interrupt request, responding to the device hot plugging the first interrupt request.
其中,为了方便对设备热插拔的触发和监控,本实施例中可以通过基 板管理控制器向第一处理器发送设备热插拔第一中断请求。该设备热插拔第一中断请求可以是基板管理器或服务管理器接收到设备热插拔请求后生成的。In this embodiment, in order to facilitate the triggering and monitoring of hot swapping of the device, The board management controller sends a device hot plug first interrupt request to the first processor. The device hot plugging first interrupt request may be generated after the baseboard manager or the service manager receives the device hot plug request.
基板管理控制器(BMC,Baseboard management controller)是计算机主板上的微控制器,也可以称为管理处理器(SP,Service Processor)。基板管理器独立于操作系统,可以监控多处理器系统在任何时刻的硬件状态。The Baseboard Management Controller (BMC) is a microcontroller on a computer motherboard, and may also be called a Service Processor (SP). The baseboard manager is independent of the operating system and can monitor the hardware status of the multiprocessor system at any time.
基板管理控制器一般都包括操作界面,用户可以通过操作界面触发设备热插拔的操作,并对其进行控制,操作性强,从而实现可视化监控。The substrate management controller generally includes an operation interface, and the user can trigger the hot plug operation of the device through the operation interface, and control the operation, and the operation is strong, thereby realizing visual monitoring.
当然该设备热插拔第一中断请求也可以是通过用户操作主板上的按键或机框上的按钮,通过南桥硬件芯片等硬件结构来触发。Of course, the hot swapping of the first interrupt request of the device may also be triggered by a user operating a button on the motherboard or a button on the chassis, through a hardware structure such as a south bridge hardware chip.
202:第一处理器调用并执行固件程序,生成处理器下线中断请求。202: The first processor invokes and executes a firmware program to generate a processor offline interrupt request.
所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器。The processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle processor.
第一处理器或第二处理器为多处理器系统中能够处理处理器下线中断请求的处理器。其中将不包括自身的任一处理器下线作为空闲处理器具体可以将不包括自身的,且业务处理压力相对较小的处理器下线作为空闲处理器。The first processor or the second processor is a processor in the multiprocessor system capable of processing a processor offline interrupt request. The processor that does not include any processor offline is used as an idle processor. Specifically, the processor that does not include itself and the service processing pressure is relatively small is taken as an idle processor.
处理器下线中断请求由多处理器系统任意一个能够处理处理器下线中断请求的处理器处理,该能够处理处理器器下线中断请求的处理器可能是第一处理器,或者多处理器系统中不包括第一处理器的任意一个处理器,为了描述方便,本申请实施例中定义为第二处理器。The processor offline interrupt request is processed by any processor of the multiprocessor system capable of processing the processor offline interrupt request, and the processor capable of processing the processor offline interrupt request may be the first processor or the multiprocessor The processor is not included in the system, and is defined as a second processor in the embodiment of the present application.
其中,下线是指业务迁移,将任一处理器下线即是将任一处理器的业务进行迁移,可以迁移到其他处理器或设备执行,使得该处理器处于不执行业务的空闲状态,即作为空闲处理器。The offline line refers to the service migration. If any processor is offline, the service of any processor is migrated, and the processor can be migrated to another processor or device for execution, so that the processor is in an idle state in which the service is not executed. That is, as an idle processor.
其中,该处理器下线中断请求触发的中断的类型可以为SCI(System Configuration Interrupt,系统配置中断)。The type of the interrupt triggered by the processor offline interrupt request may be SCI (System Configuration Interrupt).
203:第一处理器当检测到所述空闲处理器下线成功时,生成设备热插拔第二中断请求,并向所述空闲处理器发送该设备热插拔第二中断请求。203: The first processor, when detecting that the idle processor is offline, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
当空闲处理器下线成功时,即生成设备热插拔第二中断请求,发送至空闲处理器。此时第一处理器即退出当前中断处理,返回接收到设备热插拔第一中断请求时,当前执行业务的断点继续执行。 When the idle processor is offline, the device generates a hot swap second interrupt request and sends it to the idle processor. At this time, the first processor exits the current interrupt processing, and when the device receives the hot plug first interrupt request, the breakpoint of the currently executed service continues to be executed.
第一处理器生成处理器下线中断请求,以及生成设备热插拔第二中断请求,可以理解成第一处理器执行嵌套中断的过程。即第一处理器响应设备热插拔第一中断请求,即调用固件程序,通过执行固件程序生成处理器下线中断请求,此时由于有中断产生,若第一处理器可以处理该处理器下线中断请求,则暂停处理设备热插拔中断请求,而处理处理器下线中断请求,将不包括自身的任一处理器下线,之后第一处理器即退出该处理器下线中断请求的中断处理,继续设备热插拔中断请求的中断处理,从而生成设备热插拔第二中断请求。The first processor generates a processor offline interrupt request, and generates a device hot swap second interrupt request, which can be understood as a process in which the first processor performs a nested interrupt. That is, the first processor responds to the device hot plugging the first interrupt request, that is, calls the firmware program, and generates a processor offline interrupt request by executing the firmware program. At this time, if the interrupt is generated, the first processor can process the processor. The line interrupt request suspends the processing device hot swap interrupt request, and the processing processor offline interrupt request does not include any processor of its own offline, after which the first processor exits the processor offline interrupt request. The interrupt processing continues the interrupt processing of the device hot swap interrupt request, thereby generating a device hot swap second interrupt request.
当然第一处理器还可以将该处理器下线中断请求发送至可以处理处理器下线中断请求的第二处理器进行处理。Of course, the first processor can also send the processor offline interrupt request to the second processor that can process the processor offline interrupt request for processing.
处理器下线中断请求的处理由多处理器系统的操作系统控制处理器执行。The processing of the processor offline interrupt request is performed by the operating system control processor of the multiprocessor system.
第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器时,可以先判断当前执行业务是否满足预设条件,以确定当前执行业务是否不繁忙,当当前执行业务不繁忙时,再选择任一处理器下线。When the first processor or the second processor uses any processor that does not include its own processor as the idle processor, it may first determine whether the current execution service meets the preset condition to determine whether the current execution service is not busy, when the current execution is performed. When the business is not busy, choose any processor to go offline.
空闲处理器接收到设备热插拔第二中断请求,响应该设备热插拔第二中断请求,调用并执行该固件程序,实现设备热插拔的操作。空闲处理器无其他业务执行,因此设备热插拔的操作无需被反复打断。The idle processor receives the device hot plug second interrupt request, responds to the device hot plugging the second interrupt request, invokes and executes the firmware program, and implements hot swap operation of the device. The idle processor has no other service execution, so the hot swap operation of the device does not need to be interrupted repeatedly.
空闲处理器执行的设备热插拔的操作包括设备上电初始化或设备下电操作,根据热插拔类型不同而确定。The hot swap operation of the device performed by the idle processor includes the device power-on initialization or device power-off operation, which is determined according to the hot plug type.
热插拔类型为热移除时,空闲处理器执行设备热插拔的操作时,需要保证设备已经下线,即将该设备中的业务进行迁移。设备下线可以由第一处理器或任一处理器执行,与现有技术相同不再赘述。When the hot-swap type is hot-removed, when the idle processor performs the hot-swap operation of the device, you need to ensure that the device is offline and the services in the device are migrated. The device offline can be executed by the first processor or any processor, and will not be described again in the same way as the prior art.
热插拔类型为热添加时,设备热插拔的操作执行成功时,需要将设备上线,即将设备添加至设备资源中,设备上线可以由第一处理器或任一处理器执行,与现有技术相同不再赘述。When the hot-swap type is hot-added, when the device is hot-swapped, the device needs to be powered on, that is, the device is added to the device resource. The device can be online by the first processor or any processor. The same technology will not be described again.
其中,空闲处理器执行设备热插拔的操作完成时,还可以向第一处理器发送设备热插拔第三中断请求。When the idle processor performs hot swap operation of the device, the device may also send a hot swap third interrupt request to the first processor.
第一处理器响应该设备热插拔第三中断请求,调用并执行固件程序,可以生成处理器上线中断请求。该处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线。 The first processor, in response to the device hot plugging the third interrupt request, invoking and executing the firmware program, can generate a processor online interrupt request. The processor uplink interrupt request is used to trigger the first processor or the third processor to bring the idle processor online.
第一处理器或第三处理器为多处理器系统中能够处理该处理器上线中断请求的处理器。The first processor or the third processor is a processor in the multiprocessor system capable of processing the processor's online interrupt request.
处理器上线中断请求由多处理器系统任意一个能够处理处理器下线中断请求的处理器处理,该能够处理处理器器上线中断请求的处理器可能是第一处理器,或者多处理器系统中不包括第一处理器的任意一个处理器,为了描述方便,本申请实施例中定义为第三处理器。The processor online interrupt request is processed by any processor of the multiprocessor system capable of processing the processor offline interrupt request, and the processor capable of processing the processor online interrupt request may be the first processor or the multiprocessor system. The processor is not included in the first processor. For the convenience of description, the embodiment of the present application is defined as a third processor.
该第三处理器与该第二处理器可能为同一处理器或者不同的处理器。The third processor and the second processor may be the same processor or different processors.
其中,该设备热插拔第一中断请求触发的中断的类型可以是PMI或SMI。The type of the interrupt triggered by the device hot plugging the first interrupt request may be PMI or SMI.
该处理器下线中断请求触发的中断的类型可以为SCI。The type of interrupt triggered by the processor's offline interrupt request can be SCI.
当然,第一处理器调用并执行固件程序的操作,还可以包括判断设备热插拔的操作是否执行成功等,并进行标识以通知用户。例如通过主板或机框上的二极管的亮灭进行标识。Certainly, the operation of the first processor to invoke and execute the firmware program may further include determining whether the hot plug operation of the device is successfully executed, and the like, and identifying the user to notify the user. For example, it is marked by the on/off of the diode on the main board or the chassis.
在本实施例中,第一处理器响应设备热插拔第一中断请求时,可以生成处理器下线中断请求,触发将不包括第一处理器的任一处理器下线作为空闲处理器。因此第一处理器通过执行固件程序,生成设备热插拔第二请求时,可以将该设备热插拔第二请求发送至该空闲处理器,由于设备热插拔操作由空闲处理器执行,第一处理器当前执行业务无需被反复中断,从而提高了处理器运行效率。In this embodiment, when the first processor responds to the hot plugging of the first interrupt request, the processor may generate a processor offline interrupt request, and trigger any processor that does not include the first processor to be an idle processor. Therefore, when the first processor generates the device hot plugging second request by executing the firmware program, the device hot plugging second request may be sent to the idle processor, because the device hot plug operation is performed by the idle processor, The current execution of a processor by a processor does not need to be repeatedly interrupted, thereby improving the efficiency of the processor.
空闲处理器没有业务执行,不会影响整个系统的运行效率,因此还可以提高整个系统运行效率。The idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
且由于空闲处理器没有业务执行,因此可以一次执行完成对设备热插拔的操作,也无需被反复打断,保证了设备热插拔的执行效率。Because the idle processor has no service execution, the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
由于空闲处理器没有业务执行,同时避免了中断处理出错时,处理器陷入中断无法退出,而导致中断业务被无限期中止的问题。Since the idle processor has no service execution and avoids the interrupt processing error, the processor is interrupted and cannot be exited, and the interrupt service is suspended indefinitely.
图3为本申请实施例中一种设备资源控制方法又一个实施例的流程图,本申请实施例技术方案具体应用于多处理器系统中,该多处理器系统包括第一处理器,该方法可以包括以下几个步骤:FIG. 3 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, and the method The following steps can be included:
301:第一处理器接收基板管理控制器发送的处理器下线中断请求。301: The first processor receives a processor offline interrupt request sent by the baseboard management controller.
通过基板管理控制器,可以方便对设备资源配置过程进行可视化监控。The substrate management controller can be used to visually monitor the device resource configuration process.
302:第一处理器响应该处理器下线中断请求,将不包括自身的任一处 理器下线作为空闲处理器。302: The first processor responds to the processor offline interrupt request and will not include any of its own The processor is offline as an idle processor.
第一处理器响应该处理器下线中断请求,进行中断处理器,使得将不包括自身的任一处理器下线作为空闲处理器。The first processor responds to the processor offline interrupt request and performs an interrupt handler such that any processor that does not include itself is taken offline as an idle processor.
本实施例中以第一处理器可以处理处理器下线中断请求为例进行介绍,在实际应用中,该第一处理器可能由于当前自身运行情况不能处理该处理器下线中断请求,则可以由任一可以处理该处理器下线中断请求的处理器进行中断处理。In this embodiment, the first processor can process the processor offline interrupt request as an example. In an actual application, the first processor may not process the processor offline interrupt request due to the current running condition. Interrupt processing is performed by any processor that can handle the processor's offline interrupt request.
302:第一处理器接收所述基板管理控制器发送的设备热插拔第一中断请求,并响应所述设备热插拔第一中断请求。302: The first processor receives the device hot plug first interrupt request sent by the baseboard management controller, and responds to the device hot plugging the first interrupt request.
作为一种可能实现方式,第一处理器在响应该处理器下线中断请求时,可以判断当前执行业务是否满足预设条件,以确定当前执行业务是否不繁忙,当当前执行业务不繁忙时,在将不包括自身的任一处理器下线作为空闲处理器。As a possible implementation, when the first processor responds to the processor offline interrupt request, it may determine whether the current execution service meets a preset condition to determine whether the current execution service is not busy, when the current execution service is not busy, Take any processor that does not include itself as an idle processor.
基板管理控制器可以监控处理器下线中断请求的处理结果,当空闲处理器下线成功时,再向第一处理器发送设备热插拔第一中断请求。The baseboard management controller can monitor the processing result of the processor offline interrupt request, and when the idle processor is offline, send the device hot plug first interrupt request to the first processor.
304:第一处理器调用并执行固件程序,生成设备热插拔第二中断请求,并向所述空闲处理器发送该设备热插拔第二中断请求。304: The first processor invokes and executes the firmware program, generates a device hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
其中,所述设备热插拔第二中断请求用于触发所述空闲处理器执行设备热插拔的操作。The device hot plugging a second interrupt request is used to trigger the idle processor to perform a hot swap operation of the device.
空闲处理器执行设备热插拔的操作完成时,可以向第一处理器发送设备热插拔第三中断请求。When the idle processor performs the hot plug operation of the device, the device may be hot swapped for the third interrupt request to the first processor.
第一处理器响应该设备热插拔第三中断请求,调用并执行固件程序,可以对设备热插拔执行结果进行检测,确定热插拔的操作是否成功,并进行标识。The first processor responds to the hot plugging of the third interrupt request by the device, invokes and executes the firmware program, and can detect the hot plug execution result of the device, determine whether the hot plug operation is successful, and identify.
基板管理控制器可以获取该第一处理器标识的设备热插拔执行结果,并通过可视化界面输出提示信息,以通知用户。The substrate management controller may obtain the hot plug execution result of the device identified by the first processor, and output prompt information through the visual interface to notify the user.
同时,基板管理控制器检测到设备热插拔执行结果,或者在预设时间内未检测到设备热插拔执行结果时,则可以生成处理器上线中断请求。由第一处理器或第三处理器将空闲处理器上线。At the same time, when the baseboard management controller detects the hot plug execution result of the device, or does not detect the hot plug execution result of the device within a preset time, the processor online interrupt request may be generated. The idle processor is brought online by the first processor or the third processor.
第一处理器或第三处理器为多处理器系统中能够处理该处理器上线中断请求的处理器。 The first processor or the third processor is a processor in the multiprocessor system capable of processing the processor's online interrupt request.
在本实施例中,基板管理控制器可以首先生成处理器下线中断请求,触发第一处理器将任一处理器下线作为空闲处理器,然后生成设备热插拔第一中断请求。第一处理器响应该设备热插拔第一中断请求,固件程序作为该设备热插拔第一中断请求的中断处理程序被调用和执行,从而使得第一处理器生成设备热插拔第二中断请求,发送至空闲处理器,由空闲处理器对该固件程序调用和执行,实现设备热插拔的操作。由于设备热插拔操作由空闲处理器执行,处理器当前执行业务无需被反复中断,从而提高了处理器运行效率。且设备热插拔操作可由基板管理控制器控制,方便了对处理流程的监控,还能够实现可视化监控。In this embodiment, the baseboard management controller may first generate a processor offline interrupt request, trigger the first processor to take any processor offline as an idle processor, and then generate a device hot plug first interrupt request. The first processor is in response to the device hot plugging the first interrupt request, and the firmware program is invoked and executed as an interrupt handler of the device hot plugging the first interrupt request, thereby causing the first processor to generate the device hot swap second interrupt The request is sent to the idle processor, and the idle processor calls and executes the firmware program to implement hot swap operation of the device. Since the device hot plug operation is performed by the idle processor, the current execution of the processor does not need to be repeatedly interrupted, thereby improving the operating efficiency of the processor. Moreover, the hot swap operation of the device can be controlled by the baseboard management controller, which facilitates the monitoring of the processing flow and enables visual monitoring.
空闲处理器没有业务执行,不会影响整个系统的运行效率,因此还可以提高整个系统运行效率。The idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
且由于空闲处理器没有业务执行,因此可以一次执行完成对设备热插拔的操作,也无需被反复打断,保证了设备热插拔的执行效率。Because the idle processor has no service execution, the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
图4为本申请实施例中一种设备资源控制方法又一个实施例的流程图,本申请实施例技术方案具体应用于多处理器系统中,该多处理器系统包括第一处理器,该方法可以包括以下几个步骤:FIG. 4 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, and the method The following steps can be included:
401:第一处理器接收到设备热插拔第一中断请求时,响应所述设备热插拔第一中断请求。401: The first processor, when receiving the device hot plug first interrupt request, responds to the device hot plugging the first interrupt request.
该设备热插拔第一中断请求可以是基板管理控制器生成的。The device hot plug first interrupt request may be generated by the baseboard management controller.
第一处理器为多处理系统中可以处理设备热插拔第一中断请求的处理器。The first processor is a processor in the multi-processing system that can process the device to hot plug the first interrupt request.
402:第一处理器调用并执行固件程序。402: The first processor calls and executes the firmware program.
403:第一处理器当确定热插拔类型为热移除时,生成设备下线中断请求。403: The first processor generates a device offline interrupt request when determining that the hot plug type is hot removal.
所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线。The device offline interrupt request is used to trigger the first processor or the fourth processor to bring the device offline.
第一处理器或第四处理器为多处理器系统中能够处理该设备下线中断请求的处理器。The first processor or the fourth processor is a processor in the multiprocessor system capable of processing the device offline interrupt request.
设备下线中断请求由多处理器系统中任意一个能够处设备下线中断请求的处理器处理,该能够处理处理器器下线中断请求的处理器可能是第一处理器,或者多处理器系统中不包括第一处理器的任意一个处理器,为了 描述上方便,本申请实施例中定义为第四处理器。The device offline interrupt request is processed by any processor in the multiprocessor system capable of being requested to go offline. The processor capable of processing the processor offline interrupt request may be the first processor or the multiprocessor system. Does not include any processor of the first processor, in order to The description is convenient, and is defined as a fourth processor in the embodiment of the present application.
该第四处理器与第三处理器或第二处理器可能为同一处理器,或者不同处理器。The fourth processor and the third processor or the second processor may be the same processor or different processors.
404:第一处理器检测到所述设备下线成功时,生成设备热插拔第二中断请求,并向空闲处理器发送该设备热插拔第二中断请求。404: When the first processor detects that the device is offline, the device generates a hot plug second interrupt request, and sends the device hot plug second interrupt request to the idle processor.
空闲处理器响应该设备热插拔第二中断请求,调用并执行固件程序,执行设备热插拔操作。The idle processor responds to the device hot plugging the second interrupt request, calls and executes the firmware program, and performs device hot swap operation.
本领域技术人员可知的是,热插拔类型为热移除时,必然包括设备下线的操作,以使得执行设备热插拔操作时,不至于系统崩溃,在进行设备资源控制时,可以预先将设备进行下线,或者如本实施例中第一处理器进行中断处理再触发将设备下线。It is known to those skilled in the art that when the hot plug type is hot removed, the operation of the device offline must be included, so that when the device is hot swapped, the system does not collapse, and when the device resource is controlled, the device can be pre- The device is offline, or the first processor performs interrupt processing according to the embodiment, and then triggers the device to go offline.
当然,作为另一实施例,该设备下线中断请求还可以是在空闲处理器响应设备热插拔第二中断请求时生成的,当设备下线成功时,再执行设备热插拔操作。Certainly, as another embodiment, the device offline interrupt request may also be generated when the idle processor responds to the device hot plugging the second interrupt request, and when the device is offline, the device hot plug operation is performed.
405:第一处理器当确定热插拔类型为热添加时,生成设备热插拔第二中断请求,并向所述空闲处理器发送第二中断请求。405: The first processor, when determining that the hot plug type is hot add, generates a device hot plug second interrupt request, and sends a second interrupt request to the idle processor.
406:第一处理器检测到所述设备热插拔的操作成功时,生成设备上线中断请求。406: When the first processor detects that the hot plug operation of the device is successful, generating a device online interrupt request.
所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线。The device online interrupt request is used to trigger the first processor or the fifth processor to bring the device online.
第一处理器或第五处理器为多处理器系统中能够处理该设备上线中断请求的处理器。The first processor or the fifth processor is a processor in the multiprocessor system capable of processing the device's online interrupt request.
设备上线中断请求由多处理器系统任意一个能够处理设备上线中断请求的处理器处理,该能够处理设备上线中断请求的处理器可能是第一处理器,或者多处理器系统中不包括第一处理器的任意一个处理器,为了描述上方便,本申请实施例中定义为第五处理器。The device online interrupt request is processed by any processor of the multiprocessor system capable of processing the device online interrupt request, the processor capable of processing the device online interrupt request may be the first processor, or the first processor is not included in the multiprocessor system Any one of the processors is defined as a fifth processor in the embodiment of the present application for convenience of description.
设备热插拔的操作成功后,将设备上线后,即可以在使用该设备资源。After the device is hot swapped, the device resources can be used after the device is online.
作为又一实施例,该设备上线中断请求也可以是空闲处理器执行设备热插拔操作成功时生成的。As still another embodiment, the device online interrupt request may also be generated when the idle processor performs the device hot plug operation successfully.
其中,作为一种可能实现方式,该空闲处理器可以是第一处理器调用 并执行固件程序时,生成处理器下线中断请求,由第一处理器或第二处理器响应处理器下线中断请求,将不包括自身的任一处理器下线得到的。当第一处理器确定空闲处理器下线成功时,再执行步骤403或步骤405的操作。Wherein, as a possible implementation, the idle processor may be the first processor call When the firmware program is executed, a processor offline interrupt request is generated, and the first processor or the second processor responds to the processor offline interrupt request, and the processor is not included in any of its own processors. When the first processor determines that the idle processor is offline, the operation of step 403 or step 405 is performed.
第一处理器当检测到空闲处理器的设备热插拔第三中断请求时,还可以生成处理器上线中断请求。当热插拔类型为热添加时,该处理器上线中断请求可以是在确定设备上线成功后再生成。The first processor may also generate a processor online interrupt request when detecting that the device of the idle processor is hot plugged with the third interrupt request. When the hot plug type is hot add, the processor online interrupt request may be generated after determining that the device is successfully online.
作为另一种可能实现方式,该空闲处理器可以是基板管理控制器生成处理器下线请求,由第一处理器或第二处理器响应处理器下线中断请求,将不包括自身的任一处理器下线得到。当基板管理控制器确定空闲处理器下线成功时,生成设备热插拔第一中断请求。As another possible implementation manner, the idle processor may be a baseboard management controller that generates a processor offline request, and the first processor or the second processor responds to the processor offline interrupt request, and does not include any of its own The processor is offline. When the baseboard management controller determines that the idle processor is offline, the generating device hot plugs the first interrupt request.
基板管理控制器当检测到设备热插拔的操作执行结果或在预设时间内未检测到设备热插拔的操作执行结果时,还可以生成处理器上线中断请求。当然该处理器上线中断请求还可以是第一处理器接收到空闲处理器发送的设备热插拔第三中断请求后,响应该设备热插拔第三中断请求生成的。The substrate management controller may also generate a processor online interrupt request when detecting the operation execution result of the device hot plugging or the operation execution result of the device hot plugging is not detected within a preset time. Of course, the processor online interrupt request may be generated by the first processor after receiving the device hot plug third interrupt request sent by the idle processor, in response to the device hot plugging the third interrupt request.
其中,该设备上线中断请求以及设备下线中断请求触发的中断的类型可以是PMI或SMI。The type of interrupt triggered by the device online interrupt request and the device offline interrupt request may be PMI or SMI.
图5为本申请实施例提供的一种设备资源控制方法又一个实施例的流程图,本申请实施例技术方案具体应用于多处理器系统中,该处理器系统包括第一处理器,该方法可以包括以下几个步骤:FIG. 5 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the processor system includes a first processor, and the method includes The following steps can be included:
501:基板管理控制器接收设备热插拔请求。501: The baseboard management controller receives the device hot plug request.
502:基板管理控制器生成设备热插拔第一中断请求,并发送至第一处理器。502: The baseboard management controller generates a device hot plug first interrupt request and sends the first interrupt request to the first processor.
第一处理器响应该设备热插拔第一中断请求,调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The first processor is responsive to the device hot plugging the first interrupt request, invoking and executing the firmware program, generating a device hot plug second interrupt request, and transmitting the device hot plug second interrupt request to the idle processor, The device hot plugging a second interrupt request is used to trigger the idle processor to invoke and execute the firmware program to perform a hot plug operation of the device, where the idle processor is currently not executing services in the multiprocessor system Processor.
此外,基板管理控制器接收设备热插拔请求之前,还可以生成处理器下线中断请求。In addition, the processor management controller may also generate a processor offline interrupt request before receiving the device hot plug request.
该处理器下线中断请求可以触发所述第一处理器或第二处理器将不包 括自身的任一处理器下线作为空闲处理器。The processor offline interrupt request may trigger the first processor or the second processor to not include Any processor that includes itself is offline as an idle processor.
则本实施例所述方法还可以包括:The method in this embodiment may further include:
基板管理控制器检测到设备热插拔的操作执行结果,或者在预设时间内未检测到设备热插拔的操作执行结果,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线。The baseboard management controller detects an operation execution result of the hot plugging of the device, or does not detect an operation execution result of the device hot plugging within a preset time, generates a processor online interrupt request, and the processor online interrupt request is used for triggering. The first processor or the third processor brings the idle processor online.
空闲处理器执行设备热插拔的操作结束时,可以生成设备热插拔第三中断请求,以通知第一处理器,第一处理器响应该设备热插拔第三中断请求,获取空闲处理器设备热插拔的操作的执行结果,并可以进行标识。When the idle processor performs the device hot plug operation, the device hot plug third interrupt request may be generated to notify the first processor, and the first processor responds to the device hot plugging the third interrupt request to obtain the idle processor. The execution result of the hot swap operation of the device and can be identified.
基板管理控制器检测的设备热插拔的操作执行结果可以是根据第一处理器的标识结果得到,例如第一处理器将执行结果用发光二极管是否点亮表示,基板管理控制器根据发光二极管是否点亮,可以获得该设备热插拔的操作的执行结果。The operation result of the hot plug operation of the device detected by the substrate management controller may be obtained according to the identification result of the first processor, for example, the first processor indicates whether the execution result is illuminated by the LED, and the substrate management controller determines whether the LED is based on the LED When lit, the execution result of the hot plug operation of the device can be obtained.
检测到设备热插拔的操作执行结果时,表明设备热插拔的操作结束,从而可以触发空闲处理器上线。When the result of the hot swap operation of the device is detected, it indicates that the hot swap operation of the device is finished, which can trigger the idle processor to go online.
当然,还可以设置超时机制,如果在预设时间内未检测到设备热插拔的操作执行结果,可以确定设备热插拔的操作执行失败,此时,可以触发第一处理器将空闲处理器唤醒,并触发空闲处理器上线。Of course, the timeout mechanism can also be set. If the operation result of the hot plug operation of the device is not detected within the preset time, it can be determined that the operation of the hot plug operation of the device fails, and at this time, the idle processor of the first processor can be triggered. Wake up and trigger the idle processor to go online.
基板管理控制器检测到设备热插拔的执行结果时,还可以输出提示信息。When the baseboard management controller detects the execution result of the hot plugging of the device, it can also output a prompt message.
在本实施例中,通过基板管理控制器可以实现对设备资源控制的有效监控,由空闲处理器执行设备热插拔的操作,第一处理器当前执行业务无需被反复中断,从而提高了处理器运行效率。In this embodiment, the device management controller can implement effective monitoring of device resource control, and the idle processor performs hot swap operation of the device, and the current processor does not need to be repeatedly interrupted, thereby improving the processor. operating efficiency.
空闲处理器没有业务执行,不会影响整个系统的运行效率,因此还可以提高整个系统运行效率。The idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
且由于空闲处理器没有业务执行,因此可以一次执行完成对设备热插拔的操作,也无需被反复打断,保证了设备热插拔的执行效率。Because the idle processor has no service execution, the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
图6为本申请实施例提供的一种设备资源控制方法又一个实施例的流程图,本申请实施例技术方案具体应用于多处理器系统中,该处理器系统包括第一处理器,该方法可以包括以下几个步骤:FIG. 6 is a flowchart of still another embodiment of a device resource control method according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the processor system includes a first processor, and the method includes The following steps can be included:
601:空闲处理器接收第一处理器发送的设备热插拔第二中断请求,所 述设备热插拔第二中断请求为第一处理器接收到设备热插拔第一中断请求时,响应所述设备热插拔第一中断请求,调用并执行固件程序生成的;601: The idle processor receives the device hot plug second interrupt request sent by the first processor, where The device hot plugging the second interrupt request, when the first processor receives the device hot plugging first interrupt request, responding to the device hot plugging the first interrupt request, calling and executing the firmware program generation;
602:空闲处理器响应所述设备热插拔第二中断请求。602: The idle processor is responsive to the device hot plugging the second interrupt request.
空闲处理器响应设备热插拔第二中断请求,可以调用并执行所述固件程序,实现执行设备热插拔的操作,由于热插拔类型不同,因此空闲处理器执行的操作可能不同,可以包括:The idle processor responds to the device hot plugging the second interrupt request, and the firmware program may be invoked and executed to perform hot swap operation of the device. The operation performed by the idle processor may be different due to different hot plug types, and may include :
603:空闲服务器当确定热插拔类型为热移除时,生成设备下线中断请求。603: The idle server generates a device offline interrupt request when it is determined that the hot plug type is hot removal.
所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线。The device offline interrupt request is used to trigger the first processor or the fourth processor to bring the device offline.
所述第四处理器为所述多处理器系统中能够处理所述述设备下线中断请求的任一处理器。The fourth processor is any processor in the multiprocessor system capable of processing the device offline interrupt request.
604:空闲服务器检测到设备下线成功时,执行设备热插拔的操作。604: The idle server performs the hot swap operation of the device when the idle server detects that the device is offline.
空闲处理器确定热插拔类型为热移除时,若设备并未下线,则此时可以生成设备下线中断请求,请求下线该设备。If the idle processor determines that the hot swap type is hot removed, if the device is not offline, the device offline interrupt request can be generated at this time, requesting to go offline.
605:空闲服务器当确定热插拔类型为热添加时,执行设备热插拔的操作;605: The idle server performs hot swap operation of the device when determining that the hot plug type is hot add;
606:空闲服务器当确定所述设备热插拔的操作执行成功时,生成设备上线中断请求。606: The idle server generates a device online interrupt request when it is determined that the hot plug operation of the device is successfully performed.
所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线。The device online interrupt request is used to trigger the first processor or the fifth processor to bring the device online.
所述第五处理器为所述多处理器系统中能够处理所述述设备上线中断请求的任一处理器。The fifth processor is any processor in the multi-processor system capable of processing the device-on-line interrupt request.
设备热插拔的操作执行成功,即可以触发设备上线,使得系统可以使用该设备。If the hot swap operation is successful, the device can be triggered to go online, so that the system can use the device.
其中,本实施例中的空闲处理器执行设备热插拔的操作成功时,还可以向第一处理器发送设备热插拔第三中断请求。When the idle processor in the embodiment performs the hot swap operation, the device may also send the device hot plug third interrupt request to the first processor.
第一处理器响应该设备热插拔第三中断请求,可以通过调用并执行固件程序,执行例如获取设备热插拔的操作执行结果并进行标识等中断处理。The first processor responds to the hot plugging of the third interrupt request by the device, and may perform an interrupt processing such as obtaining an operation execution result of the device hot plug and performing identification, etc., by calling and executing the firmware program.
当该空闲处理器是在进行设备资源控制时,将业务迁移后得到的,则第一处理器器响应该设备热插拔第三中断请求,还可以通过调用并执行固 件程序,执行触发空闲处理器上线的操作。When the idle processor is obtained after the device resource control is performed, the first processor responds to the hot plugging of the third interrupt request by the device, and may also invoke and execute the solid state. The program executes the operation that triggers the idle processor to go online.
在本实施例中,空闲处理器根据第一处理器通过执行固件程序发送的设备热插拔第二中断请求,执行设备热插拔的操作,由于设备热插拔操作由空闲处理器执行,第一处理器当前执行业务无需被反复中断,从而提高了处理器运行效率。In this embodiment, the idle processor performs the hot plug operation of the device according to the hot swapping of the second interrupt request by the device sent by the first processor by executing the firmware program, and the hot swap operation of the device is performed by the idle processor. The current execution of a processor by a processor does not need to be repeatedly interrupted, thereby improving the efficiency of the processor.
空闲处理器没有业务执行,不会影响整个系统的运行效率,因此还可以提高整个系统运行效率。The idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system.
且由于空闲处理器没有业务执行,因此可以一次执行完成对设备热插拔的操作,也无需被反复打断,保证了设备热插拔的执行效率。Because the idle processor has no service execution, the hot swap operation of the device can be performed at one time, and the device does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请并不受所描述的动作顺序的限制,因为依据本申请,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本申请所必须的。For the foregoing method embodiments, for the sake of brevity, they are all described as a series of action combinations, but those skilled in the art should understand that the present application is not limited by the described action sequence, because according to the present application, Some steps can be performed in other orders or at the same time. In the following, those skilled in the art should also understand that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application.
图7为本申请实施例提供的一种设备资源控制装置一个实施例的结构示意图,本申请实施例技术方案具体应用于多处理器系统中,该多处理器系统包括第一处理器,该装置可以包括:FIG. 7 is a schematic structural diagram of an apparatus resource control apparatus according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, and the apparatus Can include:
中断请求生成模块701,用于当该第一处理器接收并响应设备热插拔第一中断请求时,生成设备热插拔第二中断请求。The interrupt request generating module 701 is configured to generate a device hot plug second interrupt request when the first processor receives and responds to the device hot plugging the first interrupt request.
中断请求发送模块702,用于向空闲处理器发送所述设备热插拔第二中断请求。The interrupt request sending module 702 is configured to send the device hot plug second interrupt request to the idle processor.
其中,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The device hot plugging a second interrupt request is used to trigger the idle processor to invoke and execute a firmware program, and perform a device hot swap operation, where the idle processor is in the multiprocessor system, currently no The processor that performs the business.
该中断请求生成模块生成设备热插拔第二中断请求以及中断请求发送模块实现的功能,是通过固件程序在第一处理器中运行实现的。第一处理器为接收设备热插拔第一中断请求并进行响应的处理器。The interrupt request generation module generates a device hot plug second interrupt request and a function implemented by the interrupt request sending module, which is implemented by the firmware program running in the first processor. The first processor is a processor that receives a device to hot plug the first interrupt request and responds.
为了方便对设备热插拔的触发和监控,作为一种可能的实现方式,该设备热插拔第一中断请求可以是基板管理器或服务管理器接收到设备热插拔请求后生成的。 In order to facilitate the triggering and monitoring of hot swapping of the device, as a possible implementation manner, the device hot plugging the first interrupt request may be generated after the baseboard manager or the service manager receives the hot plug request of the device.
基板管理控制器(BMC,Baseboard management controller)是计算机主板上的微控制器,也可以称为管理处理器(SP,Service Processor)。基板管理器独立于操作系统,可以监控多处理器系统在任何时刻的硬件状态。The Baseboard Management Controller (BMC) is a microcontroller on a computer motherboard, and may also be called a Service Processor (SP). The baseboard manager is independent of the operating system and can monitor the hardware status of the multiprocessor system at any time.
基板管理控制器一般都包括操作界面,用户可以通过操作界面触发设备热插拔的操作,并对其进行控制,操作性强,从而实现可视化监控。The substrate management controller generally includes an operation interface, and the user can trigger the hot plug operation of the device through the operation interface, and control the operation, and the operation is strong, thereby realizing visual monitoring.
当然该设备热插拔第一中断请求也可以是通过用户操作主板上的按键或机框上的按钮,通过南桥硬件芯片等硬件结构来触发的。Of course, the hot interrupt first interrupt request of the device may also be triggered by a user operating a button on the motherboard or a button on the chassis through a hardware structure such as a south bridge hardware chip.
在本实施例中,在第一处理器接收并响应设备热插拔第一中断请求时,通过该设备资源控制装置生成设备热插拔第二中断请求,发送至空闲处理器,由空闲处理器响应该设备热插拔第二中断请求,执行设备热插拔操作,第一处理器即退出中断处理,可以恢复其中断的执行业务。由于设备热插拔操作由空闲处理器执行,第一处理器当前执行业务无需被反复中断,从而提高了处理器运行效率。In this embodiment, when the first processor receives and responds to the device hot plugging the first interrupt request, the device resource control device generates a device hot plug second interrupt request, and sends the device to the idle processor, where the idle processor is used. In response to the device hot plugging the second interrupt request, the device is hot swapped, and the first processor exits the interrupt processing, and the interrupted execution service can be resumed. Since the device hot plug operation is performed by the idle processor, the first processor currently performs the service without being repeatedly interrupted, thereby improving the processor operating efficiency.
空闲处理器没有业务执行,不会影响整个系统的运行效率,因此还可以提高整个系统运行效率。且空闲处理器可以一次执行完成对设备热插拔的操作,也无需被反复打断,保证了设备热插拔的执行效率。The idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system. The idle processor can perform hot swap operation on the device at one time, and does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
图8为本申请实施例提供的一种设备资源控制方法另一个实施例的结构示意图,本申请实施例技术方案具体应用于多处理器系统中,该多处理器系统包括第一处理器,该装置可以包括:FIG. 8 is a schematic structural diagram of another embodiment of a device resource control method according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, where The device can include:
中断请求生成模块801,用于当该第一处理器接收并响设备热插拔第一中断请求时,生成设备热插拔第二中断请求;The interrupt request generating module 801 is configured to: when the first processor receives and responds to the device hot plugging the first interrupt request, generating a device hot plugging second interrupt request;
其中,本实施例中,该中断请求生成模块801可以包括:In this embodiment, the interrupt request generating module 801 can include:
处理器下线模块8011,用于生成处理器下线中断请求。The processor offline module 8011 is configured to generate a processor offline interrupt request.
所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器。The processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle processor.
第一处理器或第二处理器为多处理器系统中能够处理处理器下线中断请求的处理器。其中将不包括自身的任一处理器下线作为空闲处理器具体可以将不包括自身的,且业务处理压力相对较小的处理器下线作为空闲处理器。The first processor or the second processor is a processor in the multiprocessor system capable of processing a processor offline interrupt request. The processor that does not include any processor offline is used as an idle processor. Specifically, the processor that does not include itself and the service processing pressure is relatively small is taken as an idle processor.
第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器时,可以先判断当前执行业务是否满足预设条件,以确定当前执行业 务是否不繁忙,当当前执行业务不繁忙时,再选择任一处理器下线。When the first processor or the second processor uses any processor that does not include its own processor as the idle processor, it may first determine whether the current execution service meets the preset condition to determine the current execution industry. Whether the service is not busy, when the current execution business is not busy, then select any processor to go offline.
中断请求生成子模块8012,用于当检测到所述空闲处理器下线成功时,生成设备热插拔第二中断请求。The interrupt request generation sub-module 8012 is configured to generate a device hot plug second interrupt request when detecting that the idle processor is offline.
当空闲处理器下线成功时,即生成设备热插拔第二中断请求,发送至空闲处理器。此时第一处理器即退出当前中断处理,返回接收到设备热插拔第一中断请求时,当前执行业务的断点继续执行。When the idle processor is offline, the device generates a hot swap second interrupt request and sends it to the idle processor. At this time, the first processor exits the current interrupt processing, and when the device receives the hot plug first interrupt request, the breakpoint of the currently executed service continues to be executed.
中断请求发送模块802,用于向空闲处理器发送所述设备热插拔第二中断请求。The interrupt request sending module 802 is configured to send the device hot plug second interrupt request to the idle processor.
空闲处理器接收到设备热插拔第二中断请求,响应该设备热插拔第二中断请求,调用并执行该固件程序,实现设备热插拔的操作。The idle processor receives the device hot plug second interrupt request, responds to the device hot plugging the second interrupt request, invokes and executes the firmware program, and implements hot swap operation of the device.
空闲处理器执行的设备热插拔的操作包括设备上电初始化或设备下电操作,根据热插拔类型不同而确定。The hot swap operation of the device performed by the idle processor includes the device power-on initialization or device power-off operation, which is determined according to the hot plug type.
热插拔类型为热移除时,空闲处理器执行设备热插拔的操作时,需要保证设备已经下线,即将该设备中的业务进行迁移。设备下线可以由第一处理器或任一处理器执行,与现有技术相同不再赘述。When the hot-swap type is hot-removed, when the idle processor performs the hot-swap operation of the device, you need to ensure that the device is offline and the services in the device are migrated. The device offline can be executed by the first processor or any processor, and will not be described again in the same way as the prior art.
热插拔类型为热添加时,设备热插拔的操作执行成功时,需要将设备上线,即将设备添加至设备资源中,设备上线可以由第一处理器或任一处理器执行,与现有技术相同不再赘述。When the hot-swap type is hot-added, when the device is hot-swapped, the device needs to be powered on, that is, the device is added to the device resource. The device can be online by the first processor or any processor. The same technology will not be described again.
空闲处理器执行设备热插拔的操作完成时,还可以生成设备热插拔第三中断请求。When the idle processor performs the hot plug operation of the device, the device hot plug third interrupt request can also be generated.
因此,本实施例中,该装置还可以包括:Therefore, in this embodiment, the apparatus may further include:
处理器上线模块803,用于当所述第一处理器响应所述空闲处理器执行设备热插拔的操作结束时发送的设备热插拔第三中断请求时,生成处理器上线中断请求。The processor online module 803 is configured to generate a processor online interrupt request when the first processor interrupts the third interrupt request by the device that is sent when the idle processor performs the hot plug operation of the device.
所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线。The processor uplink interrupt request is used to trigger the first processor or the third processor to bring the idle processor online.
第一处理器或第三处理器为多处理器系统中能够处理该处理器上线中断请求的处理器。The first processor or the third processor is a processor in the multiprocessor system capable of processing the processor's online interrupt request.
当然,本实施例中设备资源控制装置还可以判断设备热插拔的操作是否执行成功等,并进行标识以通知用户。例如通过主板或机框上的二极管的亮灭进行标识。 Of course, in this embodiment, the device resource control apparatus may further determine whether the hot swap operation of the device is successfully executed, and perform identification to notify the user. For example, it is marked by the on/off of the diode on the main board or the chassis.
在本实施例中,当第一处理器响应设备热插拔第一中断请求时,该装置生成处理器下线中断请求,触发将不包括第一处理器的任一处理器下线作为空闲处理器。当空闲处理器下线成功时,生成设备热插拔第二请求时,发送至该空闲处理器,由空闲处理器执行设备热插拔操作,因此第一处理器当前执行业务无需被反复中断,从而提高了处理器运行效率。In this embodiment, when the first processor responds to the device hot plugging the first interrupt request, the device generates a processor offline interrupt request, triggering any processor that does not include the first processor to go offline as idle processing. Device. When the idle processor is offline, the device sends a hot request to the idle processor, and the idle processor performs the device hot swap operation, so the first processor does not need to be repeatedly interrupted. Thereby improving the operating efficiency of the processor.
空闲处理器没有业务执行,不会影响整个系统的运行效率,因此还可以提高整个系统运行效率。且空闲处理器可以一次执行完成对设备热插拔的操作,也无需被反复打断,保证了设备热插拔的执行效率。The idle processor has no service execution and does not affect the operating efficiency of the entire system, so it can also improve the efficiency of the entire system. The idle processor can perform hot swap operation on the device at one time, and does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
其中,作为另一个实施例,处理器下线中断请求可以是基板管理控制器生成并发送至第一处理器。Wherein, as another embodiment, the processor offline interrupt request may be generated by the baseboard management controller and sent to the first processor.
基板管理控制器还可以生成设备热插拔第一中断请求发送至第一处理器,第一处理器响应设备热插拔该第一中断请求时,可以通过本申请实施例提供的设备资源控制装置生成设备热插拔第二中断请求,并发送至空闲处理器。The device management controller may further generate a device hot plug first interrupt request and send the first interrupt request to the first processor. When the first processor responds to the device hot plugging the first interrupt request, the device resource control device provided by the embodiment of the present application may be used. The device hot plug second interrupt request is generated and sent to the idle processor.
基板管理控制器可以对设备热插拔执行结果进行检测,The substrate management controller can detect the hot plug execution result of the device.
检测到设备热插拔执行结果,或者在预设时间内未检测到设备热插拔执行结果时,则可以生成处理器上线中断请求。由第一处理器或第三处理器将空闲处理器上线。If the hot swap execution result of the device is detected, or the device hot plug execution result is not detected within the preset time, the processor online interrupt request can be generated. The idle processor is brought online by the first processor or the third processor.
第一处理器或第三处理器为多处理器系统中能够处理该处理器上线中断请求的处理器。The first processor or the third processor is a processor in the multiprocessor system capable of processing the processor's online interrupt request.
图9为本申请实施例中一种设备资源控制方法又一个实施例的结构示意图,本申请实施例技术方案具体应用于多处理器系统中,该处理器系统包括第一处理器,该装置可以包括:FIG. 9 is a schematic structural diagram of still another embodiment of a device resource control method according to an embodiment of the present disclosure. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the processor system includes a first processor, where the device may include:
中断请求生成模块901,用于接收到设备热插拔第一中断请求。响应所述设备热插拔第一中断请求时,生成设备热插拔第二中断请求。The interrupt request generating module 901 is configured to receive the device hot plugging first interrupt request. The device hot plugs the second interrupt request in response to the device hot plugging the first interrupt request.
本实施例中,以热插拔类型为热移除时进行介绍。In this embodiment, the hot plug type is introduced when the heat is removed.
因此该中断请求生成模块901可以包括:Therefore, the interrupt request generating module 901 can include:
第一设备下线模块9011:用于生成设备下线中断请求,所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线。The first device offline module 9011 is configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device.
中断请求生成子模块9012,用于当检测到所述设备下线成功时,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断 请求。The interrupt request generation sub-module 9012 is configured to: when detecting that the device is offline, generate a device hot plug second interrupt request, and send the device hot plug second interrupt to the idle processor request.
其中,作为一种可能的实现方式,该空闲处理器可以是第一处理器调用并执行固件程序时,生成处理器下线中断请求,由第一处理器或第二处理器响应处理器下线中断请求,将不包括自身的任一处理器下线得到的。As a possible implementation manner, the idle processor may be configured to generate a processor offline interrupt request when the first processor invokes and executes the firmware program, and the first processor or the second processor responds to the processor offline. The interrupt request will not be included if any of its own processors are offline.
因此该中断请求生成模块还可以包括:Therefore, the interrupt request generating module may further include:
处理器下线模块,用于生成处理器下线中断请求。A processor offline module for generating a processor offline interrupt request.
所述处理器下线中断请求用于触发第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器。The processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle processor.
则当热插拔类型为热移除时,该设备下线模块9011具体可以是在检测到所述空闲处理器下线成功时,生成设备下线中断请求,或者所述中断请求生成子模块9012具体可以是在检测到所述设备下线成功,且所述空闲处理器下线成功时,生成设备热插拔第二中断请求。When the hot plug type is hot removed, the device offline module 9011 may specifically generate a device offline interrupt request when detecting that the idle processor is offline, or the interrupt request generation submodule 9012 Specifically, when it is detected that the device is offline, and the idle processor is offline, the device generates a hot plug second interrupt request.
作为另一种可能实现方式,该空闲处理器可以是基板管理控制器生成处理器下线请求,由第一处理器或第二处理器响应处理器下线中断请求,将不包括自身的任一处理器下线得到。当基板管理控制器确定空闲处理器下线成功时,生成设备热插拔第一中断请求。As another possible implementation manner, the idle processor may be a baseboard management controller that generates a processor offline request, and the first processor or the second processor responds to the processor offline interrupt request, and does not include any of its own The processor is offline. When the baseboard management controller determines that the idle processor is offline, the generating device hot plugs the first interrupt request.
中断请求发送模块902,用于向空闲处理器发送所述设备热插拔第二中断请求。The interrupt request sending module 902 is configured to send the device hot plug second interrupt request to the idle processor.
空闲处理器响应该设备热插拔第二中断请求,调用并执行固件程序,执行设备热插拔操作。The idle processor responds to the device hot plugging the second interrupt request, calls and executes the firmware program, and performs device hot swap operation.
本领域技术人员可知的是,热插拔类型为热移除时,必然包括设备下线的操作,以使得执行设备热插拔操作时,不至于系统崩溃,在进行设备资源控制时,可以由任一处理器预先将设备进行下线,或者如本实施例中由设备资源控制装置进行中断处理时,触发将设备下线。It is known to those skilled in the art that when the hot plug type is hot removed, the operation of the device offline must be included, so that when the device is hot swapped, the system does not collapse, and when device resource control is performed, Any processor pre-empts the device offline, or triggers the device to go offline when interrupt processing is performed by the device resource control device in this embodiment.
图10为本申请实施例中一种设备资源控制方法又一个实施例的结构示意图,本申请实施例技术方案具体应用于多处理器系统中,该处理器系统包括第一处理器,该装置可以包括:FIG. 10 is a schematic structural diagram of still another embodiment of a device resource control method according to an embodiment of the present application. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the processor system includes a first processor, where the device may include:
中断请求生成模块1001,用于接收到设备热插拔第一中断请求。响应所述设备热插拔第一中断请求时,生成设备热插拔第二中断请求。The interrupt request generating module 1001 is configured to receive the device hot plugging first interrupt request. The device hot plugs the second interrupt request in response to the device hot plugging the first interrupt request.
中断请求发送模块1002,用于向空闲处理器发送所述设备热插拔第二 中断请求。The interrupt request sending module 1002 is configured to send the device hot plug second to the idle processor Interrupt the request.
本实施例中,以热插拔类型为热添加时进行介绍,因此,该装置还可以包括:In this embodiment, when the hot plug type is hot added, the device may further include:
第一设备上线模块1003,用于当确定所述空闲处理器执行设备热插拔的操作执行成功时,生成设备上线中断请求,所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线。The first device online module 1003 is configured to generate a device online interrupt request when determining that the idle processor performs hot swap operation of the device, and the device online interrupt request is used to trigger the first processor or the first The five processors bring the device online.
其中,作为一种可能的实现方式,该空闲处理器可以是第一处理器调用并执行固件程序时,生成处理器下线中断请求,由第一处理器或第二处理器响应处理器下线中断请求,将不包括自身的任一处理器下线得到的。As a possible implementation manner, the idle processor may be configured to generate a processor offline interrupt request when the first processor invokes and executes the firmware program, and the first processor or the second processor responds to the processor offline. The interrupt request will not be included if any of its own processors are offline.
因此该中断请求生成模块1002可以包括:Therefore, the interrupt request generating module 1002 can include:
处理器下线模块,用于生成处理器下线中断请求。A processor offline module for generating a processor offline interrupt request.
所述处理器下线中断请求用于触发第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器。The processor offline interrupt request is used to trigger the first processor or the second processor to take any processor that does not include itself as an idle processor.
中断请求生成子模块,用于当检测到所述空闲处理器下线成功时,生成设备热插拔第二中断请求。The interrupt request generation submodule is configured to generate a device hot plug second interrupt request when detecting that the idle processor is offline successfully.
因此该装置还可以包括:Therefore the device can also include:
处理器上线模块,用于响应所述空闲处理器执行设备热插拔的操作结束时发送的设备热插拔第三中断请求,生成处理器上线中断请求。And a processor online module, configured to generate a processor online interrupt request in response to the device hot plugging a third interrupt request sent by the idle processor performing the hot plug operation of the device.
所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线。The processor uplink interrupt request is used to trigger the first processor or the third processor to bring the idle processor online.
作为另一种可能实现方式,该空闲处理器可以是基板管理控制器生成处理器下线请求,由第一处理器或第二处理器响应处理器下线中断请求,将不包括自身的任一处理器下线得到。当基板管理控制器确定空闲处理器下线成功时,生成设备热插拔第一中断请求。As another possible implementation manner, the idle processor may be a baseboard management controller that generates a processor offline request, and the first processor or the second processor responds to the processor offline interrupt request, and does not include any of its own The processor is offline. When the baseboard management controller determines that the idle processor is offline, the generating device hot plugs the first interrupt request.
基板管理控制器当检测到设备热插拔的操作执行结果或在预设时间内未检测到设备热插拔的操作执行结果时,还可以生成处理器上线中断请求。The substrate management controller may also generate a processor online interrupt request when detecting the operation execution result of the device hot plugging or the operation execution result of the device hot plugging is not detected within a preset time.
当然该处理器上线中断请求还可以是第一处理器接收到空闲处理器发送的设备热插拔第三中断请求后,响应该设备热插拔第三中断请求生成并发送至基板管理控制器的。Of course, the processor uplink interrupt request may be after the first processor receives the device hot plug third interrupt request sent by the idle processor, and generates and sends the third interrupt request to the baseboard management controller in response to the hot swapping of the device. .
上述图7~图10对应的设备资源控制装置,在实际应用中可以集成到固 件程序中,该固件程序被第一处理器调用并执行,从而实现由空闲处理器执行设备热插拔操作,第一处理器的当前执行业务无需被反复中断,可以保证处理器的运行效率,同时空闲处理器执行的设备热插拔操作也无需被反复中断,保证了设备热插拔操作的执行效率。The device resource control device corresponding to the above FIG. 7 to FIG. 10 can be integrated into the solid in practical applications. In the program, the firmware program is called and executed by the first processor, so that the device performs hot plug operation by the idle processor, and the current execution service of the first processor does not need to be repeatedly interrupted, thereby ensuring the operating efficiency of the processor. At the same time, the device hot swap operation performed by the idle processor does not need to be repeatedly interrupted, which ensures the execution efficiency of the device hot plug operation.
因此本申请实施例还提供了一种固件程序,该固件程序包括图7~图10任一实施例中所述的设备资源控制装置。Therefore, the embodiment of the present application further provides a firmware program, which includes the device resource control device described in any of the embodiments of FIG. 7 to FIG.
图11为本申请实施例提供的一种设备资源控制装置又一个实施例的结构示意图,本申请技术方案具体应用于多处理器系统中,该处理器系统包括第一处理器,在实际应用中,该设备资源控制装置具体应用于基板管理控制器中,该装置可以包括:FIG. 11 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure. The technical solution of the present application is specifically applied to a multi-processor system, where the processor system includes a first processor, and is in actual application. The device resource control device is specifically applied to a baseboard management controller, and the device may include:
请求接收模块1101,用于接收设备热插拔请求;The request receiving module 1101 is configured to receive a device hot plug request;
第一中断生成模块1102,用于生成设备热插拔第一中断请求,并发送至第一处理器。The first interrupt generating module 1102 is configured to generate a device hot plug first interrupt request, and send the first interrupt request to the first processor.
第一处理器响应该设备热插拔第一中断请求,通过调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求。The first processor, in response to the device hot plugging the first interrupt request, generates a device hot plug second interrupt request by calling and executing the firmware program, and sends the device hot plug second interrupt request to the idle processor.
空闲处理器响应该设备热插拔第二中断请求,通过调用并执行所述固件程序,执行设备热插拔的操作。The idle processor performs a hot plug operation of the device by calling and executing the firmware program in response to the device hot plugging the second interrupt request.
其中,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The idle processor is a processor in the multi-processor system that currently has no service to perform.
作为一种可能的实现方式,该装置还可以包括:As a possible implementation manner, the device may further include:
处理器下线模块1103,用于生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器。a processor offline module 1103, configured to generate a processor offline interrupt request, where the processor offline interrupt request is used to trigger the first processor or the second processor to disconnect any processor that does not include itself As an idle processor.
处理器上线模块1104,用于检测到设备热插拔的操作执行结果,或者在预设时间内未检测到设备热插拔的操作执行结果,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线。The processor online module 1104 is configured to detect an operation execution result of hot plugging of the device, or not execute an operation execution result of hot plugging of the device within a preset time, generate a processor online interrupt request, and the processor is disconnected. The request is for triggering the first processor or the third processor to bring the idle processor online.
空闲处理器执行设备热插拔的操作结束时,可以生成设备热插拔第三中断请求,以通知第一处理器,第一处理器响应该设备热插拔第三中断请 求,获取空闲处理器设备热插拔的操作的执行结果,并可以进行标识。When the idle processor performs the device hot plug operation, the device hot plug third interrupt request may be generated to notify the first processor, and the first processor responds to the device hot swap third interrupt. The result of the operation of the hot swap operation of the idle processor device is obtained, and can be identified.
处理器上线模块检测的设备热插拔的操作执行结果可以是根据第一处理器的标识结果得到,例如第一处理器将执行结果用发光二极管是否点亮表示,基板管理控制器根据发光二极管是否点亮,可以获得该设备热插拔的操作的执行结果。The operation result of the hot plug operation of the device detected by the processor online module may be obtained according to the identification result of the first processor, for example, the first processor displays the execution result with whether the LED is lit, and the substrate management controller is based on whether the LED is When lit, the execution result of the hot plug operation of the device can be obtained.
检测到设备热插拔的操作执行结果时,表明设备热插拔的操作结束,从而可以触发空闲处理器上线。When the result of the hot swap operation of the device is detected, it indicates that the hot swap operation of the device is finished, which can trigger the idle processor to go online.
当然,还可以设置超时机制,如果处理器上线模块在预设时间内未检测到设备热插拔的操作执行结果,可以确定设备热插拔的操作执行失败,此时,可以触发第一处理器将空闲处理器唤醒,并触发空闲处理器上线。Of course, the timeout mechanism can also be set. If the processor online module does not detect the hot-swap operation execution result of the device within the preset time, it can be determined that the hot-swap operation of the device fails, and the first processor can be triggered. Wake up the idle processor and trigger the idle processor to go online.
另外,该装置还可以包括:In addition, the device may further include:
信息输出模块1105,用于检测到设备热插拔的执行结果时,输出提示信息。以通知用户设备热插拔的执行结果。The information output module 1105 is configured to output prompt information when detecting an execution result of hot plugging of the device. To inform the user of the execution result of the device hot swap.
图11对应的设备资源控制置在实际应用中具体应用于基板管理控制器中,通过部署本实施例设备资源控制装置的基板管理控制器可以对方便对设备热插拔操作的控制,还可以实现可视化监控。The device resource control corresponding to FIG. 11 is specifically applied to the substrate management controller in the actual application, and the substrate management controller of the device resource control device in this embodiment can be used to control the hot plug operation of the device, and can also be implemented. Visual monitoring.
通过以上描述可知,本领域的技术人员可以清楚地了解到本发明可借助软件加必需的通用硬件平台的方式来实现。参见图12,本发明实施例还提供了一种基板管理控制器,该基板管理控制器可以包括:From the above description, it will be apparent to those skilled in the art that the present invention can be implemented by means of software plus a necessary general hardware platform. Referring to FIG. 12, an embodiment of the present invention further provides a substrate management controller, where the substrate management controller may include:
接收器1201,用于接收设备热插拔请求;a receiver 1201, configured to receive a device hot plug request;
控制器1202,用于生成设备热插拔第一中断请求,并发送至第一处理器。The controller 1202 is configured to generate a device hot plug first interrupt request, and send the first interrupt request to the first processor.
第一处理器响应该设备热插拔第一中断请求,通过调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求。The first processor, in response to the device hot plugging the first interrupt request, generates a device hot plug second interrupt request by calling and executing the firmware program, and sends the device hot plug second interrupt request to the idle processor.
空闲处理器响应该设备热插拔第二中断请求,通过调用并执行所述固件程序,执行设备热插拔的操作。The idle processor performs a hot plug operation of the device by calling and executing the firmware program in response to the device hot plugging the second interrupt request.
其中,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The idle processor is a processor in the multi-processor system that currently has no service to perform.
此外,该控制器1202还可以用于生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任 一处理器下线作为空闲处理器;当检测到设备热插拔的操作执行结果,或者在预设时间内未检测到设备热插拔的操作执行结果,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线。In addition, the controller 1202 can be further configured to generate a processor offline interrupt request, where the processor offline interrupt request is used to trigger the first processor or the second processor to not include itself A processor is offline as an idle processor; when an operation execution result of the device hot plug is detected, or an operation execution result of the device hot plug is not detected within a preset time, a processor online interrupt request is generated, and the processing is performed. The online uplink interrupt request is used to trigger the first processor or the third processor to bring the idle processor online.
图13为本申请实施例提供的一种设备资源控制装置又一个实施例的结构示意图,本申请实施例技术方案具体应用于多处理器系统中,该多处理器系统包括第一处理器,该装置可以包括:FIG. 13 is a schematic structural diagram of still another embodiment of a device resource control apparatus according to an embodiment of the present disclosure. The technical solution of the embodiment of the present application is specifically applied to a multi-processor system, where the multi-processor system includes a first processor, where The device can include:
热插拔执行模块1301,用于当空闲服务器响应第一处理器发送的设备热插拔第二中断请求时,执行设备热插拔的操作。The hot plug execution module 1301 is configured to perform a hot plug operation of the device when the idle server responds to the device hot plug second interrupt request sent by the first processor.
其中,设备热插拔第二中断请求为所述第一处理器接收到设备热插拔第一中断请求时,响应所述设备热插拔第一中断请求,调用并执行固件程序生成的。The device hot plugging the second interrupt request is configured to: when the first processor receives the device hot plug first interrupt request, in response to the device hot plugging the first interrupt request, invoking and executing the firmware program generation.
该热插拔执行模块执行设备热插拔的操作根据热插拔的类型而不同。The hot plug execution module performs hot swap operation of the device according to the type of hot plug.
当设备热插拔类型为热移除时,该热插拔执行模块1301可以包括:When the device hot plug type is hot removal, the hot plug execution module 1301 may include:
第二设备下线模块1311,用于生成设备下线中断请求,所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线,所述第四处理器为所述多处理器系统中能够处理所述述设备下线中断请求的任一处理器。The second device offline module 1311 is configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device, and the fourth processing The processor is any processor in the multiprocessor system capable of processing the device offline interrupt request.
第一操作执行模块1321,用于当检测到设备下线成功时,执行设备热插拔的操作。The first operation execution module 1321 is configured to perform an operation of hot plugging the device when detecting that the device is offline successfully.
当设备热插拔类型为热添加时,该热插拔执行操作可以包括:When the device hot plug type is hot add, the hot plug execution operation may include:
第二操作执行模块1331,用于执行设备热插拔的操作;a second operation execution module 1331, configured to perform an operation of hot plugging of the device;
第二设备上线模块1341,用于当所述设备热插拔的操作执行成功时,生成设备上线中断请求,所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线,所述第五处理器为所述多处理器系统中能够处理所述述设备上线中断请求的任一处理器。a second device online module 1341, configured to generate a device online interrupt request when the hot plug operation of the device is successfully performed, where the device online interrupt request is used to trigger the first processor or the fifth processor The device is online, and the fifth processor is any processor in the multi-processor system capable of processing the device online interrupt request.
其中,当设备热插拔操作执行完成时,该装置还可以向第一处理器发送设备热插拔第三中断请求。Wherein, when the device hot plug operation is completed, the device may further send a device hot plug third interrupt request to the first processor.
第一处理器响应该设备热插拔第三中断请求,可以通过调用并执行固件程序,执行例如获取设备热插拔的操作执行结果并进行标识等中断处理。 The first processor responds to the hot plugging of the third interrupt request by the device, and may perform an interrupt processing such as obtaining an operation execution result of the device hot plug and performing identification, etc., by calling and executing the firmware program.
当该空闲处理器是在进行设备资源控制时,将业务迁移后得到的,则第一处理器器响应该设备热插拔第三中断请求,还可以通过调用并执行固件程序,执行触发空闲处理器上线的操作。When the idle processor is obtained after the device resource control is performed, the first processor responds to the hot plugging of the third interrupt request by the device, and may also execute the trigger idle process by calling and executing the firmware program. The operation of the line.
在本实施例中,当空闲处理器响应设备热插拔第二中断中断请求时,执行设备热插拔的操作,由于设备热插拔操作由空闲处理器控制执行,第一处理器当前执行业务无需被反复中断,从而提高了处理器运行效率,且空闲处理器当前无执行业务,因此其执行的设备热插拔的操作无需被反复打断,保证了设备热插拔的执行效率。In this embodiment, when the idle processor responds to the device hot plugging the second interrupt interrupt request, the hot swap operation of the device is performed. Since the device hot plug operation is controlled by the idle processor, the first processor currently performs the service. There is no need to be interrupted repeatedly, which improves the operating efficiency of the processor, and the idle processor does not currently perform the service. Therefore, the hot swap operation of the device that is performed does not need to be repeatedly interrupted, thereby ensuring the execution efficiency of the device hot swap.
上述图13对应的设备资源控制装置,在实际应用中可以集成到固件程序中,该固件程序被空闲处理器调用并执行,从而实现执行设备热插拔操作,使得第一处理器的当前执行业务无需被反复中断,可以保证处理器的运行效率,同时执行的设备热插拔操作也无需被反复中断,保证了设备热插拔操作的执行效率。The device resource control device corresponding to FIG. 13 above may be integrated into a firmware program in an actual application, and the firmware program is invoked and executed by an idle processor, thereby implementing a hot plug operation of the execution device, so that the current execution service of the first processor is performed. The operation efficiency of the processor can be ensured without repeated interruptions, and the hot plug operation of the device is not required to be repeatedly interrupted, thereby ensuring the execution efficiency of the hot plug operation of the device.
因此本申请实施例还提供了一种固件程序,该固件程序包括图13中所述的设备资源控制装置。Therefore, the embodiment of the present application further provides a firmware program, which includes the device resource control device described in FIG.
本说明书中各个实施例采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似部分互相参见即可。对于实施例公开的装置而言,由于其与实施例公开的方法相对应,所以描述的比较简单,相关之处参见方法部分说明即可。The various embodiments in the present specification are described in a progressive manner, and each embodiment focuses on differences from other embodiments, and the same similar parts between the various embodiments may be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.
最后,还需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。 Finally, it should also be noted that in this context, relational terms such as first and second are used merely to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply these entities. There is any such actual relationship or order between operations. Furthermore, the term "comprises" or "comprises" or "comprises" or any other variations thereof is intended to encompass a non-exclusive inclusion, such that a process, method, article, or device that comprises a plurality of elements includes not only those elements but also Other elements, or elements that are inherent to such a process, method, item, or device. An element that is defined by the phrase "comprising a ..." does not exclude the presence of additional equivalent elements in the process, method, item, or device that comprises the element.
为了描述的方便,描述以上装置时以功能分为各种单元分别描述。当然,在实施本申请时可以把各单元的功能在同一个或多个软件和/或硬件中实现。For the convenience of description, the above devices are described separately by function into various units. Of course, the functions of each unit may be implemented in the same software or software and/or hardware when implementing the present application.
通过以上的实施方式的描述可知,本领域的技术人员可以清楚地了解到本申请可借助软件加必需的通用硬件平台的方式来实现。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品可以存储在存储介质中,如ROM/RAM、磁碟、光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例或者实施例的某些部分所述的方法。It will be apparent to those skilled in the art from the above description of the embodiments that the present application can be implemented by means of software plus a necessary general hardware platform. Based on such understanding, the technical solution of the present application may be embodied in the form of a software product in essence or in the form of a software product, which may be stored in a storage medium such as a ROM/RAM or a disk. , an optical disk, etc., includes instructions for causing a computer device (which may be a personal computer, server, or network device, etc.) to perform the methods described in various embodiments of the present application or portions of the embodiments.
对所公开的实施例的上述说明,使本领域专业技术人员能够实现或使用本申请。对这些实施例的多种修改对本领域的专业技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本申请的精神或范围的情况下,在其它实施例中实现。因此,本申请将不会被限制于本文所示的这些实施例,而是要符合与本文所公开的原理和新颖特点相一致的最宽的范围。 The above description of the disclosed embodiments enables those skilled in the art to make or use the application. Various modifications to these embodiments are obvious to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the application. Therefore, the application is not limited to the embodiments shown herein, but is to be accorded the broadest scope of the principles and novel features disclosed herein.

Claims (15)

  1. 一种设备资源控制方法,应用于多处理器系统,其中,所述多处理器系统包括第一处理器,其特征在于,所述方法包括:A device resource control method is applied to a multiprocessor system, wherein the multiprocessor system includes a first processor, and the method includes:
    所述第一处理器接收到设备热插拔第一中断请求,响应所述设备热插拔第一中断请求时,调用并执行固件程序,生成设备热插拔第二中断请求;Receiving, by the first processor, a device hot plugging first interrupt request, in response to the device hot plugging the first interrupt request, invoking and executing a firmware program, and generating a device hot plugging second interrupt request;
    所述第一处理器向空闲处理器发送所述设备热插拔第二中断请求,其中,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The first processor sends the device hot plug second interrupt request to the idle processor, wherein the device hot plug second interrupt request is used to trigger the idle processor call and execute the firmware program, Performing a hot plug operation of the device, wherein the idle processor is a processor in the multiprocessor system that currently has no service execution.
  2. 根据权利要求1所述的方法,其特征在于,所述设备热插拔第一中断请求具体为基板管理控制器BMC接收到设备热插拔请求后生成的。The method according to claim 1, wherein the device hot plugging first interrupt request is specifically generated after the substrate management controller BMC receives the device hot plug request.
  3. 根据权利要求1或2所述的方法,其特征在于,所述调用并执行固件程序,生成设备热插拔第二中断请求,包括:The method according to claim 1 or 2, wherein the calling and executing the firmware program generates a device hot plugging the second interrupt request, including:
    调用并执行固件程序,生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;Calling and executing a firmware program to generate a processor offline interrupt request, the processor offline interrupt request for triggering the first processor or the second processor to disconnect any processor that does not include itself as idle processing The second processor is any processor in the multi-processor system capable of processing the processor offline interrupt request;
    当检测到所述空闲处理器下线成功时,生成设备热插拔第二中断请求。When it is detected that the idle processor is offline, the generating device hot plugs the second interrupt request.
  4. 一种设备资源控制方法,应用于多处理器系统中,其中,所述多处理器系统包括第一处理器,其特征在于,所述方法包括:A device resource control method is applied to a multiprocessor system, wherein the multiprocessor system includes a first processor, and the method includes:
    基板管理控制器接收设备热插拔请求;The baseboard management controller receives the device hot plug request;
    所述基板管理控制器生成设备热插拔第一中断请求,并发送至所述第一处理器,以便于所述第一处理器响应该设备热插拔第一中断请求时,调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The baseboard management controller generates a device hot plug first interrupt request, and sends the first interrupt request to the first processor, so that the first processor invokes and executes the firmware when the first interrupt request is hot plugged in response to the device a program, the device hot plugs the second interrupt request, and sends the device hot plug second interrupt request to the idle processor, the device hot plugging the second interrupt request for triggering the idle processor call and executing The firmware program performs an operation of hot plugging of the device, wherein the idle processor is a processor in the multiprocessor system that currently has no service to perform.
  5. 根据权利要求4所述的方法,其特征在于,所述生成设备热插拔第一中断请求之前,所述方法还包括:The method according to claim 4, wherein before the generating device hot plugs the first interrupt request, the method further includes:
    所述基板管理控制器生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下 线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;The baseboard management controller generates a processor offline interrupt request, and the processor offline interrupt request is used to trigger the first processor or the second processor to not include any processor under itself a line as an idle processor, the second processor being any processor in the multi-processor system capable of processing the processor offline interrupt request;
    则所述生成设备热插拔第一中断请求后,所述方法还包括:After the generating device hot plugs the first interrupt request, the method further includes:
    所述基板管理控制器检测到设备热插拔的操作执行结果,或者在预设时间内未检测到设备热插拔的操作执行结果时,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线,所述第三处理器为所述多处理器系统中能够处理所述处理器上线中断请求的任一处理器。The substrate management controller detects an operation execution result of the device hot plugging, or generates a processor online interrupt request when the device performs the hot plug operation execution result within a preset time, and the processor goes online to interrupt the request. For triggering the first processor or the third processor to bring the idle processor online, and the third processor is any processor in the multi-processor system capable of processing the processor online interrupt request .
  6. 一种设备资源控制方法,应用于多处理器系统中,其中,所述多处理器系统包括第一处理器,其特征在于所述方法包括:A device resource control method is applied to a multiprocessor system, wherein the multiprocessor system includes a first processor, wherein the method includes:
    空闲处理器响应所述第一处理器发送的设备热插拔第二中断请求,所述设备热插拔第二中断请求为所述第一处理器接收到设备热插拔第一中断请求,响应所述设备热插拔第一中断请求后,调用并执行固件程序生成的;The idle processor responds to the device hot plugged second interrupt request sent by the first processor, and the device hot plugs the second interrupt request to the first processor to receive the device hot plug first interrupt request, and the response After the device hot plugs the first interrupt request, the device is invoked and executed by the firmware program;
    所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作。The idle processor invokes and executes the firmware program to perform a hot plug operation of the device.
  7. 一种设备资源控制装置,应用于多处理器系统中,其中,所述多处理系统包括第一处理器,其特征在于,所述装置包括:A device resource control device is applied to a multiprocessor system, wherein the multiprocessing system comprises a first processor, wherein the device comprises:
    中断请求生成模块,用于当所述第一处理器接收并响应设备热插拔第一中断请求时,生成设备热插拔第二中断请求;An interrupt request generating module, configured to: when the first processor receives and responds to the device hot plugging the first interrupt request, generating a device hot plugging second interrupt request;
    中断请求发送模块,用于向空闲处理器发送所述中断请求生成模块生成的所述设备热插拔第二中断请求;An interrupt request sending module, configured to send, to the idle processor, the device hot plug second interrupt request generated by the interrupt request generating module;
    其中,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。The device hot plugging a second interrupt request is used to trigger the idle processor to invoke and execute a firmware program, and perform a device hot swap operation, where the idle processor is in the multiprocessor system, currently no The processor that performs the business.
  8. 根据权利要求7所述的装置,其特征在于,所述中断请求生成模块包括:The apparatus according to claim 7, wherein the interrupt request generating module comprises:
    处理器下线模块,用于生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;a processor offline module, configured to generate a processor offline interrupt request, where the processor offline interrupt request is used to trigger the first processor or the second processor to take off any processor that does not include itself An idle processor, the second processor being any processor in the multiprocessor system capable of processing the processor offline interrupt request;
    中断请求生成子模块,用于当检测到所述空闲处理器下线成功时,生成设备热插拔第二中断请求。 The interrupt request generation submodule is configured to generate a device hot plug second interrupt request when detecting that the idle processor is offline successfully.
  9. 根据权利要8所述的装置,其特征在于,还包括:The device of claim 8 further comprising:
    处理器上线模块,用于当响应所述空闲处理器执行设备热插拔的操作结束时发送的设备热插拔第三中断请求时,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线,所述第三处理器为所述多处理器系统中能够处理所述处理器上线中断请求的任一处理器。a processor online module, configured to generate a processor online interrupt request when the device is hot plugged with a third interrupt request sent in response to the idle processor performing a hot plug operation of the device, where the processor is online for an interrupt request The first processor or the third processor is triggered to bring the idle processor online, and the third processor is any processor in the multi-processor system capable of processing the processor online interrupt request.
  10. 根据权利要求7~9任一项所述的装置,其特征在于,热插拔类型为热移除时,所述中断请求生成模块包括:The device according to any one of claims 7 to 9, wherein when the hot plug type is hot removal, the interrupt request generating module comprises:
    第一设备下线模块:用于生成设备下线中断请求,所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线,所述第四处理器为所述多处理器系统中能够处理所述设备下线中断请求的任一处理器;a first device offline module: configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device, the fourth processor Any processor in the multiprocessor system capable of processing the device offline interrupt request;
    中断请求生成子模块,用于当检测到所述设备下线成功时,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求。The interrupt request generation submodule is configured to: when detecting that the device is offline, generate a device hot plug second interrupt request, and send the device hot plug second interrupt request to the idle processor.
  11. 根据权利要求7~9任一项所述的装置,其特征在于,热插拔类型为热添加时,所述装置还包括:The device according to any one of claims 7 to 9, wherein when the hot plug type is hot addition, the device further comprises:
    第一设备上线模块,用于当确定所述空闲处理器执行设备热插拔的操作执行成功时,生成设备上线中断请求,所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线,所述第五处理器为所述多处理器系统中能够处理所述设备上线中断请求的任一处理器。a first device online module, configured to generate a device online interrupt request when determining that the idle processor performs hot swap operation of the device, the device online interrupt request is used to trigger the first processor or the fifth The processor brings the device online, and the fifth processor is any processor in the multiprocessor system capable of processing the device online interrupt request.
  12. 一种设备资源控制装置,应用于多处理器系统中,其中,所述多处理器系统包括第一处理器,其特征在于,所述装置包括:A device resource control device is applied to a multiprocessor system, wherein the multiprocessor system includes a first processor, wherein the device comprises:
    请求接收模块,用于接收设备热插拔请求;a request receiving module, configured to receive a device hot plug request;
    第一中断生成模块,用于当所述请求接收模块接收到所述设备热插拔请求时,生成设备热插拔第一中断请求,并发送至第一处理器,以便于所述第一处理器响应该设备热插拔第一中断请求,调用并执行固件程序,生成设备热插拔第二中断请求,并向空闲处理器发送所述设备热插拔第二中断请求,所述设备热插拔第二中断请求用于触发所述空闲处理器调用并执行所述固件程序,执行设备热插拔的操作,所述空闲处理器为所述多处理器系统中,当前无执行业务的处理器。a first interrupt generating module, configured to: when the request receiving module receives the device hot plug request, generate a device hot plug first interrupt request, and send the first interrupt request to the first processor, to facilitate the first processing Responding to the device hot plugging the first interrupt request, calling and executing the firmware program, generating a device hot plug second interrupt request, and sending the device hot plug second interrupt request to the idle processor, the device hot plugging Extracting a second interrupt request for triggering the idle processor call and executing the firmware program to perform a hot plug operation of the device, wherein the idle processor is a processor in the multiprocessor system that currently has no service execution .
  13. 根据权利要求12所述的装置,其特征在于,还包括: The device according to claim 12, further comprising:
    处理器下线模块,用于生成处理器下线中断请求,所述处理器下线中断请求用于触发所述第一处理器或第二处理器将不包括自身的任一处理器下线作为空闲处理器,所述第二处理器为所述多处理器系统中能够处理所述处理器下线中断请求的任一处理器;a processor offline module, configured to generate a processor offline interrupt request, where the processor offline interrupt request is used to trigger the first processor or the second processor to take off any processor that does not include itself An idle processor, the second processor being any processor in the multiprocessor system capable of processing the processor offline interrupt request;
    处理器上线模块,用于检测到设备热插拔的操作执行结果,或者在预设时间内未检测到设备热插拔的操作执行结果,生成处理器上线中断请求,所述处理器上线中断请求用于触发所述第一处理器或第三处理器将所述空闲处理器上线,所述第三处理器为所述多处理器系统中能够处理所述处理器上线中断请求的任一处理器。The processor online module is configured to detect an operation execution result of the hot swap operation of the device, or the operation execution result of the hot plug operation of the device is not detected within a preset time, generate a processor online interrupt request, and the processor goes online to interrupt the request. For triggering the first processor or the third processor to bring the idle processor online, and the third processor is any processor in the multi-processor system capable of processing the processor online interrupt request .
  14. 一种设备资源控制装置,应用于多处理器系统中,其中,所述多处理系统包括第一处理器,其特征在于,所述装置包括:A device resource control device is applied to a multiprocessor system, wherein the multiprocessing system comprises a first processor, wherein the device comprises:
    热插拔执行模块,用于当空闲处理器响应第一处理器发送的设备热插拔第二中断请求时,执行设备热插拔的操作;所述设备热插拔第二中断请求为所述第一处理器接收到设备热插拔第一中断请求时,响应所述设备热插拔第一中断请求,调用并执行固件程序生成的。a hot plug execution module, configured to perform a device hot swap operation when the idle processor responds to the device hot plug second interrupt request sent by the first processor; the device hot plug second interrupt request is When the first processor receives the device hot plug first interrupt request, it responds to the device hot plugging the first interrupt request, and invokes and executes the firmware program generation.
  15. 根据权利要求14所述的装置,其特征在于,当热插拔类型为热移除时,所述热插拔执行模块包括:The device according to claim 14, wherein when the hot plug type is hot removal, the hot plug execution module comprises:
    第二设备下线模块,用于生成设备下线中断请求,所述设备下线中断请求用于触发所述第一处理器或第四处理器将所述设备下线,所述第四处理器为所述多处理器系统中能够处理所述述设备下线中断请求的任一处理器;a second device offline module, configured to generate a device offline interrupt request, where the device offline interrupt request is used to trigger the first processor or the fourth processor to disconnect the device, the fourth processor Any processor in the multiprocessor system capable of processing the device offline interrupt request;
    第一操作执行模块,用于当检测到设备下线成功时,执行设备热插拔的操作;或者,The first operation execution module is configured to perform an operation of hot plugging the device when detecting that the device is offline successfully; or
    当热插拔类型为热添加时,所述第二中断响应模块包括:When the hot plug type is hot add, the second interrupt response module includes:
    第二操作执行模块,用于执行设备热插拔的操作;a second operation execution module, configured to perform an operation of hot plugging of the device;
    第二设备上线模块,用于当所述设备热插拔的操作执行成功时,生成设备上线中断请求,所述设备上线中断请求用于触发所述第一处理器或第五处理器将所述设备上线,所述第五处理器为所述多处理器系统中能够处理所述述设备上线中断请求的任一处理器。 a second device online module, configured to generate a device online interrupt request when the hot plug operation of the device is successfully performed, where the device online interrupt request is used to trigger the first processor or the fifth processor to The device is online, and the fifth processor is any processor in the multi-processor system capable of processing the device uplink request.
PCT/CN2014/086100 2013-11-27 2014-09-09 Device resource control method and apparatus WO2015078215A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201310617818.3 2013-11-27
CN201310617818.3A CN103631736B (en) 2013-11-27 2013-11-27 device resource control method and device

Publications (1)

Publication Number Publication Date
WO2015078215A1 true WO2015078215A1 (en) 2015-06-04

Family

ID=50212818

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/086100 WO2015078215A1 (en) 2013-11-27 2014-09-09 Device resource control method and apparatus

Country Status (2)

Country Link
CN (1) CN103631736B (en)
WO (1) WO2015078215A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103631736B (en) * 2013-11-27 2016-08-17 华为技术有限公司 device resource control method and device
CN105677373B (en) * 2014-11-17 2019-04-19 杭州华为数字技术有限公司 A kind of method and NUMA node device of node hot plug
CN104572561A (en) * 2015-01-30 2015-04-29 浪潮电子信息产业股份有限公司 Implementing method and system of overall hot plugging of clumps
CN105573868A (en) * 2015-12-10 2016-05-11 浪潮电子信息产业股份有限公司 Method for supporting non-stop online replacement of computing nodes by high-end host
CN106980588A (en) * 2016-01-18 2017-07-25 中兴通讯股份有限公司 A kind of equipment heat treatment method and device
CN110955624B (en) * 2018-09-26 2023-08-15 阿里巴巴集团控股有限公司 Hot plug method, device and system of PCIE equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6401157B1 (en) * 1999-04-30 2002-06-04 Compaq Information Technologies Group, L.P. Hot-pluggable component detection logic
CN1542638A (en) * 2003-04-28 2004-11-03 �Ҵ���˾ Non-disruptive, dynamic hot-plug and hot-remove system and method
CN101770401A (en) * 2008-12-30 2010-07-07 北京天融信网络安全技术有限公司 Method for building multi-core operating environment
CN103631736A (en) * 2013-11-27 2014-03-12 华为技术有限公司 Method and device for controlling equipment resources

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7321947B2 (en) * 2005-03-10 2008-01-22 Dell Products L.P. Systems and methods for managing multiple hot plug operations
CN101201758A (en) * 2006-12-14 2008-06-18 英业达股份有限公司 Method for detecting timer, switching multiprocessor and supporting hot plug of processor
CN102566739B (en) * 2012-01-06 2014-11-26 威盛电子股份有限公司 Multicore processor system and dynamic power management method and control device thereof
CN102855218A (en) * 2012-05-14 2013-01-02 中兴通讯股份有限公司 Data processing system, method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6401157B1 (en) * 1999-04-30 2002-06-04 Compaq Information Technologies Group, L.P. Hot-pluggable component detection logic
CN1542638A (en) * 2003-04-28 2004-11-03 �Ҵ���˾ Non-disruptive, dynamic hot-plug and hot-remove system and method
CN101770401A (en) * 2008-12-30 2010-07-07 北京天融信网络安全技术有限公司 Method for building multi-core operating environment
CN103631736A (en) * 2013-11-27 2014-03-12 华为技术有限公司 Method and device for controlling equipment resources

Also Published As

Publication number Publication date
CN103631736B (en) 2016-08-17
CN103631736A (en) 2014-03-12

Similar Documents

Publication Publication Date Title
WO2015078215A1 (en) Device resource control method and apparatus
TWI573075B (en) Persistent and resilient worker processes
US9021472B2 (en) Virtualizing baseboard management controller operation
JP5726340B2 (en) Processor system
JP2013534664A5 (en)
US8453013B1 (en) System-hang recovery mechanisms for distributed systems
WO2019028854A1 (en) Method and device for state management of virtual machine, and intelligent terminal
WO2015172283A1 (en) Method, device and mobile terminal for reducing power consumption
WO2019000790A1 (en) Method and device for calling remote procedure using synchronous mode
US8429322B2 (en) Hotplug removal of a device in a virtual machine system
WO2021036451A1 (en) Real-time communication method and apparatus for distributed system, and distributed system
JP6088531B2 (en) Event service for local client applications through a local server
CN106775920B (en) Identification and removal of zombie virtual machines
CN109766110B (en) Control method, substrate management controller and control system
US9853933B2 (en) Message queue replication with message ownership migration
CN105677606B (en) The hot-plug method and bus unit of bus apparatus
WO2015180111A1 (en) Method, apparatus and device for managing system resource
WO2022228012A1 (en) Exception handling method, apparatus and system, and electronic device
US9910804B2 (en) Input/output method in virtual machine environments
US11416318B1 (en) Application programming interface for integration flow design
US10860078B2 (en) Managing power request during cluster operations
US20160216987A1 (en) System and method for performing efficient failover and virtual machine (vm) migration in virtual desktop infrastructure (vdi)
US10152341B2 (en) Hyper-threading based host-guest communication
Wang et al. Virtual machines of high availability using hardware-assisted failure detection
TWI409700B (en) Device and method for notifying configuration files change in multiple operation systems

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14866502

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 14866502

Country of ref document: EP

Kind code of ref document: A1