CN104346291B - The storage method and storage system of a kind of memory - Google Patents

The storage method and storage system of a kind of memory Download PDF

Info

Publication number
CN104346291B
CN104346291B CN201310336895.1A CN201310336895A CN104346291B CN 104346291 B CN104346291 B CN 104346291B CN 201310336895 A CN201310336895 A CN 201310336895A CN 104346291 B CN104346291 B CN 104346291B
Authority
CN
China
Prior art keywords
mode logic
logic blocks
data
data storage
slc
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
CN201310336895.1A
Other languages
Chinese (zh)
Other versions
CN104346291A (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.)
Actions Technology Co Ltd
Original Assignee
Juxin (zhuhai) Science & Technology Co 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 Juxin (zhuhai) Science & Technology Co Ltd filed Critical Juxin (zhuhai) Science & Technology Co Ltd
Priority to CN201310336895.1A priority Critical patent/CN104346291B/en
Priority to PCT/CN2014/083650 priority patent/WO2015018305A1/en
Publication of CN104346291A publication Critical patent/CN104346291A/en
Application granted granted Critical
Publication of CN104346291B publication Critical patent/CN104346291B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • G06F12/0238Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory
    • G06F12/0246Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory in block erasable memory, e.g. flash memory

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Read Only Memory (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The present invention relates to the storage method and storage system of technical field of memory, more particularly to a kind of memory, to solve when SLC memory stores mass data, it is necessary to memory space it is larger, cause resources costs to increase;When the high data of MLC memory storage security, because its is complicated, the problems such as easily producing loss of data.The embodiment of the present invention will need the Data Migration of migration into the MLC mode logic blocks of non-data storage using the data for determining to need to migrate in SLC mode logic blocks in SLC mode logic blocks;And determine to need the data of migration in MLC mode logic blocks, and method of the Data Migration of migration into the SLC mode logic blocks of non-data storage will be needed in MLC mode logic blocks.When the data of storage are higher to security requirement, the Data Migration is stored into SLC mode logic blocks, when the data volume of storage is larger, Data Migration stored into MLC mode logic blocks.

Description

The storage method and storage system of a kind of memory
Technical field
The present invention relates to the storage method and storage system of technical field of memory, more particularly to a kind of memory.
Background technology
SLC (Single-Level Cell, individual layer memory cell) Flash Memory and MLC (Multi-Level Cell, multilayered memory unit) Flash Memory belong to two distinct types of NAND FLASH memories, can be used as MP3 The storage medium of the products such as player, mobile storage disc.
SLC storage principle is the oxide film for having layer among floating gate and source electrode, during write-in data, is led to The electric charge making alive to floating gate is crossed, then through source electrode, you can eliminate stored electric charge, its read or write speed is very fast, But because SLC storage densitys are relatively low, each logical block can only store 1 information, when store substantial amounts of data when, it is necessary to storage Space is bigger, causes resources costs to increase.MLC storage principle is that the information of two units is stored in into a Floating Gate(The part of electric charge is deposited in flash memory cell), then using the electric charge of different potentials, pass through the voltage of memory storage Control precisely read-write.MLC stores two bits by using substantial amounts of voltage class, each logical block, and packing density is than larger. But because the data deposited in MLC each logical block is more, structure is relative complex, and the probability of error can increase, it is necessary to carry out Error correction, causes its read or write speed slower, and easily produce loss of data the problems such as.
Therefore, in the prior art, when SLC memory will store mass data, it is necessary to memory space it is bigger, cause money Source cost increases;When MLC needs the high data of storage security, due to the complexity of its structure, loss of data is easily produced The problems such as.
The content of the invention
The embodiments of the invention provide a kind of storage method of memory and storage system, to solve when SLC memory will Store mass data when, it is necessary to memory space it is bigger, cause resources costs to increase;When MLC needs the high number of storage security According to when, due to the complexity of its structure, easily produce loss of data the problems such as.
The embodiments of the invention provide a kind of storage method of memory, this method includes:
Determine to need the data of migration in SLC mode logic blocks, and the data that migration is needed in SLC mode logic blocks are moved In the MLC mode logic blocks for moving to non-data storage;And
Determine to need the data of migration in MLC mode logic blocks, and the data that migration is needed in MLC mode logic blocks are moved In the SLC mode logic blocks for moving to non-data storage.
The embodiments of the invention provide a kind of storage system of memory, the storage system includes:
Memory cell, for storing SLC mode logics block and MLC mode logic blocks;
Processing unit, for determining to need the data of migration in SLC mode logic blocks, and will be needed in SLC mode logic blocks The Data Migration to be migrated is into the MLC mode logic blocks of non-data storage;And determine to need migration in MLC mode logic blocks Data, and will be needed in MLC mode logic blocks migration Data Migration into the SLC mode logic blocks of non-data storage.
The embodiment of the present invention, which is used, to be determined to need the data of migration in SLC mode logic blocks, and by SLC mode logic blocks The Data Migration of migration is needed into the MLC mode logic blocks of non-data storage;And determine to need to move in MLC mode logic blocks The data of shifting, and the Data Migration of migration will be needed in MLC mode logic blocks into the SLC mode logic blocks of non-data storage Method, when the data of storage are higher to security requirement, the Data Migration is stored into SLC mode logic blocks, when When the data volume of storage is larger, Data Migration is stored into MLC mode logic blocks.When avoiding SLC storage mass data, need The memory bank volume wanted is bigger, causes resources costs to increase;When MLC needs storage security high data, data are easily produced The problems such as loss.
Brief description of the drawings
Fig. 1 is that the Data Migration of migration will be needed in SLC mode logic blocks to non-data storage in the embodiment of the present invention The method flow schematic diagram of MLC mode logic blocks;
Fig. 2 is that the Data Migration of migration will be needed in SLC mode logic blocks to non-data storage in the embodiment of the present invention The specific method schematic flow sheet of MLC mode logic blocks;
Fig. 3 is that the Data Migration of migration will be needed in MLC mode logic blocks to non-data storage in the embodiment of the present invention The method flow schematic diagram of SLC mode logic blocks;
Fig. 4 is that the Data Migration of migration will be needed in MLC mode logic blocks to non-data storage in the embodiment of the present invention The specific method schematic flow sheet of SLC mode logic blocks;
Fig. 5 is a kind of schematic flow sheet of the specific storage method of memory in the embodiment of the present invention;
Fig. 6 is a kind of schematic diagram of the storage system of memory in the embodiment of the present invention.
Embodiment
The embodiment of the present invention, which is used, to be determined to need the data of migration in SLC mode logic blocks, and by SLC mode logic blocks The Data Migration of migration is needed into the MLC mode logic blocks of non-data storage;And determine to need to move in MLC mode logic blocks The data of shifting, and the Data Migration of migration will be needed in MLC mode logic blocks into the SLC mode logic blocks of non-data storage Method, when storage security requires higher data, the Data Migration is stored into SLC mode logic blocks, when depositing When the data volume of storage is larger, Data Migration is stored into MLC mode logic blocks.
The embodiment of the present invention is described in further detail with reference to Figure of description.
A kind of storage method of memory in the embodiment of the present invention, this method includes:
Determine to need the data of migration in SLC mode logic blocks, and the data that migration is needed in SLC mode logic blocks are moved In the MLC mode logic blocks for moving to non-data storage;
Determine to need the data of migration in MLC mode logic blocks, and the data that migration is needed in MLC mode logic blocks are moved In the SLC mode logic blocks for moving to non-data storage.
Determine to need the data of migration in SLC mode logic blocks, and determine to need the data of migration in MLC mode logic blocks There is no front and rear sequential relationship, determine which step performed according to trigger condition, two kinds of situations are introduced separately below.
Situation one, the data for determining to need migration in SLC mode logic blocks, and migration will be needed in SLC mode logic blocks Data Migration into the MLC mode logic blocks of non-data storage.
As shown in figure 1, for the Data Migration of migration will be needed in the embodiment of the present invention in SLC mode logic blocks to not storing The method of the MLC mode logic blocks of data, this method includes:
Step 101:Determine to need the data of migration in SLC mode logic blocks;
Step 102:The Data Migration of migration will be needed in SLC mode logic blocks to the MLC mode logics of non-data storage In block.
Wherein, in step 101, determine to need the data of migration to include in SLC mode logic blocks:When non-data storage , will when the quantity of SLC mode logic blocks is less than the lower limit of the SLC mode logic number of blocks scopes of the non-data storage of setting The data that frequency is less than the corresponding erasing lower-frequency limit value of erasing frequency level are wiped in SLC mode logic blocks, SLC patterns are used as The data of migration are needed in logical block.Or,
When the quantity of the MLC mode logic blocks of non-data storage is less than the MLC mode logic blocks of the non-data storage of setting During the lower limit of quantitative range, frequency will be wiped in SLC mode logic blocks and is less than under the corresponding erasing frequency of erasing frequency level The data of limit value, are used as the data for needing to migrate in SLC mode logic blocks.Or,
When the quantity of the SLC mode logic blocks of non-data storage is less than the SLC mode logic blocks of the non-data storage of setting The lower limit of quantitative range, and the MLC moulds of non-data storage of the quantity less than setting of the MLC mode logic blocks of non-data storage During the lower limit of formula logical block quantitative range, frequency will be wiped in SLC mode logic blocks and is less than the corresponding wiping of erasing frequency level Except the data of frequency lower limit, the data for needing to migrate in SLC mode logic blocks are used as.
Wherein, the SLC mode logic number of blocks scopes of non-data storage, are specifically included:By the SLC mode logics of memory The quantity of block is divided at least two scopes, when the quantity of SLC mode logic blocks is less than the non-data storage of one of setting SLC mode logic number of blocks scopes lower limit, will in SLC mode logic blocks wipe frequency be less than erasing frequency level correspondence Erasing lower-frequency limit value data, be used as needed in SLC mode logic blocks migration data.
The MLC mode logic number of blocks scopes of non-data storage, are specifically included:By the MLC mode logic blocks of memory Quantity is divided at least two scopes, when the quantity of MLC mode logic blocks is less than the MLC of the non-data storage of one of setting During the lower limit of mode logic number of blocks scope, frequency will be wiped in SLC mode logic blocks corresponding less than erasing frequency level The data of lower-frequency limit value are wiped, the data for needing to migrate in SLC mode logic blocks are used as.
The SLC mode logic number of blocks scopes of non-data storage, and non-data storage MLC mode logic number of blocks models Enclose, specifically include:The quantity of the quantity of the SLC mode logic blocks of memory and MLC mode logic blocks is divided at least two Scope;When the quantity of SLC mode logic blocks is less than the SLC mode logic number of blocks scopes of the non-data storage of one of setting Lower limit, and MLC mode logic blocks quantity be less than one of setting non-data storage MLC mode logic numbers of blocks During the lower limit of scope, frequency will be wiped in SLC mode logic blocks and is less than the corresponding erasing lower-frequency limit value of erasing frequency level Data, be used as needed in SLC mode logic blocks migration data.
Such as with 8GB memory, the quantity of the SLC mode logic blocks of memory is divided into exemplified by 8 scopes, if Surely the space of storage SLC mode logic blocks is 4GB, sets up the SLC mode logic number of blocks scopes and SLC of each non-data storage The corresponding relation of the erasing frequency level of mode logic block.
Assuming that 4GB SLC patterns memory space can store 1024 SLC mode logic blocks, the SLC mode logics of division Number of blocks scope and corresponding erasing frequency are as shown in table 1:
Table 1
When SLC mode logics number of blocks such as non-data storage in current storage is 300, corresponding SLC patterns are patrolled It is 1 grade to collect number of blocks grade, and after data are write, the SLC mode logic numbers of blocks of non-data storage are reduced to after 240, right The SLC mode logic number of blocks grades answered change, and SLC mode logics number of blocks is less than SLC mode logic numbers of blocks grade 1 The lower limit 256 of the SLC mode logic number of blocks scopes of corresponding non-data storage, now determines SLC mode logic numbers of blocks The corresponding erasing frequency level of grade, and the corresponding erasing lower-frequency limit value of erasing frequency level, in SLC mode logic blocks Data screened, number of times will be write and be less than the data of 2 times, migrated into MLC mode logic blocks.If continuing to write to data, Patrolled when the N grades of corresponding SLC logical blocks quantitative levels that the SLC mode logics number of blocks of non-data storage is less than setting are corresponding Collect after number of blocks lower limit, the data that repetition is migrated the need for screening grade correspondence, erasing frequency is less than SLC logic block numbers The data of the corresponding erasing lower-frequency limit value of N grades of flow control, are migrated into MLC mode logic blocks.
Each corresponding erasing frequency range of frequency level of wiping can be set as needed, with above-mentioned by memory The quantity of SLC mode logic blocks be divided into exemplified by 8 scopes, the corresponding erasing frequency range of each erasing frequency level can be with Respectively:Level0 corresponding data write-in number of times is a~b-1 time, and the corresponding data write-in number of times of Level1 is b~c-1 times, Level2 corresponding data write-in number of times is c~d-1 time, and the corresponding data write-in number of times of Level3 is d~e-1 time, Level4 Corresponding data write-in number of times is e~f-1 time, and the corresponding data write-in number of times of Level5 is f~g-1 times, and Level6 is corresponding Data write-in number of times is g~h-1 time, and the corresponding data write-in number of times of Level7 is more than h time;Wherein, a~h is positive integer.
In memory, the physical block of SLC mode logics block two SLC pattern of correspondence, when the SLC mode logic blocks When first half needs write-in data, the physical block P of the SLC patterns of a non-data storage is distributed1Data are write, and foundation should SLC mode logics block and P1Mapping relations;When the latter half of the SLC mode logic blocks needs write-in data, distribution is another The physical block P of the SLC patterns of one non-data storage2Data are write, the SLC mode logics block and P is set up2Mapping relations.Cause This, the mapping relations of a SLC mode logics block and the physical block of SLC patterns have four kinds of situations:Situation one, SLC mode logics Block and the physical block of SLC patterns do not set up mapping relations;Situation two, the physical block P of SLC mode logics block only with SLC patterns1Build Mapping relations are found;Situation three, the physical block P of SLC mode logics block only with SLC patterns2Establish mapping relations;Situation four, SLC mode logics block and the physical block P of SLC patterns1And P2All establish mapping relations, i.e. SLC mode logics block and two physics Block establishes full mapping relations.
It is preferred that determine to need the data of migration in SLC mode logic blocks in step 101, including:When non-data storage When the quantity of SLC mode logic blocks is less than the lower limit of the SLC mode logic number of blocks scopes of the non-data storage of setting, or not The quantity of the MLC mode logic blocks of data storage is less than under the MLC mode logic number of blocks scopes of the non-data storage of setting During limit value, or ought non-data storage SLC mode logic blocks quantity be less than setting non-data storage SLC mode logic blocks The lower limit of quantitative range, and the MLC moulds of non-data storage of the quantity less than setting of the MLC mode logic blocks of non-data storage During the lower limit of formula logical block quantitative range;It is determined that the physical block P with SLC patterns1And P2All set up the SLC patterns of mapping relations Logical block, by the physical block P with SLC patterns1And P2All set up in the SLC mode logic blocks of mapping relations and wipe frequency less than wiping Except the data of the corresponding erasing lower-frequency limit value of frequency level, the data for needing to migrate in SLC mode logic blocks are used as.
In the time span of setting, if data are migrated to the migration number of times of SLC mode logic blocks from MLC mode logic blocks More than the migration frequency threshold value of setting, judge that migration number of times is more than the number of the SLC mode logic blocks of the migration frequency threshold value of setting According to quantity whether be more than setting amount threshold;If being more than, the SLC mode logic number of blocks scopes of non-data storage are turned down Lower limit, the erasing frequency level of data is otherwise improved, after the erasing frequency level for improving data, by the migration of the data time Number zero;If or be more than, turn down the lower limit of the MLC mode logic number of blocks scopes of non-data storage, otherwise improve data Erasing frequency level, after the erasing frequency level for improving data, the migration number of times of the data is zeroed;If or be more than, adjust The lower limit and the MLC mode logic numbers of blocks of non-data storage of the SLC mode logic number of blocks scopes of low non-data storage The lower limit of scope, otherwise improves the erasing frequency level of data, after the erasing frequency level for improving data, by moving for the data Move number of times zero.
So that the quantity of the above-mentioned SLC mode logic blocks by memory is divided into 8 scopes as an example, it is assumed that currently do not store number According to SLC mode logic number of blocks grades from the 2nd grade change to 3rd level, if migrating to the SLC mode logic blocks of non-data storage In data, the migration number of times in the time span of setting is more than the migration frequency threshold value of setting, and long in the time of setting The quantity that migration number of times in degree is more than the data of the SLC mode logic blocks of the migration frequency threshold value of setting is more than the quantity set Threshold value, then turn down the 2nd grade of SLC mode logic number of blocks grades corresponding erasing lower-frequency limit value, or by SLC mode logics The corresponding erasing lower-frequency limit value of whole grades of number of blocks is turned down, and by the wiping of corresponding SLC mode logics number of blocks grade Except frequency higher limit is adjusted.The erasing lower-frequency limit value of SLC mode logic number of blocks grade 3rd levels is such as adjusted to 6, this When the corresponding erasing frequency range of SLC mode logic number of blocks 3rd levels be revised as 6~31, by SLC mode logics number of blocks the 2 grades of erasing frequency range is revised as 2~5;Or adjust the erasing lower-frequency limit value of SLC mode logic number of blocks grade 3rd levels Whole is 6, and the corresponding erasing frequency range of 3rd level is revised as 6~29;By the 2nd grade of erasing frequency of SLC mode logics number of blocks Scope is revised as 2~5;The 4th grade of erasing frequency range of SLC mode logics number of blocks is revised as 30~61;SLC patterns are patrolled The erasing frequency range for collecting the 5th grade of number of blocks is revised as 62~125;By the 6th grade of erasing frequency model of SLC mode logics number of blocks Enclose and be revised as 126~253;The 7th grade of erasing frequency range of SLC mode logics number of blocks is revised as >=254.
It is preferred that determining that migration number of times is not more than number of the quantity more than setting of the logical block of the migration frequency threshold value of setting After amount threshold value, in addition to:Judge whether the quantity of the SLC mode logic blocks of current non-data storage is more than not storing for setting The amount threshold of the SLC mode logic blocks of data, if being more than, terminates this flow;If being not more than, illustrate non-data storage SLC mode logic numbers of blocks are not enough to support the demand of L2 cache, in order to reduce the cost of Data Migration, use MLC patterns Data are write direct in the MLC mode logic blocks of non-data storage.
When the quantity increase of the SLC mode logic blocks of non-data storage, SLC mode logic number of blocks grades change When, the erasing frequency range and erasing frequency level of corresponding logical block also change therewith, now can not be by erasing frequency symbol The Data Migration in the MLC logical blocks of current erasure frequency level is closed into SLC mode logic blocks.
As shown in Fig. 2 for the Data Migration of migration will be needed in the embodiment of the present invention in SLC mode logic blocks to not storing The specific method of the MLC mode logic blocks of data, this method includes:
Step 201:The quantity of the SLC mode logic blocks of current non-data storage changes, it is determined that currently not storing number According to SLC mode logic blocks quantitative levels;
Step 202:Judge whether the quantity of the SLC mode logic blocks of non-data storage is more than the non-data storage of setting The higher limit of the minimum zone of SLC mode logic numbers of blocks, if being more than, performs step 203, otherwise performs step 210;
Step 203:It is determined that the corresponding erasing frequency level of quantitative levels of the SLC mode logic blocks after change;
Step 204:It is determined that full mapping relations are set up with two physical blocks, and erasing frequency is less than erasing frequency of determination etc. The SLC mode logic blocks of the corresponding erasing lower-frequency limit value of level, to need the SLC mode logic blocks of migrating data;
Step 205:The migration frequency threshold value for needing the migration number of times of the data migrated whether to be more than setting is judged, if less In then execution step 206, otherwise performs step 207;
Step 206:The data in the SLC mode logic blocks of migration will be determined to need, migrated to the MLC moulds of non-data storage In formula logical block, and terminate this flow;
Step 207:Turn down the lower limit of the SLC mode logic number of blocks rate ranges of non-data storage;
Step 208:Judge whether to complete the scanning to whole SLC mode logics blocks, if completing, perform step 209, it is no Then perform step 204;
Step 209:Judge whether the quantity of the SLC mode logic blocks of non-data storage is more than the SLC moulds of non-data storage The higher limit of the minimum zone of formula logic number of blocks, if being more than, terminates this flow, otherwise performs step 210;
Step 210:It is fixed SLC mode logic blocks by erasing frequency level highest SLC mode logics block identification, by it Data in his SLC mode logic blocks are all migrated into the MLC mode logic blocks of non-data storage.
Wherein, in step 201 and step 202, can also work as non-data storage MLC mode logic blocks quantity be more than set During the higher limit of the minimum zone of the MLC mode logic numbers of blocks of fixed non-data storage, frequency will be wiped in SLC mode logic blocks Rate is less than the data of the corresponding erasing lower-frequency limit value of erasing frequency level of setting, as needing to move in SLC mode logic blocks The data of shifting;Or ought non-data storage MLC mode logic blocks quantity be more than setting non-data storage MLC mode logics The higher limit of the minimum zone of number of blocks, and the quantity of the MLC mode logic blocks of non-data storage is less than not depositing for other settings During the lower limit for the MLC mode logic number of blocks scopes for storing up data, the wiping that frequency is less than setting will be wiped in SLC mode logic blocks Except the data of the corresponding erasing lower-frequency limit value of frequency level, the data for needing to migrate in SLC mode logic blocks are used as.
In step 204, frequency can also will be only wiped less than the corresponding erasing lower-frequency limit of erasing frequency level determined The SLC mode logic blocks of value, as needing the SLC mode logic blocks of migrating data.
Situation two, the data for determining to need migration in MLC mode logic blocks, and migration will be needed in MLC mode logic blocks Data Migration into the SLC mode logic blocks of non-data storage.
As shown in figure 3, for the Data Migration of migration will be needed in the embodiment of the present invention in MLC mode logic blocks to not storing The method of the SLC mode logic blocks of data, this method includes:
Step 301:Determine to need the data of migration in MLC mode logic blocks;
Step 302:The Data Migration of migration will be needed in MLC mode logic blocks to the SLC mode logics of non-data storage In block.
Wherein in step 301, determine to need the data of migration to include in MLC mode logic blocks:When needing that MLC patterns are patrolled When data in volume block enter edlin, it would be desirable to which the data of editor, which are used as, needs the data of migration in MLC mode logic blocks.
Data in MLC mode logic blocks are entered before edlin, in addition to:It is determined that the SLC moulds of current non-data storage The quantity of formula logical block is more than the higher limit of the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting;Or determine The quantity of the MLC mode logic blocks of current non-data storage is more than the MLC mode logic block numbers of the non-data storage of minimum of setting Measure the higher limit of scope;Or determine that the quantity of the SLC mode logic blocks of current non-data storage is more than the minimum of setting and do not stored The higher limit of the SLC mode logic number of blocks scopes of data, and currently the quantity of the MLC mode logic blocks of non-data storage is more than The higher limit of the MLC mode logic number of blocks scopes of the non-data storage of minimum of setting.
As shown in table 1, the minimum for being more than setting with the quantity of the SLC mode logic blocks of currently non-data storage does not store number According to SLC mode logic number of blocks scopes higher limit exemplified by, other situations are similar.When the SLC patterns of non-data storage , it is necessary to right during any one-level of the quantity of logical block in the quantitative range of 0~6 grade of corresponding logical block of logical block quantitative levels The data of one MLC mode logic block enter edlin, then by the SLC mode logics of the Data Migration to non-data storage, adopt Edlin is entered to the data with SLC patterns;When the minimum that the quantity of the SLC mode logic blocks of non-data storage is less than setting is not deposited The higher limit of the SLC mode logic number of blocks scopes of data is stored up, i.e., the quantity of the SLC mode logic blocks of non-data storage is in logic , it is necessary to when entering edlin to the data of a MLC mode logic block in the quantitative range of the 7th grade of corresponding logical block of number of blocks, Edlin is entered to the data using MLC patterns.
In the time span of setting, if data are migrated to the migration number of times of SLC mode logic blocks from MLC mode logic blocks More than the migration frequency threshold value of setting, judge that the migration number of times in the time span of setting is more than the migration frequency threshold value of setting MLC mode logic blocks data quantity whether be more than setting amount threshold;If being more than, non-data storage is turned down SLC mode logic number of blocks lower range limits, otherwise improve the erasing frequency level of the data of the MLC mode logics block;Or If being more than, the MLC mode logic number of blocks lower range limits of non-data storage are turned down, the MLC mode logics are otherwise improved The erasing frequency level of the data of block;If or be more than, turn down the SLC mode logic number of blocks range lower limits of non-data storage Value, and the MLC mode logic number of blocks lower range limits of non-data storage are turned down, otherwise improve the MLC mode logics block The erasing frequency level of data.
When writing new data into memory, set if the quantity of the SLC mode logic blocks of current non-data storage is more than The higher limit of the SLC mode logic number of blocks scopes of the fixed non-data storage of minimum;If or the MLC patterns of current non-data storage The quantity of logical block is more than the higher limit of the MLC mode logic number of blocks scopes of the non-data storage of minimum of setting;If or current The quantity of the SLC mode logic blocks of non-data storage is more than the SLC mode logic number of blocks models of the non-data storage of minimum of setting The higher limit enclosed, and MLC of the quantity more than the non-data storage of minimum of setting of the MLC mode logic blocks of current non-data storage The higher limit of mode logic number of blocks scope;The SLC mode logic blocks of non-data storage are then write the data into using SLC patterns In.
If the quantity of the SLC mode logic blocks of current non-data storage is not more than the SLC of the non-data storage of minimum of setting During the higher limit of mode logic number of blocks scope;If or the quantity of the MLC mode logic blocks of current non-data storage is not more than and set During the higher limit of the MLC mode logic number of blocks scopes of the fixed non-data storage of minimum;If or the SLC moulds of current non-data storage The quantity of formula logical block is not more than the higher limit of the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting, and works as The quantity of the MLC mode logic blocks of preceding non-data storage is not more than the MLC mode logic block numbers of the non-data storage of minimum of setting When measuring the higher limit of scope;Then write the data into using MLC patterns in the MLC mode logic blocks of non-data storage.
As shown in table 1, the minimum for being more than setting with the quantity of the SLC mode logic blocks of currently non-data storage does not store number According to SLC mode logic number of blocks scopes higher limit exemplified by, other situations are similar.When the SLC patterns of non-data storage Any one-level of the quantity of logical block in the quantitative range of memory space logical block 0~6 grade of corresponding logical block of quantitative levels, When needing write-in new data, write the data into using SLC patterns in the SLC mode logic blocks of non-data storage;When not storing The quantity of the SLC mode logic blocks of data is in the 7th grade of memory space logic number of blocks, i.e., the SLC mode logics of non-data storage The quantity of block is when being not more than the higher limit 8 of the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting, it is necessary to write During new data, write the data into using MLC patterns in the MLC mode logic blocks of non-data storage.
When the data volume write into memory is more than the SLC patterns maximum write-in data volume of setting, moved to reduce The cost of data is moved, is write data into mlc mode in the MLC mode logic blocks of non-data storage.Such as the SLC patterns of setting Once maximum write-in data volume is 128MB, when the data volume of write-once is more than 128MB, is write data into mlc mode In the MLC mode logic blocks of non-data storage.
In memory, a logical block informations are stored using two bytes, each byte there are 8, two bytes totally 16, The implication of every information shown in table 2 is corresponding with the situation described in table 1, and other situations are similar therewith, will not be repeated here.
Table 2
As shown in figure 4, for the Data Migration of migration will be needed in the embodiment of the present invention in MLC mode logic blocks to not storing The specific method of the SLC mode logic blocks of data, this method is to judge the quantity of the SLC mode logic blocks of current non-data storage Exemplified by the higher limit for whether being more than the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting, other condition thresholds It is similar, it will not be repeated here.This method includes:
Step 401:It is determined that needing to enter edlin to the data in MLC mode logic blocks;
Step 402:Judge whether the quantity of the SLC mode logic blocks of current non-data storage is more than minimum non-data storage SLC mode logic numbers of blocks minimum zone higher limit, if being more than, perform step 403, otherwise perform step 406;
Step 403:Judge in the time span of setting, whether the migration number of times of the data in MLC mode logic blocks is big In the migration frequency threshold value of setting, if performing step 405 more than if, step 404 is otherwise performed;
Step 404:By in the SLC mode logic blocks of the Data Migration in MLC mode logic blocks to non-data storage, carry out Data edition, and terminate this flow;
Step 405:Turn down the SLC mode logic number of blocks lower range limits of non-data storage;
Step 406:The data to MLC mode logic blocks enter edlin in mlc mode, and terminate this flow.
As shown in figure 5, being not store number in a kind of specific storage method of memory in the embodiment of the present invention, this method According to SLC mode logic blocks quantity divide SLC mode logic number of blocks grades exemplified by, by memory space logical block quantitative levels 8 grades are divided into, are comprised the following steps that:
Step 501:It is determined that the quantity of the SLC mode logic blocks of current non-data storage;
Step 502:Judge current non-data storage SLC mode logics number of blocks whether setting SLC mode logics In the 0th grade of corresponding logical block quantitative range of number of blocks, if then performing step 504, step 503 is otherwise performed;
Step 503:Judge current non-data storage SLC mode logics number of blocks whether setting SLC mode logics In the range of the 7th grade of number of blocks, if then performing step 515, step 504 is otherwise performed;
Step 504:Write data into SLC mode logic blocks;
Step 505:Judge the corresponding SLC mode logics number of blocks of SLC mode logic numbers of blocks of current non-data storage Whether grade is changed, and step 506 is performed if changing, otherwise terminates this flow;
Step 506:It is determined that the corresponding erasing frequency level of SLC mode logic number of blocks grades after change;
Step 507:It is determined that full mapping relations are set up with two physical blocks, and erasing frequency is less than erasing frequency of setting etc. The data that the data of the SLC mode logic blocks of the corresponding erasing lower-frequency limit value of level migrate for needs;
Step 508:Judge in the data that needs are migrated, whether the migration number of times in the time span of setting is more than setting Migration frequency threshold value, if more than if perform step 509, otherwise perform step 511;
Step 509:Judge whether the quantity for migrating the SLC mode logic blocks for the migration frequency threshold value that number of times is more than setting is big In the amount threshold of setting, if more than step 510 is performed, otherwise performing step 512;
Step 510:The lower limit of the SLC mode logic number of blocks rate ranges of non-data storage is turned down, and performs step 513;
Step 511:The data in the SLC mode logic blocks of migration will be determined to need, migrated to the MLC moulds of non-data storage In formula logical block, and perform step 513;
Step 512:Improve migration number of times and be more than erasing frequency of SLC mode logic blocks of migration frequency threshold value of setting etc. Level, and the migration number of times of the SLC mode logic blocks is zeroed;
Step 513:Judge whether to complete the scanning to whole SLC mode logics blocks, step 514 is performed if completing, it is no Then return to step 507;
Step 514:Judge current non-data storage SLC mode logics number of blocks whether setting SLC mode logics In the 7th grade of logical block quantitative range of number of blocks, if then performing step 515, otherwise terminate this flow;
Step 515:Into direct mode operation, MLC mode logic blocks are write data into using MLC patterns;
Step 516:It is fixed SLC mode logic blocks by erasing frequency level highest SLC mode logics block identification, other SLC mode logic blocks be converted to MLC mode logic blocks, and terminate this flow.
Wherein in step 504, write data into SLC mode logic blocks and specifically include:When new data is written, by data In the SLC mode logic blocks of the non-data storage of write-in;When data in SLC mode logic blocks are updated, in SLC SLC mode logic blocks are write data under pattern;When the data in MLC mode logic blocks enter edlin, first by MLC patterns Data Migration in logical block is patrolled migrating to SLC patterns in slc mode into the SLC mode logic blocks of non-data storage The data collected in block enter edlin.
Based on same inventive concept, a kind of storage system of memory is additionally provided in the embodiment of the present invention, because this is The principle solved the problems, such as of uniting is similar to a kind of storage method of memory of the embodiment of the present invention, therefore the implementation of the system can be joined The implementation of square method, repeats part and repeats no more.
As shown in fig. 6, being a kind of storage system of memory in the embodiment of the present invention, the system includes memory cell 601, Processing unit 602.
Memory cell 601, for storing SLC mode logics block and MLC mode logic blocks;
Processing unit 602, for determining to need the data of migration in SLC mode logic blocks, and by SLC mode logic blocks The Data Migration of migration is needed into the MLC mode logic blocks of non-data storage;And determine to need to move in MLC mode logic blocks The data of shifting, and the Data Migration of migration will be needed in MLC mode logic blocks into the SLC mode logic blocks of non-data storage.
Wherein, memory cell 601 includes storage headspace and user's space;SLC mode logics block and MLC mode logics Block carries out storage in memory cell 601 to include following three kinds preferably storage sides in the present invention using various ways Formula, other modes are similar therewith.
Mode one, SLC mode logic block memory spaces are constant:SLC mode logic blocks are stored in storage headspace, MLC Mode logic block is stored in user's space.
Mode two, SLC mode logic block storage space variables, SLC mode logic blocks are stored in certain customers space, MLC Mode logic block is stored in storage headspace and remainder user's space.
Mode three, SLC mode logic block storage space variables, SLC mode logic blocks are stored in storage headspace and portion Divide user's space, MLC mode logic blocks are stored in remainder user's space.
In two kinds of situations of SLC mode logic block storage space variables, the SLC mode logics in certain customers space are stored in The quantity of block is not more than the SLC mode logic block maximum quantities of setting;Wherein SLC mode logics block maximum quantity can be according to need Set, such as SLC mode logics block maximum quantity is set as 1/3,1/2 etc. of the whole logic numbers of blocks of user's space, most Big value is no more than the whole logic numbers of blocks of user's space;Logical block is MLC mode logic blocks, MLC moulds in remaining user's space The quantity of formula logical block is not more than the maximum quantity of user's space logical block.
In processing unit 602, determine to need the data of migration to include in SLC mode logic blocks:As the SLC of non-data storage When the quantity of mode logic block is less than the lower limit of the SLC mode logic number of blocks scopes of the non-data storage of setting;Or do not deposit Store up the lower limit of the MLC mode logic number of blocks scopes of non-data storage of the quantity less than setting of the MLC mode logic blocks of data During value;Or the quantity of the SLC mode logic blocks of non-data storage is less than the SLC mode logic numbers of blocks of the non-data storage of setting The lower limit of scope, and the quantity of the MLC mode logic blocks of non-data storage is less than the MLC patterns of non-data storage of setting and patrols When collecting the lower limit of number of blocks scope;Frequency will be wiped in SLC mode logic blocks and is less than the corresponding erasing frequency of erasing frequency level The data of rate lower limit, are used as the data for needing to migrate in SLC mode logic blocks.
Wherein, in processing unit 602, the SLC mode logic number of blocks scopes of non-data storage are specifically included:Will storage The quantity of the SLC mode logic blocks of unit is divided at least two scopes, when the quantity of SLC mode logic blocks is less than one of them The lower limit of the SLC mode logic number of blocks scopes of the non-data storage of setting, is less than frequency is wiped in SLC mode logic blocks The data of the corresponding erasing lower-frequency limit value of frequency level are wiped, the data for needing to migrate in SLC mode logic blocks are used as.
In processing unit 602, the MLC mode logic number of blocks scopes of non-data storage are specifically included:By memory cell The quantity of MLC mode logic blocks is divided at least two scopes, when the quantity of MLC mode logic blocks is less than one of setting During the lower limit of the MLC mode logic number of blocks scopes of non-data storage, it is less than erasing by frequency is wiped in SLC mode logic blocks The data of the corresponding erasing lower-frequency limit value of frequency level, are used as the data for needing to migrate in SLC mode logic blocks.
When in memory cell 601, the quantity of SLC mode logic blocks is less than the SLC of the non-data storage of one of setting The lower limit of mode logic number of blocks scope, and the quantity of MLC mode logic blocks is less than one of non-data storage set MLC mode logic number of blocks scopes lower limit when, processing unit 602 will in SLC mode logic blocks wipe frequency be less than wipe Except the data of the corresponding erasing lower-frequency limit value of frequency level, the data for needing to migrate in SLC mode logic blocks are used as.
In memory cell 601.The quantity of SLC mode logic blocks is divided at least two scopes, each SLC mode logics One erasing frequency level of quantitative range correspondence of block, each one erasing frequency range of erasing frequency level correspondence, erasing frequency Rate scope is set as needed.Or
The quantity of MLC mode logic blocks is divided at least two scopes, the quantitative range pair of each MLC mode logics block An erasing frequency level is answered, each one erasing frequency range of erasing frequency level correspondence, erasing frequency range is as needed Set.Or
The quantity of the quantity of SLC mode logic blocks and MLC mode logic blocks is respectively divided at least two scopes, each The quantitative range of SLC mode logic blocks erasing frequency level corresponding with the quantitative range of MLC mode logic blocks, each erasing One erasing frequency range of frequency level correspondence, erasing frequency range is set as needed.
In memory cell 601, the physical block of SLC mode logics block two SLC pattern of correspondence, when the SLC patterns are patrolled When the first half of volume block needs write-in data, the physical block P of the SLC patterns of a non-data storage is distributed1Data are write, and Set up the SLC mode logics block and P1Mapping relations;When the latter half of the SLC mode logic blocks needs write-in data, Distribute the physical block P of the SLC patterns of another non-data storage2Data are write, the SLC mode logics block and P is set up2Mapping Relation.Therefore, the mapping relations of a SLC mode logics block and the physical block of SLC patterns have four kinds of situations:Situation one, SLC moulds Formula logical block and the physical block of SLC patterns do not set up mapping relations;Situation two, the physics of SLC mode logics block only with SLC patterns Block P1Establish mapping relations;Situation three, the physical block P of SLC mode logics block only with SLC patterns2Establish mapping relations;Feelings The physical block P of condition four, SLC mode logics block and SLC patterns1And P2All establish mapping relations, i.e. SLC mode logics block and two Individual physical block establishes full mapping relations.
It is preferred that in processing unit 602, determine to need the data of migration in SLC mode logic blocks, including:When storage is single Member 601 determines that the quantity of the SLC mode logic blocks of non-data storage is less than the SLC mode logic block numbers of the non-data storage of setting When measuring the lower limit of scope;Or the quantity of the MLC mode logic blocks of non-data storage is less than the MLC moulds of the non-data storage of setting During the lower limit of formula logical block quantitative range;Or ought non-data storage SLC mode logic blocks quantity be less than setting not depositing Store up data SLC mode logic number of blocks scopes lower limit, and the MLC mode logic blocks of non-data storage quantity be less than set During the lower limit of the MLC mode logic number of blocks scopes of fixed non-data storage;Processing unit 602 determines the thing with SLC patterns Manage block P1And P2The SLC mode logic blocks of mapping relations are all set up, by the physical block P with SLC patterns1And P2Mapping is all set up to close The data that frequency is less than the corresponding erasing lower-frequency limit value of erasing frequency level are wiped in the SLC mode logic blocks of system, SLC is used as The data of migration are needed in mode logic block.
In the time span of setting, processing unit 602 determines that data are migrated to MLC patterns from SLC mode logic blocks and patrolled The migration number of times for collecting block is more than the migration frequency threshold value of setting, judges to migrate the SLC for the migration frequency threshold value that number of times is more than setting Whether the quantity of the data of mode logic block is more than the amount threshold of setting;If being more than, the SLC patterns of non-data storage are turned down The lower limit of logical block quantitative range, otherwise improves the erasing frequency level of data in SLC mode logic blocks, improves the wiping of data After frequency level, the migration number of times of the data is zeroed;If or be more than, turn down the MLC mode logic blocks of non-data storage The lower limit of quantitative range, otherwise improves the erasing frequency level of data in SLC mode logic blocks, improves the erasing frequency of data After grade, the migration number of times of the data is zeroed;If or be more than, turn down the SLC mode logic number of blocks models of non-data storage The lower limit enclosed, and the lower limit of the MLC mode logic number of blocks scopes of non-data storage is turned down, otherwise improve SLC patterns and patrol The erasing frequency level of data in block is collected, after the erasing frequency level for improving data, the migration number of times of the data is zeroed.
It is preferred that processing unit 602 is additionally operable to, it is determined that migration number of times is not more than the data of the migration frequency threshold value of setting The quantity of SLC mode logic blocks is more than after the amount threshold of setting, in addition to:Judge the SLC patterns of current non-data storage Whether the quantity of logical block is more than the amount threshold of the SLC mode logic blocks of the non-data storage of setting, if being more than, and terminates this Flow, otherwise illustrates that the SLC mode logic numbers of blocks of non-data storage are not enough to support the demand of L2 cache, in order to reduce number According to the cost of migration, data are write direct in the MLC mode logic blocks of non-data storage using MLC patterns.
When the quantity increase of the SLC mode logic blocks of non-data storage, SLC mode logic number of blocks grades change When, the erasing frequency range and erasing frequency level of corresponding logical block also change therewith, now can not be by erasing frequency symbol The Data Migration in the MLC logical blocks of current erasure frequency level is closed into SLC mode logic blocks.
In processing unit 602, determine to need the data of migration to include in MLC mode logic blocks:When needing that MLC patterns are patrolled When data in volume block enter edlin, it would be desirable to which the data of editor, which are used as, needs the data of migration in MLC mode logic blocks.It is right Data in MLC mode logic blocks are entered before edlin, in addition to:Memory cell 601 determines the SLC moulds of current non-data storage The quantity of formula logical block is more than the higher limit of the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting;Or it is current The quantity of the MLC mode logic blocks of non-data storage is more than the MLC mode logic number of blocks models of the non-data storage of minimum of setting The higher limit enclosed;Or the quantity of the SLC mode logic blocks of current non-data storage is more than the SLC of the non-data storage of minimum of setting The higher limit of mode logic number of blocks scope, and the quantity of the MLC mode logic blocks of current non-data storage is more than setting most The higher limit of the MLC mode logic number of blocks scopes of small non-data storage.
In the time span of setting, processing unit 602 determines that data are migrated to SLC patterns from MLC mode logic blocks and patrolled The migration number of times for collecting block is more than the migration frequency threshold value of setting, judges that the migration number of times in the time span of setting is more than and sets Migration frequency threshold value data MLC mode logic blocks quantity whether be more than setting amount threshold;If being more than, turn down The SLC mode logic number of blocks lower range limits of non-data storage, otherwise improve the erasing frequency of the data of MLC mode logic blocks Grade;If or be more than, turn down the MLC mode logic number of blocks lower range limits of non-data storage, otherwise improve the MLC moulds The erasing frequency level of the data of formula logical block;If or be more than, turn down the SLC mode logic number of blocks scopes of non-data storage Lower limit, and the MLC mode logic number of blocks lower range limits of non-data storage are turned down, otherwise improve MLC mode logic blocks The erasing frequency level of data.
When new data is written, memory cell 601 determines that the quantity of the SLC mode logic blocks of current non-data storage is more than The higher limit of the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting;Or the MLC patterns of current non-data storage The quantity of logical block is more than the higher limit of the MLC mode logic number of blocks scopes of the non-data storage of minimum of setting;Or currently not The quantity of the SLC mode logic blocks of data storage is more than the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting Higher limit, and the MLC mode logic blocks of current non-data storage quantity be more than setting the non-data storage of minimum MLC moulds The higher limit of formula logical block quantitative range;The SLC mode logic blocks of non-data storage are then write the data into using SLC patterns In.
If the quantity of the SLC mode logic blocks of current non-data storage is not more than the minimum of setting not in memory cell 601 The higher limit of the SLC mode logic number of blocks scopes of data storage;Or the quantity of the MLC mode logic blocks of current non-data storage The higher limit of the MLC mode logic number of blocks scopes of the non-data storage of minimum no more than set;Or current non-data storage The quantity of SLC mode logic blocks is not more than the higher limit of the SLC mode logic number of blocks scopes of the non-data storage of minimum of setting, And the quantity of the MLC mode logic blocks of current non-data storage is not more than the MLC mode logics of the non-data storage of minimum of setting The higher limit of number of blocks scope;Then write the data into using MLC patterns in the MLC mode logic blocks of non-data storage.
When write-in data volume be more than setting SLC patterns maximum write-in data volume when, in order to reduce migrating data into This, processing unit 602 writes data into the MLC mode logic blocks of non-data storage in mlc mode.
The present invention is with reference to method according to embodiments of the present invention, equipment(System)And the flow of computer program product Figure and/or block diagram are described.It should be understood that can be by every first-class in computer program instructions implementation process figure and/or block diagram Journey and/or the flow in square frame and flow chart and/or block diagram and/or the combination of square frame.These computer programs can be provided The processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices is instructed to produce A raw machine so that produced by the instruction of computer or the computing device of other programmable data processing devices for real The device for the function of being specified in present one flow of flow chart or one square frame of multiple flows and/or block diagram or multiple square frames.
These computer program instructions, which may be alternatively stored in, can guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works so that the instruction being stored in the computer-readable memory, which is produced, to be included referring to Make the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one square frame of block diagram or The function of being specified in multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that in meter Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented processing, thus in computer or The instruction performed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one The step of function of being specified in individual square frame or multiple square frames.
, but those skilled in the art once know basic creation although preferred embodiments of the present invention have been described Property concept, then can make other change and modification to these embodiments.So, appended claims are intended to be construed to include excellent Select embodiment and fall into having altered and changing for the scope of the invention.
Obviously, those skilled in the art can carry out the essence of various changes and modification without departing from the present invention to the present invention God and scope.So, if these modifications and variations of the present invention belong to the scope of the claims in the present invention and its equivalent technologies Within, then the present invention is also intended to comprising including these changes and modification.

Claims (19)

1. a kind of storage method of memory, it is characterised in that this method includes:
Determine to need the data of migration in SLC mode logic blocks, and the Data Migration of migration will be needed in SLC mode logic blocks extremely In the MLC mode logic blocks of non-data storage;And
Determine to need the data of migration in MLC mode logic blocks, and the Data Migration of migration will be needed in MLC mode logic blocks extremely In the SLC mode logic blocks of non-data storage;
The data of migration are needed in the determination MLC mode logic blocks, including:
It will need to need the data of migration in into the data of edlin as MLC mode logic blocks in MLC mode logic blocks.
2. the method as described in claim 1, it is characterised in that the data of migration are needed in the determination SLC mode logic blocks, Including:
When the quantity of the SLC mode logic blocks of non-data storage is less than the SLC mode logic numbers of blocks of the non-data storage of setting During the lower limit of scope, frequency will be wiped in SLC mode logic blocks and is less than the corresponding erasing lower-frequency limit value of erasing frequency level Data, be used as needed in SLC mode logic blocks migration data;Or
When the quantity of the MLC mode logic blocks of non-data storage is less than the MLC mode logic numbers of blocks of the non-data storage of setting During the lower limit of scope, frequency will be wiped in SLC mode logic blocks and is less than the corresponding erasing lower-frequency limit value of erasing frequency level Data, be used as needed in SLC mode logic blocks migration data;Or
When the quantity of the SLC mode logic blocks of non-data storage is less than the SLC mode logic numbers of blocks of the non-data storage of setting The lower limit of scope, and the quantity of the MLC mode logic blocks of non-data storage is less than the MLC patterns of non-data storage of setting and patrols When collecting the lower limit of number of blocks scope, frequency will be wiped in SLC mode logic blocks and is less than the corresponding erasing of erasing frequency level frequently The data of rate lower limit, are used as the data for needing to migrate in SLC mode logic blocks.
3. method as claimed in claim 1 or 2, it is characterised in that the Data Migration of migration will be needed in SLC mode logic blocks After into the MLC mode logic blocks of non-data storage, in addition to:
If migrating the data into the MLC mode logic blocks of non-data storage, the migration number of times in the time span of setting is big In the migration frequency threshold value of setting, judge that the migration number of times in the time span of setting is more than the migration frequency threshold value of setting Whether the quantity of the data of MLC mode logic blocks is more than the amount threshold of setting;
If being more than, the lower limit of the SLC mode logic number of blocks scopes of non-data storage is turned down, the MLC moulds are otherwise improved The erasing frequency level of data in formula logical block;Or
If being more than, the lower limit of the MLC mode logic number of blocks scopes of non-data storage is turned down, the MLC moulds are otherwise improved The erasing frequency level of data in formula logical block;Or
If being more than, the lower limit of the SLC mode logic number of blocks scopes of non-data storage is turned down, and turns down non-data storage The lower limit of MLC mode logic number of blocks scopes, otherwise improves the erasing frequency level of data in the MLC mode logics block.
4. the method as described in claim 1, it is characterised in that the Data Migration of migration will be needed in MLC mode logic blocks extremely After in the SLC mode logic blocks of non-data storage, in addition to:
If migrating the data into the SLC mode logic blocks of non-data storage, the migration number of times in the time span of setting is big In the migration frequency threshold value of setting, judge that the migration number of times in the time span of setting is more than the migration frequency threshold value of setting Whether the quantity of the data of SLC mode logic blocks is more than the amount threshold of setting;
If being more than, the lower limit of the SLC mode logic number of blocks scopes of non-data storage is turned down, the SLC moulds are otherwise improved The erasing frequency level of data in formula logical block;Or
If being more than, the lower limit of the MLC mode logic number of blocks scopes of non-data storage is turned down, the SLC moulds are otherwise improved The erasing frequency level of data in formula logical block;Or
If being more than, the lower limit of the SLC mode logic number of blocks scopes of non-data storage is turned down, and turns down non-data storage The lower limit of MLC mode logic number of blocks scopes, otherwise improves the erasing frequency level of data in the SLC mode logics block.
5. the method as described in claim 1, it is characterised in that before the data for determining to need migration in MLC mode logic blocks, Also include:
It is determined that the quantity of the SLC mode logic blocks of current non-data storage is more than the SLC mode logics of the non-data storage of setting The higher limit of the minimum number scope of block;Or
It is determined that the quantity of the MLC mode logic blocks of current non-data storage is more than the MLC mode logics of the non-data storage of setting The higher limit of the minimum number scope of block;Or
It is determined that the quantity of the SLC mode logic blocks of current non-data storage is more than the SLC mode logics of the non-data storage of setting The higher limit of the minimum number scope of block, and the quantity of the MLC mode logic blocks of current non-data storage is more than not depositing for setting Store up the higher limit of the minimum number scope of the MLC mode logic blocks of data.
6. the method as described in claim 1, it is characterised in that this method also includes:
When writing new data, if the quantity of the SLC mode logic blocks of current non-data storage is more than the non-data storage of setting The higher limit of the minimum number scope of SLC mode logic blocks, or the quantity of the MLC mode logic blocks of current non-data storage are more than The higher limit of the minimum number scope of the MLC mode logic blocks of the non-data storage of setting, or the currently SLC moulds of non-data storage The quantity of formula logical block is more than the higher limit of the minimum number scope of the SLC mode logic blocks of the non-data storage of setting, and not The quantity of the MLC mode logic blocks of data storage is more than the minimum number model of the MLC mode logic blocks of the non-data storage of setting The higher limit enclosed;The SLC mode logic blocks of non-data storage are then write data into slc mode;
If the quantity of the SLC mode logic blocks of current non-data storage is not more than the SLC mode logics of the non-data storage of setting The higher limit of the minimum number scope of block, or the quantity of the MLC mode logic blocks of current non-data storage are not more than setting not The higher limit of the minimum number scope of the MLC mode logic blocks of data storage, or the currently SLC mode logic blocks of non-data storage Quantity be not more than setting non-data storage SLC mode logic blocks minimum number scope higher limit, and do not store number According to MLC mode logic blocks quantity be not more than setting non-data storage MLC mode logic blocks minimum number scope Higher limit;The MLC mode logic blocks of non-data storage are then write data into mlc mode;Or
When the data volume of write-in is more than the SLC patterns maximum write-in data volume of setting, writes data into do not deposit in mlc mode Store up the MLC mode logic blocks of data.
7. the method as described in claim 1, it is characterised in that this method also includes:
When the quantity of SLC mode logic blocks is more than the SLC mode logic block maximum quantities of setting, from the SLC moulds of data storage SLC mode logic blocks are selected in formula logical block;
By in the MLC mode logic blocks of the Data Migration in the SLC mode logic blocks of selection to non-data storage, and by selection SLC mode logic blocks are converted into MLC mode logic blocks.
8. method as claimed in claim 7, it is characterised in that SLC patterns are selected from the SLC mode logic blocks of data storage Logical block, including:
Frequency will be wiped and be less than the SLC mode logic blocks that highest wipes the corresponding erasing lower-frequency limit value of frequency level, institute is used as State the SLC mode logic blocks of selection.
9. a kind of storage system of memory, it is characterised in that the storage system includes:
Memory cell, for storing SLC mode logics block and MLC mode logic blocks;
Processing unit, for determining to need the data of migration in SLC mode logic blocks, and will need to move in SLC mode logic blocks The Data Migration of shifting is into the MLC mode logic blocks of non-data storage;And determine to need the number of migration in MLC mode logic blocks According to, and the Data Migration of migration will be needed in MLC mode logic blocks into the SLC mode logic blocks of non-data storage;
The processing unit specifically for:
It will need to need the data of migration in into the data of edlin as MLC mode logic blocks in MLC mode logic blocks.
10. storage system as claimed in claim 9, it is characterised in that the memory cell includes storage headspace and use Family space;
SLC mode logic blocks are stored in storage headspace, and MLC mode logic blocks are stored in user's space;Or
SLC mode logic blocks are stored in certain customers space, and MLC mode logic blocks are stored in storage headspace and remainder User's space;Or
SLC mode logic blocks are stored in storage headspace and certain customers space, and MLC mode logic blocks are stored in remainder User's space.
11. storage system as claimed in claim 10, it is characterised in that certain customers space is stored in the memory cell The quantity of SLC mode logic blocks be not more than the user's space SLC mode logic block maximum quantities of setting.
12. storage system as claimed in claim 10, it is characterised in that remainder user's space in the memory cell The quantity of MLC mode logic blocks is not more than the maximum quantity of user's space logical block.
13. storage system as claimed in claim 9, it is characterised in that the processing unit specifically for:
When the quantity of the SLC mode logic blocks of non-data storage is less than the SLC mode logic numbers of blocks of the non-data storage of setting During the lower limit of scope, or ought non-data storage MLC mode logic blocks quantity be less than setting non-data storage MLC moulds During the lower limit of formula logical block quantitative range, or ought non-data storage SLC mode logic blocks quantity be less than setting not depositing Store up data SLC mode logic number of blocks scopes lower limit, and the MLC mode logic blocks of non-data storage quantity be less than set During the lower limit of the MLC mode logic number of blocks scopes of fixed non-data storage, it is less than frequency is wiped in SLC mode logic blocks The data of the corresponding erasing lower-frequency limit value of frequency level are wiped, the data for needing to migrate in SLC mode logic blocks are used as.
14. the storage system as described in claim 12 or 13, it is characterised in that the processing unit is additionally operable to:
If migrating the data into the MLC mode logic blocks of non-data storage, the migration number of times in the time span of setting is big In the migration frequency threshold value of setting, judge that the migration number of times in the time span of setting is more than the migration frequency threshold value of setting Whether the quantity of the data of MLC mode logic blocks is more than the amount threshold of setting;If being more than, the SLC of non-data storage is turned down The lower limit of mode logic number of blocks scope, otherwise, improves the erasing frequency level of data in the MLC mode logics block;Or
If being more than, the lower limit of the MLC mode logic number of blocks scopes of non-data storage is turned down;Otherwise the MLC moulds are improved The erasing frequency level of data in formula logical block;Or
If being more than, the lower limit of the SLC mode logic number of blocks scopes of non-data storage is turned down, and non-data storage The lower limit of MLC mode logic number of blocks scopes;Otherwise, the erasing frequency level of data in the MLC mode logics block is improved.
15. the storage system as described in claim 9 or 12, it is characterised in that the processing unit specifically for:
If migrating the data into the SLC mode logic blocks of non-data storage, the migration number of times in the time span of setting is big In the migration frequency threshold value of setting, judge that the migration number of times in the time span of setting is more than the migration frequency threshold value of setting Whether the quantity of the data of SLC mode logic blocks is more than the amount threshold of setting;If being more than, the SLC of non-data storage is turned down The lower limit of mode logic number of blocks scope, otherwise improves the erasing frequency level of data in the SLC mode logics block;Or
If being more than, the lower limit of the MLC mode logic number of blocks scopes of non-data storage is turned down;Otherwise the SLC moulds are improved The erasing frequency level of data in formula logical block;Or
If being more than, the lower limit of the SLC mode logic number of blocks scopes of non-data storage is turned down, and non-data storage The lower limit of MLC mode logic number of blocks scopes, otherwise improves the erasing frequency level of data in the SLC mode logics block.
16. storage system as claimed in claim 9, it is characterised in that the processing unit is additionally operable to:
Determine that the quantity of the SLC mode logic blocks of current non-data storage in memory cell is more than the non-data storage of setting The higher limit of the minimum number scope of SLC mode logic blocks, determines to need the data of migration in MLC mode logic blocks;Or
Determine that the quantity of the MLC mode logic blocks of current non-data storage in memory cell is more than the non-data storage of setting After the higher limit of the minimum number scope of MLC mode logic blocks, determine to need the data of migration in MLC mode logic blocks;Or
Determine that the quantity of the SLC mode logic blocks of current non-data storage in memory cell is more than the non-data storage of setting The higher limit of the minimum number scope of SLC mode logic blocks, and currently the quantity of the MLC mode logic blocks of non-data storage is more than After the higher limit of the minimum number scope of the MLC mode logic blocks of the non-data storage of setting, determine to need in MLC mode logic blocks The data to be migrated.
17. storage system as claimed in claim 9, it is characterised in that the processing unit is additionally operable to:
When writing new data, if the quantity of the SLC mode logic blocks of current non-data storage is more than setting not in memory cell The higher limit of the minimum number scope of the SLC mode logic blocks of data storage, writes data into non-data storage in slc mode SLC mode logic blocks;Or
When writing new data, if the quantity of the MLC mode logic blocks of current non-data storage is more than setting not in memory cell The higher limit of the minimum number scope of the MLC mode logic blocks of data storage, writes data into non-data storage in slc mode SLC mode logic blocks;Or
When writing new data, if the quantity of the SLC mode logic blocks of current non-data storage is more than setting not in memory cell The higher limit of the minimum number scope of the SLC mode logic blocks of data storage, and the number of the MLC mode logic blocks of non-data storage Amount is more than the higher limit of the minimum number scope of the MLC mode logic blocks of the non-data storage of setting, in slc mode by data The SLC mode logic blocks of the non-data storage of write-in;
If the quantity of the SLC mode logic blocks of current non-data storage is not more than the non-data storage of setting in memory cell The higher limit of the minimum number scope of SLC mode logic blocks, then write data into the MLC moulds of non-data storage in mlc mode Formula logical block;Or
If the quantity of the MLC mode logic blocks of current non-data storage is not more than the non-data storage of setting in memory cell The higher limit of the minimum number scope of MLC mode logic blocks, then write data into the MLC moulds of non-data storage in mlc mode Formula logical block;Or
If the quantity of the SLC mode logic blocks of current non-data storage is not more than the non-data storage of setting in memory cell The higher limit of the minimum number scope of SLC mode logic blocks, and in memory cell current non-data storage MLC mode logic blocks Quantity be not more than setting non-data storage MLC mode logic blocks minimum number scope higher limit, then in MLC patterns Under write data into the MLC mode logic blocks of non-data storage;
When the data volume of write-in is more than the SLC patterns maximum write-in data volume of setting, writes data into do not deposit in mlc mode Store up the MLC mode logic blocks of data.
18. storage system as claimed in claim 9, it is characterised in that the processing unit is additionally operable to:
When the quantity of SLC mode logic blocks is more than the SLC mode logic block maximum quantities of setting, from the SLC moulds of data storage SLC mode logic blocks are selected in formula logical block;
By in the MLC mode logic blocks of the Data Migration in the SLC mode logic blocks of selection to non-data storage, and by selection SLC mode logic blocks are converted into MLC mode logic blocks.
19. storage system as claimed in claim 18, it is characterised in that the processing unit specifically for:
Frequency will be wiped and be less than the SLC mode logic blocks that highest wipes the corresponding erasing lower-frequency limit value of frequency level, institute is used as State the SLC mode logic blocks of selection.
CN201310336895.1A 2013-08-05 2013-08-05 The storage method and storage system of a kind of memory Active CN104346291B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201310336895.1A CN104346291B (en) 2013-08-05 2013-08-05 The storage method and storage system of a kind of memory
PCT/CN2014/083650 WO2015018305A1 (en) 2013-08-05 2014-08-04 Storage method and storage system of memory

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310336895.1A CN104346291B (en) 2013-08-05 2013-08-05 The storage method and storage system of a kind of memory

Publications (2)

Publication Number Publication Date
CN104346291A CN104346291A (en) 2015-02-11
CN104346291B true CN104346291B (en) 2017-08-01

Family

ID=52460646

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310336895.1A Active CN104346291B (en) 2013-08-05 2013-08-05 The storage method and storage system of a kind of memory

Country Status (2)

Country Link
CN (1) CN104346291B (en)
WO (1) WO2015018305A1 (en)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106959818B (en) * 2016-01-11 2020-03-31 群联电子股份有限公司 Data writing method, memory control circuit unit and memory storage device
CN106502594A (en) * 2016-10-31 2017-03-15 维沃移动通信有限公司 A kind of data processing method and terminal
CN106843762B (en) * 2017-01-17 2019-11-12 深圳忆联信息系统有限公司 The method and solid state hard disk of managing storage area
TWI640867B (en) * 2017-05-02 2018-11-11 慧榮科技股份有限公司 Data storage device and operating method therefor
CN108984109A (en) * 2017-06-05 2018-12-11 宇瞻科技股份有限公司 The control method of access efficiency is promoted on flash memory
CN108572924B (en) * 2018-04-20 2021-10-08 华中科技大学 Request processing method of 3D MLC flash memory device
CN111949199B (en) * 2019-05-16 2024-04-26 兆易创新科技集团股份有限公司 Data writing method and device of storage device and storage device
US10877882B1 (en) 2019-06-19 2020-12-29 Micron Technology, Inc. Garbage collection adapted to user device access
CN110377233B (en) * 2019-07-22 2022-03-29 深圳忆联信息系统有限公司 SSD (solid State disk) reading performance optimization method and device, computer equipment and storage medium
CN114489504B (en) * 2022-01-21 2023-08-08 苏州浪潮智能科技有限公司 SSD data management method and related components

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101211252A (en) * 2006-12-26 2008-07-02 劲永国际股份有限公司 Memorizer memory devices
CN101526923A (en) * 2009-04-02 2009-09-09 成都市华为赛门铁克科技有限公司 Data processing method, device thereof and flash-memory storage system
CN102156738A (en) * 2011-04-13 2011-08-17 成都市华为赛门铁克科技有限公司 Method for processing data blocks, and data block storage equipment and system
US20110246701A1 (en) * 2009-03-24 2011-10-06 Hitachi, Ltd. Storage apparatus and its data control method

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102841931A (en) * 2012-08-03 2012-12-26 中兴通讯股份有限公司 Storage method and storage device of distributive-type file system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101211252A (en) * 2006-12-26 2008-07-02 劲永国际股份有限公司 Memorizer memory devices
US20110246701A1 (en) * 2009-03-24 2011-10-06 Hitachi, Ltd. Storage apparatus and its data control method
CN101526923A (en) * 2009-04-02 2009-09-09 成都市华为赛门铁克科技有限公司 Data processing method, device thereof and flash-memory storage system
CN102156738A (en) * 2011-04-13 2011-08-17 成都市华为赛门铁克科技有限公司 Method for processing data blocks, and data block storage equipment and system

Also Published As

Publication number Publication date
WO2015018305A1 (en) 2015-02-12
CN104346291A (en) 2015-02-11

Similar Documents

Publication Publication Date Title
CN104346291B (en) The storage method and storage system of a kind of memory
WO2021008220A1 (en) Systems and methods for data storage system
US11093385B2 (en) Memory device with dynamic cache management
CN102880556B (en) Wear leveling method and system of Nand Flash
CN103049397B (en) A kind of solid state hard disc inner buffer management method based on phase transition storage and system
CN103678150B (en) Solid state hard disc application method and device
US20110029715A1 (en) Write-erase endurance lifetime of memory storage devices
CN107168654A (en) A kind of isomery memory allocation method and system based on data object temperature
CN104899154B (en) The page management method hosted is mixed based on embedded system
CN111341375B (en) Threshold voltage obtaining method for TLC type NAND Flash
CN109388337A (en) Equipment is stored, and to the method that the utilization rate between multiple solid state drives in storage equipment is balanced
CN109753234A (en) The control method of storage system and nonvolatile memory
CN108509355A (en) A kind of method and apparatus of SLC Cache for SSD
CN101539886A (en) Storage apparatus with a plurality of nonvolatile memory devices
CN110473581A (en) Solid state storage device and its corresponding control methods
CN106856102A (en) A kind of programmed method of Nand Flash
CN114830098A (en) Memory operation considering wear leveling
CN110837477B (en) Storage system loss balancing method and device based on life prediction
CN105988950B (en) Storage management method, memorizer control circuit unit and memory storage apparatus
CN114385092B (en) Erasing method of solid state disk flash memory array and solid state disk main control chip
CN105359116B (en) Buffer, shared cache management method and controller
CN103456354B (en) A kind of method and apparatus of nonvolatile memory difference storage lattice
CN114442946B (en) Physical block management method and solid state disk
CN110580932B (en) Memory cell quality measurement method applied to wear leveling
CN106326135A (en) Method and device for translating data of non-volatile memory NVM

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: 519085 High-tech Zone, Tangjiawan Town, Zhuhai City, Guangdong Province

Patentee after: ACTIONS TECHNOLOGY Co.,Ltd.

Address before: 519085 High-tech Zone, Tangjiawan Town, Zhuhai City, Guangdong Province

Patentee before: ACTIONS (ZHUHAI) TECHNOLOGY Co.,Ltd.