CN103677989B - A kind of utilization linux kernel realizes the device and method of multisystem - Google Patents

A kind of utilization linux kernel realizes the device and method of multisystem Download PDF

Info

Publication number
CN103677989B
CN103677989B CN201310677376.1A CN201310677376A CN103677989B CN 103677989 B CN103677989 B CN 103677989B CN 201310677376 A CN201310677376 A CN 201310677376A CN 103677989 B CN103677989 B CN 103677989B
Authority
CN
China
Prior art keywords
system
module
device file
user
linux kernel
Prior art date
Application number
CN201310677376.1A
Other languages
Chinese (zh)
Other versions
CN103677989A (en
Inventor
刘伟
Original Assignee
Tcl集团股份有限公司
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 Tcl集团股份有限公司 filed Critical Tcl集团股份有限公司
Priority to CN201310677376.1A priority Critical patent/CN103677989B/en
Publication of CN103677989A publication Critical patent/CN103677989A/en
Application granted granted Critical
Publication of CN103677989B publication Critical patent/CN103677989B/en

Links

Abstract

The present invention discloses the device and method that a kind of utilization linux kernel realizes multisystem, wherein, device includes:The bottom module shared for different system;Be arranged on bottom module for the system handover module that switches between different systems;And it is arranged on the different system on system handover module;The system handover module includes virtual terminal module and event module;The virtual terminal module includes the multiple virtual terminals for being used to show different system, and system is corresponded with virtual terminal;The event module, for the switching command according to user, is supplied to different system to conduct interviews the device file of bottom module.

Description

A kind of utilization linux kernel realizes the device and method of multisystem

Technical field

The dress of multisystem is realized the present invention relates to mobile terminal multisystem field, more particularly to a kind of utilization linux kernel Put and method.

Background technology

With the development and the progress of society of science and technology, increasing smart machine has come into huge numbers of families, smart mobile phone, The intelligent artifacts such as Intelligent flat, intelligent television are very easy to the work and life of people.At present, general in these equipment There is an operating system, such as Android, ios, firefox os.Such as can in an equipment simultaneously install two or Multiple operating systems, then by the great experience for improving user so that user can just experience many germlines in an equipment System, meets the demand of Consumer's Experience different system.

The Android device hardware of current main flow is powerful, and CPU is substantially double-core and four cores, and this is also grasped more to make Make system there is provided solid hardware foundation, prior art also achieves the side that two kinds of operating system is installed in an equipment Case, but existing dual operating systems, if desired for switching system, it is necessary to which restarting systems, could realize that system switches, switch Come inconvenient;Also, existing dual operating systems easily cause screen while the problem of showing two systems, is easily caused screen and mixes Disorderly.

Therefore, prior art has yet to be improved and developed.

The content of the invention

In view of above-mentioned the deficiencies in the prior art, polyphyly is realized it is an object of the invention to provide one kind using linux kernel The device and method of system, it is intended to solve existing multisystem and realize that technology needs restart ability switching system and cause system switching not side Just and the problem of be easily caused screen clutter.

Technical scheme is as follows:

A kind of utilization linux kernel realizes the device of multisystem, wherein, including:

The bottom module shared for different system;

Be arranged on bottom module for the system handover module that switches between different systems;

And it is arranged on the different system on system handover module;

The system handover module includes virtual terminal module and event module;

The virtual terminal module includes being used for multiple virtual terminals for being shown to different system, and system with virtually Terminal is corresponded;

The event module, for the switching command according to user, not homology is supplied to by the device file of bottom module System conducts interviews.

Described utilization linux kernel realizes the device of multisystem, wherein, the different system at least includes the first system And second system, the first system is android system.

Described utilization linux kernel realizes the device of multisystem, wherein, the event module includes:

Unit is deleted, for when switching to second system from android system according to user's switching command, deleting The device file of linux kernel;

Device file node creating unit, the device file node new for creating, for storage device file;

Reading unit, for reading device file from new device file node, captures the operation of user, and rung Should.

Described utilization linux kernel realizes the device of multisystem, wherein, the event module also includes:

Recovery unit, for when switching back to android system from second system according to user's switching command, recovering Deleted device file under linux kernel.

Described utilization linux kernel realizes the device of multisystem, wherein, the switching command is user by pressing finger Determine hot key realization.

Described utilization linux kernel realizes the device of multisystem, wherein, the specified hot key is Macintosh.

A kind of method that utilization linux kernel realizes multisystem, wherein, including step:

The system handover module switched between different systems is provided on bottom module;

The application layer of different system is set on system handover module;

Be provided for the multiple virtual terminals shown to different system in system handover module, and system with it is virtual Terminal is corresponded;

When receiving the switching command of user, it is supplied to different system to conduct interviews the device file of bottom module;

And by being shown with the one-to-one virtual terminal of system to the system after switching.

The method that described utilization linux kernel realizes multisystem, wherein, the device file by bottom module is provided The step of being conducted interviews to different system specifically includes step:

The virtual terminal that current system is used is inquired about and recorded, and obtains an idle virtual terminal, passes through the sky Not busy virtual terminal is shown.

The method that described utilization linux kernel realizes multisystem, wherein, the different system at least includes the first system And second system, the first system is android system, and the device file by bottom module is supplied to different system to enter The step of row is accessed specifically includes:

When switching to second system from android system according to user's switching command, the equipment text of linux kernel is deleted Part;

New device file node is created, for storage device file;

Device file is read from new device file node, the operation of user is captured, and is responded.

The method that described utilization linux kernel realizes multisystem, wherein, the device file by bottom module is provided The step of being conducted interviews to different system also includes:

When switching back to android system from second system according to user's switching command, recover to have deleted under linux kernel Device file.

Beneficial effect:The present invention on bottom module by setting system handover module, and in system handover module Virtual terminal module and event module are set, allow different system to share a kernel by the event module, and can Currently used system is set to respond the operation of user, while other systems will not be responded;Pass through the virtual terminal module pair Different system is shown, so that the problem of avoiding screen clutter multiple systems are shown on screen simultaneously caused by.

Brief description of the drawings

Fig. 1 is the structured flowchart for the device preferred embodiment that a kind of utilization linux kernel of the invention realizes multisystem.

Fig. 2 is the structured flowchart of event module in the present invention.

Fig. 3 is the flow chart for the method preferred embodiment that a kind of utilization linux kernel of the invention realizes multisystem.

Fig. 4 is the flow chart for the method specific embodiment that a kind of utilization linux kernel of the invention realizes multisystem.

Embodiment

The present invention provides the device and method that a kind of utilization linux kernel realizes multisystem, to make the purpose of the present invention, skill Art scheme and effect are clearer, clear and definite, and the present invention is described in more detail below.It should be appreciated that tool described herein Body embodiment only to explain the present invention, is not intended to limit the present invention.

A kind of utilization linux kernel that the present invention is provided realizes the device of multisystem, and it includes:

The bottom module shared for different system;

Be arranged on bottom module for the system handover module that switches between different systems;

And it is arranged on the different system on system handover module;

The system handover module includes virtual terminal module and event module;

The virtual terminal module includes being used for multiple virtual terminals for being shown to different system, and system with virtually Terminal is corresponded;

The event module, for the switching command according to user, not homology is supplied to by the device file of bottom module System conducts interviews.

The principle of the present invention is that a new system is set up on the basis of linux kernel(It is new it is of course possible to more than one System), new system and original system share a linux kernel, and this can just reach the purpose of fast switching system, Because the two systems all have same core, need not restart can just switch to another system, switch and come non- It is often convenient.Simultaneously as event module in the present invention can be according to the switching command of user by the device file of bottom module It is supplied to the application layer of different system to access, display causes asking for screen clutter on screen simultaneously so avoiding two systems Topic.

It is specifically described below with a specific embodiment come the device to the present invention.

As shown in figure 1, the device includes:For web os systems and the shared bottom module of android system, it is used for The system handover module of system switching is carried out between web os systems and android system, system handover module is arranged on On different system.Bottom module includes linux kernel, file system and various drivings, will by the system handover module Two different isolation of system come, and are exactly different systems on system handover module:Android system and web os systems System, the shared linux kernel of the two systems, driving and file system, because linux kernel is a system increased income, So can be modified by changing its code come the demand according to the present invention, to realize that dual system switches.

Due to running two systems on a kernel, can cause two systems causes system to show while being shown to screen Chaotic the problem of, in order to solve the above problems, the virtual terminal module in the present embodiment is provided with for being carried out to different system Multiple virtual terminals of display(That is graphical virtual terminal), and system and virtual terminal one-to-one corresponding.It is so that each is virtual Terminal fictionalizes the screen come as one, and different systems use different virtual terminals, such as on a virtual terminal Draw, do not interfere with and the operation such as draw is carried out on other virtual terminal, so two systems are separately operable different The problem of screen display is chaotic can be solved under virtual terminal.

If the virtual terminal numbering that android system is used is 7, then web os systems are not 7 void using numbering Intend terminal, for example numbering is 1.Upon power-up of the system, acquiescence, which has been to switch on virtual terminal 7, is shown, Ye Jixian Show android system, when user needs switching system, need to only be switched to virtual terminal 1, show web os systems, work as user When needing to switch back into android system, then switch back into virtual terminal 7.

The device drives file path of virtual terminal is /dev/tty, and only this file need to be operated, and by adjusting Use ioctl functions(Function for sending control and from configuration order to equipment)The purpose of switching virtual terminal can be achieved.By 63 virtual terminals are supported in linux kernel maximum, so 63 systems can be installed simultaneously on linux kernel in theory.

In the present embodiment, its input operation function with reading user of event module, and user's operation can be referred to Order passes to upper strata, transfers to upper strata to carry out response processing.The function of event module needs the Input Driver of linux kernel (Input driving)To support.In linux kernel, any equipment(Peripheral hardware input equipment)Including remote control, mouse etc. be all by Accessed as file, with the event files started be exactly device file under path/dev/input/, only need to be to these Device file is read out, and is stored in a queue, and is read out by the application layer on upper strata, makes corresponding processing, Corresponding function can be completed, so android system is exactly to read user's using the dev equipment under/dev/input/ Input operation.In the present invention, in order to isolate different system, as shown in Fig. 2 being provided with event module 100:

Unit 110 is deleted, for when switching to second system from android system according to user's switching command, deleting The device file of linux kernel;For example when system is switched to web os systems by user from android system, just delete The device file of linux kernel, that is, delete device file related under dev/input/;

Device file node creating unit 120, the device file node new for creating, for storage device file;I.e. New device file node is created under other paths, for storage device file;

Reading unit 130, for reading device file from new device file node, captures the operation of user, and carry out Response.Web os systems can read device file from new device file node, can thus capture the input operation of user, And pass to upper strata and responded;

Recovery unit 140, for when switching back to android system from second system according to user's switching command, recovering Deleted device file under linux kernel;Because original device file is deleted, so android system can not User's input operation is obtained, so when system is switched back to android system by user from web os systems, it is necessary to extensive again These multiple deleted device files, so as to reach that control two systems read the purpose of user's input operation respectively.

More preferably, the switching command is that user realizes that is, user refers to by pressing some by pressing specified hot key Determine hot key i.e. feasible system to switch, for different equipment, it specifies hot key different, so need to enter different equipment The different definition of row, such as TV its definition for mobile phone and with remote control is different.It is furthermore preferred that the specified heat Key is Macintosh, can so avoid user wrong by or the problem of used by influence user by mistake.Specify the definition of hot key, Ke Yi Event-driven is changed in linux kernel, is switched to receive corresponding specified button in different systems.

The code file path of modification is /kernel/drivers/input/input.c, in this document, increase pair Specify reception and the processing function of hot key.After receiving switching and specifying hot key, the interface of calling system handover module go into Row system switches.

Above-described embodiment is by equipment while being illustrated exemplified by installing android system and web os systems, it is clear that this Invention can also install currently a popular other systems, the system such as firefox web os, or based on existing hardware base Plinth, while the system for installing three or more, can equally realize the purpose of three system handover operations.In addition, in the present invention, if Some system in equipment breaks down, and also switches to another system and gets on to be repaired, this has been also convenient for user's solution Certainly failure.

Based on said apparatus, the present invention also provides a kind of method that utilization linux kernel realizes multisystem, as shown in figure 3, It includes step:

S101, it is provided on bottom module the system handover module that switches between different systems;

S102, on system handover module set different system application layer;

S103, it is provided in system handover module multiple virtual terminals for being shown to different system, and system Corresponded with virtual terminal;

S104, when receiving the switching command of user, be supplied to different system to carry out the device file of bottom module Access;

S105 and by being shown with the one-to-one virtual terminal of system to the system after switching.

Further, the step S104 is specifically included:

The virtual terminal that current system is used is inquired about and recorded, and obtains an idle virtual terminal, passes through the sky Not busy virtual terminal is shown.

Further, the different system at least includes the first system and second system, and the first system is Android systems System, the step S104 is specifically included:

When switching to second system from android system according to user's switching command, the equipment text of linux kernel is deleted Part;

New device file node is created, for storage device file;

Device file is read from new device file node, the operation of user is captured, and is responded.

Further, the step S104 also includes:

When switching back to android system from second system according to user's switching command, recover to have deleted under linux kernel Device file.

A method specific embodiment that multisystem is realized using linux kernel is provided below, as shown in figure 4, it includes:

Start;

S201, user's start;

S202, acquiescence enter android system;

S203, when receiving the switching command of user, preparation switches to second system;

S204, kernel receive hot key, start handover process;

The virtual terminal that S205, the current android system of inquiry are used, and its numbering is recorded, while inquiring about a free time Virtual terminal, and switch to the free virtual terminal;

S206, the device file for deleting linux kernel, while new device file node is created, for storage device text Part;

S207, the initialization process for calling second system, and give second system by control;

S208, when user presses the hot key for switching back into android system, the android system recorded before use Virtual terminal;

S209, the device file for recovering original linux kernel, while deleting the equipment text that current second system is used Part;

Terminate.

Particular technique details on the above method has been described in detail in method above.

In summary, it is of the invention by setting system handover module on bottom module, and in system handover module Virtual terminal module and event module are set, allow different system to share a kernel by the event module, and can Currently used system is set to respond the operation of user, while other systems will not be responded;Pass through the virtual terminal module pair Different system is shown, so that the problem of avoiding screen clutter multiple systems are shown on screen simultaneously caused by.

It should be appreciated that the application of the present invention is not limited to above-mentioned citing, for those of ordinary skills, can To be improved or converted according to the above description, all these modifications and variations should all belong to the guarantor of appended claims of the present invention Protect scope.

Claims (6)

1. a kind of utilization linux kernel realizes the device of multisystem, it is characterised in that including:
The bottom module shared for different system;
Be arranged on bottom module for the system handover module that switches between different systems;
And it is arranged on the different system on system handover module;
The system handover module includes virtual terminal module and event module;
The virtual terminal module includes the multiple virtual terminals for being used to show different system, and system and virtual terminal Correspond;
The event module, for the switching command according to user, is supplied to different system to enter the device file of bottom module Row is accessed;
The different system at least includes the first system and second system, and the first system is android system;
The event module includes:
Unit is deleted, for when switching to second system from android system according to user's switching command, deleting in linux The device file of core;
Device file node creating unit, the device file node new for creating, for storage device file;
Reading unit, for reading device file from new device file node, captures the operation of user, and responded.
2. utilization linux kernel according to claim 1 realizes the device of multisystem, it is characterised in that the event mould Block also includes:
Recovery unit, for when switching back to android system from second system according to user's switching command, recovering in linux Deleted device file under core.
3. utilization linux kernel according to claim 1 realizes the device of multisystem, it is characterised in that the switching refers to Make and being realized for user by pressing specified hot key.
4. utilization linux kernel according to claim 3 realizes the device of multisystem, it is characterised in that the specified heat Key is Macintosh.
5. a kind of method that utilization linux kernel realizes multisystem, it is characterised in that including step:
The system handover module switched between different systems is provided on bottom module;
The application layer of different system is set on system handover module;
The multiple virtual terminals shown to different system, and system and virtual terminal are provided in system handover module Correspond;
When receiving the switching command of user, it is supplied to different system to conduct interviews the device file of bottom module;
And by being shown with the one-to-one virtual terminal of system to the system after switching;
The device file by bottom module is supplied to the step of different system conducts interviews to specifically include step:
The virtual terminal that current system is used is inquired about and recorded, and obtains an idle virtual terminal, by described idle empty Intend terminal to be shown;
The different system at least includes the first system and second system, and the first system is android system, described the bottom of by The device file of layer module is supplied to the step of different system conducts interviews to specifically include:
When switching to second system from android system according to user's switching command, the device file of linux kernel is deleted;
New device file node is created, for storage device file;
Device file is read from new device file node, the operation of user is captured, and is responded.
6. the method that utilization linux kernel according to claim 5 realizes multisystem, it is characterised in that described by bottom The device file of module is supplied to the step of different system conducts interviews also to include:
When switching back to android system from second system according to user's switching command, recover deleted under linux kernel and set Standby file.
CN201310677376.1A 2013-12-13 2013-12-13 A kind of utilization linux kernel realizes the device and method of multisystem CN103677989B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310677376.1A CN103677989B (en) 2013-12-13 2013-12-13 A kind of utilization linux kernel realizes the device and method of multisystem

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310677376.1A CN103677989B (en) 2013-12-13 2013-12-13 A kind of utilization linux kernel realizes the device and method of multisystem

Publications (2)

Publication Number Publication Date
CN103677989A CN103677989A (en) 2014-03-26
CN103677989B true CN103677989B (en) 2017-10-24

Family

ID=50315644

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310677376.1A CN103677989B (en) 2013-12-13 2013-12-13 A kind of utilization linux kernel realizes the device and method of multisystem

Country Status (1)

Country Link
CN (1) CN103677989B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105791991B (en) * 2014-12-22 2018-07-17 Tcl集团股份有限公司 Television system and its implementation based on Firefox OS platforms
CN104732165B (en) * 2015-03-06 2018-11-06 西安酷派软件科技有限公司 A kind of management method and terminal of application
CN104794395A (en) * 2015-05-13 2015-07-22 上海瓶钵信息科技有限公司 Architecture characteristic based lightweight multi-system safety management structure
CN106548084A (en) * 2015-09-02 2017-03-29 北京壹人壹本信息科技有限公司 File security means of defence and device
CN106529228A (en) * 2015-09-02 2017-03-22 北京壹人壹本信息科技有限公司 Method and device for safe operations of personal information
CN105511920B (en) * 2015-12-08 2019-05-14 北京元心科技有限公司 A kind of mobile terminal operating system upgrade method and device based on container
CN105511947B (en) * 2015-12-11 2020-05-01 北京元心科技有限公司 Method and device for processing event information in multiple systems
CN107341407A (en) * 2017-07-26 2017-11-10 惠州Tcl移动通信有限公司 More Android system implementation method, storage medium and terminals based on terminal

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02297636A (en) * 1989-05-11 1990-12-10 Nec Corp Os control system in virtual computer system
JPH0922365A (en) * 1995-07-05 1997-01-21 Fujitsu Ltd Virtual computer system
US7370324B2 (en) * 2003-09-30 2008-05-06 Intel Corporation Switching between a service virtual machine and a guest virtual machine in a virtual machine monitor environment
CN101256503A (en) * 2006-12-22 2008-09-03 英特尔公司 Method and apparatus for multithreaded guest operating system execution through a multithreaded host virtual machine monitor
CN101894047A (en) * 2010-06-24 2010-11-24 北京航空航天大学 Kernel virtual machine scheduling policy-based implementation method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02297636A (en) * 1989-05-11 1990-12-10 Nec Corp Os control system in virtual computer system
JPH0922365A (en) * 1995-07-05 1997-01-21 Fujitsu Ltd Virtual computer system
US7370324B2 (en) * 2003-09-30 2008-05-06 Intel Corporation Switching between a service virtual machine and a guest virtual machine in a virtual machine monitor environment
CN101256503A (en) * 2006-12-22 2008-09-03 英特尔公司 Method and apparatus for multithreaded guest operating system execution through a multithreaded host virtual machine monitor
CN101894047A (en) * 2010-06-24 2010-11-24 北京航空航天大学 Kernel virtual machine scheduling policy-based implementation method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于KVM的虚拟机调度方法研究;崔泽永;《中国优秀硕士学位论文全文数据库》;20110815(第8期);说明书第14-15页,20-22页,图3-1,3-6,4-3 *

Also Published As

Publication number Publication date
CN103677989A (en) 2014-03-26

Similar Documents

Publication Publication Date Title
US20160283059A1 (en) Terminal and method for setting menu environments in the terminal
CN103927361B (en) A kind of system and its implementation of locking screen interface picture timing renewal
CN104156658B (en) A kind of mobile terminal and under dual system the method and apparatus of visit data
CN105138228B (en) Display device and its display methods
US20160253073A1 (en) Method and apparatus for adding icon to interface of android system, and mobile terminal
US20170277561A1 (en) Operating System Hot-Switching Method and Apparatus and Mobile Terminal
CN104142859B (en) The fast switch over method of a kind of dual system, device and mobile terminal
CN103338398B (en) Mobile terminal controls method and the mobile terminal of Set Top Box
CN102510458B (en) Method and system for controlling television
US9332378B2 (en) Wireless communication device for performing different wireless communications
WO2016029578A1 (en) Dual-system electronic apparatus and terminal
US20140123073A1 (en) Method, Apparatus, and Mobile Terminal for Operation Interface Management
CN103226454B (en) A kind of method and system realizing multihead display
CN104391890B (en) picture loading method and system
CN102932695B (en) A kind of remote control thereof, intelligent terminal and intelligent remote control system
CN103809848B (en) icon moving method, mobile terminal and intelligent terminal
JP5743174B2 (en) Thin client server system and USB device driver management method
JP2013515293A (en) Method and apparatus for managing an operating system in an embedded system
EP3249568B1 (en) Method and apparatus for displaying application and picture, and electronic device
US20150139025A1 (en) Wireless Network Configuration Method and System for Smart Appliance
CN103777947B (en) The management method at the main interface of a kind of mobile terminal and device
CN102780778A (en) Method for mutual control of vehicle-mounted intelligent system and intelligent terminal
KR100700951B1 (en) Apparatus and method for multi task management in mobile communication system
WO2015106514A1 (en) Hover display method and device
CN102263904B (en) Method and system for controlling double cameras and electronic equipment with double cameras

Legal Events

Date Code Title Description
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant