CN115794194A - Method, apparatus, terminal and medium for automatically checking and updating management engine layout - Google Patents

Method, apparatus, terminal and medium for automatically checking and updating management engine layout Download PDF

Info

Publication number
CN115794194A
CN115794194A CN202211664080.1A CN202211664080A CN115794194A CN 115794194 A CN115794194 A CN 115794194A CN 202211664080 A CN202211664080 A CN 202211664080A CN 115794194 A CN115794194 A CN 115794194A
Authority
CN
China
Prior art keywords
management engine
layout
code
engine layout
file
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211664080.1A
Other languages
Chinese (zh)
Inventor
仇广东
芦飞
陈鹏
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202211664080.1A priority Critical patent/CN115794194A/en
Publication of CN115794194A publication Critical patent/CN115794194A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to the field of management engine layout updating, and particularly discloses a method, a device, a terminal and a medium for automatically checking and updating a management engine layout, which are used for acquiring an original predefined management engine layout in an original basic code; after the code compiling is finished, acquiring the layout of an actual management engine; comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine; if the two are consistent, no processing is carried out; if not, the management engine layout in the original basic code is changed according to the actual management engine layout, and the code compiling is carried out again after the change. The invention can automatically check and correct the ME layout information in the code, the correction process does not need human intervention, only needs the result of human check, avoids the situations of omission and neglect of correction caused by manual check, and greatly improves the development efficiency.

Description

Method, apparatus, terminal and medium for automatically checking and updating management engine layout
Technical Field
The invention relates to the field of management engine layout updating, in particular to a method, a device, a terminal and a medium for automatically checking and updating a management engine layout.
Background
The Management Engine (ME) is integrated in the south bridge (PCH), is a microcontroller independent of the CPU, has its own firmware, and the firmware is packaged in the BIOS, and after being powered on, the ME reads its own firmware program from the BIOS ROM and runs it. The ME is mainly used for managing computer system resources and can also realize remote management.
The AMI BIOS provides AFU facilities to flush the BIOS ROM in-band, with the entire BIOS ROM including both ME and BIOS portions. The ME firmware is divided into a plurality of areas to store different contents, and the position information of the different areas in the BIOS ROM is the layout of the ME. The AFU refreshes the ME, the layout of the ME needs to be known, the default definition is arranged in the code, when the layout information of the ME cannot be acquired from the register, the default definition layout information is used, if the default layout information is inconsistent with the actual ME layout information, the ME refreshes failure possibly, or a wrong area is refreshed, and serious problems of no startup and the like are caused.
The ME typically includes FPT, FPTB, MFSB, MFS, FTPR, OPR1, SPS Recovery, SPS Operational, etc. areas that occupy a region of storage inside the BIOS ROM, where the address offset of the area needs to be predefined in the code. Generally, predefined information provided by AMI exists inside a basic code, when an actual design is changed to an ME region, for example, a region which is not used is deleted, an offset address of each region will be changed, but the BIOS code compiling process only carries out code compiling and can not check and correct ME layout information, the ME layout information defined by the current BIOS code generally needs to be manually changed according to the actual ME layout information, namely, the ME layout defined by the code needs to be manually changed, but the change is easy to ignore, because the normal situation that an AFU refreshes the ME obtains the ME layout information from a register, the default defined layout information can be utilized when the current situation cannot be obtained, and at the moment, if the actual ME layout is different from the ME layout defined by the code, the change is ignored, and the problem exists by utilizing the original predefined layout information.
Disclosure of Invention
In order to solve the above problems, the present invention provides a method, an apparatus, a terminal and a medium for automatically checking and updating a management engine layout, which can automatically check and correct ME layout information in a code, and only need to manually check a result without human intervention in a correction process, thereby avoiding missing and neglecting correction due to manual checking, and greatly improving development efficiency.
In a first aspect, a technical solution of the present invention provides a method for automatically checking and updating a management engine layout, including the following steps:
acquiring an original predefined management engine layout in an original basic code;
after the code compiling is finished, acquiring the actual management engine layout;
comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine;
if the two are consistent, no processing is carried out;
if not, the management engine layout in the original basic code is changed according to the actual management engine layout, and the code compiling is carried out again after the change.
Further, obtaining an original predefined management engine layout in the original base code specifically includes:
outputting all predefined information to a pre-stored file in a code compiling preprocessing stage;
traversing the pre-stored file, and extracting an original predefined management engine layout in the original basic code;
storing the original predefined manageability engine layout into a first identification file.
Further, after the code compiling is finished, acquiring the actual management engine layout, specifically including:
traversing a binary file generated by code compiling to obtain an actual management engine layout;
and storing the obtained actual management engine layout into a second identification file.
Further, the method specifically comprises the following steps:
and calling an FIT tool to traverse the binary file generated by code compiling, and acquiring the actual management engine layout.
Further, comparing whether the actual management engine layout is consistent with the original predefined management engine layout specifically includes:
comparing the information in the first identification file and the information in the second identification file one by one according to the keywords;
if the number of the areas in the first identification file is less than that of the areas in the second identification file, recording abnormal information;
if the number of the areas in the first identification file is more than that of the areas in the second identification file, the areas in the first identification file are used as a reference for comparison.
Further, changing the layout of the management engine in the original basic code according to the actual layout of the management engine specifically comprises:
finding a code file defining an original management engine layout;
changing the management engine layout in the found code file according to the actual management engine layout;
when searching a code file defining the layout of an original management engine, determining the priority of a file to be searched by using a file suffix, wherein the priority of an sdl suffix file is highest, the priority of an h suffix file is lowest, and the priority of a c suffix file is lowest: the method comprises the steps of firstly searching in an sdl suffix file, if not, searching in an h suffix file, and if not, searching in a c suffix file.
Further, the method comprises the following steps:
in the code compiling process, reserving a BIOS ROM area;
if the actual management engine layout is inconsistent with the original predefined management engine layout by comparison, filling effective data in a reserved BIOS ROM region after code compiling is carried out again;
when the BIOS ROM is refreshed, whether valid data are filled in a reserved BIOS ROM area or not is detected, if the valid data are filled, when the management engine is refreshed, the obtained management engine layout is compared with the management engine layout after the recoding code is compiled, if the management engine layout is consistent, refreshing is carried out, and if the management engine layout is inconsistent, refreshing is not carried out.
In a second aspect, the present invention provides an apparatus for automatically checking and updating a management engine layout, comprising,
an original layout acquisition module: acquiring an original predefined management engine layout in an original basic code;
an actual layout acquisition module: after the code compiling is finished, acquiring the actual management engine layout;
a layout comparison module: comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine;
a layout update module: if not, the management engine layout in the original basic code is changed according to the actual management engine layout, and the code compiling is carried out again after the change.
In a third aspect, a technical solution of the present invention provides a terminal, including:
a memory for storing an automatic inspection and update management engine layout program;
a processor for implementing the steps of the method of automatically checking and updating a management engine layout according to any one of the preceding claims when executing the automatic checking and updating management engine layout program.
In a fourth aspect, the present invention provides a computer-readable storage medium having stored thereon an automated inspection and update management engine layout program which, when executed by a processor, implements the steps of the automated inspection and update management engine layout method as recited in any one of the preceding claims.
Compared with the prior art, the method, the device, the terminal and the medium for automatically checking and updating the layout of the management engine have the following beneficial effects: the method comprises the steps of automatically acquiring an original predefined management engine layout, then automatically acquiring an actual management engine layout after code compiling, modifying a definition management engine in a code according to the actual management engine layout when the original predefined management engine layout and the actual management engine layout are inconsistent, and compiling the code again to realize the consistency of the management engine defined in the code and the actual management engine. The method can automatically check and correct the ME layout information in the code, does not need human intervention in the correction process, only needs the human check result, avoids the situations of omission and neglect of correction caused by the manual check, and greatly improves the development efficiency.
Drawings
For a clearer explanation of the embodiments or technical solutions of the prior art of the present application, the drawings needed for the description of the embodiments or prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a schematic flowchart of a method for automatically checking and updating a management engine layout according to an embodiment of the present invention.
FIG. 2 is a flowchart illustrating an embodiment of a method for automatically checking and updating a management engine layout according to the present invention
Fig. 3 is a flowchart illustrating a method for automatically checking and updating a management engine layout according to an embodiment of the present invention.
FIG. 4 is a schematic diagram of a complete BIOS ROM image.
Fig. 5 is a schematic block diagram of a structure of an apparatus for automatically checking and updating a management engine layout according to an embodiment of the present invention.
Fig. 6 is a schematic structural diagram of a terminal according to an embodiment of the present invention.
Detailed Description
Some terms related to the present invention are explained below.
BIOS: basic Input Output System, basic Input Output System.
AMI BIOS: BIOS system software available from AMI corporation.
ME: management Engine, management Engine.
An AFU tool: a refreshing tool.
FIT tool: an interactive testing tool.
In order that those skilled in the art will better understand the disclosure, the following detailed description will be given with reference to the accompanying drawings. It is to be understood that the embodiments described are only a few embodiments of the present application and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The core of the invention is to provide a method for automatically checking and correcting the ME layout of an intel platform in the compiling process of AMI BIOS codes, wherein the ME comprises areas such as FPT, FPTB, MFSB, MFS, FTPR, OPR1, SPS Recovery, SPS operation and the like, the areas occupy a section of area for storage in the BIOS ROM, and the address offset of the areas needs to be predefined in the codes. Usually, there is predefined information provided by AMI in the basic code, and when the actual design changes to ME area, for example, some unused area is deleted, the offset address of each area will change, and there is a problem if the original predefined layout information is reused. The BIOS code compiling process only carries out code compiling and cannot carry out verification and correction on ME layout information, so that the invention adds a checking and correcting mechanism in the code compiling stage to ensure the predefined accuracy of the ME layout information. In the code compiling stage, a predefined management engine layout is obtained, after the code compiling is completed, an actual management engine layout is obtained, whether the predefined management engine layout is consistent with the actual management engine layout is compared, if the predefined management engine layout is not consistent with the actual management engine layout, the management engine layout in the original code is changed automatically, a recompilation command is triggered after the change is completed, and after the code is recompiled, predefined management engine layout information in the code is consistent with the actual management engine layout information.
Fig. 1 is a flowchart illustrating a method for automatically checking and updating a management engine layout according to an embodiment of the present invention, where the method includes the following steps, as shown in fig. 1.
S1, acquiring an original predefined management engine layout in original basic codes.
And S2, acquiring the actual management engine layout after the code compiling is finished.
S3, comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine;
and S4, if the two are consistent, no processing is performed.
And S5, if the basic code is inconsistent with the original basic code, changing the layout of the management engine in the original basic code according to the actual layout of the management engine, and compiling the code again after changing.
The method for automatically checking and updating the management engine layout, provided by the embodiment of the invention, comprises the steps of automatically acquiring the original predefined management engine layout, then automatically acquiring the actual management engine layout after compiling the code, modifying the defined management engine in the code according to the actual management engine layout when the original predefined management engine layout and the actual management engine layout are inconsistent, and compiling the code again to realize the consistency of the management engine defined in the code and the actual management engine. The method can automatically check and correct the ME layout information in the code, does not need human intervention in the correction process, only needs the human check result, avoids the situations of omission and neglect of correction caused by the manual check, and greatly improves the development efficiency.
In order to further understand the present invention, a specific embodiment is provided below to further describe the present invention in detail, in this specific embodiment, during the compiling process, predefined ME layout information is output to inside of Token1 file, then compiling is started, if compiling has no error, a binary bin file is generated, at this time, a program is added, an FIT tool is called to extract ME layout information, the ME layout information is output to Token2 file, then ME region address offset information inside Token1 and Token2 is compared, if the two are consistent, the program is ended, if not consistent, the ME region information inside the original code is automatically changed, after the change is completed, a recompilation command is triggered, and after the code is recompiled, the predefined ME layout information inside the code and the actual ME layout information will be kept consistent.
Fig. 2 is a schematic flow chart of this embodiment, which includes the following steps, as shown in fig. 2.
S101, outputting all the predefined information to a pre-stored file in a code compiling preprocessing stage.
Before compiling, the AMI code compiling process has a preprocessing process, all predefined information is output to the inside of a file in the process, the file contains address offset information of areas of a management engine, such as FPT, FPTB, MFSB, MFS, FTPR, OPR1, SPS Recovery, SPS operation and the like, and then the corresponding original predefined management engine layout is obtained in the file.
S102, traversing the pre-stored files, and extracting the original predefined management engine layout in the original basic code.
This step can be executed after the code is compiled, or during the preprocessing process, and the user sets the specific stage to be executed according to the actual requirement, without affecting the specific implementation of the present invention.
S103, storing the original predefined management engine layout into a first identification file.
The original predefined management engine layout is independently stored, so that comparison of subsequent management engine layouts is facilitated.
And S104, traversing the binary file generated by the code compiling after the code compiling is finished, and acquiring the actual management engine layout.
If the compilation is not in error, a binary bin file is generated that contains the actual manageability engine layout. And then, traversing the binary file generated by code compiling by using an FIT tool to acquire the actual management engine layout.
And S105, storing the obtained actual management engine layout into a second identification file.
Similarly, the actual management engine layout is independently stored, so that comparison of subsequent management engine layouts is facilitated.
And S106, comparing the information in the first identification file and the second identification file one by one according to the key words, and judging whether the layout of the actual management engine is consistent with the layout of the original predefined management engine.
In the process, if the number of the areas in the first identification file is less than that of the areas in the second identification file, recording abnormal information; if the number of the areas in the first identification file is more than that of the areas in the second identification file, the areas in the first identification file are used as a reference for comparison.
And in the comparison process, comparing one by one according to the keywords, and after the examination of a certain region of the ME is finished, comparing one region until all comparisons are finished. And if the number of the ME areas extracted by the FIT tool is more than the number of the areas predefined by the codes, recording an abnormal log for reference of research personnel. If the number of ME regions provided by the FIT tool is less than the predefined number of regions by the code, the regions defined by the code are the norm.
S107, if the layout of the actual management engine is consistent with the layout of the original predefined management engine, no processing is performed.
S108, if the actual management engine layout is not consistent with the original predefined management engine layout, finding out a code file defining the original management engine layout, and changing the management engine layout in the found code file according to the actual management engine layout.
The change process is to find the original code file defined by the ME area, and then change and store the corresponding numerical value. The process relates to a code changing process, which file is located through keywords, and possibly a plurality of files are involved, and the file is judged to be effective according to a certain rule, wherein the specific rule is that the suffix of the file is the highest priority of sdl, if the sdl file is not found, the suffix is used as the highest priority of an h file, and if the h file is not found, the definition in the c file is used. Then the position of the keyword is found to change the corresponding numerical value. It should be noted that, before changing the original code file, an original file may be backed up, so that a subsequent developer may refer to and compare the original file.
Fig. 3 is a flowchart illustrating a method for automatically checking and updating a management engine layout according to an embodiment of the present invention, and as shown in fig. 3, the method includes the following steps.
And SS1, obtaining the original predefined management engine layout in the original basic code.
SS2, during the code compilation process, a BIOS ROM region is reserved.
And SS3, obtaining the layout of the actual management engine after the code compiling is finished.
And SS4, comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine, if so, not processing, and if not, executing the following steps.
And the SS5 is used for changing the layout of the management engine in the original basic code according to the actual layout of the management engine and compiling the code again after the change.
And SS6, after code compiling is carried out again, filling valid data in the reserved BIOS ROM area.
And SS7, when refreshing the BIOS ROM, firstly detecting whether the reserved BIOS ROM area is filled with valid data.
And SS8, if the valid data is filled, comparing the obtained management engine layout with the management engine layout after recompiling codes when the management engine is refreshed.
SS9 is refreshed if they match, and is not refreshed if they do not match.
In the specific implementation of this embodiment, predefined ME layout information is output to the inside of Token1 file in the compiling process, then compiling is started, if compiling is not error-free, a binary bin file is generated, at this time, a program is added, an FIT tool is called to extract ME layout information, the ME layout information is output to a Token2 file, then ME region address offset information to the inside of Token1 and Token2 is compared, if the two are consistent, the program is ended, if the two are not consistent, ME region information to the inside of the original code is automatically changed, a recompilation command is triggered after the change is completed, and after the code is recompiled, the predefined ME layout information to the inside of the code and the actual ME layout information are consistent. Meanwhile, in the compiling process, a BIOS ROM area (hole) is reserved, if the ME layout change is found in the compiling process, data can be stuffed into the data after the compiling is triggered again, and the data represents the ME layout information change. If the user triggers the AFU to refresh the ME, the content of the area in the code is checked before the ME is refreshed, if the area is found to be valid data, the area is analyzed, and then the strategy for refreshing the ME is updated, such as automatically skipping the deleted ME area and the like.
Fig. 4 is a schematic diagram of a complete BIOS ROM image, although different platforms may have differences, where GBE, PDR, and ME areas are refreshed when AFU executes a refresh ME command, so that there are 3 bytes in the reserved BIOS ROM area, which correspond to GBE, PDR, and ME areas respectively. Normally the value of these several bytes is FF. Once the layout changes, the data for this region will change, with 0 representing the region is cleared and 1 representing the layout change.
For example, the GBE field is deleted, writing 0 to this field indicates that the GBE field is deleted. In the BIOS boot execution phase, if the BIOS ROM is updated by the AFU tool, the contents of the area are first searched, and if the area is found to be FF, no change is made. If the GBE field of the area is found to be 0, the updating process is adjusted, the code for refreshing the GBE area is automatically skipped, and the next stage is directly written by the flash. For example, if the reserved ME area is set to 1, which indicates that the ME area layout changes, when reading the offsets of each area during the flash, the offset information is compared with the offset information updated in the compilation process, and if the offset information is consistent, the area is refreshed, otherwise, the area is not refreshed.
According to the method for automatically checking and updating the management engine layout, the ME refreshing strategy is automatically updated in the process of automatically checking and correcting the ME layout of the intel platform and the code execution process in the AMI BIOS code compiling process, manual intervention is not needed in the correcting process, only the result is manually checked, the situations of omission and neglect of correction caused by manual checking are avoided, the development efficiency is greatly improved, meanwhile, the ME refreshing strategy is automatically updated, and the refreshing efficiency and the refreshing accuracy are improved.
The above detailed description is directed to an embodiment of a method for automatically checking and updating a management engine layout, and based on the method for automatically checking and updating a management engine layout described in the above embodiment, an embodiment of the present invention further provides an apparatus for automatically checking and updating a management engine layout corresponding to the method.
Fig. 5 is a schematic block diagram of a structure of an apparatus for automatically checking and updating a management engine layout according to an embodiment of the present invention, as shown in fig. 5, the apparatus includes: the system comprises an original layout acquisition module, an actual layout acquisition module, a layout comparison module and a layout updating module.
An original layout acquisition module: an original predefined manageability engine layout within the original base code is obtained.
An actual layout acquisition module: and after the code compiling is finished, acquiring the layout of the actual management engine.
A layout comparison module: and comparing whether the actual management engine layout is consistent with the original predefined management engine layout.
A layout update module: if not, the management engine layout in the original basic code is changed according to the actual management engine layout, and the code compiling is carried out again after the change.
The method for obtaining the original predefined management engine layout in the original basic code includes: outputting all the predefined information to a pre-stored file in a code compiling preprocessing stage; traversing the pre-stored file, and extracting an original predefined management engine layout in the original basic code; storing the original predefined manageability engine layout into a first identification file.
The actual layout obtaining module obtains an actual management engine layout after the code compiling is finished, and specifically includes: traversing a binary file generated by compiling the code to obtain an actual management engine layout; and storing the obtained actual management engine layout into a second identification file. Specifically, an FIT tool is called to traverse a binary file generated by code compilation, and the actual management engine layout is obtained.
The layout comparison module compares whether the actual management engine layout is consistent with the original predefined management engine layout, and specifically comprises: and comparing the information in the first identification file and the information in the second identification file one by one according to the keywords. If the number of the areas in the first identification file is less than that in the second identification file, recording abnormal information; if the number of the areas in the first identification file is more than that of the areas in the second identification file, the areas in the first identification file are taken as a reference for comparison.
The layout updating module changes the management engine layout in the original basic code according to the actual management engine layout, and specifically comprises the following steps: finding a code file defining an original management engine layout; and changing the management engine layout in the found code file according to the actual management engine layout. When searching a code file defining the layout of an original management engine, determining the priority of a file to be searched by using a file suffix, wherein the priority of an sdl suffix file is highest, the priority of an h suffix file is lowest, and the priority of a c suffix file is lowest: the method comprises the steps of firstly searching in an sdl suffix file, if not, searching in an h suffix file, and if not, searching in a c suffix file.
In addition, on the basis of the above-mentioned embodiment, as a preferred embodiment, the apparatus further includes: the device comprises a ROM region reservation module, a data filling module and a refreshing module.
ROM area reservation module: during the code compilation process, a section of BIOS ROM area is reserved.
A data filling module: and if the actual management engine layout is inconsistent with the original predefined management engine layout by comparison, filling effective data in the reserved BIOS ROM region after code compiling is carried out again.
A refresh module: when the BIOS ROM is refreshed, whether a reserved BIOS ROM area is filled with valid data or not is detected, if the reserved BIOS ROM area is filled with the valid data, the obtained management engine layout is compared with the management engine layout after the recoding code is compiled when the management engine is refreshed, if the management engine layout is consistent, refreshing is carried out, and if the management engine layout is inconsistent, refreshing is not carried out.
The apparatus for automatically checking and updating a management engine layout of the present embodiment is used to implement the foregoing method for automatically checking and updating a management engine layout, and therefore, the detailed description of the apparatus can be found in the foregoing embodiment section of the method for automatically checking and updating a management engine layout, and therefore, the detailed description thereof can refer to the description of the corresponding embodiment section and will not be further described herein.
In addition, since the apparatus for automatically checking and updating a management engine layout of the present embodiment is used for implementing the foregoing method for automatically checking and updating a management engine layout, the role thereof corresponds to that of the foregoing method, and details are not described here.
Fig. 6 is a schematic structural diagram of a terminal device 600 according to an embodiment of the present invention, including: a processor 610, a memory 620, and a communication unit 630. The processor 610 is configured to implement the following steps in implementing the automated inspection and update management engine layout program stored in the memory 620:
s1, acquiring an original predefined management engine layout in an original basic code;
s2, obtaining the actual management engine layout after the code compiling is finished;
s3, comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine;
s4, if the two are consistent, no processing is carried out;
and S5, if the basic code is inconsistent with the original basic code, changing the layout of the management engine in the original basic code according to the actual layout of the management engine, and compiling the code again after the change.
The invention automatically acquires the original predefined management engine layout, then automatically acquires the actual management engine layout after the code is compiled, and modifies the definition management engine in the code according to the actual management engine layout and compiles the code again when the original predefined management engine layout and the actual management engine layout are inconsistent, thereby realizing the consistency of the management engine defined in the code and the actual management engine. The method can automatically check and correct the ME layout information in the code, does not need human intervention in the correction process, only needs the human check result, avoids the situations of omission and neglect of correction caused by the manual check, and greatly improves the development efficiency.
The terminal apparatus 600 includes a processor 610, a memory 620, and a communication unit 630. The components communicate via one or more buses, and those skilled in the art will appreciate that the architecture of the servers shown in the figures is not intended to be limiting, and may be a bus architecture, a star architecture, a combination of more or less components than those shown, or a different arrangement of components.
The memory 620 may be used for storing instructions executed by the processor 610, and the memory 620 may be implemented by any type of volatile or non-volatile storage terminal or combination thereof, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk. The executable instructions in memory 620, when executed by processor 610, enable terminal 600 to perform some or all of the steps in the method embodiments described below.
The processor 610 is a control center of the storage terminal, connects various parts of the entire electronic terminal using various interfaces and lines, and performs various functions of the electronic terminal and/or processes data by operating or executing software programs and/or modules stored in the memory 620 and calling data stored in the memory. The processor may be composed of an Integrated Circuit (IC), for example, a single packaged IC, or a plurality of packaged ICs connected with the same or different functions. For example, the processor 610 may include only a Central Processing Unit (CPU). In the embodiment of the present invention, the CPU may be a single operation core, or may include multiple operation cores.
A communication unit 630, configured to establish a communication channel so that the storage terminal can communicate with other terminals. And receiving user data sent by other terminals or sending the user data to other terminals.
The present invention also provides a computer storage medium, wherein the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM) or a Random Access Memory (RAM).
A computer storage medium stores an automated review and update management engine layout program that when executed by a processor implements the steps of:
s1, acquiring an original predefined management engine layout in an original basic code;
s2, obtaining the actual management engine layout after the code compiling is finished;
s3, comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine;
s4, if the two are consistent, no processing is performed;
and S5, if the basic code is inconsistent with the original basic code, changing the layout of the management engine in the original basic code according to the actual layout of the management engine, and compiling the code again after changing.
The invention automatically acquires the original predefined management engine layout, then automatically acquires the actual management engine layout after the code is compiled, and modifies the definition management engine in the code according to the actual management engine layout and compiles the code again when the original predefined management engine layout and the actual management engine layout are inconsistent, thereby realizing the consistency of the management engine defined in the code and the actual management engine. The method can automatically check and correct the ME layout information in the code, does not need human intervention in the correction process, only needs the human check result, avoids the situations of omission and neglect of correction caused by the manual check, and greatly improves the development efficiency.
Those skilled in the art will readily appreciate that the techniques of the embodiments of the present invention may be implemented using software plus any required general purpose hardware platform. Based on such understanding, the technical solutions in the embodiments of the present invention may be embodied in the form of a software product, where the computer software product is stored in a storage medium, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and the like, and the storage medium can store program codes, and includes instructions for enabling a computer terminal (which may be a personal computer, a server, or a second terminal, a network terminal, and the like) to perform all or part of the steps of the method in the embodiments of the present invention.
In the embodiments provided in the present invention, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The above disclosure is only for the preferred embodiments of the present invention, but the present invention is not limited thereto, and any non-inventive changes that can be made by those skilled in the art and several modifications and amendments made without departing from the principle of the present invention shall fall within the protection scope of the present invention.

Claims (10)

1. A method for automatically inspecting and updating a management engine layout, comprising the steps of:
acquiring an original predefined management engine layout in an original basic code;
after the code compiling is finished, acquiring the layout of an actual management engine;
comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine;
if the two are consistent, no processing is carried out;
if not, the management engine layout in the original basic code is changed according to the actual management engine layout, and the code compiling is carried out again after the change.
2. The method for automatically inspecting and updating a manageability engine layout of claim 1, wherein obtaining an original predefined manageability engine layout in an original base code specifically comprises:
outputting all predefined information to a pre-stored file in a code compiling preprocessing stage;
traversing the pre-stored file, and extracting an original predefined management engine layout in the original basic code;
storing the original predefined manageability engine layout into a first identification file.
3. The method for automatically checking and updating a management engine layout as claimed in claim 2, wherein obtaining the actual management engine layout after the code compilation is finished specifically comprises:
traversing a binary file generated by code compiling to obtain an actual management engine layout;
and storing the obtained actual management engine layout into a second identification file.
4. The method for automatically inspecting and updating a management engine layout of claim 3, the method comprising in particular:
and calling an FIT tool to traverse the binary file generated by code compiling, and acquiring the actual management engine layout.
5. The method of automatically inspecting and updating a manageability engine layout of claim 4, wherein comparing whether an actual manageability engine layout is consistent with an original predefined manageability engine layout comprises:
comparing the information in the first identification file and the information in the second identification file one by one according to the keywords;
if the number of the areas in the first identification file is less than that of the areas in the second identification file, recording abnormal information;
if the number of the areas in the first identification file is more than that of the areas in the second identification file, the areas in the first identification file are taken as a reference for comparison.
6. The method for automatically checking and updating a manageability engine layout of claim 5, wherein the altering the manageability engine layout in the original base code according to the actual manageability engine layout comprises:
finding a code file defining an original management engine layout;
changing the management engine layout in the found code file according to the actual management engine layout;
when searching a code file defining the layout of an original management engine, determining the priority of a file to be searched by using a file suffix, wherein the priority of an sdl suffix file is highest, the priority of an h suffix file is lowest, and the priority of a c suffix file is lowest: the method comprises the steps of firstly searching in an sdl suffix file, if not, searching in an h suffix file, and if not, searching in a c suffix file.
7. A method for automatically inspecting and updating a management engine layout according to any of claims 1-6, characterized in that the method further comprises the steps of:
in the code compiling process, reserving a BIOS ROM area;
if the actual management engine layout is inconsistent with the original predefined management engine layout by comparison, filling effective data in a reserved BIOS ROM region after code compiling is carried out again;
when the BIOS ROM is refreshed, whether a reserved BIOS ROM area is filled with valid data or not is detected, if the reserved BIOS ROM area is filled with the valid data, the obtained management engine layout is compared with the management engine layout after the recoding code is compiled when the management engine is refreshed, if the management engine layout is consistent, refreshing is carried out, and if the management engine layout is inconsistent, refreshing is not carried out.
8. An apparatus for automatically checking and updating a management engine layout, comprising,
an original layout acquisition module: acquiring an original predefined management engine layout in an original basic code;
an actual layout acquisition module: after the code compiling is finished, acquiring the actual management engine layout;
a layout comparison module: comparing whether the layout of the actual management engine is consistent with the layout of the original predefined management engine;
a layout update module: if not, the management engine layout in the original basic code is changed according to the actual management engine layout, and the code compiling is carried out again after the change.
9. A terminal, comprising:
a memory for storing an automatic inspection and update management engine layout program;
a processor for implementing the steps of the automated inspection and update management engine layout method according to any one of claims 1 to 7 when executing the automated inspection and update management engine layout program.
10. A computer readable storage medium, having stored thereon an automated inspection and update management engine layout program which, when executed by a processor, performs the steps of the automated inspection and update management engine layout method of any of claims 1-7.
CN202211664080.1A 2022-12-23 2022-12-23 Method, apparatus, terminal and medium for automatically checking and updating management engine layout Pending CN115794194A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211664080.1A CN115794194A (en) 2022-12-23 2022-12-23 Method, apparatus, terminal and medium for automatically checking and updating management engine layout

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211664080.1A CN115794194A (en) 2022-12-23 2022-12-23 Method, apparatus, terminal and medium for automatically checking and updating management engine layout

Publications (1)

Publication Number Publication Date
CN115794194A true CN115794194A (en) 2023-03-14

Family

ID=85427824

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211664080.1A Pending CN115794194A (en) 2022-12-23 2022-12-23 Method, apparatus, terminal and medium for automatically checking and updating management engine layout

Country Status (1)

Country Link
CN (1) CN115794194A (en)

Similar Documents

Publication Publication Date Title
CN105511911B (en) The generation method and device of system firmware upgrade package
US9075695B2 (en) Version conflict checking to installable unit
EP1739552A1 (en) Software installation method and computer system
CN111061643B (en) SDK cluster compatibility detection method and device, electronic equipment and storage medium
JPH076026A (en) Method for guarantee of interchangeablity of configuration management and component and method for exclusion of non- interchangeability of resident software and migration software
CN111694612A (en) Configuration checking method, device, computer system and storage medium
CN111158968A (en) BIOS configuration information self-checking method, device and storage medium
CN112463596B (en) Test case data processing method, device and equipment and processing equipment
CN111400128B (en) Log management method and device, computer equipment and storage medium
CN111966461A (en) Virtual machine cluster node guarding method, device, equipment and storage medium
CN115794194A (en) Method, apparatus, terminal and medium for automatically checking and updating management engine layout
CN114003266B (en) Method and device for generating multiple differential packets based on Android flash firmware
CN114510375A (en) Flash chip data area dynamic sharing system and method
CN113568834A (en) SDK code compatibility detection method, device, computer equipment and medium
CN111736863A (en) Software upgrading method and device and electronic equipment
CN111309598A (en) Test case execution environment recovery method, system, terminal and storage medium
CN113568632B (en) Server power firmware updating method and device, computer equipment and storage medium
JP3183398B2 (en) Resource configuration information management method
CN106502755B (en) Method and device for checking unknown symbols of Linux kernel module
CN113626088A (en) DC-SCM board control method, system and device supporting mixed board insertion
CN116339792A (en) Firmware replacement method, computer system, medium and product
CN117111986A (en) Method capable of automatically completing enterprise management software database script upgrading
CN113918169A (en) Method and device for processing imported file, storage medium and electronic equipment
CN111104312A (en) Test case variable storage management method, system, terminal and storage medium
CN115509777A (en) Fault processing method, device, equipment and storage medium in server

Legal Events

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