CN103294406B - Control method, control device, storage device and electronic equipment - Google Patents

Control method, control device, storage device and electronic equipment Download PDF

Info

Publication number
CN103294406B
CN103294406B CN201210055845.1A CN201210055845A CN103294406B CN 103294406 B CN103294406 B CN 103294406B CN 201210055845 A CN201210055845 A CN 201210055845A CN 103294406 B CN103294406 B CN 103294406B
Authority
CN
China
Prior art keywords
mapping table
switching command
electronic equipment
storage device
history
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
CN201210055845.1A
Other languages
Chinese (zh)
Other versions
CN103294406A (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 CN201210055845.1A priority Critical patent/CN103294406B/en
Publication of CN103294406A publication Critical patent/CN103294406A/en
Application granted granted Critical
Publication of CN103294406B publication Critical patent/CN103294406B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

The present invention provides a kind of control method, controls device, storage device and electronic equipment.This control method is applied to logic-based address and mapping of physical address provides in the storage device that access services, this control method includes: mutual with electronic equipment, receive a switching command, the instruction of this switching command switches to a history mapping table pre-saved from currently used mapping table, currently used mapping table have recorded the mapping relations between logical address and the physical address of the first physical storage areas in storage device, and history mapping table have recorded the mapping relations between logical address and the physical address of the second physical storage areas in storage device;By this switching command record in this storage device;When receiving a triggering command, perform this switching command;And according to this switching command, this history mapping table being set to currently used mapping table so that this second physical storage area domain browsing is operated by this electronic equipment based on this history mapping table.

Description

Control method, control device, storage device and electronic equipment
Technical field
The present invention relates to the field of electronic equipment, more particularly it relates to an control method, control Device processed, storage device and electronic equipment.
Background technology
The substantial amounts of traditional mechanical storage device that is different from has been had (to deposit as carried out data based on CD-ROM drive head at present The hard disk of storage, CD etc.) digital storage equipment, such as SSD hard disk etc..These digital storage equipment bases Mapping in logical address and physical address provides the service of access, and it provides logically to external electronic device Location conducts interviews, and realizes logical address and thing in inside by the mapping of logical address and physical address The conversion of reason address, then provides the actual data access service in physical address.
But prior art is not for the data use convenient spirit of offer one of this digital storage equipment The control method lived.
Summary of the invention
It is an object of the invention to provide a kind of control method, control device, storage device and electronic equipment, Can use for the data of digital storage equipment and a kind of convenient, flexible control method is provided.
According to one embodiment of the invention, it is provided that a kind of control method, for logic-based address and thing Mapping in the storage device that the service of access is provided of reason address, described control method includes:
Mutual with electronic equipment, receive a switching command, the instruction of described switching command is reflected from currently used Firing table switches to a history mapping table pre-saved, described currently used mapping table have recorded described in deposit Mapping relations between logical address and the physical address of the first physical storage areas in storage equipment, and Described history mapping table have recorded logical address and the thing of the second physical storage areas in described storage device Mapping relations between reason address;
By this switching command record in this storage device;
When receiving a triggering command, perform described switching command;And
According to described switching command, described history mapping table is set to currently used mapping table so that Described electronic equipment can be based on described history mapping table to described second physical storage area domain browsing operation.
Preferably, described triggering command receive from the BIOS of electronic equipment or receive from external device (ED), Or receive from network equipment.
Preferably, described control method also includes:
When receiving described triggering command, detect and whether this storage device exist described switching command, Obtain a testing result;
If the instruction of described testing result exists described switching command, then automatically perform described switching command, And described history mapping table is set to currently used mapping table so that described electronic equipment can be based on Described history mapping table is to described second physical storage area domain browsing operation;And
If the instruction of described testing result does not exist described switching command, the most described electronic equipment is based on described Currently used mapping table is to described first physical storage area domain browsing operation.
Preferably, according to described switching command, described history mapping table is set to currently used mapping Table includes:
Mutual with electronic equipment, obtain this history mapping table pre-saved.
Preferably, mutual with electronic equipment, obtain this history mapping table pre-saved and also include:
The first instruction of instruction the first mapping table is received from described electronic equipment;
Institute is selected according at least two mapping table that described first instruction prestores from described storage device State the first mapping table as described history mapping table.
Preferably, mutual with electronic equipment, obtain this history mapping table pre-saved and also include:
After the second instruction of described electronic equipment, described storage is sent to described electronic equipment receiving The record preserved in equipment has the list of all mapping tables prestored so that electronic equipment can be based on Described list selects described first mapping table.
Preferably, described control method also includes:
Second switching command is set in the BIOS of described electronic equipment, this second switching command for from At least two mapping table pre-set selects a mapping table;
When electronic equipment starts, automatically perform described second switching command, and according to the mapping selected Storage device is conducted interviews operation by table.
Preferably, described control method also includes:
Mutual with electronic equipment, after receiving a switching command, detect described first physical storage areas With the data in the same section of the second physical storage areas, it is thus achieved that a testing result;
When described testing result indicates described data to be critical data, this switching command record is deposited at this In storage equipment;
When described testing result indicates described data to be non-critical data, directly by described history mapping table It is set to currently used mapping table so that described electronic equipment can be based on described history mapping table to institute State the second physical storage area domain browsing operation.
According to another embodiment of the present invention, it is provided that a kind of control device, for logic-based address and thing Mapping in the storage device that the service of access is provided of reason address, described control device includes:
Acquiring unit, is configured to mutual with electronic equipment, receives a switching command, and described switching command refers to Show the history mapping table switching to pre-save from currently used mapping table, described currently used reflecting Firing table have recorded between logical address and the physical address of the first physical storage areas in described storage device Mapping relations, and described history mapping table have recorded the second physical storage area in described storage device Mapping relations between logical address and the physical address in territory;
Record unit, is configured to this switching command record in this storage device;
Performance element, is configured to when receiving a triggering command, performs described switching command;And
Switch unit, is configured to, according to described switching command, be set to currently make by described history mapping table Mapping table so that described second physics can be deposited by described electronic equipment based on described history mapping table Storage area domain browsing operates.
Preferably, described triggering command receive from the BIOS of electronic equipment or receive from external device (ED), Or receive from network equipment.
Preferably, described control device also includes:
Whether detector unit, is configured to when receiving described triggering command, detect in this storage device and deposit At described switching command, it is thus achieved that a testing result;
Control unit, if being configured to the instruction of described testing result to there is described switching command, holds the most automatically The described switching command of row, and described history mapping table is set to currently used mapping table so that described Electronic equipment can be based on described history mapping table to described second physical storage area domain browsing operation;And If described testing result instruction there is not described switching command, the most described electronic equipment based on described currently The mapping table used is to described first physical storage area domain browsing operation.
Preferably, described acquiring unit is additionally configured to:
Mutual with electronic equipment, obtain this history mapping table pre-saved.
Preferably, described acquiring unit is additionally configured to:
The first instruction of instruction the first mapping table is received from described electronic equipment;
Institute is selected according at least two mapping table that described first instruction prestores from described storage device State the first mapping table as described history mapping table.
Preferably, described acquiring unit is additionally configured to:
After the second instruction of described electronic equipment, described storage is sent to described electronic equipment receiving The record preserved in equipment has the list of all mapping tables prestored so that electronic equipment can be based on Described list selects described first mapping table.
Preferably, arranging the second switching command in the BIOS of described electronic equipment, this second switching refers to Order is configured to from least two mapping table pre-set select a mapping table;
When electronic equipment starts, automatically perform described second switching command, and according to the mapping selected Storage device is conducted interviews operation by table.
Preferably, described control device also includes:
Mutual with electronic equipment, after receiving a switching command, detect described first physical storage areas With the data in the same section of the second physical storage areas, it is thus achieved that a testing result;
When described testing result indicates described data to be critical data, this switching command record is deposited at this In storage equipment;
When described testing result indicates described data to be non-critical data, directly by described history mapping table It is set to currently used mapping table so that described electronic equipment can be based on described history mapping table to institute State the second physical storage area domain browsing operation.
According to another embodiment of the present invention, it is provided that a kind of storage device, be configured to logical address and The mapping of physical address provides the service of access, and described storage device includes:
Acquiring unit, is configured to mutual with electronic equipment, receives a switching command, and described switching command refers to Show the history mapping table switching to pre-save from currently used mapping table, described currently used reflecting Firing table have recorded between logical address and the physical address of the first physical storage areas in described storage device Mapping relations, and described history mapping table have recorded the second physical storage area in described storage device Mapping relations between logical address and the physical address in territory;
Record unit, is configured to this switching command record in this storage device;
Performance element, is configured to when receiving a triggering command, performs described switching command;And
Switch unit, is configured to, according to described switching command, be set to currently make by described history mapping table Mapping table so that described second physics can be deposited by described electronic equipment based on described history mapping table Storage area domain browsing operates.
According to another embodiment of the present invention, it is provided that a kind of electronic equipment, including:
Storage device, the mapping of its logic-based address and physical address provides the service of access,
Wherein, described storage device includes:
Acquiring unit, is configured to mutual with electronic equipment, receives a switching command, and described switching command refers to Show the history mapping table switching to pre-save from currently used mapping table, described currently used reflecting Firing table have recorded between logical address and the physical address of the first physical storage areas in described storage device Mapping relations, and described history mapping table have recorded the second physical storage area in described storage device Mapping relations between logical address and the physical address in territory;
Record unit, is configured to this switching command record in this storage device;
Performance element, is configured to when receiving a triggering command, performs described switching command;And
Switch unit, is configured to, according to described switching command, be set to currently make by described history mapping table Mapping table so that described second physics can be deposited by described electronic equipment based on described history mapping table Storage area domain browsing operates.
In the specific embodiment of the invention, storage device is mutual with electronic equipment, receives all from electronic equipment Change instruction, in order to electronic equipment switches to the second physical store from the first physical storage areas of storage device Region, and this switching command is asynchronous execution instruction, thus avoid when part to be switched is for closing bond number According to time the system crash that causes.
Accompanying drawing explanation
Fig. 1 is the flow chart illustrating control method according to a first embodiment of the present invention;
Fig. 2 is to illustrate the block diagram controlling device according to a first embodiment of the present invention;
Fig. 3 is the block diagram illustrating storage device according to a first embodiment of the present invention;And
Fig. 4 is the block diagram illustrating electronic equipment according to a first embodiment of the present invention.
Detailed description of the invention
Hereinafter, will be described in detail with reference to the accompanying drawings embodiments of the invention.
Fig. 1 is the flow chart illustrating control method according to a first embodiment of the present invention.
Control method according to embodiments of the present invention provides for the mapping of logic-based address and physical address Access in the storage device of service, this storage device e.g. solid storage device.
In current digital storage equipment (such as SSD hard disk etc.), can by storage device logically The corresponding relation of location and physical address saves as mapping table, i.e. snapshot (snapshot), by currently The control of mapping table so that the previously saved data got off can be accessed by user easily, for Family provides convenient data flexibly to use control.Such as, user can by switching different mapping table, Switch over immediately, so that by the different physical storage areas of storage device.
But, when switching different mapping tables, it is understood that there may be such situation, i.e. thing to be switched Manage system disk or the system data of the operating system that memory area relates to being being currently used, then this switching is moved Make to cause the collapse of operating system.
Consider this situation, be made that the present invention.Control method application according to a first embodiment of the present invention There is provided in the storage device that access services in logic-based address and mapping of physical address, described controlling party Method 100 includes:
Step S101: mutual with electronic equipment, receives a switching command, and the instruction of described switching command is from working as The mapping table of front use switches to a history mapping table pre-saved, described currently used mapping token Record the mapping between logical address and the physical address of the first physical storage areas in described storage device Relation, and described history mapping table have recorded patrolling of the second physical storage areas in described storage device Collect the mapping relations between address and physical address.
In this step, storage device is mutual with electronic equipment, to receive a switching command, and described switching Instruction instruction storage device switches over, thus switches to one to pre-save from currently used mapping table History mapping table.Described currently used mapping table have recorded the first physical store in described storage device Mapping relations between logical address and the physical address in region, say, that described storage device is being worked as The logical address using the first physical storage areas being currently in use under environment of front operating system and physically Mapping relations between location.Described history mapping table have recorded the second physical store in described storage device Mapping relations between logical address and the physical address in region, say, that according to described switching command, Mapping between logical address and the physical address of the second memory area that described storage device will use is closed System.
It should be appreciated that the electronic equipment in the embodiment of the present invention is all of can to use above-mentioned number The equipment of word storage device, such as computer, mobile phone, PDA etc..
Step S102: by this switching command record in this storage device.
In this step, this switching command is not immediately performed, and is recorded in this storage device.Also That is, this switching command is asynchronous execution order.
This switching command can record in the specific region of this storage device, such as this storage device be In system protection zone so that this switching command will not be rewritten by the write of other data.
Step S103: when receiving a triggering command, performs described switching command.
In this step, when described storage device receives triggering command, start perform already recorded in Switching command therein.It is to say, this switching command is ability before the triggering of specific triggering command Start to perform.This triggering command can come from the BIOS of electronic equipment, external device (ED) or network equipment etc..
Step S104: according to described switching command, described history mapping table is set to currently used reflecting Firing table so that described electronic equipment can be based on described history mapping table to described second physical storage areas Access operation.
In this step, according to described switching command, the history mapping table specified before is set to currently Mapping table to be used, so that described electronic equipment can be based on described history mapping table to described Two physical storage area domain browsing operations.It is to say, electronic equipment is switched to according to history mapping table The operation scenario of operating system.
In this embodiment of the invention, such as, there are two kinds of situations: 1) when the system of this electronic equipment When restarting, because the power supply of this storage device is not turned off, it is constantly in "on" position, therefore this storage Equipment can receive the triggering command of input;2) become logical when this electronic equipment switches on power from off-position During electricity condition, this storage device also switches on power, and therefore this storage device can receive the triggering of input and refers to Order.
Additionally, when this storage device can receive the triggering command of input, such as can be from electricity The BIOS of subset receives this triggering command.In this case, such as when electronic equipment restarts, First electronic equipment runs the firmware program in BIOS, and begins to use described storage in operating system Before equipment, from BIOS, send triggering command, indicate this storage device to bring into operation and deposited The switching command of storage, so that this electronic equipment uses this storage device determined according to history mapping table Physical storage areas.
Alternately, such as when using the external device (ED) startup electronic equipment such as CD, USB flash disk etc., can To receive this triggering command from external device (ED), thus this storage device starts to perform it according to this triggering command The switching command of middle storage, so that this electronic equipment uses this storage determined according to history mapping table The physical storage areas of equipment.
Alternately, such as when starting electronic equipment from network equipment, it is also possible to receive from network equipment This triggering command, thus this storage device starts the switching command that performs wherein to store according to this triggering command, So that this electronic equipment uses the physical storage area of this storage device determined according to history mapping table Territory.
It addition, when receiving described triggering command, need to detect in this storage device whether exist described Switching command a, it is thus achieved that testing result.If there is described switching command, then in the instruction of described testing result Automatically perform described switching command, and described history mapping table is set to currently used mapping table, make Obtaining described electronic equipment can be based on described history mapping table to described second physical storage area domain browsing behaviour Make.If the instruction of described testing result does not exist described switching command, the most described electronic equipment is based on described Currently used mapping table is to described first physical storage area domain browsing operation.Such as, at electronic equipment weight When the outside input of Qi Shicong performs the triggering command of switching command, need to detect the given zone of this storage device Territory has stored this switching command, only in the case of having stored this switching command, Just start to perform this switching command, and based on a determination that history mapping table to described second physical storage area Domain browsing operates.
Additionally, according to described switching command, described history mapping table is set to currently used mapping Table includes: mutual with electronic equipment, obtains this history mapping table pre-saved.Such as, this storage sets Standby the first instruction that instruction the first mapping table with electronic equipment alternately, can be received from described electronic equipment, And select institute according at least two mapping table that described first instruction prestores from described storage device State the first mapping table as described history mapping table.
By way of example, it will be assumed that storage device has pre-saved 3 mapping tables, respectively mapping table 1, Mapping table 2 and mapping table 3, now, if user has been known a priori by this 3 mapping tables, think directly Use mapping table 2, then directly can send the first instruction by electronic equipment to storage device, wherein should First instruction includes the ID of mapping table 2.
After storage device receives this first instruction, resolve this first instruction and i.e. can get the ID of mapping table 2, Just can be from mapping table 1, in mapping table 2 and mapping table 3, Choose for user table 2 is as history mapping table, Then subsequent treatment is carried out.
Alternately, this storage device can receive from described electronic equipment second instruction after to Described electronic equipment sends the record preserved in described storage device the row of all mapping tables prestored Table so that electronic equipment can select described first mapping table based on described list.
By way of example, it will be assumed that storage device has pre-saved 3 mapping tables, respectively mapping table 1, Mapping table 2 and mapping table 3.
When user needs to select, send the second instruction, instruction by described electronic equipment to storage device Storage device informs mapping table situation;
Storage device receive this second instruction after, i.e. search self preserve mapping table, i.e. mapping table 1, Mapping table 2 and mapping table 3, then send the record preserved in described storage device to described electronic equipment There is the list of all mapping tables prestored;
After electronic equipment receives list, present this list to user.
The mapping table list Choose for user table 2 that user presents based on this, then set to storage by electronic equipment Preparation send the first instruction, and wherein this first instruction includes the ID of mapping table 2.
After storage device receives this first instruction, resolve this first instruction and i.e. can get the ID of mapping table 2, Just can be from mapping table 1, in mapping table 2 and mapping table 3, Choose for user table 2 is as history mapping table, Then subsequent treatment is carried out.
Described above is in the storage device of switching command record, then the mode of asynchronous execution.
But the invention is not restricted to this.Refer to for example, it is also possible to arrange switching in the BIOS of electronic equipment Order, this switching command, for selecting a mapping table from least two mapping table pre-set, works as electricity When subset starts, automatically perform described switching command, and according to the mapping table selected to storage device Conduct interviews operation.
It is to say, in such a case it is possible to arrange switching command in BIOS, this switching command is sent out After giving storage device, storage device is immediately performed this switching command, then feeds back to BIOS.Thus, After system start-up, storage device conducted interviews operation based on the mapping table after switching.
Therefore, for the technical problem to be solved in the present invention, it is critical only that mutual with electronic equipment, connect After receiving a switching command, detect described first physical storage areas identical with the second physical storage areas Data in part a, it is thus achieved that testing result.When described testing result indicates described data to be critical data Time (such as system data), by this switching command record in this storage device.When described testing result When to indicate described data be non-critical data, directly described history mapping table is set to currently used reflecting Firing table so that described electronic equipment can be based on described history mapping table to described second physical storage areas Access operation.
It is to say, when the second physical storage areas to be switched relates to the first currently used physical store During critical data (such as system data) in region, need this switching command asynchronous execution, the most just Be say after restarting or be powered back up after perform again.If being not related to critical data, then can be direct Switch over.
By way of example, it will be assumed that user is mounted with operating system A1 in the very first time, corresponding to the first thing Reason memory area B1, when user uses operating system A1, uses the first mapping table to storage device B1 region conducts interviews.
Assuming that user is mounted with operating system A2 in the second time, corresponding to the second physical storage areas B2, when user uses operating system A2, uses the second mapping table to carry out the B2 region of storage device Access.
When user is when using operating system A1, and user can send switching command by operating system, The instruction of this switching command is switched to operating system A2.In the present case, need first to detect the second thing Whether reason memory area B2 relates to the critical data of operating system A1 in the first physical storage areas B1, And indicate this switching to relate to the key of operating system A1 of the first physical storage areas B1 in testing result During data, determine that this switching command is not immediately performed, but by this switching command record in storage device, And perform according to trigger command when restarting or be powered back up.
It is of course also possible to do not carry out above detection, but directly by this switching command record in storage device In, and perform according to trigger command when restarting or be powered back up.
According to the control method of the present invention, switching command can be performed asynchronously, thus avoid when switching refers to Order relates to the collapse causing operating system during the critical data of operating system, for the data of digital storage equipment Use and a kind of convenient, flexible control method is provided.
Described above is control method according to embodiments of the present invention, describe according to this below with reference to Fig. 2 The control device of bright embodiment.
Control device according to embodiments of the present invention is applied to the mapping of logic-based address and physical address and carries For accessing in the storage device serviced, and this control device performs controlling party according to embodiments of the present invention Method.
Described control device 200 includes:
Acquiring unit 201, is configured to mutual with electronic equipment, receives a switching command, and described switching refers to Order instruction switches to a history mapping table pre-saved from currently used mapping table, described currently used Mapping table have recorded logical address and the physical address of the first physical storage areas in described storage device Between mapping relations, and the second physics that described history mapping table have recorded in described storage device deposits Mapping relations between logical address and the physical address in storage area territory;
Record unit 202, is configured to this switching command record in this storage device;
Performance element 203, is configured to when receiving a triggering command, performs described switching command;With And
Switch unit 204, is configured to according to described switching command, is set to described history mapping table work as The mapping table of front use so that described electronic equipment can be based on described history mapping table to described second thing Reason storage area. access operation.
Preferably, described triggering command receive from the BIOS of electronic equipment or receive from external device (ED), Or receive from network equipment.
Preferably, described control device 200 also includes:
Detector unit 205, is configured to when receiving described triggering command, detects in this storage device and is No there is described switching command, it is thus achieved that a testing result;
Control unit 206, if being configured to the instruction of described testing result to there is described switching command, then certainly The described switching command of dynamic execution, and described history mapping table is set to currently used mapping table so that Described electronic equipment can be based on described history mapping table to described second physical storage area domain browsing operation; And if the instruction of described testing result does not exist described switching command, the most described electronic equipment is based on described Currently used mapping table is to described first physical storage area domain browsing operation.
Preferably, described acquiring unit 201 is additionally configured to mutual with electronic equipment, obtains this and pre-saves History mapping table.
Preferably, described acquiring unit 201 is additionally configured to: receives instruction first from described electronic equipment and reflects First instruction of firing table;At least two prestored from described storage device is instructed according to described first Mapping table selects described first mapping table as described history mapping table.
Preferably, described acquiring unit 201 is additionally configured to: receiving from described electronic equipment Sending, to described electronic equipment, the record preserved in described storage device after two instructions has prestore to own The list of mapping table so that electronic equipment can select described first mapping table based on described list.
Preferably, arranging the second switching command in the BIOS of described electronic equipment, this second switching refers to Order is configured to from least two mapping table pre-set select a mapping table;When electronic equipment starts Time, automatically perform described second switching command, and according to the mapping table selected, storage device is visited Ask operation.
Preferably, wherein, described control device also includes:
Mutual with electronic equipment, after receiving a switching command, detect described first physical storage areas With the data in the same section of the second physical storage areas, it is thus achieved that a testing result;
When described testing result indicates described data to be critical data, this switching command record is deposited at this In storage equipment;
When described testing result indicates described data to be non-critical data, directly by described history mapping table It is set to currently used mapping table so that described electronic equipment can be based on described history mapping table to institute State the second physical storage area domain browsing operation.
Control device according to the present invention, can perform switching command asynchronously, thus avoid when switching refers to Order relates to the collapse causing operating system during the critical data of operating system, for the data of digital storage equipment Use and a kind of convenient, flexible control method is provided.
Then, according to Fig. 3, storage device according to embodiments of the present invention is described.
Storage device 300 according to embodiments of the present invention is configured to reflecting of logical address and physical address Penetrating offer and access service, described storage device 300 such as includes above-mentioned control device.Specifically, this is deposited Storage equipment 300 may include that
Acquiring unit 301, is configured to mutual with electronic equipment, receives a switching command, and described switching refers to Order instruction switches to a history mapping table pre-saved from currently used mapping table, described currently used Mapping table have recorded logical address and the physics of the first physical storage areas in described storage device 300 Mapping relations between address, and described history mapping table have recorded in described storage device 300 Mapping relations between logical address and the physical address of two physical storage areas;
Record unit 302, is configured to this switching command record in this storage device 300;
Performance element 303, is configured to when receiving a triggering command, performs described switching command;With And
Switch unit 304, is configured to according to described switching command, is set to described history mapping table work as The mapping table of front use so that described electronic equipment can be based on described history mapping table to described second thing Reason storage area. access operation.
According to the storage device of the present invention, switching command can be performed asynchronously, thus avoid when switching refers to Order relates to the collapse causing operating system during the critical data of operating system, for the data of digital storage equipment Use and a kind of convenient, flexible control method is provided.
Then, according to Fig. 4, electronic equipment according to embodiments of the present invention is described.This electronic equipment includes root According to storage device and other element of the embodiment of the present invention, such as display unit, CPU etc..For It is convenient to describe, the most not shown other element and eliminate the description of other element.
This electronic equipment 400 includes:
Storage device 401, the mapping of its logic-based address and physical address provides the service of access,
Wherein, described storage device 401 includes:
Acquiring unit 402, is configured to mutual with electronic equipment 400, receives a switching command, described in cut Change instruction instruction switch to one to pre-save from currently used mapping table history mapping table, described currently The mapping table used have recorded the first physical storage areas in described storage device 401 logical address and Mapping relations between physical address, and described history mapping table have recorded in described storage device 401 The second physical storage areas logical address and physical address between mapping relations;
Record unit 403, is configured to this switching command record in this storage device 401;
Performance element 404, is configured to when receiving a triggering command, performs described switching command;With And
Switch unit 405, is configured to according to described switching command, is set to described history mapping table work as The mapping table of front use so that described electronic equipment 400 can be based on described history mapping table to described Two physical storage area domain browsing operations.
According to the electronic installation of the present invention, switching command can be performed asynchronously, thus avoid when switching refers to Order relates to the collapse causing operating system during the critical data of operating system, deposits for the numeral in electronic equipment The data of storage equipment use provides a kind of convenient, flexible control method.
Described above is several preferred embodiments of the present invention, it should be noted that in this manual, Term " includes ", " comprising " or its any other variant are intended to comprising of nonexcludability, thus Make to include that the process of a series of key element, method, article or equipment not only include those key elements, and Also include other key elements being not expressly set out, or also include for this process, method, article or The key element that person's equipment is intrinsic.In the case of there is no more restriction, by statement " including ... " The key element limited, it is not excluded that also deposit in including the process of described key element, method, article or equipment In other identical element.
Finally, in addition it is also necessary to explanation, above-mentioned a series of process not only include with order described here by The process that time series performs, and include the place performed parallel or respectively rather than in chronological order Reason.
Through the above description of the embodiments, those skilled in the art is it can be understood that arrive this Bright can add the mode of required hardware platform by software and realize, naturally it is also possible to all be come by hardware Implement.Based on such understanding, technical scheme background technology is contributed whole or Part can embody with the form of software product, and this computer software product can be stored in storage and be situated between In matter, such as ROM/RAM, magnetic disc, CD etc., instruct with so that a computer sets including some Standby (can be personal computer, server, or the network equipment etc.) performs each embodiment of the present invention Or the method described in some part of embodiment.
Above the present invention is described in detail, the specific case principle to the present invention used herein And embodiment is set forth, the method that the explanation of above example is only intended to help to understand the present invention And core concept;Simultaneously for one of ordinary skill in the art, according to the thought of the present invention, All will change in detailed description of the invention and range of application, in sum, this specification content should not It is interpreted as limitation of the present invention.

Claims (18)

1. a control method, provides, for logic-based address and mapping of physical address, the service of access In storage device, described control method includes:
Mutual with electronic equipment, receive a switching command, the instruction of described switching command is reflected from currently used Firing table switches to a history mapping table pre-saved, described currently used mapping table have recorded described in deposit Mapping relations between logical address and the physical address of the first physical storage areas in storage equipment, and Described history mapping table have recorded logical address and the thing of the second physical storage areas in described storage device Mapping relations between reason address;
By this switching command record in this storage device;
When receiving a triggering command, perform described switching command;And
According to described switching command, described history mapping table is set to currently used mapping table so that Described electronic equipment can be based on described history mapping table to described second physical storage area domain browsing operation.
Control method the most according to claim 1, wherein said triggering command is from electronic equipment BIOS receives or receives from external device (ED).
Control method the most according to claim 1, also includes:
When receiving described triggering command, detect and whether this storage device exist described switching command, Obtain a testing result;
If the instruction of described testing result exists described switching command, then automatically perform described switching command, And described history mapping table is set to currently used mapping table so that described electronic equipment can be based on Described history mapping table is to described second physical storage area domain browsing operation;And
If the instruction of described testing result does not exist described switching command, the most described electronic equipment is based on switching Front currently used mapping table is to described first physical storage area domain browsing operation.
Control method the most according to claim 1, wherein according to described switching command, reflects described history Firing table is set to currently used mapping table and includes:
Mutual with electronic equipment, obtain this history mapping table pre-saved.
Control method the most according to claim 4, wherein mutual with electronic equipment, obtain this and pre-save History mapping table also include:
The first instruction of instruction the first mapping table is received from described electronic equipment;
Institute is selected according at least two mapping table that described first instruction prestores from described storage device State the first mapping table as described history mapping table.
Control method the most according to claim 5, wherein mutual with electronic equipment, obtain this in advance The history mapping table preserved also includes:
After the second instruction of described electronic equipment, described storage is sent to described electronic equipment receiving The record preserved in equipment has the list of all mapping tables prestored so that electronic equipment can be based on Described list selects described first mapping table.
Control method the most according to claim 1, also includes:
Second switching command is set in the BIOS of described electronic equipment, this second switching command for from At least two mapping table pre-set selects a mapping table;
When electronic equipment starts, automatically perform described second switching command, and according to the mapping selected Storage device is conducted interviews operation by table.
Control method the most according to claim 1, also includes:
Mutual with electronic equipment, after receiving a switching command, detect described first physical storage areas With the data in the same section of the second physical storage areas, it is thus achieved that a testing result;
When described testing result indicates described data to be critical data, this switching command record is deposited at this In storage equipment;
When described testing result indicates described data to be non-critical data, directly by described history mapping table It is set to currently used mapping table so that described electronic equipment can be based on described history mapping table to institute State the second physical storage area domain browsing operation.
9. control a device, provide, for logic-based address and mapping of physical address, the service of access In storage device, described control device includes:
Acquiring unit, is configured to mutual with electronic equipment, receives a switching command, and described switching command refers to Show the history mapping table switching to pre-save from currently used mapping table, described currently used reflecting Firing table have recorded between logical address and the physical address of the first physical storage areas in described storage device Mapping relations, and described history mapping table have recorded the second physical storage area in described storage device Mapping relations between logical address and the physical address in territory;
Record unit, is configured to this switching command record in this storage device;
Performance element, is configured to when receiving a triggering command, performs described switching command;And
Switch unit, is configured to, according to described switching command, be set to currently make by described history mapping table Mapping table so that described second physics can be deposited by described electronic equipment based on described history mapping table Storage area domain browsing operates.
Controlling device the most as claimed in claim 9, wherein said triggering command is from the BIOS of electronic equipment Receive or receive from external device (ED).
11. control device as claimed in claim 9, also include:
Whether detector unit, is configured to when receiving described triggering command, detect in this storage device and deposit At described switching command, it is thus achieved that a testing result;
Control unit, if being configured to the instruction of described testing result to there is described switching command, holds the most automatically The described switching command of row, and described history mapping table is set to currently used mapping table so that described Electronic equipment can be based on described history mapping table to described second physical storage area domain browsing operation;And If there is not described switching command in the instruction of described testing result, before the most described electronic equipment is based on switching Currently used mapping table is to described first physical storage area domain browsing operation.
12. control devices according to claim 9, wherein said acquiring unit is additionally configured to:
Mutual with electronic equipment, obtain this history mapping table pre-saved.
13. control devices according to claim 12, wherein said acquiring unit is additionally configured to:
The first instruction of instruction the first mapping table is received from described electronic equipment;
Institute is selected according at least two mapping table that described first instruction prestores from described storage device State the first mapping table as described history mapping table.
14. control devices according to claim 13, wherein said acquiring unit is additionally configured to:
After the second instruction of described electronic equipment, described storage is sent to described electronic equipment receiving The record preserved in equipment has the list of all mapping tables prestored so that electronic equipment can be based on Described list selects described first mapping table.
15. control devices according to claim 9, wherein, in the BIOS of described electronic equipment Arranging the second switching command, this second switching command is configured to from least two mapping table pre-set Select a mapping table;
When electronic equipment starts, automatically perform described second switching command, and according to the mapping selected Storage device is conducted interviews operation by table.
16. control devices according to claim 9, also include:
Mutual with electronic equipment, after receiving a switching command, detect described first physical storage areas With the data in the same section of the second physical storage areas, it is thus achieved that a testing result;
When described testing result indicates described data to be critical data, this switching command record is deposited at this In storage equipment;
When described testing result indicates described data to be non-critical data, directly by described history mapping table It is set to currently used mapping table so that described electronic equipment can be based on described history mapping table to institute State the second physical storage area domain browsing operation.
17. 1 kinds of storage devices, the mapping being configured to logical address and physical address provides access clothes Business, described storage device includes:
Acquiring unit, is configured to mutual with electronic equipment, receives a switching command, and described switching command refers to Show the history mapping table switching to pre-save from currently used mapping table, described currently used reflecting Firing table have recorded between logical address and the physical address of the first physical storage areas in described storage device Mapping relations, and described history mapping table have recorded the second physical storage area in described storage device Mapping relations between logical address and the physical address in territory;
Record unit, is configured to this switching command record in this storage device;
Performance element, is configured to when receiving a triggering command, performs described switching command;And
Switch unit, is configured to, according to described switching command, be set to currently make by described history mapping table Mapping table so that described second physics can be deposited by described electronic equipment based on described history mapping table Storage area domain browsing operates.
18. 1 kinds of electronic equipments, including:
Storage device, the mapping of its logic-based address and physical address provides the service of access,
Wherein, described storage device includes:
Acquiring unit, is configured to mutual with electronic equipment, receives a switching command, and described switching command refers to Show the history mapping table switching to pre-save from currently used mapping table, described currently used reflecting Firing table have recorded between logical address and the physical address of the first physical storage areas in described storage device Mapping relations, and described history mapping table have recorded the second physical storage area in described storage device Mapping relations between logical address and the physical address in territory;
Record unit, is configured to this switching command record in this storage device;
Performance element, is configured to when receiving a triggering command, performs described switching command;And
Switch unit, is configured to, according to described switching command, be set to currently make by described history mapping table Mapping table so that described second physics can be deposited by described electronic equipment based on described history mapping table Storage area domain browsing operates.
CN201210055845.1A 2012-03-05 2012-03-05 Control method, control device, storage device and electronic equipment Active CN103294406B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210055845.1A CN103294406B (en) 2012-03-05 2012-03-05 Control method, control device, storage device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210055845.1A CN103294406B (en) 2012-03-05 2012-03-05 Control method, control device, storage device and electronic equipment

Publications (2)

Publication Number Publication Date
CN103294406A CN103294406A (en) 2013-09-11
CN103294406B true CN103294406B (en) 2016-08-17

Family

ID=49095367

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210055845.1A Active CN103294406B (en) 2012-03-05 2012-03-05 Control method, control device, storage device and electronic equipment

Country Status (1)

Country Link
CN (1) CN103294406B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6823027B2 (en) * 2018-09-18 2021-01-27 ファナック株式会社 Numerical control device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7346758B1 (en) * 2005-05-10 2008-03-18 Advanced Micro Devices, Inc. System and method for trace messaging
CN101673581A (en) * 2008-06-13 2010-03-17 三星电子株式会社 Memory system and method of accessing a semiconductor memory device
EP2275930A1 (en) * 1999-01-28 2011-01-19 ATI Technologies ULC Executing programs for a first computer architecture on a computer of a second architecture

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2275930A1 (en) * 1999-01-28 2011-01-19 ATI Technologies ULC Executing programs for a first computer architecture on a computer of a second architecture
US7346758B1 (en) * 2005-05-10 2008-03-18 Advanced Micro Devices, Inc. System and method for trace messaging
CN101673581A (en) * 2008-06-13 2010-03-17 三星电子株式会社 Memory system and method of accessing a semiconductor memory device

Also Published As

Publication number Publication date
CN103294406A (en) 2013-09-11

Similar Documents

Publication Publication Date Title
KR102206364B1 (en) Memory collection method and device
JP4923990B2 (en) Failover method and its computer system.
KR101398935B1 (en) System restore method and apparatus using virtualization
TWI475402B (en) Remote backup system and remote backup method thereof
KR101760778B1 (en) Computer system and method for updating program therein
CN104662552A (en) Secure disk access control
CN107566624B (en) Display method for power consumption and temperature of terminal, terminal and computer readable storage medium
CN102043608A (en) Register state saving and restoring
US8732413B2 (en) Method and system for preloading page using control flow
CN104008345A (en) Method and device for protecting user privacy data of application program
CN104360805A (en) Application icon management method and application icon management device
CN105573637A (en) Operation method and device for touch screen equipment
CN103793256A (en) Method for management of memory cards, and electronic device
CN106155721A (en) The deployment method of application program, the generation method and device of the recommendation page
CN104461372B (en) For controlling method, control device and the electronic equipment of storage device
CN105874428A (en) Technologies for operating system transitions in multiple-operating-system environments
CN102880477A (en) Method for realizing computer start and computer
CN104778081A (en) Method for switching operating system and electronic device
CN103369660A (en) Network-element data synchronization method and network-element device
CN105224402A (en) A kind of multisystem fast switch over method and system
CN103294406B (en) Control method, control device, storage device and electronic equipment
CN116450244A (en) Chip starting method, device, computer equipment and storage medium
CN102207939B (en) Multi-hardware system data processing apparatus and method for deleting duplicated data
CN103019833A (en) Terminal equipment and method for enabling same to support quick switching of operating systems
CN104424115B (en) Recover method, storage device and the electronic equipment of the preset state of electronic 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