CN101408864A - Data protection method for current failure and controller using the same - Google Patents
Data protection method for current failure and controller using the same Download PDFInfo
- Publication number
- CN101408864A CN101408864A CNA2007101629951A CN200710162995A CN101408864A CN 101408864 A CN101408864 A CN 101408864A CN A2007101629951 A CNA2007101629951 A CN A2007101629951A CN 200710162995 A CN200710162995 A CN 200710162995A CN 101408864 A CN101408864 A CN 101408864A
- Authority
- CN
- China
- Prior art keywords
- data
- physical blocks
- update information
- relation
- data update
- 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.)
- Granted
Links
Images
Landscapes
- Techniques For Improving Reliability Of Storages (AREA)
Abstract
The invention provides a data protection method which is suitable for being used in a plurality of physical blocks corresponding to a logic block in a nonvolatile memory. The data protection method comprises the steps as follows: data updating information is recorded in each physical block and is used for identifying data updating relation in the physical block; the updating relation of the physical block is regained according to the data updating information, wherein, the data updating information consists of a plurality of characters with circular relation, and the number of the characters is more than the number of the physical blocks; wherein, the data updating information is recorded in each physical block in sequence according to the updating relation and the circular relation.
Description
Technical field
The present invention relates to a kind of data guard method, and particularly relate to a kind of when being used to cut off the power supply data guard method and use the controller of the method.
Background technology
Digital camera, mobile phone camera and MP3 are very rapid in growth over the years, make the consumer also increase rapidly to the demand of Storage Media, because flash memory (Flash Memory) has that data are non-volatile, power saving, volume is little and the characteristic of no mechanical structure etc., be fit to portable use, the most suitable being used on the portable battery-powered product of this class.Except the portable product built-in storage needs, wait the circumscribed product for mini memory card and carry-on dish, everyone may have a plurality of carry-on dishes and mini memory card simultaneously, so market scale is bigger than those equipment.Therefore, the flash memory industry becomes in the electronic industry quite popular a kind of in recent years.
The management of flash memory generally is to be unit with block (block), if under the situation of a plurality of physical blocks of unity logic block mapping and undesired outage occur in data and write fashionablely, then might cause the incorrect or unsettled phenomenon of data.That is to say that system can't identification raw data physical blocks and new data physical blocks after recovering electric power again.
For addressing the above problem, traditionally can be in a byte of the redundant area of each page of physical blocks tag-related.For example, with 1 logical blocks of 3 physical blocks mappings is example, each can become 0 characteristic by 1 to utilize flash memory, in selected byte with the different mark of the filling of writing mode several times, for example write down when the phase one, write down when FF is changed into 0F and is illustrated in subordinate phase with the FF representative and with 0F change into 00 be illustrated in the phase III in time institute's record.Just, if this represents it is up-to-date data and 0F represents time old data and the oldest data of 00 expression when being labeled as FF.
Yet there is following problems in known technology.When employed storer is that (Multi Level Cell during MLC) with non-(NAND) flash memory, because this type of flash memory can only write once, therefore can't use the above-mentioned method that writes several times to come mark to the multilayer storage unit.That is to say that in the case of MLC and non-flash memory, this mark just can't change once writing the back again.
Based on this, be necessary to develop a kind of data guard method, after outage, to distinguish the more new relation of block effectively again.
Summary of the invention
The invention provides a kind of data guard method that is used for nonvolatile memory, after outage, distinguish new legacy data again effectively.
The invention provides a kind of controller, it can carry out the data guard method that is used for nonvolatile memory, and it can distinguish new legacy data effectively again after outage.
The present invention proposes a kind of data guard method, it is applicable to a plurality of physical blocks of logical blocks institute mapping in the nonvolatile memory, this data guard method comprises: record data lastest imformation in each physical blocks, and Data Update information is in order to the more new relation of data in the identification physical blocks; And the more new relation that rebulids physical blocks according to Data Update information, wherein Data Update information is made up of a plurality of character with recurrence relation, and the number of described character is greater than the number of described physical blocks, and wherein the record data lastest imformation is according to more new relation and recurrence relation are come record in order in each physical blocks.
In one embodiment of this invention, above-mentioned character is a plurality of numerals or a plurality of literal.
In one embodiment of this invention, above-mentioned reconstruction more new relation comprises that the physical blocks of discerning the Data Update information that comprises character late with the character late of untapped character according to recurrence relation is the physical blocks with legacy data, and discerns the more new relation of other physical blocks in order according to recurrence relation.
In one embodiment of this invention, above-mentioned reconstruction more new relation comprises that the physical blocks of discerning the Data Update information that comprises character late with the character late of untapped character according to recurrence relation is the physical blocks with latest data, and discerns the more new relation of other physical blocks in order according to recurrence relation.
In one embodiment of this invention, above-mentioned record data lastest imformation in each physical blocks is the redundant area that Data Update information is recorded in each physical blocks.
In one embodiment of this invention, above-mentioned nonvolatile memory is one page (Program) flash memory once of can only programming.
In one embodiment of this invention, above-mentioned flash memory is SLC (Single Level Cell) or MLC (Multi Level Cell) and non-(NAND) flash memory.
The invention provides a kind of controller, it is applicable to storage device, a plurality of physical blocks of logical blocks mapping in the nonvolatile memory of storage device.Controller comprises non-volatile memory interface, memory buffer, microprocessing unit and memory management module.Non-volatile memory interface is in order to the access nonvolatile memory.Memory buffer is in order to storage data temporarily.Microprocessing unit is in order to control the overall operation of this controller.Memory management module is in order to managing non-volatile memory, wherein memory management module can be carried out data guard method, this data guard method comprises: record data lastest imformation in each physical blocks, and Data Update information is in order to the more new relation of data in the identification physical blocks; And the more new relation that rebulids physical blocks according to Data Update information, wherein Data Update information is made up of a plurality of character with recurrence relation, and the number of described character is greater than the number of described physical blocks, and wherein the record data lastest imformation is according to more new relation and recurrence relation are come record in order in each physical blocks.
In one embodiment of this invention, above-mentioned character is a plurality of numerals or a plurality of literal.
In one embodiment of this invention; rebuild in the above-mentioned data guard method more that new relation comprises that the physical blocks of discerning the Data Update information that comprises character late with the character late of untapped character according to recurrence relation is the physical blocks with legacy data, and discern the more new relation of other physical blocks according to recurrence relation in order.
In one embodiment of this invention; rebuild in the above-mentioned data guard method more that new relation comprises that the physical blocks of discerning the Data Update information that comprises character late with the character late of untapped character according to recurrence relation is the physical blocks with latest data, and discern the more new relation of other physical blocks according to recurrence relation in order.
In one embodiment of this invention, in the above-mentioned data guard method in each physical blocks the record data lastest imformation be the redundant area that Data Update information is recorded in each physical blocks.
In one embodiment of this invention, above-mentioned nonvolatile memory is one page (Program) flash memory once of can only programming.
In one embodiment of this invention, above-mentioned flash memory is SLC (Single Level Cell) or MLC (Multi Level Cell) and non-(NAND) flash memory.
In one embodiment of this invention, above-mentioned storage device is flash memory Storage Media, USB dish, flash memory card or solid state hard disc with oneself.
The invention provides a kind of data guard method, it is applicable to a plurality of physical blocks of logical blocks institute mapping in the nonvolatile memory, data guard method comprises: record data lastest imformation in each physical blocks, and Data Update information is in order to the more new relation of data in the identification physical blocks; And according to the more new relation of Data Update information acquisition physical blocks, record data lastest imformation record simultaneously when physical blocks writes data in physical blocks wherein.
In one embodiment of this invention, the above-mentioned Data Update information in physical blocks is only to write once.
In one embodiment of this invention, the above-mentioned Data Update information in physical blocks is a plurality of circulation characters.
In one embodiment of this invention, the number of above-mentioned circulation character is between 3-5.
The invention provides a kind of controller, it is applicable to storage device, a plurality of physical blocks of logical blocks mapping in the nonvolatile memory of storage device.Controller comprises non-volatile memory interface memory buffer, microprocessing unit and memory management module.Non-volatile memory interface is in order to the access nonvolatile memory.Memory buffer is in order to storage data temporarily.Microprocessing unit is in order to control the overall operation of this controller.Memory management module is in order to managing non-volatile memory, wherein memory management module can be carried out data guard method, this data guard method comprises: record data lastest imformation in each physical blocks, and Data Update information is in order to the more new relation of data in the identification physical blocks; And according to the more new relation of Data Update information acquisition physical blocks, wherein the record data lastest imformation is a record simultaneously when physical blocks writes data in physical blocks, and wherein the Data Update information in physical blocks is only to write once.
In one embodiment of this invention, above-mentioned storage device is flash memory Storage Media, USB dish, flash memory card or solid state hard disc with oneself.
The present invention proposes a kind of data guard method, and the more new relation that it can write down the Data Update information of one-to-many block effectively and obtain block after undesired outage from Data Update information avoids data to lose after undesired outage thus.
For above-mentioned feature and advantage of the present invention can be become apparent, preferred embodiment cited below particularly, and be described with reference to the accompanying drawings as follows.
Description of drawings
Figure 1A illustrates the main frame that uses the non-volatile memory storage device according to the embodiment of the invention.
Figure 1B shows the detailed block diagram of the device of non-volatile memory storage shown in Figure 1A.
Fig. 1 C is the calcspar that illustrates controller according to another embodiment of the present invention.
Fig. 2 A and 2B are the detailed block diagram that illustrates nonvolatile memory and running thereof according to the embodiment of the invention.
Fig. 3 is the detailed block diagram that illustrates the redundant area R of page or leaf among Figure 1B according to the embodiment of the invention.
Fig. 4 A is the synoptic diagram of Data Update information when illustrating a logical blocks to three physical blocks according to the embodiment of the invention.
Fig. 4 B is the synoptic diagram that illustrates another Data Update information according to Fig. 4 A.
Fig. 5 is the process flow diagram that illustrates data guard method according to first embodiment of the invention.
Fig. 6 is the process flow diagram that illustrates data guard method according to second embodiment of the invention.
Fig. 7 is the applicable schematic representation of apparatus of average abrasion method that illustrates the embodiment of the invention.
The reference numeral explanation
100: main frame
102: microprocessor
104: random access memory
106: input/output device
108: system bus
110: data transmission interface
120: the non-volatile memory storage device
122,122 ': controller
122a: memory management module
122b: non-volatile memory interface
122c: host computer transmission interface
122d: memory buffer
122e: programmable memory
122f: error correction module
122g: power management module
122h: microprocessing unit
124: nonvolatile memory
124-0,124-1,124-2,124-N: block
202: system region
204: the data field
206: the spare area
208: replace the district
210: instantaneous district
M, C, T: block
302: the addressing mark
304: upgrade relation mark
306: the block status indication
308: other mark
310: the byte of stocking system information
320: the byte that stores error-correcting code (error correcting code)
401: logical blocks
402,403,404: physical blocks
S501, S503, S505, S507, S509: step
S601, S603, S605, S607, S609: step
The 702:USB flash disks
704: digital still camera
The 704a:SD card
The 704b:MMC card
The 704c:CF card
704d: memory stick
706: solid state hard disc
Embodiment
Generally speaking nonvolatile memory storage system comprises nonvolatile memory and controller (control chip).Usually nonvolatile memory storage system can be used with host computer system, so that host computer system can write to data nonvolatile memory storage system or reading of data from nonvolatile memory storage system.In addition, nonvolatile memory storage system also being arranged is to comprise embedded non-volatile memory and can be executed on the host computer system with substantially as the software of the controller of this embedded flash storer.
Figure 1A illustrates the main frame that uses the non-volatile memory storage device according to the embodiment of the invention.
Please refer to Figure 1A, main frame 100 generally comprise microprocessor 102, random access memory (randomaccess memory, RAM) 104, I/O (input/output, I/O) device 106, system bus 108 and data transmission interface 110.It must be appreciated that main frame 100 can also comprise other assembly, for example display equipment or network equipment etc.
Non-volatile memory storage device 120 is connected with other electrical component of main frame 100 by data transmission interface 110 in embodiments of the present invention.Data can be write to non-volatile memory storage device 120 or reading of data from non-volatile memory storage device 120 by microprocessor 102, random access memory 104 with the processing of input/output device 106.Non-volatile memory storage device 120 comprise carry-on dish, storage card or solid state hard disc (Solid State Drive, SSD).
Figure 1B shows the detailed block diagram of the device of non-volatile memory storage shown in Figure 1A.
Please refer to Figure 1B, non-volatile memory storage device 120 generally comprises controller 122 and nonvolatile memory 124.
In another embodiment of the present invention, please refer to Fig. 1 C, controller 122 ' also comprises host computer transmission interface 122c, programmable memory 122e, error correction module 122f and power management module 122g.
Host computer transmission interface 122c in order to main frame 100 communications, host computer transmission interface 122c can be USB interface, IEEE 1394 interfaces, SATA interface, PCI Express interface, MS interface, MMC interface, SD card, CF card or ide interface.
Be sector (sector) size corresponding to disc driver, generally speaking, user data field D is generally 512 bytes, and redundant area R is generally 16 bytes.Just, one page is a sector.Yet, also can form one page in a plurality of sectors, for example one page comprises 4 sectors.
Generally speaking, block can be formed for example 64 pages, 128 pages, 256 pages etc. by the page or leaf of arbitrary number.Block 124-0 to 124-N also can be grouped into a plurality of zones (zone) usually, and coming diode-capacitor storage with the zone is to operate independently of one another with the parallel degree of increase operation execution and the complexity of streamlining management in a way.
Below will be and be described with reference to the accompanying drawings the running of nonvolatile memory according to the present invention.It must be appreciated that using speech such as " extraction ", " moving ", " exchange " to operate the flash memory block in the following description is in logic notion.That is to say that the physical location of flash memory block is not changed, but in logic the flash memory block is operated.
Fig. 2 A and 2B are the detailed block diagram that illustrates nonvolatile memory 124 and running thereof according to the embodiment of the invention.
Please refer to Fig. 2 A, in embodiments of the present invention, for (promptly write and the wipe) nonvolatile memory 124 of programming efficiently, the block 124-1 to 124-N of nonvolatile memory 124 can logically be grouped into a system region 202, a data field 204 and a spare area 206.In general, the block that belongs to data field 204 in the nonvolatile memory 124 can account for more than 90%, remaining system region 202 and the spare area 206 of being only.
Block in the system region 202 is in order to the register system data, and system data for example is about the number of pages of the number of regions of nonvolatile memory 124, block counts that each is regional, each block, logical physical mapping table etc.
Block in the data field 204 is in order to store user's data, in general is exactly the operated pairing block of logical block addresses of main frame 100.
Therefore block in the spare area 206 is in order to the block in the replacement data district 204, and the block in spare area 206 be sky or spendable block, i.e. no record data or be labeled as invalid data useless.Specifically, because if will be when writing Data Position and write data once more, the operation that execution is earlier wiped.Yet the flash memory unit of writing is a page or leaf as previously mentioned, and erase unit is a block.A unit of wiping is greater than the unit that writes, and this expression be if will carry out block erase operation, must be earlier active page in will erase blocks just can carry out after being copied to other block.Therefore, when writing new data among the block M that will in data field 204, write Data Position, generally can in spare area 206, extract a block C, after then the valid data among the block M being copied to block C and new data being write block C, move to the spare area 206 after block M wiped and simultaneously block C is moved to the data field 204.It must be appreciated that moving to the spare area 206 after block M is wiped, simultaneously block C to be moved to the data field 204 be in logic block M to be associated with spare area 206 and block C is associated with data field 204.Wherein those skilled in the art's logical relation that all can understand block in the data field 204 can be safeguarded by logical physical mapping table.
In embodiments of the present invention, in order to use nonvolatile memory 124 more efficiently, block 124-1 to 124-N logically also is divided into one and replaces district 208 and time zone 210 at a flash.
Please refer to Fig. 2 B, replacing district 208 is in order to temporarily to deposit the block of the block of preparing replacement data district 204.In more detail, when the block C of above-mentioned spare area 206 is extracted the block M that replaces data field 204, new data can be write to block C in embodiments of the present invention, but can at once the valid data among the block M not moved to block C and erase blocks M.Therefore this is because it is invalid that the valid data among the block M might become in next operation, at once the valid data among the block M moved to physical blocks C and can be caused meaningless moving.In embodiments of the present invention, the block C that can will write new data temporarily is associated as and replaces the district, and in the mapping of logical block addresses and physical blocks address, can write down the situation that a plurality of physical blocks address corresponds to a logical block addresses, just the content integration of block M and block C gets up to be only the content of institute's mapping logical blocks, promotes the service efficiency of block thus.The relation of these mother and child blocks (block M and block C) can be decided according to the size of memory buffer 122d in the controller 122, is to do in fact with five groups in embodiments of the present invention.
The function in instantaneous district 210 is similar with replacement district 208.As mentioned above, be to use MLC NAND flash memory in embodiments of the present invention.This MLC NAND flash memory is the multilayer storage unit, can comprise 4 sectors in its 1 page, the sector of 4 512 bytes is promptly arranged, totally 2048 bytes in 1 page.As mentioned above, flash memory is to be unit with the page or leaf writing fashionable, and the waste of resource can be caused in 4 sectors of therefore at every turn must programming under the situation of using MLC NAND flash memory therefore when writing the small amount of data of discontented one page.In embodiments of the present invention, instantaneous district 210 is in order to temporarily to deposit this type of small amount of data.Specifically, when the data that will write the block C that replaces district 208 are the small amount of data of discontented one page, can from spare area 206, extract a block T as mentioned above, then this small amount of data be write to block T and block T is associated as instantaneous district 210.Afterwards, when the follow-up data volume that writes enough writes one page, more described data are write to block C, and then block T is wiped and from instantaneous district 210, move to the spare area 206.
As mentioned above, for fear of frequent erase blocks, can use block C and block T to carry out the renewal of the data of block M.Yet system is in instantaneous time that has block M, C and T during non-volatile memory storage device 120 running, if when undesired outage takes place, the more new relation between block M, C and the T will be lost.Specifically, during 120 runnings of non-volatile memory storage device, the instantaneous relation of block M, C and T can be stored among the memory buffer 122d of controller 122, and when the 120 undesired outages of non-volatile memory storage device, the data among the memory buffer 122d will be lost.Therefore, after non-volatile memory storage device 120 recovers electric power again, though controller 122 can obtain the information of block M, C and the same logical blocks of T mapping from the logical physical mapping table that rebulids, can't distinguish the more new relation of block M, C and T.
In order to solve the above problems, the present invention in the redundant area of the page or leaf of block mark about this block information of new relation more.Fig. 3 is the detailed block diagram that illustrates the redundant area R of page or leaf among Figure 1B according to the embodiment of the invention.
As mentioned above, redundant area R is generally 16 bytes, wherein is divided into 6 bytes 310 of stocking system information and 10 bytes 320 of storage error-correcting code (error correcting code).And the byte 310 of stocking system information comprises addressing mark 302, upgrades relation mark 304, block status indication 306 and other mark 308.
Addressing mark 302 comprises 3 bytes, and wherein 2 bytes are in order to the zone (zone) under this block of mark, and 1 byte is in order to the logical blocks of this block mapping of mark.
According to the present invention, when having instantaneous relation of block M, C and T in the system, memory management module 122a can be in upgrading relation mark 304 the record data lastest imformation.Data Update information is made up of a plurality of character with a recurrence relation, and the number of described character is the number greater than the block of this instantaneous relation of composition, that is to say, if when forming the block of this instantaneous relation and having n, represent that then the character of Data Update information must have n+1 at least.In addition, the record data lastest imformation is to come record in order according to the more new relation of block and the recurrence relation of character in each physical blocks.
Fig. 4 A is the synoptic diagram of Data Update information when illustrating a logical blocks to three physical blocks according to the embodiment of the invention.
Please refer to Fig. 4 A, logical blocks 401 mapping physical blocks 402,403 and 404.Wherein physical blocks 402 has the oldest data, and physical blocks 403 has time old data, and physical blocks 404 has up-to-date data.
Be with the character of digital 0-3 that circulate in Fig. 4 A as expression Data Update information.The renewal relation mark of supposing physical blocks 402 is 0 o'clock, and the more new relation of physical blocks 403 can be marked as 1 and when the physical blocks 404 that renewal is arranged again produced, the more new relation of physical blocks 404 can be marked as 2 when newer physical blocks produces.Controller 122 can be 3 according to the untapped character of Data Update information Recognition after the 120 undesired outages of non-volatile memory storage device, and the character late of character 3 is 0 in the circulation of 0-3, therefore the block that has legacy data is a physical blocks 402, and circulation identification physical blocks 403 has time old data according to this, and identification physical blocks 404 has up-to-date data.
Fig. 4 B is the synoptic diagram that illustrates another Data Update information according to Fig. 4 A.
Please refer to Fig. 4 B, is with the character of digital 0-3 as expression Data Update information that circulate equally.The renewal relation mark of supposing physical blocks 402 is 2 o'clock, and the more new relation of physical blocks 403 can be marked as 3 and when the physical blocks 404 that renewal is arranged again produced, the more new relation of physical blocks 404 can be marked as 0 when newer physical blocks produces.Controller 122 can be 1 according to the untapped character of Data Update information Recognition after the 120 undesired outages of non-volatile memory storage device, and the character late of character 1 is 2 in the circulation of 0-3, therefore the block that has legacy data is a physical blocks 402, and circulation identification physical blocks 403 has time old data according to this, and identification physical blocks 404 has up-to-date data.
Present embodiment be with numeral as Data Update information, yet, the invention is not restricted to this, other symbol also can be applicable to the present invention, for example makes the literal (for example A, B, C, D...) of apparatus recurrence relation.
Be as the block that indicates the legacy data of tool in the present embodiment with the character late that do not use character in the Data Update information, yet, be not use in Data Update information the character late of character in this another embodiment as the block that indicates the tool latest data.
Please with reference to figure 3, block status indication 306 comprises 1 byte, and whether it is normal blocks or bad block in order to this block of mark.
Present embodiment is to dispose with the redundant area of 16 bytes and byte thereof to explain the present invention.But must be appreciated that, the invention is not restricted to this, the redundant area of other byte number or other byte configuration mode are also applicable to the present invention.
Fig. 5 is the process flow diagram that illustrates data guard method according to first embodiment of the invention, and it is that memory management module 122a by controller 122 carries out, to obtain the relation between above-mentioned instantaneous block M, C and the T again after undesired outage.
Please refer to Fig. 5, data guard method is divided into two parts, and step S501 can write down a Data Update information in each physical blocks that one-to-many (i.e. 1 a plurality of physical blocks of logical blocks mapping) takes place in (a) of Fig. 5.The composition of Data Update information and mode described in detail as before, do not repeat them here.
In (b) of Fig. 5, after undesired outage takes place, can whether there be a plurality of physical blocks (step S503) that to discern new and old relation in the decision logic physics mapping table.If in step S503, judge have can't identification physical blocks the time, then in step S505, from the redundant area of the page or leaf of described physical blocks, read the renewal relation mark.Afterwards, in step S507, judge block with the oldest (or up-to-date) data according to the character of data streams read lastest imformation from upgrade relation mark.Judge the oldest (or up-to-date) data block mode with describe in conjunction with Fig. 4 A and Fig. 4 B as before, do not repeat them here.Afterwards, in step S509, discern the more new relation of the physical blocks that other can't identification according to the recurrence relation of Data Update information.
Fig. 6 is the process flow diagram that illustrates data guard method according to second embodiment of the invention.The controller hardware structure of carrying out the data guard method of second embodiment is to be same as first embodiment, in this no longer repeat specification.
Please refer to Fig. 6; data guard method also is to be divided into two parts, and step S601 can write data in physical blocks and write down a Data Update information in simultaneously to each physical blocks that one-to-many (i.e. 1 a plurality of physical blocks of logical blocks mapping) takes place in (a) of Fig. 6.The composition of Data Update information and mode described in detail as before, do not repeat them here.
In another embodiment of the present invention, the Data Update information in the physical blocks is only to write once.That is to say that in one page can only be programmed the case of (Program) flash memory once, data to write once, could be programmed after must wiping earlier only again in the time must programming again.
In (b) of Fig. 6, after undesired outage takes place, can whether there be a plurality of physical blocks (step S603) that to discern new and old relation in the decision logic physics mapping table.If in step S603, judge have can't identification physical blocks the time, then in step S605, from the redundant area of the page or leaf of described physical blocks, read the renewal relation mark.Afterwards, judge the block with the oldest (or up-to-date) data according to a plurality of circulation characters of data streams read lastest imformation from upgrade relation mark in step S607, for example, the number of circulation character is between 3-5.The mode of judging the block of the oldest (or up-to-date) data cooperated Fig. 4 A and Fig. 4 B to describe as before, do not repeat them here.Afterwards, in step S609 according to the circulation character recognition of Data Update information other can't identification the more new relation of physical blocks.
Be to be applicable to nonvolatile memory according to data guard method proposed by the invention, therefore data guard method proposed by the invention can be used various with the device of nonvolatile memory as Storage Media.USB flash disks 702 for example shown in Figure 7, digital camera (video camera) 704 employed SD card 704a, mmc card 704b, CF card 704c and memory stick (memory stick) 704d and solid state hard disc 706 etc.
In sum, the data guard method that is used for nonvolatile memory proposed by the invention can obtain the more new relation of one-to-many block effectively after undesired outage.Thus, avoid the loss of undesired outage back data.
Though the present invention discloses as above with preferred embodiment; right its is not in order to qualification the present invention, those skilled in the art, under the premise without departing from the spirit and scope of the present invention; when can doing some changes and modification, so protection scope of the present invention should be as the criterion with claim of the present invention.
Claims (21)
1. data guard method, it is applicable to a plurality of physical blocks of logical blocks institute mapping in the nonvolatile memory, this data guard method comprises:
Record one Data Update information in each described physical blocks, this Data Update information is in order to discern the more new relation of data in the described physical blocks; And
This of the described physical blocks of the described Data Update information acquisition of foundation be new relation more,
Wherein said Data Update information is made up of a plurality of character with a recurrence relation, and the number of described character is greater than the number of described physical blocks,
Wherein this Data Update information of record is that more new relation and this recurrence relation are come record in order according to this in each described physical blocks.
2. data guard method as claimed in claim 1, wherein said character are a plurality of numerals or a plurality of literal.
3. data guard method as claimed in claim 1; wherein obtain this more new relation comprise that the physical blocks of discerning this Data Update information that comprises this character late with the character late of untapped described character according to this recurrence relation is the physical blocks with legacy data, and this new relation more of discerning other described physical blocks in order according to this recurrence relation.
4. data guard method as claimed in claim 1; wherein obtain this more new relation comprise that the physical blocks of discerning this Data Update information that comprises this character late with the character late of untapped described character according to this recurrence relation is the physical blocks with latest data, and this new relation more of discerning other described physical blocks in order according to this recurrence relation.
5. data guard method as claimed in claim 1, wherein this Data Update information of record is a redundant area that this Data Update information is recorded in each described physical blocks in each described physical blocks.
6. data guard method as claimed in claim 1, wherein this nonvolatile memory is can only programme once a flash memory of one page.
7. data guard method as claimed in claim 6, wherein this flash memory is a SLC or MLC and non-flash memory.
8. controller, it is applicable to a storage device, a plurality of physical blocks of a logical blocks mapping in the nonvolatile memory of this storage device, this controller comprises:
One non-volatile memory interface is in order to this nonvolatile memory of access;
One memory buffer is in order to storage data temporarily;
One microprocessing unit is in order to control the overall operation of this controller; And
One memory management module, in order to manage this nonvolatile memory, wherein this memory management module can be carried out a data guard method, and this data guard method comprises:
Record one Data Update information in each described physical blocks, this Data Update information is in order to discern the more new relation of data in the described physical blocks; And
This of the described physical blocks of the described Data Update information acquisition of foundation be new relation more,
Wherein said Data Update information is made up of a plurality of character with a recurrence relation, and the number of described character is greater than the number of described physical blocks,
Wherein this Data Update information of record is that more new relation and this recurrence relation are come record in order according to this in each described physical blocks.
9. controller as claimed in claim 8, wherein said character are a plurality of numerals or a plurality of literal.
10. controller as claimed in claim 8; wherein in this data guard method, obtain this more new relation comprise that the physical blocks of discerning this Data Update information that comprises this character late with the character late of untapped described character according to this recurrence relation is the physical blocks with legacy data, and this new relation more of discerning other described physical blocks in order according to this recurrence relation.
11. controller as claimed in claim 8; wherein in this data guard method, obtain this more new relation comprise that the physical blocks of discerning this Data Update information that comprises this character late with the character late of untapped described character according to this recurrence relation is the physical blocks with latest data, and this new relation more of discerning other described physical blocks in order according to this recurrence relation.
12. controller as claimed in claim 8, wherein writing down this Data Update information in each described physical blocks in this data guard method is a redundant area that this Data Update information is recorded in each described physical blocks.
13. controller as claimed in claim 8, wherein this nonvolatile memory is can only programme once a flash memory of one page.
14. controller as claimed in claim 13, wherein this flash memory is a SLC or MLC and non-flash memory.
15. controller as claimed in claim 8, wherein this storage device be that a flash memory Storage Media, a USB coil with oneself, a flash memory card or a solid state hard disc.
16. a data guard method, it is applicable to a plurality of physical blocks of logical blocks institute mapping in the nonvolatile memory, and this data guard method comprises:
Record one Data Update information in each described physical blocks, this Data Update information is in order to discern the more new relation of data in the described physical blocks; And
This of the described physical blocks of the described Data Update information acquisition of foundation be new relation more,
Wherein this Data Update information of record is record simultaneously when this physical blocks writes data in described physical blocks.
17. data guard method as claimed in claim 16, wherein the Data Update information in described physical blocks is only to write once.
18. data guard method as claimed in claim 17, the described Data Update information in the wherein said physical blocks is a plurality of circulation characters.
19. data guard method as claimed in claim 18, the number of wherein said circulation character is between 3-5.
20. a controller, it is applicable to a storage device, a plurality of physical blocks of a logical blocks mapping in the nonvolatile memory of this storage device, and this controller comprises:
One non-volatile memory interface is in order to this nonvolatile memory of access;
One memory buffer is in order to storage data temporarily;
One microprocessing unit is in order to control the overall operation of this controller; And
One memory management module, in order to manage this nonvolatile memory, wherein this memory management module can be carried out a data guard method, and this data guard method comprises:
Record one Data Update information in each described physical blocks, this Data Update information is in order to discern the more new relation of data in the described physical blocks; And
This of the described physical blocks of the described Data Update information acquisition of foundation be new relation more,
Wherein this Data Update information of record is record simultaneously when this physical blocks writes data in described physical blocks,
Data Update information in the wherein said physical blocks is only to write once.
21. controller as claimed in claim 20, wherein this storage device be that a flash memory Storage Media, a USB coil with oneself, a flash memory card or a solid state hard disc.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2007101629951A CN101408864B (en) | 2007-10-09 | 2007-10-09 | Data protection method for current failure and controller using the same |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2007101629951A CN101408864B (en) | 2007-10-09 | 2007-10-09 | Data protection method for current failure and controller using the same |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101408864A true CN101408864A (en) | 2009-04-15 |
CN101408864B CN101408864B (en) | 2011-08-24 |
Family
ID=40571884
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2007101629951A Active CN101408864B (en) | 2007-10-09 | 2007-10-09 | Data protection method for current failure and controller using the same |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101408864B (en) |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102110121A (en) * | 2009-12-24 | 2011-06-29 | 阿里巴巴集团控股有限公司 | Method and system for processing data |
CN102375779A (en) * | 2010-08-16 | 2012-03-14 | 深圳市朗科科技股份有限公司 | Data processing method and data processing module |
CN103678162A (en) * | 2012-09-12 | 2014-03-26 | 群联电子股份有限公司 | System data storage method, memorizer controller and memorizer storing device |
CN103699344A (en) * | 2013-11-05 | 2014-04-02 | 威盛电子股份有限公司 | Nonvolatile memory device and method of operating the same |
CN105630704A (en) * | 2015-06-10 | 2016-06-01 | 上海磁宇信息科技有限公司 | Storage device and read-write method applying block-based logic physical address comparison table |
CN105630404A (en) * | 2015-04-02 | 2016-06-01 | 上海磁宇信息科技有限公司 | Solid-state drive using MRAM and read-write method |
CN107092563A (en) * | 2017-04-20 | 2017-08-25 | 紫光华山信息技术有限公司 | A kind of rubbish recovering method and device |
CN105608016B (en) * | 2015-08-05 | 2018-11-23 | 上海磁宇信息科技有限公司 | Solid state hard disk of the DRAM in conjunction with MRAM and the storage card using MRAM |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100577380B1 (en) * | 1999-09-29 | 2006-05-09 | 삼성전자주식회사 | A flash-memory and a it's controling method |
CN100377119C (en) * | 2003-06-20 | 2008-03-26 | 深圳市朗科科技有限公司 | Protection method for data in flash memory media |
-
2007
- 2007-10-09 CN CN2007101629951A patent/CN101408864B/en active Active
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102110121A (en) * | 2009-12-24 | 2011-06-29 | 阿里巴巴集团控股有限公司 | Method and system for processing data |
CN102375779A (en) * | 2010-08-16 | 2012-03-14 | 深圳市朗科科技股份有限公司 | Data processing method and data processing module |
CN102375779B (en) * | 2010-08-16 | 2015-08-19 | 深圳市朗科科技股份有限公司 | A kind of data processing method and data processing module |
CN103678162A (en) * | 2012-09-12 | 2014-03-26 | 群联电子股份有限公司 | System data storage method, memorizer controller and memorizer storing device |
CN103699344A (en) * | 2013-11-05 | 2014-04-02 | 威盛电子股份有限公司 | Nonvolatile memory device and method of operating the same |
CN103699344B (en) * | 2013-11-05 | 2016-08-17 | 威盛电子股份有限公司 | Nonvolatile memory device and method of operating the same |
CN105630404A (en) * | 2015-04-02 | 2016-06-01 | 上海磁宇信息科技有限公司 | Solid-state drive using MRAM and read-write method |
CN105630704A (en) * | 2015-06-10 | 2016-06-01 | 上海磁宇信息科技有限公司 | Storage device and read-write method applying block-based logic physical address comparison table |
CN105608016B (en) * | 2015-08-05 | 2018-11-23 | 上海磁宇信息科技有限公司 | Solid state hard disk of the DRAM in conjunction with MRAM and the storage card using MRAM |
CN107092563A (en) * | 2017-04-20 | 2017-08-25 | 紫光华山信息技术有限公司 | A kind of rubbish recovering method and device |
CN107092563B (en) * | 2017-04-20 | 2021-02-26 | 新华三信息技术有限公司 | Garbage recovery method and device |
Also Published As
Publication number | Publication date |
---|---|
CN101408864B (en) | 2011-08-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102135942B (en) | Method for realizing wear-leveling in storage equipment as well as the storage equipment | |
CN101408864B (en) | Data protection method for current failure and controller using the same | |
CN101494085B (en) | Prevent nonvolatile memory from method and the controller thereof of interference occurring to read | |
CN102157202B (en) | Method and controller for preventing nonvolatile memory from occurring read interference | |
CN101634967B (en) | Block management method for flash memory, storage system and controller | |
CN101414282B (en) | Average abrasion method and controller using the same | |
CN101625897B (en) | Data write-in method, storage system and controller used for quick flash memory | |
CN101661431B (en) | Block management method for flash memory, flash storage system and controller | |
CN101499315B (en) | Average abrasion method of flash memory and its controller | |
CN101425338B (en) | Writing method for nonvolatile memory and controller using the method | |
CN101944386A (en) | Control circuit and storage system and method for identifying error data in flash memory | |
CN101419834A (en) | Average abrasion method and controller using the method | |
CN102890655A (en) | Memory storage device, memory controller and valid data recognition method thereof | |
CN101527169A (en) | Data write-in method for flash memory and controller thereof | |
CN101630233A (en) | Data access method used for flash memory, storage system and controller | |
CN103136111A (en) | Data writing method, memorizer controller and memorizer storage device | |
CN102968385B (en) | Method for writing data, Memory Controller and storage device | |
CN102567221B (en) | Data management method, memory controller and memory storage device | |
CN101409108B (en) | Average abrasion method and controller using the same | |
CN101727397B (en) | Block management and change method, flash memory storage system and controller thereof | |
CN103678162A (en) | System data storage method, memorizer controller and memorizer storing device | |
CN102800357A (en) | Program code loading and accessing methods, memory controller and storage device of memory | |
CN102999437A (en) | Data transfer method, memory controller and memory storage device | |
CN102110056B (en) | Flash memory management method, flash memory controller and flash memory storage system | |
CN102841853B (en) | Memory management table disposal route, Memory Controller and memorizer memory devices |
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 |