Method for allocating communication space of hardware management interface and electronic device

CN123030541APending Publication Date: 2026-11-03INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611533011.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-30
Publication Date
2026-11-03

AI Technical Summary

Technical Problem

In the existing technology, the communication space allocation of the hardware management interface fails to effectively reserve resources, resulting in unstable communication performance, difficulty in meeting the functional requirements of hardware components, and easy occurrence of address and resource conflicts.

Method used

By detecting out-of-bounds conditions of the target hardware partition in the processor and correcting the base address of the next hardware partition when no out-of-bounds condition occurs, and by reserving additional resource space equal to the preset resource requirements, the reserved communication space of the target hardware partition is ensured, resource conflicts are avoided, and the rationality and stability of hardware resource allocation are improved.

Benefits of technology

By detecting out-of-bounds situations of target hardware partitions in the processor and characterizing the out-of-bounds detection of target hardware partitions in the detection results, and by correcting the out-of-bounds detection module and address correction module of the next hardware partition, reasonable allocation of hardware resources and stable communication are achieved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123030541A_ABST
    Figure CN123030541A_ABST
Patent Text Reader

Abstract

The application provides a communication space allocation method of a hardware management interface and an electronic device, which can be applied to the technical field of computers. The method comprises the following steps: in the case that no head identifier corresponding to a reserved communication space exists in a target hardware partition in a processor for carrying a communication task of the hardware management interface, performing out-of-bound detection on the target hardware partition based on a first base address of the target hardware partition, a preset resource requirement amount of a hardware component of a preset component type, and a second base address of a next hardware partition located after the target hardware partition, to obtain a detection result; in the case that the detection result represents that no out-of-bound exists in the target hardware partition, correcting the second base address based on the preset resource requirement amount, so as to set the reserved communication space in the target hardware partition re-determined based on the first base address and the corrected second base address.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and more specifically to a communication space allocation method for a hardware management interface and an electronic device. Background Technology

[0002] In processor systems where multiple hardware components collaborate, such as servers and industrial control equipment, the next-generation hardware management interface standard, exemplified by Redfish, has become a core technology for achieving cross-vendor hardware component status monitoring, instruction interaction, and resource scheduling due to its lightweight and scalable characteristics.

[0003] In the process of implementing this application, it was found that when using various hardware management interfaces for communication and management, it is necessary to ensure that stable storage space is allocated for temporary storage and forwarding of instructions. However, the allocation of processor resources in related technologies is usually adjusted in real time according to the number and demand of external devices, making it difficult to reserve resource space for hardware management interfaces, which affects the communication effect. Summary of the Invention

[0004] In view of the above problems, this application provides a communication space allocation method for a hardware management interface and an electronic device.

[0005] According to the first aspect of this application, a method for allocating communication space for a hardware management interface is provided, comprising: when it is determined that there is no header identifier corresponding to reserved communication space in the target hardware partition used to carry the communication task of the hardware management interface in the processor, performing boundary detection on the target hardware partition based on the first base address of the target hardware partition, the preset resource requirement of the hardware component of the preset component type, and the second base address of the next hardware partition after the target hardware partition, and obtaining a detection result, wherein the target hardware partition includes an initial hardware partition corresponding to the hardware component of the preset component type, the initial hardware partition is obtained by dividing the hardware resources in the processor according to the component types of multiple hardware components, and the second base address is determined according to the first base address and the partition capacity of the target hardware partition; when the detection result indicates that the target hardware partition does not exceed the boundary, correcting the second base address based on the preset resource requirement, so as to set reserved communication space in the target hardware partition re-determined based on the first base address and the corrected second base address.

[0006] The second aspect of this application provides a communication space allocation device for a hardware management interface, comprising: an out-of-bounds detection module, configured to, when it is determined that there is no header identifier corresponding to reserved communication space in the target hardware partition used to carry the communication task of the hardware management interface in the processor, perform out-of-bounds detection on the target hardware partition based on a first base address of the target hardware partition, a preset resource requirement of a hardware component of a preset component type, and a second base address of the next hardware partition after the target hardware partition, and obtain a detection result, wherein the target hardware partition includes an initial hardware partition corresponding to a hardware component of a preset component type, the initial hardware partition being obtained by dividing the hardware resources in the processor according to the component types of multiple hardware components, and the second base address being determined based on the first base address and the partition capacity of the target hardware partition; and an address correction module, configured to, when the detection result indicates that the target hardware partition does not have an out-of-bounds condition, correct the second base address based on the preset resource requirement, so as to set reserved communication space in the target hardware partition re-determined based on the first base address and the corrected second base address.

[0007] A third aspect of this application provides an electronic device comprising: one or more processors; and a memory for storing one or more computer programs, wherein the one or more processors execute the one or more computer programs to implement the steps of the method described above.

[0008] A fourth aspect of this application also provides a computer-readable storage medium having a computer program or instructions stored thereon, which, when executed by a processor, implement the steps of the above-described method.

[0009] The fifth aspect of this application also provides a computer program product, including a computer program or instructions that, when executed by a processor, implement the steps of the above-described method.

[0010] According to embodiments of this application, the header identifier of the target hardware partition is detected by a basic input / output system. If it is determined that no reserved communication space has been allocated, the boundary crossing of the target hardware partition is detected. If no boundary crossing occurs, the second base address of the next hardware partition is corrected, and additional resource space equal to the preset resource requirement is reserved for the target hardware partition. This ensures that the target hardware partition can meet the needs of hardware components of the preset component type to perform their functions, avoiding address and resource conflicts, and eliminating the need to occupy resources of the next hardware partition, thereby improving the rationality and stability of hardware resource allocation. Furthermore, setting reserved communication space in the target hardware partition to carry the communication tasks of the hardware management interface ensures the security and stability of the reserved communication space, thus ensuring the stability of communication using the hardware management interface. Attached Figure Description

[0011] The above-mentioned contents, other objects, features and advantages of this application will become clearer from the following description of embodiments of this application with reference to the accompanying drawings.

[0012] Figure 1 The diagram illustrates a communication space allocation method for a hardware management interface according to an embodiment of this application, and an application scenario diagram for an electronic device.

[0013] Figure 2 A flowchart illustrating a communication space allocation method for a hardware management interface according to an embodiment of this application is shown.

[0014] Figure 3 A flowchart of a communication space allocation method for a hardware management interface according to another embodiment of this application is shown.

[0015] Figure 4 A structural block diagram of a communication space allocation device for a hardware management interface according to an embodiment of this application is shown.

[0016] Figure 5 A block diagram of an electronic device suitable for implementing a communication space allocation method for a hardware management interface according to an embodiment of this application is shown. Detailed Implementation

[0017] The embodiments of this application will now be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of this application. In the following detailed description, numerous specific details are set forth to provide a thorough understanding of the embodiments of this application for ease of explanation. However, it will be apparent that one or more embodiments may be implemented without these specific details. Furthermore, descriptions of well-known structures and technologies are omitted in the following description to avoid unnecessarily obscuring the concepts of this application.

[0018] The terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the scope of this application. The terms “comprising,” “including,” etc., as used herein indicate the presence of the stated features, steps, operations, and / or components, but do not exclude the presence or addition of one or more other features, steps, operations, or components.

[0019] All terms used herein (including technical and scientific terms) have the meanings commonly understood by those skilled in the art, unless otherwise defined. It should be noted that the terms used herein are to be interpreted in a manner consistent with the context of this specification, and not in an idealized or overly rigid way.

[0020] When using expressions such as "at least one of A, B and C", they should generally be interpreted in accordance with the meaning that is commonly understood by those skilled in the art (e.g., "a system having at least one of A, B and C" should include, but is not limited to, a system having A alone, a system having B alone, a system having C alone, a system having A and B, a system having A and C, a system having B and C, and / or a system having A, B and C, etc.).

[0021] Embodiments of this application provide a communication space allocation method for a hardware management interface, comprising: when it is determined that there is no header identifier corresponding to reserved communication space in the target hardware partition used to carry the communication task of the hardware management interface in the processor, performing boundary detection on the target hardware partition based on the first base address of the target hardware partition, the preset resource requirement of the hardware component of the preset component type, and the second base address of the next hardware partition after the target hardware partition, and obtaining a detection result, wherein the target hardware partition includes an initial hardware partition corresponding to the hardware component of the preset component type, the initial hardware partition is obtained by dividing the hardware resources in the processor according to the component types of multiple hardware components, and the second base address is determined according to the first base address and the partition capacity of the target hardware partition; when the detection result indicates that the target hardware partition does not exceed the boundary, correcting the second base address based on the preset resource requirement, so as to set reserved communication space in the target hardware partition re-determined based on the first base address and the corrected second base address.

[0022] Figure 1 The diagram illustrates a communication space allocation method for a hardware management interface according to an embodiment of this application, and an application scenario diagram for an electronic device.

[0023] like Figure 1 As shown, the application scenario 100 according to this embodiment may include a server motherboard 110, a hardware management interface (Redfish) management terminal 120, and a baseboard management controller (BMC) interface 130.

[0024] The server motherboard 110 includes a processor 111, a baseboard management controller 112, a Basic Input / Output System (BIOS) 113, and a Peripheral Component Interconnect Express (PCIe) architecture 114. The processor 111 allocates its hardware resources to multiple initial hardware partitions within the PCIe architecture 114, including a first initial hardware partition 1141, a second initial hardware partition 1142, and a third initial hardware partition 1143. Each initial hardware partition is used to mount a hardware component of a specific component type.

[0025] Taking the first initial hardware partition 1141 with a video graphics array (VGA) as an example, the resources of the first initial hardware partition 1141 can be divided into a video graphics array hardware resource space for the VGA to perform its own functions and a reserved communication space for carrying the communication tasks of the hardware management interface.

[0026] The hardware management interface management terminal 120 can communicate with the baseboard management controller interface 130 to receive hardware management instructions sent through the baseboard management controller interface 130, convert the hardware management instructions into hardware management commands that conform to the Redfish rules, and store them in the reserved communication space of the first initial hardware partition 1141.

[0027] The processor 111, the baseboard management controller 112, and the basic input / output system 113 can communicate with the high-speed peripheral component interconnect architecture 114 to read and write from the reserved communication space of the first initial hardware partition 1141, obtain hardware management commands and obtain corresponding data based on the hardware management commands, and write the corresponding data or the execution result of the hardware management commands back to the reserved communication space, so that the hardware management interface management terminal 120 can read and write to the reserved communication space, obtain the corresponding data or the execution result of the hardware management commands, and forward it to the baseboard management controller interface 130.

[0028] Figure 2 A flowchart illustrating a communication space allocation method for a hardware management interface according to an embodiment of this application is shown.

[0029] like Figure 2 As shown, the communication space allocation method of the hardware management interface in this embodiment includes operations S210 to S220.

[0030] In operation S210, if it is determined that there is no header identifier corresponding to the reserved communication space in the target hardware partition used to carry the communication task of the hardware management interface in the processor, an out-of-bounds detection is performed on the target hardware partition based on the first base address of the target hardware partition, the preset resource requirement of the hardware component of the preset component type, and the second base address of the next hardware partition after the target hardware partition, and the detection result is obtained.

[0031] In operation S220, if the detection result indicates that the target hardware partition does not exceed the limit, the second base address is corrected based on the preset resource requirements so as to set reserved communication space in the target hardware partition that is re-determined based on the first base address and the corrected second base address.

[0032] After the terminal device containing the processor boots up, the component types of multiple hardware components in the terminal device can be obtained. Based on these component types, the hardware resources in the processor of the terminal device are then divided into multiple initial hardware partitions. Each initial hardware partition corresponds to a component type, and the hardware components of that component type can use the hardware resources in that initial hardware partition to perform their own functions.

[0033] Among multiple initial hardware partitions, the initial hardware partition corresponding to the hardware component of the preset component type can be used as the target hardware partition to carry the communication tasks of the hardware management interface. The preset component type can include the graphics output type of the PCIe interface, the hardware component of the preset component type can include VGA, etc., and the hardware management interface can include Redfish, etc.

[0034] It can be understood that using the target hardware partition to carry the communication task of the hardware management interface can specifically include: using the target hardware partition to store commands generated or processed by the hardware management interface, so that other hardware components can read and write commands in the target hardware partition, thereby executing the communication task.

[0035] A header identifier corresponding to the reserved communication space can be marked in the target hardware partition. This allows the user to issue hardware management commands through the hardware management platform, and then locate the reserved communication space through the BMC or BIOS based on the header identifier. The user can then perform read and write operations on the reserved communication space based on the hardware management commands processed by the hardware management interface, thereby controlling and managing the hardware.

[0036] Therefore, after the terminal device starts up and the initial hardware partitioning is completed, the basic input / output system can be used to detect the target hardware partition of the processor and determine whether there is a header in the target hardware partition that corresponds to the reserved communication space.

[0037] If a header identifier is confirmed to exist, the reserved communication space in the target hardware partition is considered valid. If a header identifier is not confirmed to exist, the reserved communication space in the target hardware partition is considered invalid. Reasons for the invalidation of the reserved communication space may include: no header identifier is set in the target hardware partition; the target hardware partition also needs to support hardware components of other graphics output types besides VGA; and the operation of other hardware components occupies the reserved communication space.

[0038] If the reserved communication space in the target hardware partition is determined to be invalid, the header identifier can be re-marked and the reserved communication space can be divided in the target hardware partition. Specifically, the base address of the target hardware partition can be determined as the first base address, and the partition capacity of the target hardware partition can be determined.

[0039] Based on the first base address and the partition capacity of the target hardware partition, the last address belonging to the target hardware partition can be determined. Since multiple initial hardware partitions are connected end-to-end in terms of address and do not overlap with each other, the last address of the target hardware partition is the base address of the next hardware partition after the target hardware partition. The base address of the next hardware partition can be used as the second base address.

[0040] It should be noted that when multiple hardware components of the same type exist, they may compete for resources. For VGA, according to VGA standardization constraints, it needs to occupy reserved resource space in the hardware partition. This reserved resource space can be quantified using a preset resource requirement, that is, the reserved resource space is usually an integer multiple of the preset resource requirement. Preferably, the preset resource requirement can be 16M.

[0041] In this situation, other hardware components besides VGA may preempt resources from the target hardware partition of VGA, causing the resources of the target hardware partition to fail to meet VGA standardization constraints. Therefore, during VGA operation, it needs to preempt some resources from the next hardware partition after the target hardware partition so that the sum of the resources in the target hardware partition and the resources preempted from the next hardware partition can meet the standardization constraints. This preemption behavior can lead to an out-of-bounds situation in the target hardware partition. An out-of-bounds situation means that the reserved resource space required by VGA during operation cannot be completely included within the target hardware partition; in other words, the reserved resource space includes some resources from the next hardware partition.

[0042] If an out-of-bounds error occurs, it can cause instability in the VGA and the hardware components corresponding to the next hardware partition. Therefore, out-of-bounds detection can be performed on the target hardware partition to ensure the stable operation of all hardware components.

[0043] Specifically, based on the first base address and the preset resource requirements, the last address of the target hardware partition that meets the standardization constraints of VGA can be calculated. This address is then compared with the second base address to determine the detection result indicating whether the target hardware partition has exceeded the limit.

[0044] If the test results indicate that the address determined by the sum of the first base address and the preset resource requirement is less than or equal to the second base address, it means that the target hardware partition is not out of bounds. In this case, the second base address can be shifted to correct it, ensuring that even if other hardware components preempt the target hardware partition's resources, the remaining resources of the target hardware partition can still meet the VGA standardization constraints.

[0045] Specifically, additional hardware resources can be added to the target hardware partition according to the preset resource requirements. In other words, the second base address can be shifted to the right according to the preset resource requirements. The resource quantity of the target hardware partition, redefined based on the first base address and the corrected second base address, is the sum of the original resource quantity and the preset resource requirements. After redefining the target hardware partition, reserved communication space can be set in the target hardware partition to carry the communication tasks of the hardware management interface.

[0046] Specifically, during communication using the hardware management interface, the BIOS and BMC can temporarily store hardware management interface commands and their responses in a reserved communication space, and then read and write based on this reserved communication space to achieve communication using the hardware management interface.

[0047] According to embodiments of this application, the header identifier of the target hardware partition is detected by a basic input / output system. If it is determined that no reserved communication space has been allocated, the boundary crossing of the target hardware partition is detected. If no boundary crossing occurs, the second base address of the next hardware partition is corrected, and additional resource space equal to the preset resource requirement is reserved for the target hardware partition. This ensures that the target hardware partition can meet the needs of hardware components of the preset component type to perform their functions, avoiding address and resource conflicts, and eliminating the need to occupy resources of the next hardware partition, thereby improving the rationality and stability of hardware resource allocation. Furthermore, setting reserved communication space in the target hardware partition to carry the communication tasks of the hardware management interface ensures the security and stability of the reserved communication space, thus ensuring the stability of communication using the hardware management interface.

[0048] If the test results indicate that the sum of the first base address and the preset resource requirement is greater than the second base address, it is determined that the target hardware partition is out of bounds. If the target hardware partition is determined to be out of bounds, the out-of-bounds situation can be resolved by redistributing resources among multiple initial hardware partitions before reserving additional preset resource requirements for the target hardware partition.

[0049] In addition, limit detection can be performed on multiple initial hardware partitions. If it is determined that there is at least one limit-overriding partition among the multiple initial hardware partitions, resources can also be reallocated among the multiple initial hardware partitions. In this case, the hardware resources of the limit-overriding partition cannot meet the resource requirements of at least one hardware component corresponding to the limit-overriding partition.

[0050] Therefore, the conditions for resource reallocation may include at least one of the following: among multiple initial hardware partitions, there is at least one partition that exceeds the limit; or the target hardware partition is out of bounds.

[0051] According to embodiments of this application, in such Figure 2 After operation S220, if it is determined that the multiple initial hardware partitions meet the resource reallocation conditions, the multiple initial hardware partitions are reallocated in the following manner: the hardware resources of each of the multiple initial hardware partitions and the resource requirements of at least one hardware component corresponding to each of the multiple initial hardware partitions are determined respectively; and the multiple initial hardware partitions are reallocated based on the hardware resources of each of the multiple initial hardware partitions and at least one hardware requirement.

[0052] When performing resource reallocation, the hardware resources of each initial hardware partition and the resource requirements of at least one hardware component corresponding to that initial hardware partition can be determined separately. The hardware resources and the resource requirements of at least one hardware component are compared to determine whether the current hardware resources of each initial hardware partition can meet the resource requirements of at least one hardware component. Based on the comparison results, the resource reallocation strategy is determined and the resource reallocation is completed.

[0053] Specifically, for multiple initial resource partitions, the hardware resources of each initial resource partition and at least one hardware component corresponding to the initial resource partition can be determined respectively; based on the resource requirements of each of the at least one hardware component, the peak resource requirement of the initial resource partition can be determined; and if the peak resource requirement is greater than the hardware resources of the initial resource partition, the initial resource partition can be determined as an over-limit partition.

[0054] For each initial resource partition, the resource demand of that initial resource partition reaches its peak when at least one hardware component corresponding to that initial resource partition is running simultaneously. Therefore, the resource demands of each of the at least one hardware component can be summed to obtain the peak resource demand. By comparing the peak resource demand with the hardware resources of the initial resource partition, it can be determined whether the hardware resources of the initial resource partition can meet the peak resource demand of that initial resource partition.

[0055] If the peak resource demand exceeds the hardware resources of the initial resource partition, it can be determined that the hardware resources of the initial resource partition are insufficient to support the simultaneous operation of at least one hardware component corresponding to the initial resource partition. Therefore, the initial resource partition can be determined to be an over-limit partition.

[0056] It is understandable that if the peak resource demand is less than or equal to the hardware resources of the initial resource partition, it can be determined that the hardware resources of the initial resource partition are sufficient to support the simultaneous operation of at least one hardware component corresponding to the initial resource partition. Therefore, it can be determined that the initial resource partition is an unrestricted partition.

[0057] According to the embodiments of this application, setting resource reallocation trigger conditions and executing partition resource adjustments solves the problem of hardware partition resource supply and demand imbalance. Initiating a reallocation process for over-limit and out-of-bounds partitions avoids hardware management interface communication task lag caused by insufficient resources, while simultaneously achieving dynamic scheduling of hardware resources, improving the utilization rate of processor hardware resources, and ensuring the stability of multi-component collaborative work. Furthermore, determining over-limit partitions by calculating the peak resource demand of the initial hardware partitions achieves proactive identification of resource shortage risks. Compared to methods based on real-time resource occupancy, peak calculation better reflects the extreme resource demands of hardware components, avoids resource shortages in high-load scenarios, improves the accuracy of over-limit partition determination, and provides a reliable basis for resource reallocation.

[0058] According to embodiments of this application, resource reallocation is performed on multiple initial hardware partitions based on their respective hardware resources and at least one hardware requirement, including: for at least one over-limit partition, determining the amount of resources to be supplemented for the over-limit partition based on at least one hardware requirement and the hardware resources of the over-limit partition; for at least one non-over-limit partition, determining the amount of redundant resources for the non-over-limit partition based on at least one hardware requirement and the hardware resources of the non-over-limit partition, wherein the non-over-limit partition includes initial hardware partitions different from the over-limit partition; and resource reallocation is performed on the multiple initial hardware partitions based on at least one amount of resources to be supplemented and at least one amount of redundant resources.

[0059] For over-limit partitions, the difference between the peak resource demand of the over-limit partition and the hardware resources of the over-limit partition can be used as the amount of resources to be supplemented. It can be understood that after supplementing the over-limit partition with the amount of resources to be supplemented, the resource quantity of the over-limit partition can meet its peak resource demand.

[0060] For partitions that are not over-limited, the difference between the peak resource demand of the non-over-limited partition and the peak resource demand of the non-over-limited partition can be used as the amount of redundant resources. It can be understood that after the redundant resources of the non-over-limited partition are redistributed to other initial hardware partitions, the remaining hardware resources of the non-over-limited partition can still meet its peak resource demand.

[0061] Therefore, the resource redistribution of multiple initial hardware partitions can be achieved by supplementing the resource quantity of each un-over-limit partition with its own redundant resource quantity, thereby realizing the resource redistribution of multiple initial hardware partitions.

[0062] According to embodiments of this application, a reallocation of resources is performed based on the amount of resources to be replenished in over-limit partitions and the amount of redundant resources in non-over-limit partitions, achieving targeted scheduling of hardware resources. No additional processor hardware resources are needed; the requirements of over-limit partitions can be met through internal resource reallocation, reducing hardware expansion costs. Targeted reallocation reduces resource waste and improves the efficiency and relevance of resource reallocation.

[0063] According to embodiments of this application, resource reallocation of multiple initial hardware partitions based on at least one amount of resources to be replenished and at least one amount of redundant resources may include: for at least one amount of resources to be replenished, sequentially retrieving hardware resources from the redundant resources to replenish the amount of resources to be replenished until the amount of resources to be replenished reaches a preset value; and when it is determined that at least one amount of resources to be replenished has reached the preset value, and there is a redundant amount of resources that has not reached the preset value, retrieving hardware resources from the redundant resources based on a preset resource requirement and allocating them to the target hardware partition.

[0064] For each resource quantity to be supplemented, hardware resources identical to the resource quantity to be supplemented are retrieved from the redundant resource quantity to supplement the resource quantity to be supplemented.

[0065] Specifically, the over-limit partitions can be selected sequentially to determine the amount of resources to be supplemented, and the unprocessed redundant resources can be selected from the redundant resources of multiple non-over-limit partitions to determine the size relationship between the amount of resources to be supplemented and the amount of redundant resources.

[0066] If it is determined that the amount of resources to be supplemented is less than the amount of redundant resources, hardware resources of the same amount as the amount of resources to be supplemented are retrieved from the amount of redundant resources and allocated to the over-limit partition to supplement the amount of resources to be supplemented.

[0067] For example, if the amount of resources to be supplemented is 15M and the amount of redundant resources is 20M, 15M can be allocated from the redundant resources to the over-limit partition to complete the supplementation operation of the resources to be supplemented. Then, the amount of redundant resources will be updated to 5M.

[0068] If it is determined that the amount of resources to be supplemented is greater than or equal to the amount of redundant resources, all the resources to be supplemented are assigned to the over-limit partition, and the difference between the amount of resources to be supplemented and the amount of redundant resources is calculated. The amount of resources to be supplemented is then updated, and the process of selecting redundant resources and supplementing resources is repeated until the amount of resources to be supplemented is 0.

[0069] For example, if the amount of resources to be supplemented is 20M and the amount of redundant resources is 15M, the entire amount of redundant resources can be allocated to the amount of resources to be supplemented, and the difference between the two can be determined, i.e., the current amount of resources to be supplemented is 5M. Then, the unprocessed amount of redundant resources is reselected as 10M, and 5M is retrieved from the redundant resources and allocated to the over-limit partition, completing the supplementation operation for the amount of resources to be supplemented. The amount of redundant resources is then updated to 5M.

[0070] According to the embodiments of this application, priority is given to supplementing the resource gaps in over-limit partitions, and the remaining redundant resources are allocated to the target hardware partitions, achieving a tiered optimization of resource configuration. This ensures the basic operational needs of hardware components while reserving sufficient communication space for the hardware management interface, avoiding imbalances in resource allocation, and further improving the rationality of resource utilization and the synergy of hardware partitions.

[0071] Figure 3 A flowchart of a communication space allocation method for a hardware management interface according to another embodiment of this application is shown.

[0072] like Figure 3 As shown, the communication space allocation process of this hardware management interface includes operations S301 to S310.

[0073] In operation S301, the hardware resources of the initial resource partition and the resource requirements of the hardware components corresponding to the initial resource partition are obtained.

[0074] In operation S302, calculate the peak resource demand of the initial resource partition.

[0075] In operation S303, determine whether the peak resource demand exceeds the hardware resources of the initial resource partition. If so, execute operation S304; otherwise, execute operation S306.

[0076] In operation S304, the initial resource partition is identified as an over-limit partition.

[0077] In operation S305, calculate the amount of resources to be supplemented in the over-limit partition, and then execute operation S308.

[0078] In operation S306, the initial resource partition is determined to be a non-over-limit partition.

[0079] In operation S307, calculate the amount of redundant resources in the non-over-limit partition, and then execute operation S308.

[0080] In operation S308, determine if there is an uncalculated initial resource partition. If yes, return to operation S301; otherwise, execute operation S309.

[0081] In operation S309, based on the calculated amount of resources to be supplemented and the amount of redundant resources, resources are reallocated to multiple initial resource partitions.

[0082] When operating the S310, hardware resources are allocated to the target hardware partition according to the preset resource requirements.

[0083] After the above resource reallocation operation, it can be ensured that the adjusted initial hardware partitions can meet their respective resource requirements. For the target hardware partition, since it is necessary to ensure the stability of the reserved communication space, space can be reserved for the target hardware partition through operation S230.

[0084] According to an embodiment of this application, the second base address is modified based on a preset resource requirement, including: determining a reserved resource space based on service requirements and the preset resource requirement, wherein the reserved resource space is a positive integer multiple of the preset resource requirement; and calculating the modified second base address based on the reserved resource space and the second base address.

[0085] Based on business needs, the resource multiplier can be determined, and the product of the resource multiplier and the preset resource demand can be used as the reserved resource space.

[0086] For example, if business requirements indicate that VGA does not need to perform many display tasks, the resource requirements for VGA to perform its own functions are low. Therefore, the resource multiplier can be set to 1, meaning it only needs to ensure that the standardization constraints of VGA are met. In this case, the reserved resource space can be set to 1 * 16M = 16M.

[0087] For example, if the business requirement indicates that a lot of display tasks need to be performed through VGA, the resource requirements of VGA when performing its own functions are high. In this case, the resource multiplier can be set to 3, and the reserved resource space can be set to 3*16M=48M.

[0088] According to embodiments of this application, the reserved resource space is determined based on business requirements, and the second base address is modified, thereby achieving flexible allocation of the reserved communication space. Compared to a fixed-size reserved space setting, flexible allocation is better able to adapt to changes in business requirements, avoiding resource waste caused by excessive space or communication congestion caused by insufficient space, and improving the adaptability of the reserved space.

[0089] According to an embodiment of this application, the communication space allocation method of the hardware management interface further includes: using a basic input / output system to forward a first base address to a baseboard management controller, so that the baseboard management controller determines a header identifier for marking the start of the reserved communication space based on the first base address and the hardware resources required for the operation of the hardware components of a preset component type; and determining the reserved communication space based on the header identifier and a preset amount of resources for the reserved communication space.

[0090] The basic input / output system can send a command to the board control manager to enter the driver execution environment (DXE) through the intelligent platform management interface (IPMI). The command may include the first base address.

[0091] After receiving the command, the baseboard control manager can determine the base address of the target hardware partition where the VGA is located based on the first base address carried in the command, and reserve the resource space required for the VGA to perform its own functions according to the hardware resources required for the operation of the hardware components of the preset component type. The space in the reserved resource space other than the resource space required for the VGA to perform its own functions is used as reserved communication space.

[0092] Preferably, the resource space required for the VGA to perform its own functions can be preset to 12M. The reserved resource space size is 16M. Therefore, 12M-16M of the reserved resource space can be used as reserved communication space, and the preset resource amount of the reserved communication space is 4M.

[0093] Specifically, the first address of the reserved communication space, i.e., 12M after the first base address, can be determined based on the first base address and the resource space required for the VGA to perform its functions. Therefore, a header identifier can be set at the address 12M from the first base address to mark the start of the reserved communication space.

[0094] For example, if the first base address is 6M, a header identifier can be set at 18M to mark that the reserved communication space starts from 18M, and the range of 18M-22M is the reserved communication space.

[0095] According to embodiments of this application, the base address is forwarded to the baseboard management controller via a basic input / output system, which then marks the header identifier of the reserved communication space, thereby achieving standardized identification and management of the reserved space. The header identifier allows the hardware management interface to quickly locate the communication space, avoiding the time-consuming space addressing and improving the execution efficiency of communication tasks. Simultaneously, the standardized identification mechanism facilitates subsequent space expansion and adjustment, enhancing the scalability of the method.

[0096] According to an embodiment of this application, the communication space allocation method for the hardware management interface further includes: determining a target hardware partition for carrying the communication task of the hardware management interface from multiple initial hardware partitions based on the device identifier of the hardware component of a preset component type and the device connection topology of multiple hardware components; using a basic input / output system to detect a header identifier in the target hardware partition, and determining that there is no reserved communication space in the target hardware partition for carrying the communication task of the hardware management interface if no header identifier is detected.

[0097] Device connection topology can be stored using Memory-Mapped I / O (MMIO) technology. Identifiers for hardware components of a preset component type can be obtained using the Basic Input / Output System (BIS). These identifiers can be in the form of Bus-Device-Function (BDF). Based on the BDF identifier, the initial hardware partition corresponding to that BDF identifier is then determined in PCIe MMIO, serving as the target hardware partition.

[0098] Furthermore, the basic input / output system can determine the first base address of the target hardware partition and detect the header identifier in the target hardware partition according to the relationship between the first base address and the header identifier address. If the header identifier is not detected, it can be determined that there is no reserved communication space in the current target hardware partition. If the header identifier is detected, it can be determined that there is reserved communication space in the current target hardware partition.

[0099] According to embodiments of this application, the target hardware partition is determined based on the hardware component device identifier and connection topology. Combined with header identifier detection to determine the reserved space status, accurate positioning of the target partition and rapid identification of its space status are achieved. This avoids the inefficiency caused by blindly traversing hardware partitions, while ensuring that reserved space allocation only occurs in unconfigured scenarios, preventing resource conflicts caused by duplicate allocation, and improving the overall process rigor.

[0100] According to an embodiment of this application, the communication space allocation method of the hardware management interface further includes: obtaining hardware resources in the processor; determining the number of initial hardware partitions based on the component types of the multiple hardware components; allocating hardware resources from the hardware resources in the processor to the predefined hardware partitions according to the predefined resource amount when predefined initial hardware partitions exist; and evenly distributing the remaining hardware resources in the processor to the undefined initial hardware partitions.

[0101] The number of initial hardware partitions can be the same as the number of component types, where each initial hardware partition can be used to load a hardware component of a component type to perform its own function.

[0102] For multiple component types, if a predefined initial hardware partition is determined to exist, a predefined amount of resources is allocated to the initial hardware partition from the processor's hardware resources, and the predefined amount of resources is deducted from the processor's hardware resources to calculate the remaining hardware resources of the current processor.

[0103] After completing the resource allocation for the predefined initial hardware partitions, for hardware partitions that have not been predefined, the remaining hardware resources of the processor can be evenly distributed among the undefined initial hardware partitions according to the number of undefined initial hardware partitions.

[0104] According to embodiments of this application, by combining predefined rules and an average allocation strategy to divide the initial hardware partitions, a standardized initial allocation of processor hardware resources is achieved. The predefined partitions prioritize the resource needs of core hardware components, while the average allocation of remaining resources ensures fairness for non-core components, avoiding resource imbalance during the initial allocation phase and laying a stable resource foundation for subsequent reserved space allocation and resource reallocation.

[0105] According to an embodiment of this application, the communication space allocation method of the hardware management interface may further include: when the resource partitioning method for the processor is consistent with the historical resource partitioning method stored in the memory, partitioning the hardware resources of the processor according to the resource partitioning method, wherein the resource partitioning method includes the base address and partition capacity of each of the multiple initial hardware partitions; when the resource partitioning method for the processor is inconsistent with the historical resource partitioning method stored in the memory, replacing the historical resource partitioning method stored in the memory based on the resource partitioning method for the processor of the target server.

[0106] The memory may include non-volatile random access memory (NVRAM), which can store verified historical resource allocation methods from historical resource allocation behavior.

[0107] In response to determining the resource allocation method for the processor, the new allocation method is compared with historical allocation methods. If they match, the processor's hardware resources can be directly allocated according to the new allocation method. If they do not match, the communication space allocation method of the aforementioned hardware management interface can be used to determine a new resource allocation method, which is then stored in NVRAM, overwriting the historical allocation method. This new allocation method serves as a comparison benchmark during subsequent startups, improving the efficiency and accuracy of communication space allocation.

[0108] According to embodiments of this disclosure, the server CPU includes multiple PCIe architectures, which are used as MMIO resource allocation units. Ordinary PCIe devices and the VGA controller on the BMC side are both mounted under their respective PCIe architectures. The VGA controller on the BMC side is connected to the server's PCIe topology via a PCIe bridge in the form of a PCIe EP, thus being recognized as a VGA device by the BIOS on the server side. The BMC acts as the management controller behind this VGA device, and the two share physical memory via a PCIe link.

[0109] The BIOS is the main body for server-side resource allocation and control. During the PEI or BDS stage, it enumerates PCIe devices, allocates and adjusts MMIO resources according to the PCIe architecture, and allocates VGA Base for VGA devices in a 16MB alignment manner. The 4MB MMIO space at VGA Base+12MB is used as a shared memory area for Redfish data interaction between the BIOS and BMC. At the same time, the MMIO configuration of each stack is saved through NVRAM.

[0110] On the control plane, the BIOS notifies the BMC to enter the DXE stage via IPMI commands. The BMC obtains the VGA base and marks the communication header in shared memory. The BIOS then reads the header to confirm whether Redfish initialization was successful. In the event of an OOR or VGA address out of bounds during the BDS stage, the BIOS calculates the difference in resources between each stack, uses the MMIO of the surplus stack to supply the insufficient stack, reserves an additional 16MB for the stack containing VGA, updates the NVRAM, and reboots to make the configuration take effect, thereby ensuring the stability of the Redfish communication link between the BMC and the host BIOS.

[0111] Based on the aforementioned communication space allocation method using a hardware management interface, this application also provides a communication space allocation device using a hardware management interface. The following will be combined with... Figure 4 The device is described in detail.

[0112] Figure 4 A structural block diagram of a communication space allocation device for a hardware management interface according to an embodiment of this application is shown.

[0113] like Figure 4 As shown, the communication space allocation device 400 of the hardware management interface in this embodiment includes an out-of-bounds detection module 410 and an address correction module 420.

[0114] The boundary detection module 410 is used to detect boundary issues in the target hardware partition of the processor that is used to carry the communication task of the hardware management interface. If it is determined that there is no header identifier corresponding to the reserved communication space in the target hardware partition, the module performs boundary detection on the target hardware partition based on the first base address of the target hardware partition, the preset resource requirement of the hardware component of the preset component type, and the second base address of the next hardware partition after the target hardware partition. The target hardware partition includes an initial hardware partition corresponding to the hardware component of the preset component type. The initial hardware partition is obtained by dividing the hardware resources in the processor according to the component types of multiple hardware components. The second base address is determined based on the first base address and the partition capacity of the target hardware partition. In one embodiment, the boundary detection module 410 can be used to execute the operation S210 described above, which will not be repeated here.

[0115] The address correction module 420 is used to correct the second base address based on a preset resource requirement when the detection result indicates that the target hardware partition does not exceed the boundary. This is to set reserved communication space in the target hardware partition that is redefined based on the first base address and the corrected second base address. In one embodiment, the address correction module 420 can be used to perform the operation S220 described above, which will not be repeated here.

[0116] According to an embodiment of this application, the communication space allocation device 400 of the hardware management interface further includes a demand determination module and a resource allocation module.

[0117] The requirement determination module is used to determine the hardware resources of each of the multiple initial hardware partitions and the resource requirements of at least one hardware component corresponding to each of the multiple initial hardware partitions.

[0118] The resource allocation module is used to reallocate resources among multiple initial hardware partitions based on their respective hardware resources and at least one hardware requirement.

[0119] According to an embodiment of this application, the communication space allocation device 400 of the hardware management interface further includes a component correspondence module, a resource determination module, and an over-limit judgment module.

[0120] The component-corresponding module is used to determine the hardware resources of the initial resource partition and at least one hardware component corresponding to the initial resource partition for each of the multiple initial resource partitions.

[0121] The resource determination module is used to determine the peak resource demand of the initial resource partition based on the resource requirements of at least one hardware component.

[0122] The over-limit judgment module is used to determine that the initial resource partition is an over-limit partition when the peak resource demand exceeds the hardware resources of the initial resource partition.

[0123] According to an embodiment of this application, the resource allocation module includes a first resource determination submodule, a second resource determination submodule, and a resource allocation submodule.

[0124] The first resource determination submodule is used to determine the amount of resources to be supplemented for at least one over-limit partition, based on at least one hardware requirement and the hardware resources of the over-limit partition.

[0125] The second resource determination submodule is used to determine the amount of redundant resources of at least one non-limited partition based on at least one hardware requirement and hardware resources of the non-limited partition, wherein the non-limited partition includes an initial hardware partition that is different from the limit-overriding partition.

[0126] The resource allocation submodule is used to reallocate resources among multiple initial hardware partitions based on at least one amount of resources to be replenished and at least one amount of redundant resources.

[0127] According to an embodiment of this application, the resource allocation submodule includes a resource replenishment unit and a resource pre-allocation unit.

[0128] The resource replenishment unit is used to sequentially retrieve hardware resources from the redundant resources to replenish at least one resource quantity to be replenished, until the resource quantity to be replenished reaches a preset value.

[0129] The resource pre-allocation unit is used to, based on the preset resource demand, retrieve hardware resources from the redundant resources and allocate them to the target hardware partition when it is determined that at least one resource to be supplemented has reached a preset value and there is a redundant resource that has not reached the preset value.

[0130] According to an embodiment of this application, the address correction module 420 includes a space determination submodule and an address correction submodule.

[0131] The space determination submodule is used to determine the reserved resource space based on business needs and preset resource requirements. The reserved resource space is a positive integer multiple of the preset resource requirements.

[0132] The address correction submodule is used to calculate the corrected second base address based on the reserved resource space and the second base address.

[0133] According to an embodiment of this application, the communication space allocation device 400 of the hardware management interface further includes an address forwarding module and a space determination module.

[0134] The address forwarding module is used to forward the first base address to the baseboard management controller using the basic input / output system, so that the baseboard management controller can determine the header identifier used to mark the start of the reserved communication space based on the first base address and the hardware resources required for the operation of the hardware components of the preset component type.

[0135] The space determination module is used to determine the reserved communication space based on the header identifier and the preset resource amount of reserved communication space.

[0136] According to an embodiment of this application, the communication space allocation device 400 of the hardware management interface further includes a partition determination module and an identification detection module.

[0137] The partition determination module is used to determine the target hardware partition for carrying communication tasks of the hardware management interface from multiple initial hardware partitions based on the device identifier of the hardware component of the preset component type and the device connection topology of multiple hardware components.

[0138] The identifier detection module is used to detect header identifiers in the target hardware partition using the basic input / output system. If no header identifier is detected, it is determined that there is no reserved communication space in the target hardware partition used to carry the communication task of the hardware management interface.

[0139] According to an embodiment of this application, the communication space allocation device 400 of the hardware management interface further includes a resource acquisition module, a partition counting module, a first resource allocation module, and a second resource allocation module.

[0140] The resource acquisition module is used to acquire hardware resources in the processor.

[0141] The partition counting module is used to determine the initial number of hardware partitions based on the component types of multiple hardware components.

[0142] The first resource allocation module is used to allocate hardware resources from the processor's hardware resources to the predefined hardware partition according to the predefined resource amount, provided that a predefined initial hardware partition exists.

[0143] The second resource allocation module is used to evenly distribute the remaining hardware resources in the processor to the undefined initial hardware partition.

[0144] According to embodiments of this application, any plurality of modules in the boundary detection module 410 and the address correction module 420 can be combined into one module, or any one of the modules can be split into multiple modules. Alternatively, at least a portion of the functionality of one or more of these modules can be combined with at least a portion of the functionality of other modules and implemented in one module. According to embodiments of this application, at least one of the boundary detection module 410 and the address correction module 420 can be at least partially implemented as hardware circuitry, such as a field-programmable gate array (FPGA), a programmable logic array (PLA), a system-on-a-chip, a system-on-a-substrate, a system-on-package, an application-specific integrated circuit (ASIC), or implemented in hardware or firmware by any other reasonable means of integrating or packaging the circuitry, or implemented in any one of software, hardware, and firmware methods, or in a suitable combination of any of these. Alternatively, at least one of the boundary detection module 410 and the address correction module 420 can be at least partially implemented as a computer program module, which can perform corresponding functions when the computer program module is run.

[0145] Figure 5 A block diagram of an electronic device suitable for implementing a communication space allocation method for a hardware management interface according to an embodiment of this application is shown.

[0146] like Figure 5 As shown, an electronic device 500 according to an embodiment of this application includes a processor 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage portion 508 into a random access memory (RAM) 503. The processor 501 may include, for example, a general-purpose microprocessor (e.g., a CPU), an instruction set processor and / or an associated chipset and / or a special-purpose microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 501 may also include onboard memory for caching purposes. The processor 501 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of this application.

[0147] RAM 503 stores various programs and data required for the operation of electronic device 500. Processor 501, ROM 502, and RAM 503 are interconnected via bus 504. Processor 501 executes various operations of the method flow according to embodiments of this application by executing programs in ROM 502 and / or RAM 503. It should be noted that the programs may also be stored in one or more memories other than ROM 502 and RAM 503. Processor 501 may also execute various operations of the method flow according to embodiments of this application by executing programs stored in said one or more memories.

[0148] According to embodiments of this application, the electronic device 500 may further include an input / output (I / O) interface 505, which is also connected to a bus 504. The electronic device 500 may also include one or more of the following components connected to the input / output (I / O) interface 505: an input section 506 including a keyboard, mouse, etc.; an output section 507 including a cathode ray tube (CRT), liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 508 including a hard disk, etc.; and a communication section 509 including a network interface card such as a LAN card, modem, etc. The communication section 509 performs communication processing via a network such as the Internet. A drive 510 is also connected to the input / output (I / O) interface 505 as needed. A removable medium 511, such as a disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on the drive 510 as needed so that computer programs read from it can be installed into the storage section 508 as needed.

[0149] This application also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiments; or it may exist independently and not assembled into the device / apparatus / system. The computer-readable storage medium carries one or more programs, which, when executed, implement the method according to the embodiments of this application.

[0150] According to embodiments of this application, the computer-readable storage medium can be a non-volatile computer-readable storage medium, such as including but not limited to: portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this application, the computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. For example, according to embodiments of this application, the computer-readable storage medium may include ROM 502 and / or RAM 503 and / or one or more memories other than ROM 502 and RAM 503 described above.

[0151] Embodiments of this application also include a computer program product comprising a computer program containing program code for performing the methods shown in the flowchart. When the computer program product is run on a computer system, the program code is used to cause the computer system to implement the methods provided in the embodiments of this application.

[0152] When the computer program is executed by the processor 501, it performs the functions defined in the system / apparatus of this application embodiment. According to the embodiments of this application, the systems, apparatuses, modules, units, etc., described above can be implemented by computer program modules.

[0153] In one embodiment, the computer program may rely on a tangible storage medium such as an optical storage device or a magnetic storage device. In another embodiment, the computer program may also be transmitted and distributed in the form of signals over a network medium, and may be downloaded and installed via the communication section 509, and / or installed from a removable medium 511. The program code contained in the computer program can be transmitted using any suitable network medium, including but not limited to: wireless, wired, etc., or any suitable combination thereof.

[0154] In such an embodiment, the computer program can be downloaded and installed from a network via communication section 509, and / or installed from removable medium 511. When the computer program is executed by processor 501, it performs the functions defined in the system of this application embodiment. According to embodiments of this application, the systems, devices, apparatuses, modules, units, etc., described above can be implemented by computer program modules.

[0155] According to embodiments of this application, program code for executing the computer programs provided in the embodiments of this application can be written in any combination of one or more programming languages. Specifically, these computational programs can be implemented using high-level procedural and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages ​​include, but are not limited to, languages ​​such as Java, C++, Python, "C", or similar programming languages. The program code can be executed entirely on the user's computing device, partially on the user's device, partially on a remote computing device, or entirely on a remote computing device or server. In cases involving remote computing devices, the remote computing device can be connected to the user's computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computing device (e.g., via the Internet using an Internet service provider).

[0156] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0157] Those skilled in the art will understand that the features described in the various embodiments of this application can be combined and / or combined in various ways, even if such combinations or combinations are not explicitly described in this application. In particular, the features described in the various embodiments of this application can be combined and / or combined in various ways without departing from the spirit and teachings of this application. All such combinations and / or combinations fall within the scope of this application.

[0158] The embodiments of this application have been described above. However, these embodiments are merely illustrative and not intended to limit the scope of this application. Although various embodiments have been described above, this does not mean that the measures in the various embodiments cannot be used advantageously in combination. Without departing from the scope of this application, those skilled in the art can make various substitutions and modifications, all of which should fall within the scope of this application.

Claims

1. A method for allocating communication space for a hardware management interface, characterized in that, The method includes: If it is determined that there is no header identifier corresponding to the reserved communication space in the target hardware partition used to carry the communication task of the hardware management interface in the processor, an out-of-bounds detection is performed on the target hardware partition based on the first base address of the target hardware partition, the preset resource requirement of the hardware component of the preset component type, and the second base address of the next hardware partition after the target hardware partition, and a detection result is obtained. The target hardware partition includes an initial hardware partition corresponding to the hardware component of the preset component type. The initial hardware partition is obtained by dividing the hardware resources in the processor according to the component types of multiple hardware components. The second base address is determined according to the first base address and the partition capacity of the target hardware partition. If the detection result indicates that the target hardware partition does not exceed the limit, the second base address is corrected based on the preset resource requirement, so as to set the reserved communication space in the target hardware partition that is re-determined based on the first base address and the corrected second base address.

2. The method according to claim 1, characterized in that, The method further includes: If it is determined that the plurality of initial hardware partitions meet the resource reallocation conditions, the plurality of initial hardware partitions shall be reallocated in the following manner: Determine the hardware resources of each of the plurality of initial hardware partitions and the resource requirements of at least one hardware component corresponding to each of the plurality of initial hardware partitions; and Based on the hardware resources of each of the multiple initial hardware partitions and at least one of the hardware requirements, resources are reallocated to the multiple initial hardware partitions. The resource reallocation conditions include at least one of the following: Among the plurality of initial hardware partitions, there is at least one over-limit partition, wherein the hardware resources of the over-limit partition cannot meet the resource requirements of at least one hardware component corresponding to the over-limit partition. The target hardware partition is out of bounds, wherein if the detection result indicates that the sum of the first base address and the preset resource requirement is greater than the second base address, it is determined that the target hardware partition is out of bounds.

3. The method according to claim 2, characterized in that, The method further includes: For each of the multiple initial resource partitions, the hardware resources of the initial resource partition and at least one hardware component corresponding to the initial resource partition are determined respectively. Based on the resource requirements of at least one of the hardware components, determine the peak resource requirement of the initial resource partition; and If the peak resource demand exceeds the hardware resources of the initial resource partition, the initial resource partition is determined to be an over-limit partition.

4. The method according to claim 2, characterized in that, The step of reallocating resources among the multiple initial hardware partitions based on their respective hardware resources and at least one of the hardware requirements includes: For at least one of the over-limit partitions, the amount of resources to be supplemented for the over-limit partition is determined based on at least one of the hardware requirements of the over-limit partition and the hardware resources of the over-limit partition. For at least one non-over-limit partition, based on at least one of the hardware requirements of the non-over-limit partition and the hardware resources of the non-over-limit partition, determine the amount of redundant resources for the non-over-limit partition, wherein the non-over-limit partition includes an initial hardware partition that is different from the over-limit partition; and Based on at least one of the resources to be supplemented and at least one of the redundant resources, resources are reallocated to multiple initial hardware partitions.

5. The method according to claim 4, characterized in that, The process of reallocating resources among multiple initial hardware partitions based on at least one of the resources to be supplemented and at least one of the redundant resources includes: For at least one of the resource quantities to be replenished, hardware resources are sequentially retrieved from the redundant resource quantities to replenish the resource quantities to be replenished until the resource quantities to be replenished reach a preset value; and If it is determined that at least one of the resource quantities to be supplemented has reached the preset value, and there is a redundant resource quantity that has not reached the preset value, then based on the preset resource requirement, hardware resources are retrieved from the redundant resource quantity and allocated to the target hardware partition.

6. The method according to claim 1, characterized in that, The step of modifying the second base address based on the preset resource requirement includes: Based on business needs and the preset resource requirements, a reserved resource space is determined, wherein the reserved resource space is a positive integer multiple of the preset resource requirements; and The corrected second base address is calculated based on the reserved resource space and the second base address.

7. The method according to claim 1, characterized in that, The method further includes: Using the basic input / output system, the first base address is forwarded to the baseboard management controller, so that the baseboard management controller, based on the first base address and the hardware resources required for the operation of the hardware components of the preset component type, determines a header identifier for marking the start of the reserved communication space; and The reserved communication space is determined based on the header identifier and the preset resource amount of the reserved communication space.

8. The method according to claim 7, characterized in that, The method further includes: Based on the device identifier of the hardware component of the preset component type and the device connection topology of the multiple hardware components, a target hardware partition for carrying the communication task of the hardware management interface is determined from the multiple initial hardware partitions; and Using the basic input / output system, the header identifier is detected in the target hardware partition. If the header identifier is not detected, it is determined that the reserved communication space does not exist in the target hardware partition used to carry the communication task of the hardware management interface.

9. The method according to claim 1, characterized in that, The method further includes: Obtain the hardware resources in the processor; The number of initial hardware partitions is determined based on the component types of the various hardware components. If a predefined initial hardware partition exists, hardware resources are allocated from the processor's hardware resources to the predefined hardware partition according to a predefined resource amount; and The remaining hardware resources in the processor are evenly distributed to the undefined initial hardware partition.

10. An electronic device, comprising: One or more processors; Memory, used to store one or more computer programs. The characteristic feature is that the one or more processors execute the one or more computer programs to implement the steps of the method according to any one of claims 1 to 9.