CN107656757A - operating system switching method and device - Google Patents
operating system switching method and device Download PDFInfo
- Publication number
- CN107656757A CN107656757A CN201610590623.8A CN201610590623A CN107656757A CN 107656757 A CN107656757 A CN 107656757A CN 201610590623 A CN201610590623 A CN 201610590623A CN 107656757 A CN107656757 A CN 107656757A
- Authority
- CN
- China
- Prior art keywords
- operating system
- address
- file
- guiding
- terminal
- 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.)
- Withdrawn
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/4401—Bootstrapping
- G06F9/4406—Loading of operating system
- G06F9/441—Multiboot arrangements, i.e. selecting an operating system to be loaded
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
The invention provides a kind of operating system switching method and device, wherein, this method includes:Physical memory of the guiding file and the image file of the second operating system that storage system starts to terminal, the terminal is switched into the second operating system by the first operating system using the guiding file in the physical memory and the image file, has skipped original initialization operation of guiding file.Using above-mentioned technical proposal, time-consuming for the switching operating system for solving the problems, such as in correlation technique, and the time of switching operating system is greatly shortened.
Description
Technical field
The present invention relates to the communications field, in particular to a kind of operating system switching method and device.
Background technology
In the related art, the failure recovery time or servicing down times of embedded device, it is an important property
Energy index, required time are more short better.The recovery of many failures, or normal edition upgrading operation, are required for passing through thermogravimetric
Opening equipment could complete.Or upgrade (In-Service Software Upgrade, referred to as ISSU) in non-interrupting service
In, if can faster restarting equipment, also can quickly allow equipment to enter the ready state of masterslave switchover, can improve system can
By property.
The one-shot of computer equipment, typically start (such as (basic input output system (Basic from firmware program
Input Output System, referred to as BIOS)) BIOS+grub or u-boot) start, in these boot bootstrap
The configuration of some DDR and memory management unit (Memory Management Unit, referred to as MMU) is done, then by boot generations
Code is copied into DDR from ROM, is continued to run with DDR, and System guides file boot continues to do the operation of some hardware initializations, with
And other initial configurations operation of specific business need, System guides file boot final stage just read in operating system nucleus
Mirror image and other necessary files, boot program final step just guide operating system nucleus to start.Added again by operating system nucleus
The business application of operational outfit is carried, realizes the function of equipment.
Under embedded environment, after common boot bootstrap guiding os starting, core cpu is no longer taken,
Also no longer terminate-and-stay-resident.And the use of boot and operating system for MMU, the control of multinuclear, these aspects of the support of interruption
There is larger difference.Operating system can not directly perform the code of boot program.Typically boot and operating system are regarded as mutually
Two independent stages, or two kinds of program images.
For in correlation technique, switching operating system the problem of time-consuming, there is presently no effective solution.
The content of the invention
The embodiments of the invention provide a kind of operating system switching method and device, at least to solve to switch in correlation technique
Operating system the problem of time-consuming.
According to one embodiment of present invention, there is provided a kind of operating system switching method, including:What storage system started
File and the image file of the second operating system are guided to the physical memory of terminal;Draw using described in the physical memory
Lead file and the image file and the terminal is switched into the second operating system by the first operating system.
Alternatively, the guiding file and the image file of the second operating system that storage system starts are in the physics of terminal
Before depositing, methods described also includes:Discharge the physical memory of the terminal.
Alternatively, the physical memory of the terminal is discharged, including:End out of service in addition to switching flow needs business
End business.
Alternatively, using the guiding file in the physical memory and the image file by the terminal by first
Operating system switches to the second operating system, including:Obtain and perform the configuration information that the guiding file needs;Match somebody with somebody according to described
Confidence breath performs the guiding file, and installs second operating system according to the image file.
Alternatively, obtain and perform the configuration information that the guiding file needs, including:Obtain and perform the internal memory that function needs
Data and control register state, wherein, the function is used to guide second operating system to open for described guide in file
Dynamic function;And obtain and perform the general register environment that the function needs.
Alternatively, in the case where the guiding file is uboot files, for guiding the function of the second operating system to be
Do_bootm functions, methods described include:Obtaining the internal storage data and control register shape of execution do_bootm function needs
After state, by performing the second os starting described in the do_bootm functions, wherein, the do_bootm functions
Support to read the second operating system mirror image being stored in preset address, the preset address is in the physical memory
Address.
Alternatively, the second operating system mirror image being stored in preset address, including at least one of:Storage institute
The image file of the second operating system is stated to the first address;Dtb files are stored to the second address;Root file system is stored to the 3rd
Address;General register environmental variance that second operating system needs is stored to the 4th address;Wherein, first ground
Location, the second address, the 3rd address and the 4th address are the preset address.
Alternatively, internal storage data and the control register state for performing that do_bootm functions need are obtained, including below extremely
It is one of few:Forbid the core cpu fortune in addition to the central processor CPU core for switching flow in multiprocessor smp system
OK;It is configured to map the transmission look-aside buffer TLB of complete dynamic RAM DDR address spaces;The uboot texts
Part is supported to access the DDR.
Alternatively, first operating system and the same type system that second operating system is different editions, or
Person, first operating system and second operating system are different type system.
According to another embodiment of the invention, there is provided a kind of operating system switching device, applied to terminal, including:
Memory module, the guiding file and the image file of the second operating system started for storage system is in the physics of terminal
Deposit;Handover module, for using the guiding file in the physical memory and the image file by the terminal by the
One operating system switches to the second operating system.
Alternatively, the memory module is additionally operable to the guiding file of storage system startup and the mirror image of the second operating system
File is to the physical memory for before the physical memory of terminal, discharging the terminal.
Alternatively, the memory module is additionally operable to the terminal traffic out of service in addition to switching flow needs business.
Alternatively, the handover module, which is additionally operable to obtain, performs the configuration information that the guiding file needs;According to described
Configuration information performs the guiding file, and installs second operating system according to the image file.
Alternatively, the handover module is additionally operable to obtain internal storage data and the control register state for performing that function needs,
Wherein, the function is used for the function for guiding second os starting for described guide in file;And obtain and perform
The general register environment that the function needs.
Alternatively, in the case where the guiding file is uboot files, for guiding the function of the second operating system to be
Do_bootm functions, the handover module are additionally operable to deposit in the internal storage data and control that obtain execution do_bootm function needs
After device state, by performing the second os starting described in the do_bootm functions, wherein, the do_bootm
Function supports reading to be stored in the second operating system mirror image in preset address, and the preset address is the physical memory
In address.
Alternatively, the second operating system mirror image being stored in preset address, including at least one of:Storage institute
The image file of the second operating system is stated to the first address;Dtb files are stored to the second address;Root file system is stored to the 3rd
Address;General register environmental variance that second operating system needs is stored to the 4th address;Wherein, first ground
Location, the second address, the 3rd address and the 4th address are the preset address.
Alternatively, the handover module is additionally operable to perform at least one following operation:Forbid removing in multiprocessor smp system
For the core cpu operation outside the central processor CPU core of switching flow;It is configured to map complete dynamic random and deposits
The transmission look-aside buffer TLB of reservoir DDR address spaces;The uboot files are supported to access the DDR.
Alternatively, first operating system and the same type system that second operating system is different editions, or
Person, first operating system and second operating system are different type system.
According to still another embodiment of the invention, a kind of storage medium is additionally provided.The storage medium is arranged to storage and used
In the program code for performing following steps:The guiding file and the image file of the second operating system that storage system starts are to eventually
The physical memory at end;Using the guiding file in the physical memory and the image file by the terminal by the first behaviour
The second operating system is switched to as system.
By the present invention, before the first operating system switching system, it is by guiding file and the to be switched second operation
The image file of system is stored in the physical memory of terminal, either switching system or thermogravimetric starting system, directly passes through guiding
Image file in file loading physical memory, has skipped the original initialization operation of guiding file, has solved in correlation technique
Switching operating system the problem of time-consuming, time of switching operating system is greatly shortened.
Brief description of the drawings
Accompanying drawing described herein is used for providing a further understanding of the present invention, forms the part of the application, this hair
Bright schematic description and description is used to explain the present invention, does not form inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is a kind of hardware block diagram of the terminal of operating system switching method of the embodiment of the present invention;
Fig. 2 is a kind of flow chart of operating system switching method according to embodiments of the present invention;
Fig. 3 is a kind of structured flowchart of operating system switching device according to embodiments of the present invention.
Embodiment
Describe the present invention in detail below with reference to accompanying drawing and in conjunction with the embodiments.It should be noted that do not conflicting
In the case of, the feature in embodiment and embodiment in the application can be mutually combined.
It should be noted that term " first " in description and claims of this specification and above-mentioned accompanying drawing, "
Two " etc. be for distinguishing similar object, without for describing specific order or precedence.
Embodiment 1
The embodiment of the method that the embodiment of the present application one is provided can be to hold in terminal or similar arithmetic unit
OK.Exemplified by running on computer terminals, Fig. 1 is that a kind of computer of operating system switching method of the embodiment of the present invention is whole
The hardware block diagram at end.As shown in figure 1, mobile terminal 10 can include one or more (one is only shown in figure) processors
102 (processor 102 can include but is not limited to Micro-processor MCV or PLD FPGA etc. processing unit), use
Memory 104 in data storage and the transmitting device 106 for communication function.Those of ordinary skill in the art can manage
Solution, the structure shown in Fig. 1 are only to illustrate, and it does not cause to limit to the structure of above-mentioned electronic installation.For example, mobile terminal 10 is also
It may include more either less components than shown in Fig. 1 or there is the configuration different from shown in Fig. 1.
Memory 104 can be used for the software program and module of storage application software, such as one kind in the embodiment of the present invention
Programmed instruction/module corresponding to operating system switching method, processor 102 are stored in the software in memory 104 by operation
Program and module, so as to perform various function application and data processing, that is, realize above-mentioned method.Memory 104 can wrap
Include high speed random access memory, may also include nonvolatile memory, as one or more magnetic storage device, flash memory or
Other non-volatile solid state memories.In some instances, memory 104 can further comprise long-range relative to processor 102
The memory of setting, these remote memories can pass through network connection to mobile terminal 10.The example of above-mentioned network include but
It is not limited to internet, intranet, LAN, mobile radio communication and combinations thereof.
Transmitting device 106 is used to data are received or sent via a network.Above-mentioned network instantiation may include
The wireless network that the communication providerses of mobile terminal 10 provide.In an example, transmitting device 106 includes a Network adaptation
Device (Network Interface Controller, NIC), its can be connected by base station with other network equipments so as to it is mutual
Networking is communicated.In an example, transmitting device 106 can be radio frequency (Radio Frequency, RF) module, and it is used
In wirelessly being communicated with internet.
A kind of operating system switching method for running on above computer terminal is provided in the present embodiment, and Fig. 2 is root
According to a kind of flow chart of operating system switching method of the embodiment of the present invention, as shown in Fig. 2 the flow comprises the following steps:
Step S202, the physics of the guiding file and the image file of the second operating system that storage system starts to terminal
Internal memory;
Step S204, it is by the first operation by the terminal using the guiding file in the physical memory and the image file
System switches to the second operating system.
By above-mentioned steps, guiding file and the image file of the second operating system that storage system starts arrive terminal
Physical memory, the terminal is switched to by the first operating system using the guiding file in the physical memory and the image file
Second operating system, time-consuming for the switching operating system for solving the problems, such as in correlation technique, and handover operation system is greatly shortened
The time of system.In one alternate embodiment, obtained by external storage the interface such as usb or terminal of terminal network interface
File and the second operating system file are guided, is saved in the physical memory of terminal.
Guiding file has been recorded in alternative embodiment below present specification and has been preferably uboot files, corresponding operation
System is LINUX system, and in fact, the main application scenarios in this application file are LINUX system, exists in system version and updates
In the case of, system needs hot restart, using the technical scheme described in above-mentioned implementation 2, by the system mirror after being updated over
Deposited in as file in the physical memory of terminal, in switching operating system, system image text is obtained directly from physical memory
Part.Alternatively application scenarios can also be that such as different types of operating system switches over when system switches over, such as
VXWORKS is switched to LINUX system.With reference to foregoing description, it is necessary to supplement, the system switching described in present specification
Flow can also include the switching between same system different editions, i.e., need to carry out thermogravimetric when system upgrade or system are repaired
Open.Or the application scenarios of technical scheme can also be that the two is identical operating system in present specification, that is, grasp
Make system and carry out simple hot restart, be not related to other business.
You need to add is that the guiding file that system starts is obtained from the physical memory of terminal in step S202, should
Guiding file is the guiding file of the second operating system, certainly, if the second operating system and the first operating system are same systems
If the different editions of system, guiding file can guide two operating systems.
Alternatively, the guiding file and the image file of the second operating system that storage system starts are in the physics of terminal
Before depositing, the physical memory of the terminal is discharged.System switching flow physical memory being mainly used in technical scheme, will be except
Business outside the business being related in switching flow is all closed, and is switching flow vacating space, substantial amounts of resource, and then is saved and cut
Change time or the time of operating system hot restart.Terminal traffic out of service in addition to switching flow needs business.
Alternatively, include obtaining the configuration information for performing the guiding file needs in step S202;Match somebody with somebody confidence according to this
Breath performs the guiding file, and installs second operating system according to the image file.Guiding file can guide system loads
The image file (image file i.e. to be cut for changing to operating system) of the second operating system in physical memory is stored in, and performs and draws
Leading file needs to do some preparations, and preparation can obtain internal storage data and the control register for performing that function needs
State, wherein, the function is the function for being used to guide second os starting in the guiding file;And obtain to perform and be somebody's turn to do
The parameter that the general register environment that function needs, i.e. function entrance need.You need to add is that function entrance refers generally to entrance
Function, i.e. program most start the function called when running, all processing later be called all under this function or
Connect called.The parameter of function entrance, it is from core cpu application binaries interface (application binary
Interface, referred to as ABI) directly obtain in the general register that defines of specification, or the storehouse specified from general register
Obtain.
Preferred application scenarios LINUX system in present specification needs hot restart, with more redaction or patching bugs
Etc. scene.Under LINUX scenes, the guiding file is uboot files, and the letter for guiding system is used in corresponding uboot files
Number is do_bootm functions, and under scene in the present embodiment, the technical scheme specific implementation process in present specification is as follows:
, should by performing after the internal storage data for performing do_bootm functions needs and control register state is obtained
Do_bootm functions second os starting, wherein, the do_bootm functions support reading to be stored in preset address
In the second operating system mirror image, the preset address be the physical memory in address.You need to add is that do_ here
Bootm functions are to pass through transformation on do_bootm functional foundations in the related art, can be carried out in specification further part
The detailed description of transformation.
The image file of the second operating system is obtained for the ease of improved do_bootm functions, in this alternative embodiment
It is middle to store the associated documents being used in switching flow respectively.The image file of second operating system is stored to the first ground
Location;Dtb files are stored to the second address;Root file system is stored to the 3rd address;Store the logical of second operating system needs
With registers contexts variable to the 4th address;Wherein, first address, the second address, the 3rd address and the 4th address are pre- for this
If address.
Alternatively, internal storage data and the control register state for performing that do_bootm functions need are obtained, including below extremely
It is one of few:Forbid the core cpu fortune in addition to the central processor CPU core for switching flow in multiprocessor smp system
OK;It is configured to map the transmission look-aside buffer TLB of complete dynamic RAM DDR address spaces;The uboot files
Support to access the DDR (meeting the needs of uboot codes access ddr).
Alternatively, first operating system and the same type system that second operating system is different editions, or, should
First operating system and second operating system are different type system, or, first operating system and second behaviour
Make the same type system that system is identical version.Different types of operating system implication refers to entirely different operating system,
Such as LINUX system and VXWORKS systems.And the same type system of different editions then should be readily appreciated that, such as LINUX system
Different editions.First operating system and the same type system that the second operating system is identical version, i.e., the two is same system
System, application scenarios be by hot restart come repair card move etc..
The method realized by performing this patent, can be when operating system needs hot restart, in operating system
Under performing environment, the image file for the second operating system that boot files (guiding file) and next time need to perform is loaded
Enter internal memory, the running environment being ready to required for boot operations, then perform the final step of boot program.
Do_bootm transformations in the related art are illustrated below.
Application scenarios are as follows:In the operating system of uboot guiding, quick hot restart is realized.
U-Boot or uboot, full name Universal Boot Loader, it is the open source code item for following GPL clauses
Mesh, the operating systems such as LINUX, VXWORKS, QNX, NETBSD can be guided.The method that this use-case illustrates can be using U-Boot
Or used on the revision based on U-Boot, so can also support the hot restart of aforesaid operations system to accelerate.
Uboot last function, that is, it is used for the function do_bootm for guiding the second os starting.In order to realize
Quick hot restart is transformed, it is necessary to carry out two aspects to do_bootm functions.
It is as follows to transform 1:
Do_bootm function prototypes be int do_bootm (cmd_tbl_t*cmdtp, int flag, int argc,
char*argv[]).If former do_bootm will guide LINUX, it is necessary to parse operating system mirror image storing place from parameter
Location, dtb files storage address and root file system storage address.Do_bootm prototypes are transformed into int in present specification
Do_bootm (void), it is no longer necessary to incoming parameter.Operating system mirror image storage address is defined as the first address, dtb simultaneously
File is stored in the second address, and root file system is stored in the 3rd address.Improved do_bootm functions will be from address above mentioned
It is middle to obtain the file needed, no longer go to parse from function parameter.
It is as follows to transform 2:
To make the information of do_bootm needs to be obtained from ddr, it is no longer necessary to access peripheral hardware, it is necessary to transform do_
The code of the environmental variance of general register is obtained in bootm, to realize that do_bootm functions can obtain from the 4th address
The environmental variances such as kernel start-up parameter.
With above-mentioned transformation 1 and transformation 2 it is corresponding be, in correlation technique, boot code of the equipment in normal cold-boot,
It is the content needed in boot program filling above-mentioned first, second, third and the 4th address, then performs do_bootm functions.
Before switching operating system is carried out using improved do_bootm functions, also need to perform following preparation, walk
It is rapid as follows:
Step 1, the business procedure of terminating terminal equipment, with releasing memory resource.Close the industry removed and needed in switching flow
Terminal traffic outside business.
Step 2, under operating system environment to, uboot executable files are copied to the physical memory of terminal.Copy
Shellfish to target physical address can be relocate_code in former uboot codes destination address, the content of copy can also
As the content in relocate_code in correlation technique.
Step 3, the image file of the second operating system of startup next time and other necessary startup files are copied to
The physical memory of terminal.Such as guiding LINUX operating systems, copy the image file of the second operating system to first address,
Dtb file copies copy the 3rd address to the second address, root file system, start the general deposit that the second operating system needs
Device environmental variance is saved in the 4th address.
Step 4, be ready to carry out do_bootm function bodies needs internal storage data and control register state (equivalent to it
Acquisition in preceding alternative embodiment performs the configuration information that the guiding file needs).Preparation process comprises the following steps but not
It is limited to following steps:Forbid other core cpus of smp systems to run, configure tlb to map complete DDR address spaces, meet
The demand that uboot codes are accessed ddr.
Step 5, the do_bootm functions that control terminal core cpu is jumped in the uboot mirror images of step 2 copy enter
Mouthful.
Above step one to five, and for uboot transformation be this alternative embodiment main process.Pass through this side
Method, boot initial phase in the operating system for having supported uboot to rise, can be adjusted, directly guides new kernel to start,
Reduce the thermal starting time.
Through the above description of the embodiments, those skilled in the art can be understood that according to above-mentioned implementation
The method of example can add the mode of required general hardware platform to realize by software, naturally it is also possible to by hardware, but a lot
In the case of the former be more preferably embodiment.Based on such understanding, technical scheme is substantially in other words to existing
The part that technology contributes can be embodied in the form of software product, and the computer software product is stored in a storage
In medium (such as ROM/RAM, magnetic disc, CD), including some instructions to cause a station terminal equipment (can be mobile phone, calculate
Machine, server, or network equipment etc.) perform method described in each embodiment of the present invention.
Embodiment 2
A kind of operating system switching device is additionally provided in the present embodiment, and applied to terminal, the device is used to realize
Embodiment and preferred embodiment are stated, had carried out repeating no more for explanation.As used below, term " module " can be with
Realize the combination of the software and/or hardware of predetermined function.Although the device described by following examples is preferably come real with software
It is existing, but hardware, or the realization of the combination of software and hardware is also what may and be contemplated.
Fig. 3 is a kind of structured flowchart of operating system switching device according to embodiments of the present invention, as shown in figure 3, the dress
Put including:
Memory module 32, the guiding file and the image file of the second operating system started for storage system to terminal
Physical memory;
Handover module 34, it is connected with memory module 32, for using guiding file and the mirror image in the physical memory
The terminal is switched to the second operating system by file by the first operating system.
Alternatively, the memory module 32 is additionally operable to the guiding file of storage system startup and the mirror image of the second operating system
File is to the physical memory for before the physical memory of terminal, discharging the terminal.
Alternatively, the memory module 32 is additionally operable to the terminal traffic out of service in addition to switching flow needs business.
Alternatively, the handover module 34, which is additionally operable to obtain, performs the configuration information that the guiding file needs;According to the configuration
Information performs the guiding file, and installs second operating system according to the image file.
Alternatively, the handover module 34 is additionally operable to obtain internal storage data and the control register state for performing that function needs,
Wherein, the function is the function for being used to guide second os starting in the guiding file;And obtain and perform the function
The general register environment needed.
Alternatively, in the case where the guiding file is uboot files, the function is do_bootm functions, the switching mould
Block 34 is additionally operable to after the internal storage data for performing do_bootm functions needs and control register state is obtained, should by performing
Do_bootm functions second os starting, wherein, the do_bootm functions support reading to be stored in preset address
In the second operating system mirror image, the preset address be the physical memory in address.
Alternatively, the second operating system mirror image being stored in preset address, including at least one of:Store this
The image file of two operating systems is to the first address;Dtb files are stored to the second address;Root file system is stored to the 3rd ground
Location;The general register environmental variance of second operating system needs is stored to the 4th address;Wherein, the first address, second
Address, the 3rd address and the 4th address are the preset address.
Alternatively, the handover module 34 is additionally operable to perform at least one following operation:Forbid removing in multiprocessor smp system
For the core cpu operation outside the central processor CPU core of switching flow;It is configured to map complete dynamic random and deposits
The transmission look-aside buffer TLB of reservoir DDR address spaces;The uboot files are supported to access the DDR.
Alternatively, first operating system and the same type system that second operating system is different editions, or, should
First operating system and second operating system are different type system, or, first operating system and the second operation system
Unite as the same type system of identical version.
It should be noted that above-mentioned modules can be realized by software or hardware, for the latter, Ke Yitong
Cross in the following manner realization, but not limited to this:Above-mentioned module is respectively positioned in same processor;Or above-mentioned modules are with any
The form of combination is located in different processors respectively.
Embodiment 3
Embodiments of the invention additionally provide a kind of storage medium.Alternatively, in the present embodiment, above-mentioned storage medium can
The program code for performing following steps to be arranged to storage to be used for:
S1, the physical memory of the guiding file and the image file of the second operating system that storage system starts to terminal;
S2, the terminal is switched by the first operating system using the guiding file in the physical memory and the image file
To the second operating system.
Alternatively, in the present embodiment, above-mentioned storage medium can include but is not limited to:USB flash disk, read-only storage (ROM,
Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disc or
CD etc. is various can be with the medium of store program codes.
Alternatively, in the present embodiment, processor performs above-mentioned implementation according to the program code stored in storage medium
Method and step described in example.
Alternatively, the specific example in the present embodiment may be referred to described in above-described embodiment and optional embodiment
Example, the present embodiment will not be repeated here.
Obviously, those skilled in the art should be understood that above-mentioned each module of the invention or each step can be with general
Computing device realize that they can be concentrated on single computing device, or be distributed in multiple computing devices and formed
Network on, alternatively, they can be realized with the program code that computing device can perform, it is thus possible to they are stored
Performed in the storage device by computing device, and in some cases, can be with different from shown in order execution herein
The step of going out or describing, they are either fabricated to each integrated circuit modules respectively or by multiple modules in them or
Step is fabricated to single integrated circuit module to realize.So, the present invention is not restricted to any specific hardware and software combination.
The preferred embodiments of the present invention are the foregoing is only, are not intended to limit the invention, for the skill of this area
For art personnel, the present invention can have various modifications and variations.Within the spirit and principles of the invention, that is made any repaiies
Change, equivalent substitution, improvement etc., should be included in the scope of the protection.
Claims (18)
- A kind of 1. operating system switching method, it is characterised in that including:Physical memory of the guiding file and the image file of the second operating system that storage system starts to terminal;The terminal is cut by the first operating system using the guiding file in the physical memory and the image file Shift to the second operating system.
- 2. according to the method for claim 1, it is characterised in that the guiding file and the second operation system that storage system starts To before the physical memory of terminal, methods described also includes the image file of system:Discharge the physical memory of the terminal.
- 3. according to the method for claim 2, it is characterised in that the physical memory of the terminal is discharged, including:Terminal traffic out of service in addition to switching flow needs business.
- 4. according to the method for claim 1, it is characterised in that use the guiding file in the physical memory and institute State image file and the terminal is switched into the second operating system by the first operating system, including:Obtain and perform the configuration information that the guiding file needs;The guiding file is performed according to the configuration information, and second operating system is installed according to the image file.
- 5. according to the method for claim 4, it is characterised in that obtain and perform the configuration information that the guiding file needs, Including:Internal storage data and the control register state for performing that function needs are obtained, wherein, the function is in the guiding file For guiding the function of second os starting;AndObtain and perform the general register environment that the function needs.
- 6. according to the method for claim 4, it is characterised in that in the case where the guiding file is uboot files, use It is do_bootm functions in the function of the second operating system of guiding, methods described includes:After the internal storage data for performing do_bootm functions needs and control register state is obtained, by performing the do_ Second os starting described in bootm functions, wherein, the do_bootm functions support reading to be stored in preset address In the second operating system mirror image, the preset address be the physical memory in address.
- 7. according to the method for claim 6, it is characterised in that the second operation system being stored in the preset address System mirror image, including at least one of:The image file of second operating system is stored to the first address;Dtb files are stored to the second address;Store root file System is to the 3rd address;General register environmental variance that second operating system needs is stored to the 4th address;Wherein, first address, second address, the 3rd address and the 4th address are the preset address.
- 8. according to the method for claim 6, it is characterised in that obtain perform internal storage data that do_bootm functions need and Control register state, including at least one of:Forbid the core cpu fortune in addition to the host CPU core cpu for switching flow in multiprocessor smp system OK;It is configured to map the transmission look-aside buffer TLB of complete dynamic RAM DDR address spaces;The uboot files are supported to access the DDR.
- 9. according to the method described in any one of claim 1 to 8, it is characterised in thatFirst operating system and the same type system that second operating system is different editions, or, described first Operating system and second operating system are different type system, or, first operating system and second operation System is the same type system of identical version.
- A kind of 10. operating system switching device, applied to terminal, it is characterised in that including:Memory module, the physics of the guiding file and the image file of the second operating system started for storage system to terminal Internal memory;Handover module, for using the guiding file in the physical memory and the image file by the terminal by the One operating system switches to the second operating system.
- 11. device according to claim 10, it is characterised in that the memory module is additionally operable to drawing for storage system startup The image file of file and the second operating system is led to the physical memory for before the physical memory of terminal, discharging the terminal.
- 12. device according to claim 11, it is characterised in that the memory module is additionally operable to out of service except switching stream Journey needs the terminal traffic outside business.
- 13. device according to claim 10, it is characterised in that the handover module, which is additionally operable to obtain, performs the guiding The configuration information that file needs;The guiding file is performed according to the configuration information, and institute is installed according to the image file State the second operating system.
- 14. device according to claim 13, it is characterised in that the handover module, which is additionally operable to obtain, performs function needs Internal storage data and control register state, wherein, the function for it is described guiding file in be used for guide it is described second operation The function that system starts;And obtain and perform the general register environment that the function needs.
- 15. device according to claim 13, it is characterised in that in the case where the guiding file is uboot files, Function for guiding the second operating system is do_bootm functions, and the handover module is additionally operable to obtaining execution do_bootm After internal storage data and control register state that function needs, by performing the second behaviour described in the do_bootm functions Make system startup, wherein, the do_bootm functions are supported to read the second operating system mirror being stored in preset address Picture, the preset address are the address in the physical memory.
- 16. device according to claim 15, it is characterised in that second operating system being stored in preset address Mirror image, including at least one of:The image file of second operating system is stored to the first address;Dtb files are stored to the second address;Store root file System is to the 3rd address;General register environmental variance that second operating system needs is stored to the 4th address;Wherein, first address, the second address, the 3rd address and the 4th address are the preset address.
- 17. device according to claim 15, it is characterised in that the handover module is additionally operable to perform following operation at least One of:Forbid the core cpu operation in addition to the central processor CPU core for switching flow in multiprocessor smp system;It is configured to map the transmission look-aside buffer TLB of complete dynamic RAM DDR address spaces;The uboot files are supported to access the DDR.
- 18. according to the device described in any one of claim 10 to 17, it is characterised in thatFirst operating system and the same type system that second operating system is different editions, or, described first Operating system and second operating system are different type system, or, first operating system and second operation System is the same type system of identical version.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610590623.8A CN107656757A (en) | 2016-07-25 | 2016-07-25 | operating system switching method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610590623.8A CN107656757A (en) | 2016-07-25 | 2016-07-25 | operating system switching method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107656757A true CN107656757A (en) | 2018-02-02 |
Family
ID=61126170
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610590623.8A Withdrawn CN107656757A (en) | 2016-07-25 | 2016-07-25 | operating system switching method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107656757A (en) |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110471705A (en) * | 2019-07-15 | 2019-11-19 | 江苏泛腾电子科技有限公司 | A kind of customization dual system |
CN110825315A (en) * | 2018-08-14 | 2020-02-21 | 爱思开海力士有限公司 | Memory system, data processing system and operation method thereof |
CN111209059A (en) * | 2020-01-14 | 2020-05-29 | 中国北方车辆研究所 | Embedded software multi-version control system and method |
CN111880846A (en) * | 2020-06-04 | 2020-11-03 | 普联国际有限公司 | Method, device and equipment for quickly starting embedded system |
CN112230942A (en) * | 2020-09-28 | 2021-01-15 | 烽火通信科技股份有限公司 | Automatic deployment method and system supporting various domestic operating systems |
CN112631669A (en) * | 2020-12-30 | 2021-04-09 | 北京天融信网络安全技术有限公司 | Method, device, computer equipment and medium for starting embedded system |
CN112631671A (en) * | 2020-12-31 | 2021-04-09 | 东软睿驰汽车技术(沈阳)有限公司 | Method and device for initializing operating system |
CN113268366A (en) * | 2020-02-17 | 2021-08-17 | 斑马智行网络(香港)有限公司 | Kernel operation method, device and system |
CN113391879A (en) * | 2021-06-16 | 2021-09-14 | 锐捷网络(苏州)有限公司 | Virtual system switching method and host machine |
CN116243996A (en) * | 2023-05-12 | 2023-06-09 | 苏州浪潮智能科技有限公司 | Service operation switching method and device, storage medium and electronic device |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101324850A (en) * | 2007-06-12 | 2008-12-17 | 中兴通讯股份有限公司 | LINUX inner core dynamic loading method |
CN101840341A (en) * | 2010-04-01 | 2010-09-22 | 惠州Tcl移动通信有限公司 | Intelligent mobile phone system and starting method thereof |
CN103309737A (en) * | 2012-03-07 | 2013-09-18 | 联想(北京)有限公司 | Method and device for switching operating system |
CN103870298A (en) * | 2012-12-17 | 2014-06-18 | 联想(北京)有限公司 | Switching method and electronic device |
CN104899091A (en) * | 2015-07-02 | 2015-09-09 | 中国地质大学(武汉) | Multi-operating system switching method of intelligent embedded equipment |
CN105786547A (en) * | 2014-12-26 | 2016-07-20 | 中兴通讯股份有限公司 | Operation system restarting method and apparatus |
-
2016
- 2016-07-25 CN CN201610590623.8A patent/CN107656757A/en not_active Withdrawn
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101324850A (en) * | 2007-06-12 | 2008-12-17 | 中兴通讯股份有限公司 | LINUX inner core dynamic loading method |
CN101840341A (en) * | 2010-04-01 | 2010-09-22 | 惠州Tcl移动通信有限公司 | Intelligent mobile phone system and starting method thereof |
CN103309737A (en) * | 2012-03-07 | 2013-09-18 | 联想(北京)有限公司 | Method and device for switching operating system |
CN103870298A (en) * | 2012-12-17 | 2014-06-18 | 联想(北京)有限公司 | Switching method and electronic device |
CN105786547A (en) * | 2014-12-26 | 2016-07-20 | 中兴通讯股份有限公司 | Operation system restarting method and apparatus |
CN104899091A (en) * | 2015-07-02 | 2015-09-09 | 中国地质大学(武汉) | Multi-operating system switching method of intelligent embedded equipment |
Cited By (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110825315A (en) * | 2018-08-14 | 2020-02-21 | 爱思开海力士有限公司 | Memory system, data processing system and operation method thereof |
CN110825315B (en) * | 2018-08-14 | 2023-04-28 | 爱思开海力士有限公司 | Memory system, data processing system and method of operation thereof |
CN110471705A (en) * | 2019-07-15 | 2019-11-19 | 江苏泛腾电子科技有限公司 | A kind of customization dual system |
CN111209059A (en) * | 2020-01-14 | 2020-05-29 | 中国北方车辆研究所 | Embedded software multi-version control system and method |
CN111209059B (en) * | 2020-01-14 | 2023-03-03 | 中国北方车辆研究所 | Embedded software multi-version control system and method |
CN113268366A (en) * | 2020-02-17 | 2021-08-17 | 斑马智行网络(香港)有限公司 | Kernel operation method, device and system |
CN111880846A (en) * | 2020-06-04 | 2020-11-03 | 普联国际有限公司 | Method, device and equipment for quickly starting embedded system |
CN111880846B (en) * | 2020-06-04 | 2023-12-15 | 普联国际有限公司 | Method, device and equipment for quickly starting embedded system |
CN112230942A (en) * | 2020-09-28 | 2021-01-15 | 烽火通信科技股份有限公司 | Automatic deployment method and system supporting various domestic operating systems |
CN112631669A (en) * | 2020-12-30 | 2021-04-09 | 北京天融信网络安全技术有限公司 | Method, device, computer equipment and medium for starting embedded system |
CN112631671A (en) * | 2020-12-31 | 2021-04-09 | 东软睿驰汽车技术(沈阳)有限公司 | Method and device for initializing operating system |
CN113391879A (en) * | 2021-06-16 | 2021-09-14 | 锐捷网络(苏州)有限公司 | Virtual system switching method and host machine |
CN116243996A (en) * | 2023-05-12 | 2023-06-09 | 苏州浪潮智能科技有限公司 | Service operation switching method and device, storage medium and electronic device |
CN116243996B (en) * | 2023-05-12 | 2023-08-08 | 苏州浪潮智能科技有限公司 | Service operation switching method and device, storage medium and electronic device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107656757A (en) | operating system switching method and device | |
US11531535B2 (en) | Firmware upgrade method and apparatus, and terminal | |
CN109032846A (en) | Equipment remote backup upgrade method, device, computer storage medium and equipment | |
CN103324498B (en) | Method and equipment for booting bare metal computing device | |
CN109062617B (en) | Application method of platform supporting multiple types of equipment and mobile terminal | |
US9928059B1 (en) | Automated deployment of a multi-version application in a network-based computing environment | |
CN105446769A (en) | Mirror image file update processing method and apparatus and terminal device | |
US20140325043A1 (en) | Network Switching Method, Version Upgrade Method, and Terminal Device | |
CN103189851A (en) | Apparatus and method for network driver injection into target image | |
US10929149B2 (en) | Method and system for updating firmware | |
CN102622241A (en) | Software upgrading method and software upgrading device | |
KR20080007132A (en) | Device and method for upgrading version information of terminal | |
US10579801B2 (en) | Selecting and loading firmware volumes based on license | |
CN108089890B (en) | It is a kind of that operation method and system are applied based on disk | |
CN105824678A (en) | Method and device for installing operating system | |
CN105739961A (en) | Starting method and device of embedded system | |
CN111857765A (en) | Plug-in system for drug design system, and generation method and updating method thereof | |
US5940627A (en) | User selectable feature set for a flash ROM based peripheral | |
CN112015448A (en) | System upgrading method and device based on over-the-air technology | |
CN109947500A (en) | A kind of program loading method, device, system, chip and storage medium | |
CN110597568B (en) | Plug-in deployment method, system and terminal | |
CN110209420A (en) | A kind of method and device updating bootstrap loader | |
CN116594639A (en) | Method, apparatus, storage medium, and program product for managing system installation package | |
CN116991758A (en) | Spatial layout updating method, device, equipment and medium | |
CN112162794A (en) | Single board starting method, device, single board and network equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
TA01 | Transfer of patent application right |
Effective date of registration: 20180418 Address after: 518057 Nanshan District science and technology, Guangdong Province, South Road, No. 55, No. Applicant after: ZTE Corporation Address before: Yuhuatai District of Nanjing City, Jiangsu province 210012 Bauhinia Road No. 68 Applicant before: Nanjing Zhongxing New Software Co., Ltd. |
|
TA01 | Transfer of patent application right | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20180202 |
|
WW01 | Invention patent application withdrawn after publication |