IP Library Granted Patent US 11,307,973
Granted Patent B2
US 11,307,973 · App. 16/493,269 · Granted Apr 19, 2022

Method and device for testing robustness and stability of SMM, and storage medium

Inventors: Pengfang Luo (Henan, CN); Guangyao Cao (Henan, CN)
Assignee: ZHENGZHOU YUNHAI INFORMATION TECHNOLOGY CO., LTD.
G06F11/3688
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,307,973
App. No.
16/493,269
Granted
Apr 19, 2022
Kind
B2
Abstract

There are provided a method and a device for testing robustness and stability of an SMM, and a computer readable storage medium. In the method, a target variable is firstly obtained, and it is judged whether an SMI is triggered. Once it is judged that the SMI is triggered, the SMM is entered. In the SMM, a target testing model corresponding to a current value of the target variable is determined, and a target SMM function is tested with the target testing model pre-stored in a system management memory, and serial port information is printed by using firmware to determine the robustness and stability of the SMM, thereby achieving the testing for the robustness and stability of the SMM.

Claims (59)

1. A method for testing robustness and stability of a system management mode (SMM), the method comprising:

acquiring a target variable and judging whether a system management interrupt (SMI) is triggered;

entering the SMM if it is judged that the SMI is triggered;

determining a target testing model corresponding to a current value of the target variable according to a predetermined correspondence relationship; and

testing a target SMM function with the target testing model, and printing serial port information by using firmware to determine the robustness and stability of the SMM, wherein

the target testing model corresponds to the target SMM function and is pre-stored in a system management memory.

2. The method for testing robustness and stability of an SMM according to claim 1 , wherein

the target variable is a predefined system variable; and

the determining a target testing model corresponding to a current value of the target variable according to a predetermined correspondence relationship comprises: determining a target testing model corresponding to a current value of the system variable according to the predetermined correspondence relationship.

3. The method for testing robustness and stability of an SMM according to claim 1 , wherein

the target variable comprises a plurality of variables set in a target address segment, the plurality of variables comprising a first variable and a second variable;

the determining a target testing model corresponding to a current value of the target variable according to a predetermined correspondence relationship comprises: determining a target testing model corresponding to a current value of the first variable according to the predetermined correspondence relationship; and

the testing a target SMM function with the target testing model comprises: testing the target SMM function based on a current value of the second variable with the target testing model.

4. The method for testing robustness and stability of an SMM according to claim 1 , wherein the acquiring a target variable comprises:

acquiring the target variable set in an EFI shell environment.

5. The method for testing robustness and stability of an SMM according to claim 4 , wherein the judging whether an SMI is triggered comprises:

judging whether a target value is received at an IO port whose address is 0xB2;

judging that the SMI is triggered if the target value is received at the IO port whose address is 0xB2; and

judging that the SMI is not triggered if the target value is not received at the IO port whose address is 0xB2.

6. The method for testing robustness and stability of an SMM according to claim 1 , wherein the acquiring a target variable comprises:

acquiring the target variable set in an operating system environment.

7. The method for testing robustness and stability of an SMM according to claim 6 , wherein the judging whether an SMI is triggered comprises:

judging whether a target value is received at an IO port whose address is 0xB2;

judging that the SMI is triggered if the target value is received at the IO port whose address is 0xB2; and

judging that the SMI is not triggered if the target value is not received at the IO port whose address is 0xB2.

8. A non-transitory computer readable storage medium having stored thereon a testing program, wherein the testing program, when executed by a processor, causes the processor to perform the method for testing robustness and stability of an SMM according to claim 1 .

9. A device for testing robustness and stability of a system management mode (SMM), the device comprising: an acquiring and judging module, an entering module, a determining module, and a testing and printing module, wherein

the acquiring and judging module is configured to acquire a target variable and judge whether a system management interrupt (SMI) is triggered;

the entering module is configured to: if it is judged that the SMI is triggered, enter the SMM and trigger the determining module;

the determining module is configured to determine a target testing model corresponding to a current value of the target variable according to a predetermined correspondence relationship; and

the testing and printing module is configured to: test a target SMM function with the target testing model, and print serial port information by using firmware to determine the robustness and stability of the SMM, wherein

the target testing model corresponds to the target SMM function and is pre-stored in a system management memory.

10. A device for testing robustness and stability of a system management mode (SMM), the device comprising:

a memory configured to store a testing program, and

a processor configured to execute the testing program to perform operations of:

acquiring a target variable and judging whether a system management interrupt (SMI) is triggered;

entering the SMM if it is judged that the SMI is triggered;

determining a target testing model corresponding to a current value of the target variable according to a predetermined correspondence relationship; and

testing a target SMM function with the target testing model, and printing serial port information by using firmware to determine the robustness and stability of the SMM,

wherein the target testing model corresponds to the target SMM function and is pre-stored in a system management memory.

11. The device for testing robustness and stability of an SMM according to claim 10 , wherein

the target variable is a predefined system variable; and

the determining a target testing model corresponding to a current value of the target variable according to a predetermined correspondence relationship comprises: determining a target testing model corresponding to a current value of the system variable according to the predetermined correspondence relationship.

12. The device for testing robustness and stability of an SMM according to claim 10 , wherein

the target variable comprises a plurality of variables set in a target address segment, the plurality of variables comprising a first variable and a second variable;

the determining a target testing model corresponding to a current value of the target variable according to a predetermined correspondence relationship comprises: determining a target testing model corresponding to a current value of the first variable according to the predetermined correspondence relationship; and

the testing a target SMM function with the target testing model comprises: testing the target SMM function based on a current value of the second variable with the target testing model.

13. The device for testing robustness and stability of an SMM according to claim 10 , wherein the acquiring a target variable comprises:

acquiring the target variable set in an EFI shell environment.

14. The device for testing robustness and stability of an SMM according to claim 13 , wherein the judging whether an SMI is triggered comprises:

judging whether a target value is received at an IO port whose address is 0xB2;

judging that the SMI is triggered if the target value is received at the IO port whose address is 0xB2; and

judging that the SMI is not triggered if the target value is not received at the IO port whose address is 0xB2.

15. The device for testing robustness and stability of an SMM according to claim 10 , wherein the acquiring a target variable comprises:

acquiring the target variable set in an operating system environment.

16. The device for testing robustness and stability of an SMM according to claim 15 , wherein the judging whether an SMI is triggered comprises:

judging whether a target value is received at an IO port whose address is 0xB2;

judging that the SMI is triggered if the target value is received at the IO port whose address is 0xB2; and

judging that the SMI is not triggered if the target value is not received at the IO port whose address is 0xB2.

Assignments (2)
LICENSE Recorded Jun 30, 2026
From: IEIT SYSTEMS CO., LTD
To: AIVRES SYSTEMS INC.
Reel/Frame 075857/0939 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 8, 2019
From: LUO, PENGFANG; CAO, GUANGYAO
To: ZHENGZHOU YUNHAI INFORMATION TECHNOLOGY CO., LTD.
Reel/Frame 050646/0941 →
Priority Claims (1)
CN 201810678976.2 · Jun 27, 2018 · national
Continuity (1)
Related Publication 20210357312A1 · Nov 18, 2021