US00922373OB2

(12) United States Patent (10) Patent No.: US 9.223,730 B2 Lin et al. (45) Date of Patent: Dec. 29, 2015

(54) VIRTUAL SYSTEM MANAGEMENT MODE (56) References Cited DEVICE AND CONTROL METHOD THEREOF U.S. PATENT DOCUMENTS 6.799.316 B1* 9/2004 Aguilar et al...... T18, 1 (71) Applicant: WISTRON CORP., New Taipei (TW) 2010/0162242 A1* 6, 2010 Grouzdev ...... 718.1 2015,0040 130 A1 2/2015 Ali et al...... T18, 1 (72) Inventors: Wen-Tai Lin, New Taipei (TW); Yuan-Chan Lee, New Taipei (TW) OTHER PUBLICATIONS (73) Assignee: Wistron Corp., New Taipei (TW) Taiwan Patent Office, Office Action, Patent Application No. 101109290, Apr. 11, 2014, Taiwan. (*) Notice: Subject to any disclaimer, the term of this All I Know about SCI, http://diablo0709.blogspot.tw/2013/04/aii-i- patent is extended or adjusted under 35 know-about-sci.html, Apr. 10, 2013, 6 pages, Taiwan. U.S.C. 154(b) by 570 days. KBSMI & KBSCI, http://boy-asmc.blogspot.tw/2011/03/eckbSmi. html, Mar. 25, 2011, 3 pages,Taiwan. (21) Appl. No.: 13/685,618 * cited by examiner (22) Filed: Nov. 26, 2012 Primary Examiner — Nimesh G Patel (65) Prior Publication Data (57) ABSTRACT US 2013/0246678A1 Sep. 19, 2013 A virtual system management mode device, for processing a (30) Foreign Application Priority Data system management interrupt signal generated by a special process, includes a transformation unit, a control unit Mar. 19, 2012 (TW) ...... 10110929OA memory, and a control unit. The transformation unit trans forms the system management interrupt signal into a virtual (51) Int. Cl. system management interrupt signal. The control unit G06F I3/32 (2006.01) memory stores a plurality of system management interrupt (52) U.S. Cl. processes. The control unit executes one of the system man CPC ...... G06F 13/32 (2013.01) agement interrupt processes according to the virtual system (58) Field of Classification Search management interrupt signal. CPC ...... GO6F 13/32 See application file for complete search history. 18 Claims, 3 Drawing Sheets

Control unit memory 100

Control unit

Central processing unit U.S. Patent Dec. 29, 2015 Sheet 1 of 3 US 9.223,730 B2

00||

I"OIH

ÁJOUUQUU1?un?OJ??OO U.S. Patent Dec. 29, 2015 Sheet 2 of 3 US 9.223,730 B2

The transformation unit transforms a system management interrupt signal into a virtual S2O2 system management interrupt signal The control unit obtains a corresponding S204 System management interrupt process

S206 The control YeS unit determines whether data of the Selected device is accessible

The control unit directly The control unit transmits accesses the data of the a request signal to the Selected device transformation unit according to the SMI proceSS

The transformation unit transforms the request signal into a CPU request signal, and transmits it to the CPU

The CPU obtains the data of the Selected device, and transmits it to the transformation unit

The transformation unit transmits the S216-data of the Selected device to the control unit according to the reply signal

The control unit executes the system S218 management interrupt process FIG. 2 END U.S. Patent Dec. 29, 2015 Sheet 3 of 3 US 9.223,730 B2

The transformation unit transforms a system management interrupt Signal into a Virtual S302 System management interrupt Signal The control unit obtains a corresponding S304 System management interrupt process

The control

Yes unit determines whether the selected NO data can be directly transmitted to the selected device

The control unit directly The control unit transmits transmits the selected data a request signal to the to the Selected device transformation unit according to the SMI process

The transformation unit transforms the request Signal into a CPU request signal, and transmits it to the CPU

The CPU sends the selected data to the selected device

END FIG. 3 US 9,223,730 B2 1. 2 VIRTUAL SYSTEM MANAGEMENT MODE ated, however, that the embodiments provide many appli DEVICE AND CONTROL METHOD cable inventive concepts that can be embodied in a wide THEREOF variety of specific contexts. The specific embodiments dis cussed are merely illustrative of specific ways to make and CROSS REFERENCE TO RELATED use the invention, and do not limit the scope of the invention. APPLICATIONS FIG. 1 is a schematic diagram illustrating an embodiment of a virtual system management mode device 100 according This application claims priority of Taiwan Patent Applica to the invention for processing a system management inter tion No. 101109290, filed on Mar. 19, 2012, the entirety of which is incorporated by reference herein. rupt signal SMI generated by a special process. The virtual 10 system management mode device 100 includes a control unit BACKGROUND OF THE INVENTION 110, a control unit memory 112, a transformation unit 120, and a 130. In some embodiments, the 1. Field of the Invention control unit 110 may be an or a micro The disclosure relates generally to a virtual system man processor, and the control unit memory 112 may store system agement mode device, and more particularly relates to a sys 15 management interrupt processes corresponding to the system tem management mode for a computer system. management interrupt signal SMI. Also, due to the system 2. Description of the Related Art management interrupt processes (such as obtaining a system Generally speaking, a conventional central processing unit password, temporary management, or ) (CPU) executes a system management interrupt operation by being very important parts for the system, the processing System Management Interrupt (SMI), and the central pro priorities thereofare set as the highest. Further, the operation cessing unit executes system management interrupt process. of the system management interrupt processes is inaccessible When the system management interrupt process is com to the operation system executed by the central processing pleted, a return system management command is generated, unit 130. Thus, if the system management interrupt process is Such that the interrupted process may be used improperly, the computer system would be unsafe. In continued. The system management interrupt process 25 order to prevent this situation, the control unit memory 112 is includes lots of functions, and is widely used in computer systems due to the great number of safety features available only accessible via the control unit 110. Namely, the other and high priority for processing. However, those functions units besides the control unit 110 have no authority to access depend on the support of a CPU. Once the CPU has no the the data of the control unit memory 112. system management interrupt mode, it would be more diffi Furthermore, the system management interrupt signal SMI cult to use the application of the related system management 30 may be generated by any unit of the computer system, or be and keep the system management function safe. Therefore, in generated through an application executed by the central pro Such a case, a method to replace a system management inter cessing unit 130. For example, a temporary management application can obtain a temporary of the computer system by rupt mode is needed. generating a system management interrupt signal. However, BRIEF SUMMARY OF THE INVENTION 35 the mechanism of the System Management Mode is designed for a central processing unit. Thus, in order to make the An embodiment of a virtual system management mode control unit 110 execute the system management process device according to the invention, for processing a system correctly, in Some embodiments, the system management management interrupt (SMI) signal generated by a special interrupt signal SMI may be transformed into a virtual system process, is provided. The virtual system management mode 40 management interrupt signal VSMI which can be understood device includes: a transformation unit for transforming the via the control unit 110. Note that although the system man system management interrupt signal into a virtual system agement interrupt signal SMI is generated via the central management interrupt signal; a control unit memory for Stor processing unit 130 in the embodiment of FIG. 1, the present ing a plurality of system management interrupt processes; invention is not limited thereto. Other devices can directly and a control unit for executing one of the system manage 45 transmit the system management interrupt signal SMI to the ment interrupt processes according to the virtual system man transformation unit 120. agement interrupt signal. In an embodiment of the present invention, when the con trol unit 110 receives the virtual system management inter BRIEF DESCRIPTION OF DRAWINGS rupt signal VSMI, the control unit 110 obtains a correspond 50 ing system management interrupt process from the control The invention will become more fully understood by refer unit memory 112 according to the virtual system manage ring to the following detailed description with reference to the ment interrupt signal VSMI, and the control unit 110 executes accompanying drawings, wherein: the corresponding system management interrupt process FIG. 1 is a schematic diagram illustrating an embodiment according to the virtual system management interrupt signal of a virtual system management mode device according to the 55 VSMI. In an embodiment, the control unit 110 can be per invention; formed by any embedded controller or which FIG. 2 is a flowchart of an embodiment of a method for the has been included in the computer system. Therefore, when virtual system management mode device shown in FIG. 1 the control unit 110 receives the virtual system management according to the invention; and interrupt signal VSMI, the present operation process is inter FIG. 3 is a flowchart of another embodiment of a method 60 rupt and stored. After the execution of the system manage for the virtual system management mode device shown in ment interrupt processes are finished, the process returns to FIG. 1 according to the invention. the stored operation process. In an embodiment, when the executed system management DETAILED DESCRIPTION OF THE INVENTION interrupt process executed by the control unit 110 has to 65 obtain data of a selected device, the control unit 110 may be The making and using of the embodiments of the present notable to access the data of the selected device. Because the invention are discussed in detail below. It should be appreci selected device may not be directly connected to the control US 9,223,730 B2 3 4 unit 110 and may be connected to the central processing unit processing unit 130 generates a system management interrupt 130, the data of the selected device may only be accessible via signal SMI according to the executed application program. the central processing unit 130. After the transformation unit 120 receives the system man In some embodiments of the present invention, the control agement interrupt signal SMI, the transformation unit 120 unit 110 may determine whether data of the selected device is transforms the system management interrupt signal SMI into accessible to the control unit 110. When the control unit 110 a virtual system management interrupt signal VSMI. After the cannot access the data of the selected device, the transforma control unit 110 finishes executing the system management tion unit 120 can be a communication interface between the interrupt process according to the virtual system management control unit 110 and the central processing unit 130, so that interrupt signal VSMI, the next steps are the same as the the control unit 110 can obtain the data of the selected device. 10 For example, when the control unit 110 determines that the embodiment described above, and the control unit 110 trans data of the selected device is not accessible, the control unit mits the results data of the system management interrupt 110 transmits a request signal S, to the transformation unit processes to a selected device. For example, the results data is 120 according to the system management interrupt process. stored in a specific memory address, and the application The transformation unit 120 transforms the request signal 15 program may obtain the results data from the specific S., into a central processing unit request signal Sce, and memory address and proceed to operate the corresponding transmits the central processing unit request signal S. to process. the central processing unit 130 for notifying the central pro In some embodiments, the central processing unit can cessing unit 130 to obtain the data of the selected device. determine whether the application program has to wait for the Next, the central processing unit 130 obtains the data of the system management interrupt process to finish. If so, the selected device according to the central processing unit central processing unit stops executing the application pro request signal S. from the transformation unit 120, and gram until the system management interrupt process finishes. transmits a reply signal S, to the transformation unit 120 For example, after the control unit 110 finishes the system according to the data of the selected device. Finally, the management interrupt process, the control unit 110 transmits transformation unit 120 transmits a control unit reply signal 25 a virtual system management finish signal V to the trans Sc. to the control unit 110 according to the reply signal S. formation unit 120. The transformation unit 120 transforms so that the control unit 110 can obtain the data of the selected the virtual system management finish signal V into a sys device to process the system management interrupt process. tem management finish signal S. and transmits the system It should be noted that the transformation unit 120 can be a management finish signal S to the central processing unit transformation mechanism and be included in the control unit 30 130 for notifying the central processing unit 130 that the 110 or the central processing unit 130. Therefore, when the system management process has finished. Then, the central control unit 110 and the central processing unit 130 transmit processing unit 130 may return to execute the application data to each other, the transformation unit 120 is provided as program. an interface transformation between the control unit 110 and FIG. 2 is a flowchart of an embodiment of a method for the the central processing unit 130 for information communica 35 virtual system management mode device shown in FIG. 1 tion. according to the invention. In step S202, the transformation On the other hand, when the control unit 110 can directly unit 120 receives a system management interrupt signal SMI access the data of the selected device, namely, the control unit and transforms the system management interrupt signal SMI 110 is directly connected to the selected device, the control into a virtual system management interrupt signal VSMI. In unit 110 can directly obtain the data of the selected device to 40 step S204, the control unit 110 obtains a corresponding sys process the system management interrupt process. tem management interrupt process from the control unit In some embodiments of the present invention, the control memory 112 according to the virtual system management unit 110 may transmit results data of the system management interrupt signal VSMI. interrupt processes or any selected data to a selected device. In step S206, the control unit 110 determines whether data Because the selected device may not be connected to the 45 of the selected device is accessible according to the obtained control unit 110 but connected to the central processing unit system management interrupt process. When the control unit 130, the control unit 110 will determine whether the results 110 can directly access the data of the selected device, step data can be directly transmitted to the selected device. S208 is performed. When the control unit 110 cannot directly When the control unit 110 determines that the selected data access the data of the selected device, step S210 is performed. can be directly transmitted to the selected device, the control 50 In step S208, the control unit 110 accesses the data of the unit 110 directly transmits the selected data to the selected selected device. Next, the control unit 110 executes the sys device. On the other hand, when the control unit 110 deter tem management interrupt process in step S218. In the step mines that the selected data cannot be directly transmitted to S210, the control unit 110 transmits a request signal S. to the the selected device, the control unit 110 transmits a request transformation unit 120 according to the system management signal S, to the transformation unit 120 according to the 55 interrupt process. Next, in step S212, the transformation unit system management interrupt process. The transformation 120 transforms the request signal S. into a central process unit 120 transforms the request signal S. into a central ing unit request signal Sce, and transmits the central pro processing unit request signal Sce, and transmits the central cessing unit request signal Sce, to the central processing unit processing unit request signal Sce, to the central processing 130 for notifying the central processing unit 130 to obtain the unit 130 for notifying the central processing unit 130 to send 60 data of the selected device. Next, in step S214, the central the selected data to the selected device. Next, the central processing unit 130 obtains the data of the selected device processing unit 130 sends the selected data to the selected according to the central processing unit request signal Sce, device according to the central processing unit request signal from the transformation unit 120, and transmits a reply signal S from the transformation unit 120. S. to the transformation unit 120 according to the data of In some embodiments of the present invention, when an 65 the selected device. Finally, in step S216, the transformation application program tries to obtain the results data generated unit 120 transmits a control unit reply signal S to the control via the system management interrupt process, the central unit 110 according to the reply signal S., so that the control US 9,223,730 B2 5 6 unit 110 can obtain the data of the selected device to process management interrupt process is not able to access the the system management interrupt process. selected value of the selected unit, the control unit trans FIG. 3 is a flowchart of another embodiment of a method mits a request signal to the transformation unit accord for the virtual system management mode device shown in ing to the executed system management interrupt pro FIG. 1 according to the invention. In step S302, the transfor cess, and wherein the transformation unit transmits a mation unit 120 receives a system management interrupt sig CPU request signal to the central processing unit accord nal SMI and transforms the system management interrupt ing to the request signal. signal SMI into a virtual system management interrupt signal 2. The virtual system management mode device of claim 1, VSMI. In step S304, the control unit 110 obtains a corre wherein the central processing unit obtains the selected value sponding system management interrupt process from the con 10 of the selected unit according to the CPU request signal, and trol unit memory 112 according to the virtual system man transmits a reply signal to the transformation unit, wherein agement interrupt signal VSMI. the transformation unit transmits a control unit reply signal to In step S306, the control unit 110 determines whether the the control unit according to the reply signal, and wherein the selected data can be directly transmitted to the selected control unit obtain the selected value of the selected unit device. When the selected data can be directly transmitted to 15 according to the control unit reply signal, and executes the the selected device, step S308 is performed. When the executed system management interrupt process based on the selected data cannot be directly transmitted to the selected selected value. device, step S310 is performed. 3. The virtual system management mode device of claim 1, In step S308, the control unit 110 directly transmits the wherein when the executed system management interrupt selected data to the selected device. In step S310, the control process is able to access the selected value of the selected unit, unit 110 transmits a request signal S, to the transformation the control unit obtains the selected value of the selected unit unit 120 according to the system management interrupt pro according to the executed System management interrupt pro cess. Next, in the step S312, the transformation unit 120 cess and executes the executed system management interrupt transforms the request signal S. into a central processing process based on the selected value. unit request signal Sce, and transmits the central processing 25 4. The virtual system management mode device of claim 1, unit request signal S, to the central processing unit 130 for wherein the central processing unit further executes the spe notifying the central processing unit 130 to send the selected cial process, and generates the system management interrupt data to the selected device. Finally, in step S314, the central signal according to the special process. processing unit 130 sends the selected data to the selected 5. The computer integral device of claim 4, wherein after device according to the central processing unit request signal 30 the central processing unit generates the system management S from the transformation unit 120. interrupt signal according to the special process, the central It should be noted that, those who are skilled in the art can processing unit temporarily stops executing the special pro delete, add, or change the order of the steps described above CCSS, without departing from the scope and spirit of this invention. 6. The computer integral device of claim 5, wherein when For example, the system management process executed via 35 the control unit finishes executing the executed System man the central processing unit 130 may include multiple opera agement interrupt process, the control unit transmits a virtual tions. Therefore, a system management process may include system management finish signal to the transformation unit, accessing data of a selected device (such as the flow chart of wherein the transformation unit transmit a system manage FIG. 2) and transmitting a selected data to a selected device ment finish signal to the central processing unit according to (such as the flow chart of FIG. 3). 40 the virtual system management finish signal, and wherein While the invention has been described by way of example when the central processing unit receives the system manage and in terms of preferred embodiment, it is to be understood ment finish signal, the central processing unit restarts execut that the invention is not limited thereto. Those who are skilled ing the special process. in this technology can still make various alterations and modi 7. The computer integral device of claim 1, wherein the fications without departing from the scope and spirit of this 45 control unit memory is only accessible via the control unit. invention. Therefore, the scope of the present invention shall 8. A virtual system management mode device, for process be defined and protected by the following claims and their ing a system management interrupt (SMI) signal generated by equivalents. a special process, the virtual system management mode What is claimed is: device comprising: 1. A virtual system management mode device, for process 50 a transformation unit for transforming the system manage ing a system management interrupt (SMI) signal generated by ment interrupt signal into a virtual system management a special process, the virtual system management mode interrupt signal; device comprising: a control unit memory for storing a plurality of system a transformation unit for transforming the system manage management interrupt processes; ment interrupt signal into a virtual system management 55 a control unit for executing one of the system management interrupt signal; interrupt processes according to the virtual system man a control unit memory for storing a plurality of system agement interrupt signal; and management interrupt processes; a central processing unit, wherein the control unit further a control unit for executing one of the system management determines whether the executed system management interrupt processes according to the virtual system man 60 interrupt process has to send a selected value to a agement interrupt signal; and Selected unit, wherein when the executed system man a central processing unit, wherein when the executed sys agement interrupt process has to send the selected value tem management interrupt process has to obtain a to the selected unit, the control unit transmits a request selected value of a selected unit, the control unit further signal to the transformation unit according to the determines whether the executed system management 65 executed system management interrupt process, interrupt process is able to access the selected value of wherein the transformation unit transmits a CPU request the selected unit, wherein when the executed system signal to the central processing unit according to the US 9,223,730 B2 7 8 request signal, and wherein the central processing unit generating the system management interrupt signal sends the selected value to the selected unit according to according to the special process via the central process the request signal. ing unit. 9. The virtual system management mode device of claim 8, 14. The virtual system management mode control method wherein the control unit generates the selected value accord 5 of claim 13, further comprising: ing to the executed system management interrupt process. after the central processing unit generates the system man 10. A virtual system management mode control method, agement interrupt signal according to the special pro for processing a system management interrupt (SMI) signal cess, temporarily stopping, the execution of the special generated by a special process, the method comprising: process. transforming the system management interrupt signal into 10 15. The virtual system management mode control method a virtual system management interrupt signal; of claim 14, further comprising: storing a plurality of system management interrupt pro when the control unit finishes executing the executed sys cesses in a control unit memory; and tem management interrupt process, transmitting a vir executing one of the system management interrupt pro tual system management finish signal to the transforma cesses according to the virtual system management 15 tion unit via the control unit; interrupt signal by a control unit; transmitting a system management finish signal to the cen further comprising: tral processing unit according to the virtual system man when the executed system management interrupt process agement finish signal; and has to obtain a selected value of a selected unit, deter when the central processing unit receives the system man mining whether the executed system management inter agement finish signal, restarting execution of the special rupt process is able to access the selected value of the process. selected unit via the control unit; 16. The virtual system management mode control method when the executed system management interrupt process is of claim 10, wherein the control unit memory is only acces notable to access the selected value of the selected unit, sible via the control unit. transmitting a request signal to the transformation unit 25 17. A virtual system management mode control method, according to the executed system management interrupt for processing a system management interrupt (SMI) signal process via the control unit; and generated by a special process, the method comprising: transmitting a CPU request signal to a central processing transforming the system management interrupt signal into unit according to the request signal. a virtual system management interrupt signal; 11. The virtual system management mode control method 30 storing a plurality of system management interrupt pro of claim 10, further comprising: cesses in a control unit memory; and obtaining the selected value of the selected unit according executing one of the system management interrupt pro to the CPU request signal via the central processing unit; cesses according to the virtual system management generating a reply signal according to the obtained selected interrupt signal by a control unit; value via the central processing unit; 35 further comprising: transmitting a control unit reply signal to the control unit determining whether the executed system management according to the reply signal; interrupt process has to send a selected value to a obtaining the selected value of the selected unit according selected unit via the control unit; to the control unit reply signal via the control unit; and when the executed system management interrupt process executing the executed system management interrupt pro 40 has to send the selected value to the selected unit, gen cess based on the selected value via the control unit. erating a request signal according to the executed system 12. The virtual system management mode control method management interrupt process via the control unit; of claim 10, further comprising: transmitting a CPU request signal to a central processing when the executed system management interrupt process is unit according to the request signal; and able to access the selected value of the selected unit, 45 sending the selected value to the selected unit according to obtaining the selected value of the selected unit accord the request signal via the central processing unit. ing to the executed system management interrupt pro 18. The virtual system management mode control method cess via the control unit; and of claim 17, further comprising: executing the executed system management interrupt pro generating the selected value according to the executed cess based on the selected value via the control unit. 50 System management interrupt process via the control 13. The virtual system management mode control method unit. of claim 10, further comprising: