CN101685404B - Device and method for dynamically switching equipment in virtual environment - Google Patents

Device and method for dynamically switching equipment in virtual environment Download PDF

Info

Publication number
CN101685404B
CN101685404B CN 200810223294 CN200810223294A CN101685404B CN 101685404 B CN101685404 B CN 101685404B CN 200810223294 CN200810223294 CN 200810223294 CN 200810223294 A CN200810223294 A CN 200810223294A CN 101685404 B CN101685404 B CN 101685404B
Authority
CN
China
Prior art keywords
hardware device
operating system
operational order
equipment
virtual machine
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.)
Active
Application number
CN 200810223294
Other languages
Chinese (zh)
Other versions
CN101685404A (en
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.)
Lenovo Beijing Ltd
Original Assignee
Lenovo Beijing 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 Lenovo Beijing Ltd filed Critical Lenovo Beijing Ltd
Priority to CN 200810223294 priority Critical patent/CN101685404B/en
Publication of CN101685404A publication Critical patent/CN101685404A/en
Application granted granted Critical
Publication of CN101685404B publication Critical patent/CN101685404B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention provides a device dynamically switching equipment in a virtual environment and a method, wherein the equipment comprises a processing module which is used for receiving a moving-out command of a hardware equipment to be moved out, and simulating some moving-out or insertion events for the hardware equipment at a bottom layer through a virtual machine manager according to the moving-out command, or moving the hardware equipment from a first operating system to a second operating system through moving-out or insertion operation to the hardware equipment in each operation system through application programs, so that the hardware equipment can be used only by the second operating system. Due to the adoption of the technical scheme, all the operating systems of the computer can share the hardware equipment independently, thus the performance and the sharing property of the hardware equipment are ensured, and the hardware equipment can be switched among different operating systems.

Description

Equipment dynamic switching device and method in a kind of virtual environment
Technical field
The present invention relates to virtual machine technique in computer realm, refer to especially equipment dynamic switching device and method in a kind of virtual environment.
Background technology
common virtual machine architecture as shown in Figure 1, comprise hardware platform, be arranged on the virtual machine manager (as VMM etc.) on hardware platform, be arranged on a plurality of operating systems on virtual machine manager, as GuestOS1, Guest OS2 etc., these operating systems are managed by virtual machine manager and distribute the use of the equipment in hardware platform, can share between a plurality of operating systems in order to make equipment, virtual machine manager is usually to be the virtual equipment of a certain operating system, as hardware platform, a physical network card is installed, if a plurality of operating systems all need to use this physical network card, normally virtual machine manager is respectively these operating systems virtual network interface card respectively, for this operating system, but to can not show a candle to the performance of direct use physical network card good for the performance of this equipment like this, in order to improve system performance, adopt the mode that operating system exclusively enjoys equipment, but like this when having a plurality of operating systems to want simultaneously to use this equipment, will cause conflict, perhaps work as previous operating system and using this equipment, when this equipment is not in idle condition, other operating system can't be used this equipment, affect other operating systems and use the diversity of this equipment.
The inventor finds that in present technology, there are the following problems at least in realizing process of the present invention:
In dummy machine system, during a certain equipment of a plurality of operating systems in using hardware platform, the existing demand that can not satisfy each operating system to the employment mechanism of equipment causes the performance of system not high.
Summary of the invention
The technical problem to be solved in the present invention is to provide method for dynamically switching equipment in a kind of computing machine and virtual environment, make each operating system of computing machine can exclusively enjoy this equipment within certain period, guaranteed performance and the sharing of equipment, reached the purpose that hardware device switches between different operating system.
For solving the problems of the technologies described above, embodiments of the invention provide technical scheme as follows:
A kind of computing machine comprises:
Hardware platform comprises at least one hardware device;
Virtual machine manager is arranged on described hardware platform;
The first operating unit is equipped with the first operating system when the user operates described the first operating unit, and described hardware device can only be used by described the first operating unit;
The second operating unit is equipped with the second operating system; It is characterized in that, also comprise:
Processing module, be used for receiving the instruction of shifting out that described hardware device is shifted out in requirement, and shift out instruction described hardware device is moved to described the second operating system from described the first operating system according to described, described hardware device can only be used by described the second operating system.
Preferably, described processing module comprises:
Receiver module is used for receiving the instruction of shifting out that described hardware device is shifted out in requirement;
The first operational order generation module is used for shifting out instruction according to described, produces the first operational order, and described the first operational order is transferred to described the first operating system;
The second operational order generation module, be used for according to described the first operating system according to the shift out operating result of described the first operational order to described hardware device, produce the second operational order, and described the second operational order is transferred to described the second operating system by described virtual machine manager;
Described the second operating system is carried out update according to described the second operational order to described hardware device.
Preferably, described the first operational order generation module is specially: the first analog module, be used for shifting out instruction according to described, and simulation produces the request event that shifts out in the power management standard, and the described request event that shifts out is transferred to described the first operating system;
Described the second operational order generation module is specially: the second analog module, be used for according to described the first operating system according to the described request event that shifts out the operating result that shifts out of described hardware device, the equipment that simulation produces in the power management standard inserts event, and described equipment insertion event is transferred to described the second operating system by described virtual machine manager;
Described the second operating system is inserted the event scanning bus according to described equipment, and find described hardware device and load the driver of described hardware device, and the described hardware device of initialization.
Preferably, described the first operational order generation module is specially: the 3rd analog module, be used for shifting out instruction according to described, and simulation produces the power cut-off incident of power management, and the power cut-off incident of described power management is transferred to described the first operating system;
Described the second operational order generation module is specially: the 4th analog module, be used for according to the power cut-off incident of described power management, described hardware device being placed in the operating result that power supply is moved out of state fully according to described the first operating system, simulation generation equipment wake events, and described equipment wake events is transferred to described the second operating system by virtual machine manager;
Described the second operating system is waken described hardware device up according to described equipment wake events.
Preferably, described the first operating unit comprises:
Power management module is used for described hardware device to be carried out shifting out operation according to the described request event that shifts out, and perhaps according to the power cut-off incident of described power management, described hardware device is placed in power supply and is moved out of state fully.
Preferably, described the second operating unit comprises:
Power management module is used for inserting the event scanning bus according to described equipment, finds described hardware device and loads the driver of described hardware device, and the described hardware device of initialization perhaps wakes described hardware device up according to described equipment wake events.
Preferably, described the first operational order generation module and described the second operational order generation module are arranged in described virtual machine manager.
Preferably, above-mentioned computing machine also comprises the 3rd operating unit, the 3rd operating system is installed, and described the 3rd operating system installation is on described virtual machine manager, and described the first operational order generation module and described the second operational order generation module are arranged in described the 3rd operating unit.
Preferably, described processing module comprises:
First processes submodule, be arranged in described the first operating unit, be used for receiving the instruction of shifting out to described hardware device, shift out instruction according to described, unload the driver of described hardware device, control described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system;
Second processes submodule, is arranged in described the second operating unit, is used for loading the driver of described hardware device, and the described hardware device of initialization.
Preferably, described processing module comprises:
The 3rd processes submodule, be arranged in described the first operating unit, be used for receiving the instruction of shifting out to described hardware device, shift out instruction according to described, described hardware device is placed in the state that power supply is moved out of fully, control described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system;
The manages submodule everywhere, is arranged in described the second operating unit, is used for finding and waking up described hardware device.
Embodiments of the invention also provide method for dynamically switching equipment in a kind of virtual environment, comprising:
Receive the instruction of shifting out that hardware device is shifted out in requirement;
According to the described instruction control virtual machine manager that shifts out, hardware device is shifted out from the first operating system, and described hardware device is inserted into the second operating system.
Preferably, shift out instruction and control virtual machine manager hardware device is shifted out from the first operating system according to described, and the step that described hardware device is inserted into the second operating system is specially;
Shift out instruction according to described, simulation produces the first operational order, and described the first operational order is transferred to described the first operating system;
According to the shift out operating result of described the first operational order to described hardware device, simulation produces the second operational order according to described the first operating system;
Described the second operational order is transferred to described the second operating system by described virtual machine manager.
Preferably, described the first operational order is specially the request event that shifts out in the power management standard, and the equipment that described the second operational order is specially in the power management standard inserts event; Perhaps described the first operational order is specially the power cut-off incident of device power supply (DPS) management, and described the second operational order is specially the equipment wake events.
Preferably, describedly shift out instruction and control virtual machine manager hardware device is shifted out from the first operating system according to described, and the step that described hardware device is inserted into the second operating system is specially:
Shift out instruction according to described, the driver of the described hardware device of unloading is controlled described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system.
Preferably, describedly shift out instruction and control virtual machine manager hardware device is shifted out from the first operating system according to described, and the step that described hardware device is inserted into the second operating system is specially:
Shift out instruction according to described, described hardware device is placed in the state that power supply is moved out of fully, control described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system.
Embodiments of the invention have following beneficial effect:
Such scheme simulates some for the event that hardware device is shifted out or inserts by the bottom at computing machine, perhaps hardware device is operated in each operating system by application program, make computing machine each operating system in virtual environment can exclusively enjoy certain hardware device within certain time period, guarantee performance and the sharing of hardware device, reached the purpose of the dynamic switching of hardware device between different operating system.
Description of drawings
Fig. 1 is existing dummy machine system structural representation;
Fig. 2 is embodiments of the invention computer organization schematic diagram;
Fig. 3 is a concrete structure schematic diagram of computing machine shown in Figure 2;
Fig. 4 is a concrete structure schematic diagram of computing machine shown in Figure 3;
Fig. 5 is another concrete structure schematic diagram of computing machine shown in Figure 3;
Fig. 6 is that the first processing module of computing machine shown in Figure 3 is arranged on the schematic diagram in virtual machine manager;
Fig. 7 is that the first processing module of computing machine shown in Figure 3 is arranged on the schematic diagram in the 3rd operating unit;
Fig. 8 is another concrete structure schematic diagram of computing machine shown in Figure 2;
Fig. 9 is the another concrete structure schematic diagram of computing machine shown in Figure 2;
Figure 10 is method for dynamically switching equipment schematic flow sheet in the embodiments of the invention virtual environment.
Embodiment
For technical matters, technical scheme and advantage that embodiments of the invention will be solved is clearer, be described in detail below in conjunction with the accompanying drawings and the specific embodiments.
Embodiments of the invention are in existing dummy machine system, during a certain hardware device of a plurality of operating systems in using hardware platform, the problem that existing employment mechanism to hardware device is not being met each operating system provides method for dynamically switching equipment in a kind of computing machine and virtual environment.
As shown in Figure 2, computing machine comprises hardware platform, and this hardware platform comprises at least one hardware device; Virtual machine manager is arranged on hardware platform; The first operating unit is equipped with the first operating system, current this hardware device that using of this first operating system; The second operating unit is equipped with the second operating system; Processing module is used for receiving the instruction of shifting out that hardware device is shifted out in requirement, according to shifting out instruction control virtual machine manager, hardware device is shifted out from the first operating system, and described hardware device is switched to the second operating system.
In this embodiment, by increase by a processing module in computing machine, when hardware device need to be from an operating system migration to another operating system, receive the user to the instruction of shifting out of hardware device, and shift out instruction according to this this hardware device is switched to another operating system from an operating system, make each operating system can exclusively enjoy certain hardware device within certain time period, guarantee performance and the sharing of hardware device, reached the switching of hardware device between different operating system.
As shown in Figure 3, in an alternative embodiment of the invention, above-mentioned processing module receive the user to hardware device shift out instruction after, need to carry out sequence of operations, make this hardware device switch to the second operating system from the first current operating system, specifically, processing module comprises:
Receiver module is used for receiving the user to the instruction of shifting out of hardware device;
The first operational order generation module is used for according to the shift out instruction of user to hardware device, produces the first operational order, and this first operational order is transferred to this first operating system;
The second operational order generation module, be used for hardware device being carried out according to this first operational order according to this first operating system and shift out the result of operation, produce the second operational order, and this second operational order is transferred to the second operating system by virtual machine manager;
The second operating system is carried out update according to this second operational order to hardware device.
When customer requirements shifted out this hardware device, this processing module was carried out above-mentioned steps, completes the dynamic switching of hardware device from the first operating system to the second operating system like this.
As shown in Figure 4, above-mentioned control hardware equipment shifts out from the first operating system, and the process that is inserted into the second operating system specifically can be realized by following dual mode:
first kind of way, definition has Notify method (Notification Method) in the ACPI of computer system BIOS, provide the equipment that needs dynamic migration and the event that will support (eject request event and Buscheck event), and definition _ EJO (hot remove) method, the first operational order generation module is specially: the first analog module, be used for according to shifting out instruction, simulation produces the request event that shifts out in power management standard (ACPI), i.e. simulation produces eject request event (SCI interruption), and will shift out request event and transfer to the first operating system,
The OSPM module of the first operating system (being power management module) receives that this shifts out request event, with closing device, closes the file of opening, and unloads the driver of this hardware device, produces to shift out operating result; At this moment, the operating result of VMM interception the first operating system OSPM to equipment, virtual machine manager unloads equipment from the virtual pci bus space of the first operating system, and joins the virtual pci bus space of the second operating system;
The second operational order generation module is specially: the second analog module, be used for according to the first operating system according to shifting out the shift out operating result of request event to hardware device, the equipment that simulation produces in the power management standard inserts the event event, and equipment is inserted event transfers to the second operating system by virtual machine manager;
This second operating system also need to define Notify method in ACPI BIOS, support the checkbus event, and define corresponding method; After the OSPM module of the second operating system was received this equipment insertion event, knowing had new equipment to insert, and rescans bus, and the driver of loaded with hardware equipment again, initialization apparatus.
The second way, as shown in Figure 5, adopt the D0 state of ACPI normalized definition and the device power supply (DPS) Managed Solution of D3 state, the D0 state here is the equipment normal operating conditions, the D3 state is that the power supply of hardware device is moved out of fully, and all hardware devices can enter this state.In ACPI BIOS, the corresponding notify event of define equipment.
The first operational order generation module is specially: the 3rd analog module, be used for according to the shift out instruction of user to hardware device, and simulation produces the power cut-off incident of device power supply (DPS) management, i.e. D3 event, and the power cut-off incident of power management is transferred to the first operating system; After the OSPM module of the first operating system receives the power cut-off incident of this power management, hardware device can be set to the D3 state;
The second operational order generation module is specially: the 4th analog module, be used for according to the power cut-off incident of power management, hardware device being placed in the operating result that power supply is moved out of state (being the D3 state) fully according to the first operating system, generation equipment wake events, the event of namely waking up from D3, and the equipment wake events is transferred to the second operating system by virtual machine manager; After the OSPM module of the second operating system (being power management module) receives this equipment wake events, according to this equipment wake events, hardware device is waken up from the D3 state.
in above-described embodiment, to produce some event that hardware device is shifted out and inserts in the ACPI standard by simulation, hardware device to the first operating system shifts out operation, and this hardware device is inserted in the second operating system, as shown in Figure 6, above-mentioned the first operational order generation module and the second operational order generation module can be arranged in virtual machine manager, realize above-mentioned function, certainly above-mentioned reception requires to shift out the receiver module that shifts out instruction of hardware device, also can be arranged in the first operating unit, also can be arranged in this virtual machine manager, certainly as shown in Figure 7, computing machine also can comprise the 3rd operating unit, the 3rd operating system is installed, the 3rd operating system installation is on virtual machine manager, the first operational order generation module and the second operational order generation module also can be arranged in the 3rd operating unit, above-mentioned receiver module can be arranged in the 3rd operating unit, also can be arranged in the first operating unit, this the first operational order generation module and the second operational order generation module can certainly be arranged in other operating systems or software/hardware platform that can support these module operations.
In above-described embodiment, realize the dynamic switching of hardware device from the first operating system to the second operating system by the relevant device Action Events in the first operational order generation module and the second operational order generation module simulation ACPI standard, certainly, also can adopt other mode to realize the dynamic switching of hardware device from the first operating system to the second operating system, as adopting the mode of difference set up applications in the first operating system and the second operating system, shown in Figure 8, processing module can also comprise:
First processes submodule, be arranged in the first operating unit, be used for according to the shift out instruction of user to hardware device, the driver of unloading hardware device, and notice virtual machine manager, by virtual machine manager, hardware device is shifted out from the first operating system, and hardware device is inserted into the second operating system; These first these functions of processing submodule can be realized by an application program in specific implementation;
Virtual machine manager is notified the second operating system, and the second operating unit comprises that second processes submodule, and this second processing submodule is used for the scanning bus, finds new hardware device, the driver of loaded with hardware equipment, and this hardware device of initialization.So just realized the dynamic switching of hardware device from the first operating system to the second operating system, these second these functions of processing submodule also can be realized by an application program.
Equally, for above-mentioned power management scheme, can realize by the application program in the first operating system and the second operating system equally, as shown in Figure 9, above-mentioned processing module comprises:
The 3rd processes submodule, be arranged in the first operating unit, be used for according to the shift out instruction of user to hardware device, call the interface of hardware device, hardware device is placed in the state that power supply is moved out of fully, i.e. D3 state, this hardware device outage, virtual machine manager shifts out this hardware device from the first operating system, and this hardware device is inserted into described the second operating system; Virtual machine manager is notified the second operating system, has the to manage submodule everywhere in the second operating unit, and this is managed submodule everywhere and be used for finding this hardware device, call the interface of this hardware device, this hardware device is carried out the D0 operation, and wake this hardware device, device power up.
in above-described embodiment, the first operating system and the second operating system are an example, the 3rd operating system and the 4th operating system can be arranged, until n operating system, simulate some by virtual machine manager at bottom and be used for shifting out or the insertion event hardware device, perhaps hardware device is shifted out or update in each operating system by application program, make computing machine each operating system in virtual environment can exclusively enjoy certain hardware device within certain time period, performance and the sharing of hardware device have been guaranteed, when the user need to use this hardware device in another operating system, just can be by shifting out instruction, this hardware device is shifted out from current the first operating system of using, and be inserted into the second operating system that to use this hardware device, reached the purpose of the dynamic switching of hardware device between different operating system.
As shown in figure 10, embodiments of the invention also provide method for dynamically switching equipment in a kind of virtual environment, comprising:
Step S101 receives the instruction of shifting out that hardware device is shifted out in requirement;
Step S102 shifts out hardware device according to shifting out instruction control virtual machine manager, and this hardware device is inserted into the second operating system from the first operating system.
Wherein, above-mentioned steps S102 is specially:
According to shifting out instruction, produce the first operational order, and the first operational order is transferred to the first operating system; The first operating system shifts out operation according to this first operational order to this hardware device, produces an operating result, then shifts out operating result according to this, produces the second operational order;
At this moment, virtual machine manager unloads hardware device from the first operating system virtual pci bus space, and joins the virtual pci bus space of the second operating system;
The second operational order is transferred to the second operating system by virtual machine manager, and the second operating system is carried out update according to this second operational order to this hardware device.
Specifically, above-mentioned the first operational order is specially and shifts out request event (eject request event) in power management standard (ACPI), and the second operational order is specially equipment and inserts or the scan bus event; Perhaps the first operational order is specially device power supply (DPS) management D3 event, and the second operational order is specially the equipment wake events, the event that equipment is waken up from the D3 state.
Above-mentioned steps S102 can also be specially: the application program of the first operating system is according to shifting out instruction, the driver of unloading hardware device, controlling virtual machine manager shifts out hardware device from the first operating system, and this hardware device is inserted into the second operating system, this hardware device of the application discovery of the second operating system, and load the driver of this hardware device, this hardware device of initialization.
Above-mentioned steps S102 can also be specially: according to the shift out instruction of user to hardware device, the application program of the first operating system is placed in hardware device the state that power supply is moved out of fully, it is the D3 state, controlling virtual machine manager shifts out hardware device from the first operating system, and this hardware device is inserted into the second operating system, the second operating system is found this hardware device, wakes this hardware device up, powers on for this hardware device.
said method embodiment simulates some by the bottom at computing machine and is used for hardware device is shifted out or the insertion event, perhaps hardware device is shifted out or update in each operating system by application program, make computing machine each operating system in virtual environment can exclusively enjoy certain hardware device within certain time period, performance and the sharing of hardware device have been guaranteed, when the user need to use this hardware device in another operating system, just can be by shifting out instruction, this hardware device is shifted out from current the first operating system of using, and be inserted into the second operating system that to use this hardware device, reached the purpose of the dynamic switching of hardware device between different operating system.
The above is the preferred embodiment of the present invention; should be pointed out that for those skilled in the art, under the prerequisite that does not break away from principle of the present invention; can also make some improvements and modifications, these improvements and modifications also should be considered as protection scope of the present invention.

Claims (9)

1. equipment dynamic switching device in a virtual environment comprises:
Processing module, be used for to receive require the instruction of shifting out of the hardware device that shifts out, and shift out instruction and simulate some by virtual machine manager at bottom and be used for shifting out or the insertion event hardware device according to described, perhaps hardware device is shifted out in each operating system by application program or update is moved to the second operating system with described hardware device from the first operating system, described hardware device can only be used by described the second operating system;
Wherein, described processing module comprises:
Receiver module is used for receiving the instruction of shifting out that described hardware device is shifted out in requirement;
The first operational order generation module is used for shifting out instruction according to described, produces the first operational order, and described the first operational order is transferred to described the first operating system;
The second operational order generation module, be used for according to described the first operating system according to the shift out operating result of described the first operational order to described hardware device, produce the second operational order, and described the second operational order is transferred to described the second operating system by described virtual machine manager;
Described the second operating system is carried out update according to described the second operational order to described hardware device;
Perhaps described processing module comprises:
First processes submodule, be installed in described the first operating system, be used for receiving the instruction of shifting out to described hardware device, shift out instruction according to described, unload the driver of described hardware device, control described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system;
Second processes submodule, is installed in described the second operating system, is used for loading the driver of described hardware device, and the described hardware device of initialization;
Perhaps described processing module comprises:
The 3rd processes submodule, be arranged in described the first operating system, be used for receiving the instruction of shifting out to described hardware device, shift out instruction according to described, described hardware device is placed in the state that power supply is moved out of fully, control described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system;
The manages submodule everywhere, is arranged in described the second operating system, is used for finding and waking up described hardware device.
2. equipment dynamic switching device in virtual environment according to claim 1, it is characterized in that, described the first operational order generation module is specially: the first analog module, be used for shifting out instruction according to described, simulation produces the request event that shifts out in the power management standard, and the described request event that shifts out is transferred to described the first operating system;
Described the second operational order generation module is specially: the second analog module, be used for according to described the first operating system according to the described request event that shifts out the operating result that shifts out of described hardware device, the equipment that simulation produces in the power management standard inserts event, and described equipment insertion event is transferred to described the second operating system by described virtual machine manager;
Described the second operating system is inserted the event scanning bus according to described equipment, and find described hardware device and load the driver of described hardware device, and the described hardware device of initialization.
3. equipment dynamic switching device in virtual environment according to claim 1, it is characterized in that, described the first operational order generation module is specially: the 3rd analog module, be used for shifting out instruction according to described, simulation produces the power cut-off incident of power management, and the power cut-off incident of described power management is transferred to described the first operating system;
Described the second operational order generation module is specially: the 4th analog module, be used for according to the power cut-off incident of described power management, described hardware device being placed in the operating result that power supply is moved out of state fully according to described the first operating system, simulation generation equipment wake events, and described equipment wake events is transferred to described the second operating system by virtual machine manager;
Described the second operating system is waken described hardware device up according to described equipment wake events.
4. equipment dynamic switching device according to claim 2 or 3 described virtual environments, is characterized in that, described the first operating unit comprises:
Power management module is used for described hardware device to be carried out shifting out operation according to the described request event that shifts out, and perhaps according to the power cut-off incident of described power management, described hardware device is placed in power supply and is moved out of state fully.
5. equipment dynamic switching device according to claim 2 or 3 described virtual environments, is characterized in that, described the second operating unit comprises:
Power management module is used for inserting the event scanning bus according to described equipment, finds described hardware device and loads the driver of described hardware device, and the described hardware device of initialization perhaps wakes described hardware device up according to described equipment wake events.
6. equipment dynamic switching device in virtual environment according to claim 1, is characterized in that, described the first operational order generation module and described the second operational order generation module are arranged in described virtual machine manager.
7. equipment dynamic switching device in virtual environment according to claim 1, it is characterized in that, also comprise the 3rd operating unit, the 3rd operating system is installed, described the 3rd operating system installation is on described virtual machine manager, and described the first operational order generation module and described the second operational order generation module are arranged in described the 3rd operating unit.
8. method for dynamically switching equipment in a virtual environment, is characterized in that, comprising:
Receive the instruction of shifting out that hardware device is shifted out in requirement;
simulate some for shifting out or the insertion event hardware device according to the described instruction control virtual machine manager that shifts out at bottom, perhaps hardware device is shifted out in each operating system by application program or update shifts out hardware device from the first operating system, and described hardware device is inserted into the second operating system wherein, according to described shift out instruction control virtual machine manager bottom simulate some be used for to hardware device shift out or the insertion event shifts out hardware device from the first operating system, and the step that described hardware device is inserted into the second operating system is comprised:
Shift out instruction according to described, produce the first operational order in the bottom simulation, and described the first operational order is transferred to described the first operating system; According to the shift out operating result of described the first operational order to described hardware device, simulation produces the second operational order according to described the first operating system; Described the second operational order is transferred to described the second operating system by described virtual machine manager;
Perhaps shift out instruction according to described, the driver of the described hardware device of unloading is controlled described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system;
Perhaps shift out instruction according to described, described hardware device is placed in the state that power supply is moved out of fully, control described virtual machine manager described hardware device is shifted out from described the first operating system, and described hardware device is inserted into described the second operating system.
9. method according to claim 8, is characterized in that, described the first operational order is specially the request event that shifts out in the power management standard, and the equipment that described the second operational order is specially in the power management standard inserts event; Perhaps described the first operational order is specially the power cut-off incident of device power supply (DPS) management, and described the second operational order is specially the equipment wake events.
CN 200810223294 2008-09-28 2008-09-28 Device and method for dynamically switching equipment in virtual environment Active CN101685404B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 200810223294 CN101685404B (en) 2008-09-28 2008-09-28 Device and method for dynamically switching equipment in virtual environment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 200810223294 CN101685404B (en) 2008-09-28 2008-09-28 Device and method for dynamically switching equipment in virtual environment

Publications (2)

Publication Number Publication Date
CN101685404A CN101685404A (en) 2010-03-31
CN101685404B true CN101685404B (en) 2013-06-05

Family

ID=42048573

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 200810223294 Active CN101685404B (en) 2008-09-28 2008-09-28 Device and method for dynamically switching equipment in virtual environment

Country Status (1)

Country Link
CN (1) CN101685404B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102646080A (en) * 2011-02-22 2012-08-22 鸿富锦精密工业(深圳)有限公司 System and method for configuring USB (universal serial bus) equipment in virtual environment
CN103123612B (en) * 2011-11-21 2017-11-28 联想(北京)有限公司 A kind of control method and a kind of electronic equipment of shared equipment
CN105607728B (en) * 2012-02-10 2019-07-26 联想(北京)有限公司 Electronic equipment and its method for managing power supply
CN103927227A (en) * 2014-04-16 2014-07-16 乐视致新电子科技(天津)有限公司 Method and device for switching multiple operating systems and smart television
CN104571964A (en) * 2015-01-15 2015-04-29 宇龙计算机通信科技(深圳)有限公司 Dual system based external storage device mounting method and system
CN106201565A (en) * 2015-05-08 2016-12-07 宇龙计算机通信科技(深圳)有限公司 Method, device and the terminal of a kind of multiple operating system terminal carry SD card
CN105159633A (en) * 2015-07-07 2015-12-16 国鼎网络空间安全技术有限公司 Virtual machine switching display smoothing method and system
CN108401453B (en) * 2017-12-27 2020-01-07 深圳前海达闼云端智能科技有限公司 Method and device for controlling display screen and intelligent terminal
CN115562765B (en) * 2022-12-05 2023-04-07 北京小米移动软件有限公司 Control method and device of positioning assembly, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101059761A (en) * 2006-04-20 2007-10-24 联想(北京)有限公司 Dummy machine system and its hardware access method
CN101093448A (en) * 2006-06-23 2007-12-26 联想(北京)有限公司 Method for switching a system of virtual machine and hardware devices
CN101097526A (en) * 2006-06-29 2008-01-02 联想(北京)有限公司 Virtual machine system and accessing control method of hardware equipment
CN101154130A (en) * 2006-09-30 2008-04-02 联想(北京)有限公司 Virtual machine system and its power supply management method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101059761A (en) * 2006-04-20 2007-10-24 联想(北京)有限公司 Dummy machine system and its hardware access method
CN101093448A (en) * 2006-06-23 2007-12-26 联想(北京)有限公司 Method for switching a system of virtual machine and hardware devices
CN101097526A (en) * 2006-06-29 2008-01-02 联想(北京)有限公司 Virtual machine system and accessing control method of hardware equipment
CN101154130A (en) * 2006-09-30 2008-04-02 联想(北京)有限公司 Virtual machine system and its power supply management method

Also Published As

Publication number Publication date
CN101685404A (en) 2010-03-31

Similar Documents

Publication Publication Date Title
CN101685404B (en) Device and method for dynamically switching equipment in virtual environment
CN102326132B (en) Power management to maximize reduced power state for virtual machine platforms
US8826052B1 (en) Methods and apparatus for power mode control for PDA with separate communications and applications processors
CN101788845B (en) For performing the method and system of computer task reducing power consumption state
CN101819564B (en) Method and device for assisting communication between virtual machines
CN101493781B (en) Virtual machine system and start-up method thereof
CN100399273C (en) System of virtual machine, and method for configuring hardware
EP2720111B1 (en) Computer system, connection device, power supply control method, and power supply control program recording medium
CN101963929B (en) The method preserving/resume work scene
CN102053857A (en) Apparatus for managing a running virtual machine and switching method thereof
CN105204931A (en) Low-power wearable equipment and multi-operation system switching, communication and management method thereof
KR20080069332A (en) Power control apparatus and method thereof
US8473460B2 (en) Driver model for replacing core system hardware
CN101765225A (en) Virtual cluster management system and cluster node
CN103150276B (en) Dynamic Configuration and device
CN102063398B (en) Board card equipment-based inter-board seamless data exchange method
CN107220102A (en) The dormancy of virtual machine and awakening method and system
CN102708027A (en) Method and system for avoiding outage of communication device
CN104978233A (en) Method and device for dynamically using memory
CN101553791B (en) Driver model for replacing core system hardware
CN103870295B (en) Changing method and electronic equipment
CN102196308A (en) Digital-television-based multi-hardware interface compatible driving system
WO2024131161A1 (en) Server architecture for supporting cloud gaming
CN101639780A (en) Shared system and method thereof for basic input-output system of high density server
CN109831326B (en) Network equipment control method and network equipment

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant