Configuration retention method, device, equipment and medium

By comparing the current configuration menu with the reserved configuration table during the BIOS upgrade process, only the changed configuration options are saved in the handover block space, solving the problems of excessive memory resource usage and low upgrade efficiency during BIOS upgrades, and achieving more efficient resource utilization and fast upgrades.

CN120447993BActive Publication Date: 2025-09-23INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510927952.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-07-07
Publication Date
2025-09-23
Estimated Expiration
2045-07-07

AI Technical Summary

Technical Problem

During a BIOS upgrade, the retained configuration may cause excessive memory usage and low upgrade efficiency.

Method used

By comparing the current configuration menu of the BIOS with the reserved configuration table, the configuration options that have been changed are determined, and only the handover block space of the corresponding size is requested to save the information of these configuration options. The computer is initialized in combination with the current configuration menu and the handover block space.

Benefits of technology

It reduces the resource usage of the handover block space, improves computer resource utilization, shortens the upgrade time, and improves the upgrade speed and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120447993B_ABST
    Figure CN120447993B_ABST
Patent Text Reader

Abstract

The present invention discloses a configuration reservation method, apparatus, device and medium, and relates to the field of computer technology. When a reserved configuration table is received, a basic input / output system compares its current configuration menu with the reserved configuration table, determines the configuration options that have been changed, and then applies for a handover block space only for the configuration options that have been changed. During configuration, the handover block space and the current configuration menu are simultaneously used to initialize the computer. Configurations that are inconsistent with the configuration options in the reserved configuration table and the current configuration menu are accurately screened through comparison, and only these inconsistent configurations are saved in the handover block space, thereby reducing the resource occupation of the handover block space and improving the resource utilization of the computer. The basic input / output system can also quickly locate and process each configuration option by reading the information in the handover block space, saving the time cost of upgrading, accelerating the upgrading speed and improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a configuration reservation method, apparatus, device and medium. Background Art

[0002] During computer system operation, the BIOS (Basic Input / Output System) plays a vital role as the bridge between the computer hardware and the operating system. It is responsible for key tasks such as initializing hardware devices and loading the operating system. With the continuous advancement of hardware technology and the increasing functionality of software, the BIOS requires regular updates to fix vulnerabilities, add new features, or improve system performance. During a BIOS update, users often wish to retain their previously customized configurations made in the BIOS setup interface. Currently, when the Baseboard Management Controller (BMC) transfers a retain configuration table, the BIOS allocates a HOB (Hand-Off Block) of the same size to store these configurations. Subsequently, during computer initialization, the BIOS configures the computer according to the configurations stored in the HOB. However, because the retain configuration table contains the entire BIOS setup options, the HOB space allocated by the BIOS is often very large. This not only consumes valuable computer memory resources, but also requires a full read / write operation to retrieve the configuration, even if only minor configuration changes are made during a BIOS update. This increases upgrade time and reduces upgrade efficiency.

[0003] It can be seen that how to solve the problems of excessive memory resource usage and low upgrade efficiency caused by retaining configuration during BIOS upgrade is a problem that needs to be solved by those skilled in the art. Summary of the Invention

[0004] The purpose of the embodiments of the present invention is to provide a configuration retention method, apparatus, device and medium, which can solve the problems of excessive memory resource occupation and low upgrade efficiency caused by retaining configuration during BIOS upgrade.

[0005] To solve the above technical problems, an embodiment of the present invention provides a configuration reservation method, which is applied to a basic input / output system. The configuration reservation method includes:

[0006] When receiving the reserved configuration table of the basic input and output system, comparing the current configuration menu of the basic input and output system with the reserved configuration table to determine whether there is a changed configuration option in the current configuration menu;

[0007] Apply for the corresponding size of the handover block space based on the configuration options that have been changed;

[0008] Save the changed configuration options and the corresponding configuration information of the configuration options in the reserved configuration table to the handover block space;

[0009] When initializing the computer, for the configuration options existing in the handover block space, the computer is initialized based on the corresponding configuration information in the handover block space;

[0010] For configuration options that do not exist in the handover block space, the computer is initialized based on the corresponding configuration information in the current configuration menu.

[0011] In some embodiments, after the computer is initialized, the process further includes:

[0012] Generate a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the corresponding configuration information of the configuration options in the reserved configuration table, and the current configuration menu;

[0013] The reserved configuration table corresponding to this initialization is sent to the baseboard management controller.

[0014] In some embodiments, generating a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the configuration information corresponding to the configuration options in the reserved configuration table, and the current configuration menu includes:

[0015] In the driver execution environment phase, the configuration information in the handover block space is synchronized to the configuration options corresponding to the current configuration menu to obtain an adjusted configuration menu;

[0016] During the boot phase, the adjusted configuration menu is read, and a reserved configuration table corresponding to this initialization is generated based on the read result.

[0017] In some embodiments, before comparing the current configuration menu of the basic input and output system with the reserved configuration table, the method further includes:

[0018] The baseboard management controller receives the reserved configuration table of the basic input and output system sent by the baseboard management controller. The baseboard management controller sends the reserved configuration table to the basic input and output system when receiving the upgrade instruction of the basic input and output system.

[0019] In some embodiments, saving the modified configuration options and the configuration information corresponding to the configuration options in the reserved configuration table to the handover block space includes:

[0020] Save the changed configuration options to the handover block space based on the preset format;

[0021] Determine the position correspondence between the configuration information corresponding to the configuration option in the retained configuration table and the configuration option according to the preset rules, and save the configuration information corresponding to the configuration option in the retained configuration table to the corresponding position in the handover block space according to the position correspondence and based on the preset format.

[0022] In some embodiments, applying for a corresponding size of the interleaving block space based on the changed configuration option includes:

[0023] Determine the configuration options that have been changed and the original data volume of the configuration information corresponding to the configuration options in the retained configuration table;

[0024] Determine the overhead corresponding to the preset format based on the amount of original data;

[0025] The sum of the original data amount and the overhead data amount is used as the target size, and an intersection block space of the target size is requested from the central processing unit cache of the computer.

[0026] In some embodiments, comparing the current configuration menu of the basic input and output system with the reserved configuration table to determine whether there is a changed configuration option in the current configuration menu includes:

[0027] Classifying all configuration options in the current configuration menu of the basic input and output system according to a preset classification method to obtain configuration options of several categories;

[0028] Traversing a number of categories in a first preset order;

[0029] When traversing any category, traverse all configuration options in the category according to the second preset order;

[0030] For any configuration option, compare the configuration information corresponding to the configuration option in the current configuration menu with the configuration information corresponding to the configuration option in the reserved configuration table;

[0031] Determine whether the configuration information corresponding to the configuration option in the current configuration menu is completely consistent with the configuration information corresponding to the configuration option in the reserved configuration table;

[0032] If so, it is determined that there is no change in the configuration option;

[0033] If not, it is determined that the configuration option has been changed and a mark is added to the configuration option;

[0034] Configuration options for which a flag exists are identified as configuration options for which changes have occurred.

[0035] To solve the above technical problems, an embodiment of the present invention further provides a configuration retention device, which is applied to a basic input and output system. The configuration retention device includes:

[0036] a comparing unit, configured to, upon receiving the reserved configuration table of the basic input / output system, compare the current configuration menu of the basic input / output system with the reserved configuration table, and determine whether there is a changed configuration option in the current configuration menu;

[0037] An application unit is used to apply for a handover block space of a corresponding size based on a changed configuration option;

[0038] A saving unit, configured to save the modified configuration options and the configuration information corresponding to the configuration options in the reserved configuration table to the handover block space;

[0039] a first initialization unit configured to initialize the computer based on corresponding configuration information in the interface block space for configuration options in the interface block space when initializing the computer;

[0040] The second initialization unit is configured to initialize the computer based on the corresponding configuration information in the current configuration menu for the configuration options that do not exist in the handover block space.

[0041] To solve the above technical problems, an embodiment of the present invention further provides an electronic device, including:

[0042] Memory for storing computer programs;

[0043] A processor is configured to execute a computer program to implement the steps of the aforementioned configuration reservation method.

[0044] To solve the above technical problems, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the configuration reservation method as described above are implemented.

[0045] It can be seen from the above technical solution that when the reserved configuration table is received, the basic input and output system will compare its own current configuration menu with the reserved configuration table, determine the configuration options that have been changed, and then apply for the handover block space only for the configuration options that have been changed. During configuration, the handover block space and the current configuration menu are simultaneously used to initialize the computer; the beneficial effect of the present invention is that, through comparison, the configurations in the reserved configuration table that are inconsistent with the configuration options in the current configuration menu are accurately screened, and only these inconsistent configurations are saved in the handover block space, thereby reducing the resource occupation of the handover block space and improving the resource utilization of the computer, and also enabling the basic input and output system to quickly locate and process each configuration option by reading the information in the handover block space, saving the time cost of upgrading, speeding up the upgrade speed, and improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] In order to more clearly illustrate the embodiments of the present invention, the following is a brief introduction to the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0047] Figure 1 A flowchart of a configuration retention method provided in an embodiment of the present invention;

[0048] Figure 2 A schematic diagram of a flow chart of another configuration reservation method provided in an embodiment of the present invention;

[0049] Figure 3 A schematic diagram of a process for retaining configuration information after initialization is completed provided by an embodiment of the present invention;

[0050] Figure 4 A schematic structural diagram of a configuration retention device provided in an embodiment of the present invention;

[0051] Figure 5 A schematic structural diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0052] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making any creative efforts shall fall within the scope of protection of the present invention.

[0053] The terms "including" and "having," as used in the present description and accompanying drawings, and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus comprising a series of steps or elements is not limited to the listed steps or elements and may include steps or elements that are not listed.

[0054] In order to enable those skilled in the art to better understand the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific implementation methods.

[0055] Next, a configuration reservation method provided by an embodiment of the present invention is described in detail, which is applied to a basic input and output system. Figure 1 As shown, Figure 1 A flowchart of a configuration retention method provided in an embodiment of the present invention; the configuration retention method includes:

[0056] S11: upon receiving the reserved configuration table of the basic input / output system, comparing the current configuration menu of the basic input / output system with the reserved configuration table to determine whether there is a changed configuration option in the current configuration menu;

[0057] It's easy to understand that to avoid excessive HOB space being allocated when preserving BIOS configurations, preserving and processing them is a waste of resources, especially for configuration options that haven't changed before or after the upgrade. However, during a BIOS upgrade, some BIOS configurations may be modified. To preserve the user's personalized configuration, when the computer restarts after the BIOS upgrade, the BIOS first retrieves its own preserved configuration table and compares it with its current configuration menu to determine which configuration options have changed before and after the upgrade.

[0058] It's important to note that the BIOS itself has a configuration retention mechanism. Before an upgrade, all configuration options in the BIOS configuration menu and their corresponding configuration information are stored in the BMC in the form of a retained configuration table. Generally speaking, after each computer initialization, the BIOS sends all contents of its configuration menu to the BMC to generate the retained configuration table corresponding to that initialization. Therefore, the retained configuration table refers to the configuration previously stored by the BIOS in the BMC. It records the user's previous configuration settings in the BIOS setup and serves as an important basis for subsequent configuration retention and initialization. After the BIOS upgrade is complete, this retained configuration table can be retrieved and compared with the current configuration menu to determine which configuration options in the BIOS configuration menu have changed since the upgrade. Changed configuration options refer to those whose corresponding configuration information has changed. The current BIOS configuration menu refers to the BIOS configuration menu after the upgrade. The BIOS configuration menu refers to the various configuration option menus within the BIOS setup interface (BIOS Setup), i.e., the specific contents of the BIOS Setup program. This application does not specifically limit the method for obtaining the retained configuration table or its specific implementation. The retained configuration package can be implemented in formats such as JSON (JavaScript Object Notation) and XML (eXtensible Markup Language). There are also various options for comparing the current configuration menu with the retained configuration table. For example, in UEFI (Unified Extensible Firmware Interface), the EDKII (EFI Development Kit II) framework can be used to extend the CompareConfigLib library to implement configuration option comparison. Specifically, each configuration option in the current configuration menu and the retained configuration table must be compared to see if the corresponding configuration information has changed. This comparison requires a detailed comparison of various aspects of the configuration information, including configuration values ​​and configuration status, to ensure accurate consistency between the two. Only when all aspects of the configuration information are completely consistent can the corresponding configuration option be determined to have not changed. If any inconsistency exists, the corresponding configuration option is determined to be inconsistent and has been changed.

[0059] S12: applying for a handover block space of a corresponding size based on the changed configuration options;

[0060] As you can understand, after determining which configuration options have changed in the current configuration menu, the BIOS will only apply for HOB space based on the data size corresponding to the changed configuration options. For example, if only one configuration option has changed, the BIOS only needs to apply for HOB space that can store this configuration option. Based on the inconsistent configuration options that have been screened out, the BIOS dynamically applies for HOB space of appropriate size, thus implementing dynamic HOB space management. Compared to applying for HOB space of the same size as the entire reserved configuration table, this dynamic application method in this application can accurately control the size of the HOB space applied according to actual needs. If only a few configuration options have changed, the HOB space applied will be very small, thereby effectively reducing memory resource usage.

[0061] S13: Saving the changed configuration options and the corresponding configuration information of the configuration options in the reserved configuration table to the handover block space;

[0062] It is easy to understand that after the HOB space application is completed, the modified configuration options and the corresponding configuration information in the reserved configuration table need to be saved to the HOB space so that the BIOS can subsequently obtain the reserved configuration corresponding to the modified configuration options from the HOB space. This application does not specifically limit the specific saving method.

[0063] S14: When initializing the computer, for the configuration options in the handover block space, the computer is initialized based on the corresponding configuration information in the handover block space;

[0064] S15: For configuration options that do not exist in the handover block space, the computer is initialized based on the corresponding configuration information in the current configuration menu.

[0065] It is understandable that after completing the application for the HOB space and saving the configuration, the BIOS will begin to initialize the computer according to the configuration saved in the HOB space and the configuration in the current configuration menu. For configuration options that have not been changed, the corresponding configuration information in the current configuration menu is the user's personalized configuration that needs to be retained. Therefore, the configuration information in the current configuration menu can be directly used to initialize the configuration of the corresponding configuration option. For configuration options that have been changed, the corresponding configuration information in the current configuration menu is the result of an upgrade change. At this time, the corresponding configuration information in the retained configuration table is the user's personalized configuration that needs to be retained. Therefore, it is necessary to obtain the corresponding configuration information in the retained configuration table from the HOB space and use the configuration information in the HOB space to initialize the configuration of the corresponding configuration option. Finally, the HOB space and the current configuration menu are used to complete the configuration corresponding to all configuration options, achieving complete initialization of the computer.

[0066] It should be noted that this application does not specifically limit the specific type of computer and implementation method. This application does not specifically limit the specific setting method of configuration options in the BIOS, including the specific type of each configuration option and the specific content of the configuration information corresponding to the configuration option. These settings can be made according to the specific configuration requirements and application scenarios of the computer in actual application. The configuration retention method provided in this application can be applied during the BIOS upgrade process of a computer system. Primarily, after the BIOS upgrade, when the computer automatically restarts and enters the POST (Power On Self Test) phase, the configuration retention method applies the target configuration, such as the user's personalized configuration or the specific configuration that needs to be retained, to the BIOS initialization process of the computer, to ensure that the computer can complete the configuration based on the target configuration. Since the number of configuration options that need to be processed and saved is reduced, the configuration processing time of the BIOS during the upgrade process is greatly shortened, thereby quickly completing the computer initialization and then quickly completing the BIOS upgrade process. This configuration retention method can be widely applicable to scenarios such as servers and workstations where frequent BIOS upgrades are required, and is particularly suitable for scenarios where BIOS configuration retention and recovery are performed through the BMC in server systems.

[0067] As a specific embodiment, see Figure 2 As shown, Figure 2 A flowchart of another configuration retention method provided by an embodiment of the present invention; to facilitate the setting and application of different computer and BIOS operating modes, the computer or BIOS setup will set different operation items, such as a yes operation item and a no operation item in the BIOS setup setting to determine whether the configuration upgrade needs to be retained. If the user clicks the yes operation item, it indicates that the user needs to retain the configuration upgrade. In this case, after the BIOS upgrade is completed, when the computer restarts and starts up, the configuration retention method provided by this application is triggered. If the user clicks the no operation item, the configuration retention method provided by this application will not be triggered subsequently.

[0068] After the configuration retention method is triggered, the BMC will first detect the need for a BIOS upgrade through the results of this operation. When the BMC detects the need for a BIOS upgrade, it will pass the retention configuration table containing the entire BIOS setup options to the BIOS. After receiving the retention configuration table passed by the BMC, the BIOS will start the item-by-item comparison mechanism to compare the retention configuration table with the current BIOS setup item by item. Specifically, the BIOS will perform a detailed comparison of each configuration option in the retention configuration table with the corresponding configuration option in the BIOS setup of the current BIOS according to the preset classification and order of the configuration options. This comparison goes deep into the key information level such as the value and status of the configuration options. For example, for the boot sequence option, not only the name of the boot device must be considered, but also the details such as the priority order of the boot device must be accurate; for the password option in the security settings, it is necessary to ensure that the characters, length, format, etc. of the password are exactly the same to be considered the same. Through this comprehensive comparison, it is possible to accurately identify which configuration options have changed before and after the upgrade.

[0069] After completing the item-by-item comparison, the BIOS filters the results to identify inconsistent configuration options. For configuration options that are identical between the retained configuration table and the current BIOS setup, the BIOS excludes them from further processing and applies them directly to the computer initialization phase. For inconsistent configuration options, the BIOS marks them and collects their associated configuration information (including the name, original value, and new value). This marking and information collection makes subsequent handling of inconsistent configuration options more efficient and targeted. For example, if a graphics card resolution setting is inconsistent, the BIOS marks the configuration option and records the graphics card resolution value in the retained configuration table and the current BIOS setup, allowing for accurate update and configuration during initialization. After filtering, inconsistent configuration options need to be saved to the HOB space. Therefore, the BIOS dynamically allocates an appropriately sized HOB space based on the identified inconsistent configuration options. This HOB space is used solely to store these inconsistent configuration options, significantly reducing memory usage.

[0070] Finally, after completing the HOB space application and saving the configuration, the BIOS begins initializing the computer according to the configuration information for the inconsistent configuration options stored in the HOB. For configuration options not recorded in the HOB space, the BIOS retains the current BIOS Setup default settings or the previously valid settings. This targeted update method ensures the continuity of important user configurations while avoiding unnecessary configuration changes, improving the efficiency of computer system initialization. In this way, the BIOS can quickly complete computer system initialization while ensuring that user configurations are accurately preserved.

[0071] The configuration retention method provided by the present invention includes a complete BIOS configuration retention method based on difference analysis, starting with the baseboard management (BMC) transferring a retention configuration table, sequentially comparing the retention configuration table with the current BIOS setup, filtering inconsistent configuration options, saving the inconsistent configuration options to a HOB space, and initializing the computer system according to the configuration in the HOB. This method completes the BIOS upgrade and computer initialization based on the upgraded BIOS, completing the complete upgrade process. This configuration retention method and BIOS upgrade process can reduce memory resource usage in the computer system by reducing HOB space usage, while also preventing the impact of the retained configuration on the BIOS upgrade speed, thereby improving the BIOS upgrade speed and efficiency.

[0072] Furthermore, if the user needs to modify the configuration, he or she needs to first modify the configuration information in the corresponding configuration options in the BIOS Setup. After saving, click the operation item for restarting without retaining the configuration. At this time, after the BMC detects this operation item, it will not trigger the configuration retention method; the computer restarts normally, and after restarting, the BIOS directly initializes the computer according to the modified and saved BIOS Setup. After initialization is completed, the retained configuration table is regenerated according to the modified and saved BIOS Setup, and transmitted to the BMC to update the retained configuration table in the BMC; ensure that the retained configuration table in the BMC is always the latest user configuration.

[0073] This invention proposes a BIOS configuration retention method based on differential analysis. This method optimizes the configuration retention process during BIOS upgrades through a differentiated storage mechanism, significantly reducing memory resource usage and improving upgrade efficiency. By accurately screening the configurations that are inconsistent between the retained configuration table and the current BIOS setup, only these inconsistent configurations are saved to the HOB space, thereby reducing HOB space usage. This allows the HOB space to efficiently retain the user's original configuration settings during the BIOS upgrade process, improving computer system resource utilization. It also enables the BIOS to quickly locate and process various configuration options when reading configuration information from the HOB space, accelerating BIOS upgrades and enhancing the user experience.

[0074] See also Figure 3 As shown, Figure 3 A flowchart of retaining configuration information after initialization is provided in an embodiment of the present invention; in some embodiments, after the computer is initialized, the process further includes:

[0075] Generate a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the corresponding configuration information of the configuration options in the reserved configuration table, and the current configuration menu;

[0076] The reserved configuration table corresponding to this initialization is sent to the baseboard management controller.

[0077] It is not difficult to understand that in order to ensure the consistency and integrity of the configuration information in the retained configuration table and avoid abnormal situations such as data loss or data errors, the BIOS needs to synchronously update the retained configuration table in the BMC after each computer initialization is completed. Therefore, after the initialization of this computer is completed, that is, after the computer initialization is completed when the computer is restarted after the BIOS upgrade, the BIOS also needs to generate the retained configuration table corresponding to this initialization, and because the configuration information in the HOB space is used in this initialization, the configuration information in the HOB space needs to be used when generating the retained configuration table to ensure that the generated retained configuration table is consistent with the configuration information applied during the actual initialization. This application does not make any special restrictions on the specific storage method of the retained configuration table in the BMC. Taking this initialization as an example, if the configuration retention method is used during a certain initialization, the retained configuration table regenerated by the BIOS will basically remain in a completely consistent state with the content in the retained configuration table originally stored in the BMC. The update operation is only to avoid data loss caused by factors such as long-term storage, and to avoid the costs and risks brought about by configuration loss.

[0078] Specifically, the reserved configuration table in the BMC is updated by regenerating the reserved configuration table after initialization. When the configuration retention method is adopted in this initialization, the update of the reserved configuration table does not involve substantial changes in the content. It only synchronizes and refreshes the reserved configuration table in the BMC to maintain the consistency of the configuration information and ensure the real-time nature of the configuration information.

[0079] In some embodiments, generating a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the configuration information corresponding to the configuration options in the reserved configuration table, and the current configuration menu includes:

[0080] In the driver execution environment phase, the configuration information in the handover block space is synchronized to the configuration options corresponding to the current configuration menu to obtain an adjusted configuration menu;

[0081] During the boot phase, the adjusted configuration menu is read, and a reserved configuration table corresponding to this initialization is generated based on the read result.

[0082] It is understandable that after the computer system's memory initialization is completed, the computer will enter the DXE (Driver Execution Environment) stage. At this time, the BIOS will synchronize the configuration options and corresponding configuration information (including configuration values, configuration status, etc.) retained in the HOB space to the corresponding options of the current BIOS setup, so as to update the inconsistent configuration options recorded in the HOB space to the reserved configuration table, and update the BIOS configuration menu. In the later stage of POST, the BIOS reads the configuration options and corresponding configuration information of all current BIOS setups, generates a reserved configuration table that supports BMC reception, and then passes this reserved configuration table to the BMC to achieve the retention of the configuration applied in this initialization, thereby achieving the retention of the user's original configuration and finally completing the entire BIOS upgrade process.

[0083] It should be noted that the post-POST phase can specifically be the boot phase or any other phase after POST, as long as it is the phase between the completion of basic hardware detection and the loading of the operating system. It can also be the firmware loading phase, etc., and this application does not make any special restrictions here. The specific method for BIOS to synchronize the corresponding configuration information from the HOB space is not specifically limited here. This application can implement it through the SetVariable() service interface or other methods.

[0084] As a specific embodiment, the present application tests an Intel Xeon 6389P-C processor, 2120 BIOS configuration options, and 156 different items in the current configuration menu after the BIOS upgrade and the reserved configuration table corresponding to the system before the BIOS upgrade. Without adopting the configuration retention method provided by the present invention, the BIOS upgrade takes approximately 45 seconds. After adopting the configuration retention method provided by the present invention, the BIOS upgrade only takes approximately 38 seconds, shortening the upgrade time, that is, the configuration recovery time, by 15%. At the same time, the HOB space requested by the BIOS can be saved by approximately 92.7%, achieving a HOB space saving of more than 90%.

[0085] Specifically, by synchronizing the corresponding configuration information from the HOB space, it is effectively ensured that the reserved configuration table finally generated by the BIOS is the configuration information actually applied in this initialization, thereby improving the accuracy and reliability of the reserved configuration table update operation.

[0086] In some embodiments, before comparing the current configuration menu of the basic input and output system with the reserved configuration table, the method further includes:

[0087] The baseboard management controller receives the reserved configuration table of the basic input and output system sent by the baseboard management controller. The baseboard management controller sends the reserved configuration table to the basic input and output system when receiving the upgrade instruction of the basic input and output system.

[0088] It is not difficult to understand that when the BMC detects the need for a BIOS upgrade upon receiving a basic input / output system upgrade instruction, the BMC will proactively send the retained configuration table to the BIOS so that the BIOS can directly begin comparing configuration options when triggering the configuration retention method. This application does not specifically limit the communication method between the BMC and the BIOS, which can be implemented through methods such as the H2B (Host to BMC) communication interface. This application does not specifically limit the specific type and implementation method of the upgrade instruction. The upgrade instruction can include an indication of whether the BIOS needs to retain the configuration upgrade for this upgrade. The BMC can determine whether it needs to send the retained configuration table to the BIOS based on this indication. The BMC can also send the retained configuration table to the BIOS as soon as it receives the upgrade instruction. The BIOS itself determines whether it needs to trigger the configuration retention method based on the indication information before the computer is restarted or the instruction information issued by the user after the computer is restarted and before initialization.

[0089] Specifically, to ensure data persistence and storage reliability, the retained configuration table will be stored in the BMC, using the BMC's non-volatile storage to preserve the configuration for a long time. When the BIOS is upgraded, the BMC can also use its own out-of-band management capabilities to effectively help the BIOS restore the configuration.

[0090] In some embodiments, saving the modified configuration options and the configuration information corresponding to the configuration options in the reserved configuration table to the handover block space includes:

[0091] Save the changed configuration options to the handover block space based on the preset format;

[0092] Determine the position correspondence between the configuration information corresponding to the configuration option in the retained configuration table and the configuration option according to the preset rules, and save the configuration information corresponding to the configuration option in the retained configuration table to the corresponding position in the handover block space according to the position correspondence and based on the preset format.

[0093] It is understood that a specific preset format and preset rules can be used to save the inconsistent configuration options and their corresponding configuration information found by the mobile phone in the HOB space, ensuring that the configuration information can be accurately read and used during the subsequent initialization process. This application does not specifically limit the specific types and implementation methods of the preset formats and preset rules. The preset rules are not limited to the location correspondence between the storage locations of the configuration options and configuration information in this embodiment. The configuration options and configuration information can also be saved using different preset formats.

[0094] Specifically, by setting corresponding saving rules and saving formats, the configuration options and configuration information in the HOB space can be saved in an orderly manner, which helps to improve the efficiency and accuracy of computer system initialization and avoid configuration errors caused by information confusion.

[0095] In some embodiments, applying for a corresponding size of the interleaving block space based on the changed configuration option includes:

[0096] Determine the configuration options that have been changed and the original data volume of the configuration information corresponding to the configuration options in the retained configuration table;

[0097] Determine the overhead corresponding to the preset format based on the amount of original data;

[0098] The sum of the original data amount and the overhead data amount is used as the target size, and an intersection block space of the target size is requested from the central processing unit cache of the computer.

[0099] It is not difficult to understand that the size of the HOB space applied for needs to be determined based on the specific data volume of the configuration options and configuration information. At the same time, in order to ensure that the configuration options and configuration information can be accurately saved in the HOB space, an address field will be added to the header of the data to indicate the routing path when saving. At the same time, in order to avoid bit errors introduced during transmission and ensure data reliability, verification mechanisms such as check codes may be introduced when saving configuration options and configuration information. These address fields and check codes will cause overhead. Overhead refers to non-core information added to support data storage, transmission, and management. The HOB space also needs to save the original data corresponding to the configuration options and configuration information and the corresponding overhead. Therefore, the sum of the original data volume and the overhead data volume needs to be used as the target size that needs to be applied for. This application does not make any special restrictions on the specific type and implementation method of the overhead, and is not limited to the check code and address field described in this embodiment.

[0100] Specifically, the target size of the HOB space to be applied for is determined by calculating the specific amount of data. In actual application, the target size can be appropriately increased to make it no less than the sum of the original data amount and the overhead data amount. This is simple, effective, and easy to implement, ensuring that all modified configuration options and their configuration information can be effectively saved in the HOB space.

[0101] In some embodiments, comparing the current configuration menu of the basic input and output system with the reserved configuration table to determine whether there is a changed configuration option in the current configuration menu includes:

[0102] Classifying all configuration options in the current configuration menu of the basic input and output system according to a preset classification method to obtain configuration options of several categories;

[0103] Traversing a number of categories in a first preset order;

[0104] When traversing any category, traverse all configuration options in the category according to the second preset order;

[0105] For any configuration option, compare the configuration information corresponding to the configuration option in the current configuration menu with the configuration information corresponding to the configuration option in the reserved configuration table;

[0106] Determine whether the configuration information corresponding to the configuration option in the current configuration menu is completely consistent with the configuration information corresponding to the configuration option in the reserved configuration table;

[0107] If so, it is determined that there is no change in the configuration option;

[0108] If not, it is determined that the configuration option has been changed and a mark is added to the configuration option;

[0109] Configuration options for which a flag exists are identified as configuration options for which changes have occurred.

[0110] It is understandable that when comparing the current configuration menu and the reserved configuration table, all the configuration options therein need to be compared item by item and in detail. Therefore, in order to improve the efficiency and accuracy of the comparison, the configuration options in the BIOS setup can be compared according to a certain classification and order. First, all configuration options are classified according to the preset classification method, and then a specific traversal order is configured for each category. Then, each category and the configuration options in each category are traversed in turn according to the first preset order and the second preset order, so as to realize the scanning and comparison of all configuration options. This application does not make any special restrictions on the specific types and implementation methods of the preset classification method, the first preset order and the second preset order. The preset classification method can be directly reused to achieve the main menu title and submenu title of the BIOS setup itself. For example, Boot (boot option) is directly determined as a category, and the various configuration options corresponding to the submenu titles such as Boot Device Priority (boot device priority) under Boot (boot option) are all classified into this category.

[0111] It should be noted that each configuration option traversed needs to be compared with the configuration information to determine the consistency of all configuration information. In the case of changes in the configuration options, a mark can be added to the configuration option so that the subsequent BIOS can directly determine whether it is necessary to use the configuration information in the HOB space for initialization configuration based on this mark. This application does not make any special restrictions on the specific type of the mark and the implementation method. It can be implemented in the form of numbers or specific identifiers. Each configuration option that has changed can be implemented with the same mark or different marks. This embodiment provides a specific configuration option comparison method for comparing the configuration options in the retained configuration table and the current BIOS setup, including the order and method of comparison, etc. The comparison content includes the value and status of the configuration options, etc., and implements a logic for filtering inconsistent configuration options and saving these configuration options to the HOB space.

[0112] The present invention saves only inconsistent configuration options to the HOB space, thus avoiding the need to apply for a HOB space of the same size as the entire reserved configuration table. The memory resource usage can be effectively reduced by 50%-90% (depending on the configuration change ratio), effectively reducing the computer system's memory resource usage and improving the utilization rate of the computer system's resources. Since the number of configuration options that need to be processed and saved is reduced in the HOB space, the BIOS significantly shortens the configuration processing time during the upgrade process, thereby speeding up the BIOS upgrade. It is particularly suitable for large-scale server clusters, improving upgrade efficiency and user experience. While retaining the user's original configuration, only the changed configuration is updated, avoiding the risk of configuration errors that may be introduced by processing all configuration options, and ensuring the accuracy and stability of the computer system configuration. By accurately screening and saving inconsistent configuration options, problems such as large memory resource usage and low upgrade efficiency are effectively solved.

[0113] See also Figure 4 As shown, Figure 4 A schematic diagram of a configuration retention device provided in an embodiment of the present invention; to solve the above technical problems, an embodiment of the present invention further provides a configuration retention device applied to a basic input and output system; the configuration retention device includes:

[0114] The comparison unit 11 is configured to compare the current configuration menu of the basic input and output system with the reserved configuration table upon receiving the reserved configuration table, and determine whether there is a changed configuration option in the current configuration menu;

[0115] An application unit 12 is configured to apply for a handover block space of a corresponding size based on the modified configuration option;

[0116] A saving unit 13 is configured to save the modified configuration options and the configuration information corresponding to the configuration options in the reserved configuration table to the handover block space;

[0117] A first initialization unit 14 is configured to initialize the computer based on the configuration information corresponding to the configuration options in the handover block space when initializing the computer;

[0118] The second initialization unit 15 is configured to initialize the computer based on the corresponding configuration information in the current configuration menu for the configuration options that do not exist in the interface block space.

[0119] In some embodiments, further comprising:

[0120] A configuration table updating unit is configured to generate a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the configuration information corresponding to the configuration options in the reserved configuration table, and the current configuration menu after the computer is initialized;

[0121] The configuration table sending unit is used to send the reserved configuration table corresponding to this initialization to the baseboard management controller.

[0122] In some embodiments, the configuration table updating unit includes:

[0123] A synchronization unit, configured to synchronize the configuration information in the handover block space with the configuration options corresponding to the current configuration menu during the driver execution environment phase, so as to obtain an adjusted configuration menu;

[0124] The generating unit is used to read the adjusted configuration menu during the booting phase and generate a reserved configuration table corresponding to this initialization according to the reading result.

[0125] In some embodiments, further comprising:

[0126] The configuration table receiving unit is used to receive the reserved configuration table of the basic input and output system sent by the baseboard management controller; wherein the baseboard management controller sends the reserved configuration table to the basic input and output system when receiving the upgrade instruction of the basic input and output system.

[0127] In some embodiments, the storage unit 13 includes:

[0128] A first saving subunit is configured to save the modified configuration options to the handover block space based on a preset format;

[0129] The second saving sub-unit is used to determine the position correspondence between the configuration information corresponding to the configuration option in the retained configuration table and the configuration option according to a preset rule, and save the configuration information corresponding to the configuration option in the retained configuration table to the corresponding position in the handover block space according to the position correspondence and based on a preset format.

[0130] In some embodiments, the application unit 12 includes:

[0131] an original data amount determining unit, configured to determine the original data amount of the configuration options with changes and the configuration information corresponding to the configuration options in the reserved configuration table;

[0132] An overhead determining unit, configured to determine an overhead corresponding to a preset format according to the amount of original data;

[0133] The total data volume determining unit is used to take the sum of the original data volume and the overhead data volume as the target size and apply for the intersection block space of the target size from the central processing unit cache of the computer.

[0134] In some embodiments, the comparison unit 11 includes:

[0135] A classification unit, configured to classify all configuration options in the current configuration menu of the basic input and output system according to a preset classification method to obtain configuration options of several categories;

[0136] a first traversal unit, configured to traverse a plurality of categories in a first preset order;

[0137] A second traversal unit is configured to traverse all configuration options in any category according to a second preset order when traversing any category;

[0138] A comparison subunit, configured to compare, for any configuration option, configuration information corresponding to the configuration option in the current configuration menu with configuration information corresponding to the configuration option in the reserved configuration table;

[0139] a judgment unit, configured to judge whether the configuration information corresponding to the configuration option in the current configuration menu is completely consistent with the configuration information corresponding to the configuration option in the reserved configuration table; if so, triggering the first judgment unit; if not, triggering the second judgment unit;

[0140] a first determination unit, configured to determine that no configuration option has been changed;

[0141] a second determination unit, configured to determine whether a configuration option has been changed and to mark the configuration option;

[0142] The option determination unit is configured to determine the configuration option having a mark as a configuration option having a change.

[0143] For descriptions of features in the configuration retention device provided in the embodiments of the present invention, reference may be made to the relevant descriptions of the embodiments of the configuration retention method, which will not be described in detail here.

[0144] See also Figure 5 To solve the above technical problems, an embodiment of the present invention further provides an electronic device, including:

[0145] Memory 60, for storing computer programs;

[0146] The processor 61 is configured to execute a computer program to implement the steps of the aforementioned configuration reservation method.

[0147] The electronic device provided in this embodiment may include but is not limited to a smart phone, a tablet computer, a laptop computer, or a desktop computer.

[0148] The processor 61 may include one or more processing cores, such as a quad-core processor or an octa-core processor. The processor 61 may be implemented using at least one of the following hardware forms: a digital signal processing (DSP), a field-programmable gate array (FPGA), or a programmable logic array (PLA). The processor 61 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a central processing unit (CPU); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 61 may be integrated with a graphics processing unit (GPU), which is responsible for rendering and drawing content required to be displayed on the display screen. In some embodiments, the processor 61 may also include an artificial intelligence (AI) processor for handling computational operations related to machine learning.

[0149] The memory 60 may include one or more computer-readable storage media, which may be non-transitory. The memory 60 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In this embodiment, the memory 60 is at least used to store the following computer program 601, wherein, after the computer program is loaded and executed by the processor 61, it can implement the relevant steps of the configuration retention method disclosed in any of the aforementioned embodiments. In addition, the resources stored in the memory 60 may also include an operating system 602 and data 603, etc., and the storage method may be temporary storage or permanent storage. Among them, the operating system 602 may include Windows, Unix, Linux, etc. The data 603 may include but is not limited to the data in the configuration retention method, etc.

[0150] In some embodiments, the electronic device may further include a display screen 62 , an input / output interface 63 , a communication interface 64 , a power supply 65 , and a communication bus 66 .

[0151] Those skilled in the art will understand that Figure 5 The structure shown in the figure does not constitute a limitation of the electronic device, and may include more or fewer components than shown in the figure.

[0152] For descriptions of features in the electronic device provided by the embodiments of the present invention, reference may be made to the relevant descriptions of the embodiments of the configuration retention method, which will not be described in detail here.

[0153] It is understood that if the configuration retention method in the above-mentioned embodiment is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the portion that contributes to the current technology, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and performs all or part of the steps of the various embodiments of the present invention. The aforementioned storage medium includes: USB flash drives, mobile hard drives, read-only memories (ROM), random access memories (RAM), electrically erasable programmable ROMs, registers, hard drives, removable disks, CD-ROMs, magnetic disks, or optical disks, and other media that can store program code.

[0154] To solve the above technical problems, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the configuration reservation method as described above are implemented.

[0155] For descriptions of features in the computer-readable storage medium provided in the embodiments of the present invention, reference may be made to the relevant descriptions of the embodiments of the configuration retention method, which will not be described in detail here.

[0156] An embodiment of the present invention further provides a computer program product, including a computer program / instruction, which implements the steps of the configuration reservation method of the above embodiment when executed by a processor.

[0157] For descriptions of features in the computer program product provided by the embodiments of the present invention, reference may be made to the relevant descriptions of the embodiments of the configuration reservation method, which will not be described in detail here.

[0158] The above describes in detail the configuration retention method, apparatus, device, and medium provided by the embodiments of the present invention. The various embodiments are described in a progressive manner throughout this specification, with each embodiment focusing on its differences from other embodiments. For similar or identical parts between the various embodiments, reference can be made to each other. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple. For relevant details, refer to the method description.

[0159] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the above description has generally described the components and steps of each example according to their functions. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present invention.

[0160] The above is a detailed introduction to a configuration retention method, apparatus, device, and medium provided by the present invention. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only intended to help understand the method and core concept of the present invention. It should be noted that, for those skilled in the art, without departing from the principles of the present invention, several improvements and modifications may be made to the present invention, and such improvements and modifications also fall within the scope of protection of the present invention.

Claims

1. A configuration retention method, characterized in that: Applied to basic input and output systems; The configuration retention method includes: Upon receiving the reserved configuration table of the basic input / output system, comparing the current configuration menu of the basic input / output system with the reserved configuration table to determine whether there is a changed configuration option in the current configuration menu; wherein the reserved configuration table records the configuration of the basic input / output system previously stored in the baseboard management controller; comparing whether there is a change in configuration information corresponding to the same configuration option, wherein the configuration information includes at least a configuration value and a configuration status; Apply for the corresponding size of the handover block space based on the configuration options that have been changed; Saving the modified configuration options and the configuration information corresponding to the configuration options in the reserved configuration table to the handover block space; When initializing the computer, for the configuration options existing in the interleaving block space, initializing the computer based on the corresponding configuration information in the interleaving block space; For configuration options not existing in the interface block space, initializing the computer based on corresponding configuration information in the current configuration menu; After the initialization of the computer is completed, the method further includes: generating a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the configuration information corresponding to the configuration options in the reserved configuration table, and the current configuration menu; Send the reserved configuration table corresponding to this initialization to the baseboard management controller; Generating a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the configuration information corresponding to the configuration options in the reserved configuration table, and the current configuration menu, including: In the driving execution environment stage, the configuration information in the handover block space is synchronized with the configuration options corresponding to the current configuration menu to obtain an adjusted configuration menu; During the booting phase, the adjusted configuration menu is read, and a reserved configuration table corresponding to this initialization is generated according to the reading result.

2. The configuration retention method according to claim 1, characterized in that: Before comparing the current configuration menu of the basic input and output system with the reserved configuration table, the method further includes: Receive the reserved configuration table of the basic input and output system sent by the baseboard management controller; wherein, the baseboard management controller sends the reserved configuration table to the basic input and output system when receiving the upgrade instruction of the basic input and output system.

3. The configuration retention method according to claim 1, characterized in that: Saving the modified configuration options and the configuration information corresponding to the configuration options in the reserved configuration table to the handover block space includes: Saving the modified configuration options to the handover block space based on a preset format; Determine the position correspondence between the configuration information corresponding to the configuration option in the retained configuration table and the configuration option according to a preset rule, and save the configuration information corresponding to the configuration option in the retained configuration table to the corresponding position in the handover block space according to the position correspondence and based on a preset format.

4. The configuration retention method according to claim 3, characterized in that: Apply for a corresponding size of interface block space based on the configuration options that have changed, including: Determine the configuration options that have been modified and the original data volume of the configuration information corresponding to the configuration options in the reserved configuration table; Determining an overhead corresponding to the preset format according to the amount of original data; The sum of the original data volume and the overhead data volume is used as a target size, and an application for a handover block space of the target size is made to a central processing unit cache of a computer.

5. The configuration retention method according to any one of claims 1 to 4, characterized in that: Comparing the current configuration menu of the basic input / output system with the reserved configuration table to determine whether there is a changed configuration option in the current configuration menu includes: Classifying all configuration options in the current configuration menu of the basic input and output system according to a preset classification method to obtain configuration options of several categories; Traversing the plurality of categories in a first predetermined order; When traversing any category, traversing all configuration options in the category according to a second preset order; For any configuration option, compare the configuration information corresponding to the configuration option in the current configuration menu with the configuration information corresponding to the configuration option in the reserved configuration table; Determine whether the configuration information corresponding to the configuration option in the current configuration menu is completely consistent with the configuration information corresponding to the configuration option in the reserved configuration table; If so, determining that there is no change in the configuration option; If not, it is determined that the configuration option has been changed, and a mark is added to the configuration option; The configuration option having the flag is determined as a configuration option having a change.

6. A configuration retention device, characterized in that, Applied to basic input and output systems; The configuration retaining device comprises: a comparing unit configured to, upon receiving the reserved configuration table of the basic input / output system, compare a current configuration menu of the basic input / output system with the reserved configuration table to determine whether a changed configuration option exists in the current configuration menu; wherein the reserved configuration table records a configuration of the basic input / output system previously stored in the baseboard management controller; and compare whether configuration information corresponding to the same configuration option has been changed, wherein the configuration information includes at least a configuration value and a configuration status; An application unit is used to apply for a handover block space of a corresponding size based on a changed configuration option; A saving unit, configured to save the modified configuration options and the configuration information corresponding to the configuration options in the reserved configuration table to the handover block space; a first initialization unit, configured to initialize the computer based on the configuration information corresponding to the configuration options in the interface block space when initializing the computer; a second initialization unit, configured to initialize the computer based on corresponding configuration information in the current configuration menu for configuration options not existing in the interface block space; Also includes: A configuration table updating unit is configured to generate a reserved configuration table corresponding to this initialization based on the configuration options in the handover block space, the configuration information corresponding to the configuration options in the reserved configuration table, and the current configuration menu after the computer is initialized; The configuration table sending unit is used to send the reserved configuration table corresponding to the current initialization to the baseboard management controller; The configuration table update unit includes: A synchronization unit, configured to synchronize the configuration information in the handover block space with the configuration options corresponding to the current configuration menu during the driver execution environment phase, so as to obtain an adjusted configuration menu; The generating unit is used to read the adjusted configuration menu during the booting phase and generate a reserved configuration table corresponding to this initialization according to the reading result.

7. An electronic device, characterized in that: include: Memory for storing computer programs; A processor, configured to execute the computer program to implement the steps of the configuration reservation method according to any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the configuration reservation method according to any one of claims 1 to 5 are implemented.

Citation Information

Patent Citations

  • Menu option modification method and device, BIOS system, equipment and storage medium

    CN117311844A

  • Configuration option management method and device, equipment and storage medium

    CN119292680A