[go: up one dir, main page]

CN103608866A - Data wiping method and device for flash memory - Google Patents

Data wiping method and device for flash memory Download PDF

Info

Publication number
CN103608866A
CN103608866A CN201380000705.7A CN201380000705A CN103608866A CN 103608866 A CN103608866 A CN 103608866A CN 201380000705 A CN201380000705 A CN 201380000705A CN 103608866 A CN103608866 A CN 103608866A
Authority
CN
China
Prior art keywords
data
storage address
division
wipe
wiped
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
Application number
CN201380000705.7A
Other languages
Chinese (zh)
Other versions
CN103608866B (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Publication of CN103608866A publication Critical patent/CN103608866A/en
Application granted granted Critical
Publication of CN103608866B publication Critical patent/CN103608866B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/0652Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket
    • 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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/78Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure storage of data
    • G06F21/79Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure storage of data in semiconductor storage media, e.g. directly-addressable memories
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0619Improving the reliability of storage systems in relation to data integrity, e.g. data losses, bit errors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0679Non-volatile semiconductor memory device, e.g. flash memory, one time programmable memory [OTP]
    • 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/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0888Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches using selective caching, e.g. bypass
    • 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/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0893Caches characterised by their organisation or structure
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1032Reliability improvement, data loss prevention, degraded operation etc
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1052Security improvement
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/20Employing a main memory using a specific memory technology
    • G06F2212/202Non-volatile memory
    • G06F2212/2022Flash memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/20Employing a main memory using a specific memory technology
    • G06F2212/202Non-volatile memory
    • G06F2212/2024Rewritable memory not requiring erasing, e.g. resistive or ferroelectric RAM
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/72Details relating to flash memory management
    • G06F2212/7201Logical to physical mapping or translation of blocks or pages
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/72Details relating to flash memory management
    • G06F2212/7205Cleaning, compaction, garbage collection, erase control
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2221/00Indexing scheme relating to security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F2221/21Indexing scheme relating to G06F21/00 and subgroups addressing additional information or applications relating to security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F2221/2143Clearing memory, e.g. to prevent the data from being stolen
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C16/00Erasable programmable read-only memories
    • G11C16/02Erasable programmable read-only memories electrically programmable
    • G11C16/04Erasable programmable read-only memories electrically programmable using variable threshold transistors, e.g. FAMOS
    • G11C16/0483Erasable programmable read-only memories electrically programmable using variable threshold transistors, e.g. FAMOS comprising cells having several storage transistors connected in series

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Human Computer Interaction (AREA)
  • Software Systems (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本发明公开了一种用于闪存存储器的数据擦除方法及装置。该方法包括:接收数据擦除指令,数据擦除指令指示擦除数据或者所述数据对应的数据部分中的至少一个数据部分;当所述数据擦除指令指示擦除所述数据时,查找记录的所述数据对应的所有数据部分的存放地址,并根据所述查找到的存放地址,擦除所述数据对应的所有数据部分;当所述数据擦除指令指示擦除所述数据对应的数据部分中的至少一个数据部分时,查找记录的所述至少一个数据部分的存放地址,并根据所述查找到的存放地址,擦除所述至少一个数据部分。本发明可用于闪存存储器的实现技术中。

Figure 201380000705

The invention discloses a data erasing method and device for a flash memory. The method includes: receiving a data erasing instruction, the data erasing instruction instructs to erase data or at least one data portion in the data portion corresponding to the data; when the data erasing instruction instructs to erase the data, searching for the record The storage address of all the data parts corresponding to the data, and according to the found storage address, erase all the data parts corresponding to the data; when the data erasing instruction indicates to erase the data corresponding to the data When at least one data part in the part is selected, the storage address of the at least one data part in the record is searched, and the at least one data part is erased according to the found storage address. The present invention can be used in the realization technology of the flash memory.

Figure 201380000705

Description

Data erase method and device for flash memories
Technical field
The present invention relates to technical field of memory, relate in particular to a kind of data erase method for flash memories and device.
Background technology
Flash Memory (flash memories) is a kind of nonvolatile memory, has the advantages that data do not disappear after power-off, therefore, is used widely as external memory storage.
The storage mode of flash memories is different from traditional mechanical storage, for instance, the all or part of data of a file are stored in a storage area of flash memories, when user deposits these data again, for example user has revised these data and has directly preserved, these data of depositing again can't be write in former storage area by flash memories, but are write a new storage area in flash memories by flash memories, and the data on former storage area do not change.So, come outwardly the data that these data have been deposited again by user to substitute, but in fact, even if user has deleted the data of depositing again, data before user deposits again are still present in flash memories, professional and technical personnel still can read these by some technological means or instrument and also be present in the data on flash memories, therefore cannot guarantee that data are not revealed.
In prior art, for realizing the secure erase of the data of storing in flash memories, wipe all data divisions relevant to these data of storing in flash memories, comprise the data before depositing again and deposit again after data, conventionally there are two kinds of modes, mode is a system list item for erasing flash memory storer, reaches the object of data destroying; Another kind of mode is that flash memories is wiped totally, i.e. format totally.Yet, these two kinds of erase mode have weak point, adopt first kind of way can cause flash memories not to be used again, adopt the second way can cause overall loss of data, therefore affected the read-write of other data except the data that needs are wiped of storing in flash memories.
Summary of the invention
The embodiment of the present invention provides a kind of data erase method for flash memories and device, can realize the secure erase of the data that need to wipe, and does not affect the read-write of other data except the data that needs are wiped of storing in flash memories.
A first aspect of the present invention, provides a kind of data erase method for flash memories, and the method comprises:
Receive data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
According to described data erase instruction, wipe and in data division corresponding to described data, need the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
In the possible implementation of the first of first aspect, the storage address of data division comprises LBA (Logical Block Addressing) LBA(Logic Block Address described in each of described record) and data block number BN(Block Number);
Described wiping in data division corresponding to described data needs the data division of wiping to comprise:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped;
According to described established data piece and page, search and wipe the data division that described needs are wiped.
In conjunction with the possible implementation of the first of first aspect or first aspect, in the possible implementation of the second of first aspect:
At least two data divisions of described data correspondence;
In this case, before the instruction of described reception data erase, described method also comprises:
Write at least two data divisions corresponding to described data, and record write each described in the storage address of data division.
In conjunction with the possible implementation of the second of first aspect, in the third possible implementation of first aspect:
In described flash memories, be provided with mapping table and trace log;
In this case, at least two data divisions that said write data are corresponding, and record write each described in the storage address of data division comprise:
Successively write at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in described trace log;
Described when described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data and comprise:
When described data are wiped in described data erase instruction indication, search the storage address of the described latest data part recording in described mapping table, according to the described storage address finding, wipe described latest data part, and the storage address of searching the described historical data part recording in described trace log, according to the described storage address finding, wipe described historical data part.
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, if the data division that indication is wiped comprises latest data part, search the storage address of the described latest data part recording in described mapping table, according to the described storage address finding, wipe described latest data part, if the data division that indication is wiped comprises historical data part, search the storage address of the described historical data part recording in described trace log, according to the described storage address finding, wipe described historical data part.
In conjunction with the third possible implementation of first aspect, in the 4th kind of possible implementation of first aspect:
At least two data divisions that described priority writes comprise latest data part and in the inferior new data part last time writing of described latest data part;
In this case, described priority writes at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in to described trace log and comprises:
Write new data part described time, in described mapping table, record the storage address of described new data part;
Write described latest data part, the storage address of described new data part of described mapping table record is transferred in described trace log, and in described mapping table, record the storage address of described latest data part.
In conjunction with the third possible implementation of first aspect or the 4th kind of possible implementation of first aspect, in the 5th kind of possible implementation of first aspect, described method also comprises:
Determine that whether the idle storage space of described trace log is lower than storage space threshold value;
If the idle storage space of described definite trace log is lower than described storage space threshold value, according to the storage address recording in described trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in described trace log.
In conjunction with any one implementation in above-mentioned each possible implementation of first aspect or first aspect, in the 6th kind of possible implementation of first aspect, wiping all data divisions corresponding to described data or wiping after described at least one data division, described method also comprises:
Wipe described record described in the storage address of the data division wiped.
In conjunction with any one implementation in above-mentioned each possible implementation of first aspect or first aspect, in the 7th kind of possible implementation of first aspect, described in wipe in data division corresponding to described data and need the data division of wiping to comprise:
Make carbon copies the data division that described needs are wiped;
Wipe the data division after described manifolding.
In conjunction with any one implementation in above-mentioned each possible implementation of first aspect or first aspect, in the 8th kind of possible implementation of first aspect, described method also comprises:
Wipe data division that the junk data of described flash memories storage is corresponding to obtain blank storage space;
Wipe the storage address of the data division that the described junk data of historical record is corresponding.
A second aspect of the present invention, provides a kind of data erasure apparatus for flash memories, and this device comprises:
Receiving element, for receiving data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
Erase unit, for the data erase instruction receiving according to described receiving element, wipes and in data division corresponding to described data, needs the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
In the possible implementation of the first of second aspect, the storage address of data division comprises LBA (Logical Block Addressing) LBA and data block number BN described in each of described record;
Described erase unit specifically for:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped;
According to described established data piece and page, search and wipe the data division that described needs are wiped.
In conjunction with the possible implementation of the first of second aspect or second aspect, in the possible implementation of the second of second aspect:
At least two data divisions of described data correspondence;
Described device also comprises:
Writing unit, for writing at least two data divisions corresponding to described data, and record write each described in the storage address of data division.
In conjunction with the possible implementation of the second of second aspect, in the third possible implementation of second aspect:
In described flash memories, be provided with mapping table and trace log;
In this case, said write unit specifically for:
Successively write at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in described trace log;
And described erase unit specifically for:
When described data are wiped in described data erase instruction indication, search the storage address of the described latest data part recording in described mapping table, according to the described storage address finding, wipe described latest data part, and the storage address of searching the described historical data part recording in described trace log, according to the described storage address finding, wipe described historical data part.
In conjunction with the third possible implementation of second aspect, in the 4th kind of possible implementation of second aspect:
At least two data divisions that said write unit successively writes comprise latest data part and in the inferior new data part last time writing of described latest data part;
In this case, said write unit specifically for:
Write new data part described time, in described mapping table, record the storage address of described new data part;
Write described latest data part, the storage address of described new data part of described mapping table record is transferred in described trace log, and in described mapping table, record the storage address of described latest data part.
In conjunction with the third possible implementation of second aspect or the 4th kind of possible implementation of second aspect, in the 5th kind of possible implementation of second aspect, described device also comprises:
Determining unit, for the idle storage space of determining described trace log whether lower than storage space threshold value;
Described erase unit also for: if the idle storage space of the definite trace log of described determining unit is during lower than described storage space threshold value, according to the storage address of the historical data recording in described trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in described trace log.
In conjunction with any one implementation in above-mentioned each possible implementation of second aspect or second aspect, in the 6th kind of possible implementation of second aspect, described erase unit also for wipe described record described in the storage address of the data division wiped.
In conjunction with any one implementation in above-mentioned each possible implementation of second aspect or second aspect, in the 7th kind of possible implementation of second aspect, described erase unit specifically for:
Make carbon copies the data division that described needs are wiped;
Wipe the data division after described manifolding.
In conjunction with any one implementation in above-mentioned each possible implementation of second aspect or second aspect, in the 8th kind of possible implementation of second aspect, described erase unit also for: wipe data division that the junk data of described flash memories storage is corresponding to obtain blank storage space, and wipe the storage address of the data division that the described junk data of historical record is corresponding.
A third aspect of the present invention, provides the another kind of data erasure apparatus for flash memories, and this device comprises:
Processor, storer, communication interface and bus;
Described processor, described storer and described communication interface are connected by described bus and complete mutual communication;
Described storer is for stores executable programs code;
Described processor moves the program corresponding with described executable program code by reading the executable program code of storing in described storer, for:
Receive data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
According to described data erase instruction, wipe and in data division corresponding to described data, need the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
In the possible implementation of the first of the third aspect, the storage address of data division comprises LBA (Logical Block Addressing) LBA and data block number BN described in each of described processor for recording;
Described processor specifically for:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped;
According to described established data piece and page, search and wipe the data division that described needs are wiped.
In conjunction with the third aspect or the third aspect the possible implementation of the first in, in the possible implementation of the second of the third aspect:
At least two data divisions of described data correspondence;
In this case, described processor specifically for:
Write at least two data divisions corresponding to described data, and record write each described in the storage address of data division.
In conjunction with the possible implementation of the second of the third aspect, in the third possible implementation of the third aspect:
In described flash memories, be provided with mapping table and trace log;
In this case, described processor specifically for:
Successively write at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in described trace log;
When described data are wiped in described data erase instruction indication, search the storage address of the described latest data part recording in described mapping table, according to the described storage address finding, wipe described latest data part, and the storage address of searching the described historical data part recording in described trace log, according to the described storage address finding, wipe described historical data part.
In conjunction with the third possible implementation of the third aspect, in the 4th kind of possible implementation of the third aspect:
At least two data divisions that described processor successively writes comprise latest data part and in the inferior new data part last time writing of described latest data part;
In this case, described processor specifically for:
Write new data part described time, in described mapping table, record the storage address of described new data part;
Write described latest data part, the storage address of described new data part of described mapping table record is transferred in described trace log, and in described mapping table, record the storage address of described latest data part.
In conjunction with the third possible implementation of the third aspect or the 4th kind of possible implementation of the third aspect, in the 5th kind of possible implementation of the third aspect, described processing unit also for:
Determine that whether the idle storage space of described trace log is lower than storage space threshold value;
If the idle storage space of described definite trace log is during lower than described storage space threshold value, according to the storage address of the historical data recording in described trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in described trace log.
In conjunction with the third aspect or or above-mentioned each possible implementation of the third aspect in any one implementation, in the 6th kind of possible implementation of the third aspect, described processor also for:
Wipe described record described in the storage address of the data division wiped.
In conjunction with any one implementation in above-mentioned each possible implementation of the third aspect or the third aspect, in the 7th kind of possible implementation of the third aspect, described processor specifically for:
Make carbon copies the data division that described needs are wiped;
Wipe the data division after described manifolding.
In conjunction with any one implementation in above-mentioned each possible implementation of the third aspect or the third aspect, in the 8th kind of possible implementation of the third aspect, described processor also for:
Wipe data division that the junk data of described flash memories storage is corresponding to obtain blank storage space, and wipe the storage address of the data division that the described junk data of historical record is corresponding.
A fourth aspect of the present invention, a kind of flash memories is provided, in described flash memories, be provided with data erasure apparatus, the data erasure apparatus that any one implementation in the data erasure apparatus that any one implementation in above-mentioned each possible implementation that described data erasure apparatus is second aspect present invention or second aspect provides or above-mentioned each possible implementation of the third aspect or the third aspect provides.
In the possible implementation of the first of fourth aspect, described flash memories comprise following any one:
Solid state hard disc, SM card (Smart Media, smart media card), CF card (Compact Flash, compact flash card), mmc card (Multi Media Card, multimedia memory card), SD card (Secure Digital Memory Card, safe digital card), memory stick (Memory Stick), XD card (XD-Picture Card, XD image card) and micro harddisk.
Method, data erasure apparatus and the flash memories of the data erase for flash memories that the embodiment of the present invention provides, when receiving the laggard row data erase of data erase instruction, according to data erase instruction, search the storage address of record, wipe and in data division corresponding to described data, need the data division wiped.Like this, can find the data division writing according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, realize the secure erase of data, but also can wipe certain or a few data divisions of appointment and not affect the read-write of other data except the data that needs are wiped according to customer requirements.
Accompanying drawing explanation
In order to be illustrated more clearly in the technical scheme of the embodiment of the present invention, below the accompanying drawing of required use during embodiment is described is briefly described, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skills, do not paying under the prerequisite of creative work, can also obtain according to these accompanying drawings other accompanying drawing.
A kind of schematic flow sheet of the data erase method that Fig. 1 provides for the embodiment of the present invention;
The another kind of schematic flow sheet of the data erase method that Fig. 2 provides for the embodiment of the present invention;
A kind of illustrative diagram of the data erase method that Fig. 3 provides for the embodiment of the present invention;
The another kind of schematic flow sheet of the data erase method that Fig. 4 provides for the embodiment of the present invention;
A kind of structural representation of the data erasure apparatus that Fig. 5 provides for the embodiment of the present invention;
The another kind of structural representation of the data erasure apparatus that Fig. 6 provides for the embodiment of the present invention;
The another kind of structural representation of the data erasure apparatus that Fig. 7 provides for the embodiment of the present invention;
The another kind of structural representation of the data erasure apparatus that Fig. 8 provides for the embodiment of the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme of the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only a part of embodiment of the present invention, rather than whole embodiment.Embodiment based in the present invention, all other embodiment that those of ordinary skills obtain under the prerequisite of not making creative work, belong to the scope of protection of the invention.
In order to make those skilled in the art better understand technical scheme of the present invention, first the storage organization of the flash memories relating in the present invention is briefly introduced.
Flash memories is comprised of an internal register and storage matrix conventionally, and storage matrix comprises some (Block), and each piece comprises again some pages (Page), and each page comprises again some bytes (Bytes).Such as, can form a Page with 4224 Bytes, 128 Page form a Block, and 8192 Block form whole flash memories.
Generally, flash memories all be take Page as unit to the read-write of data, that is, the reading and writing data of flash memories is that a Page, a Page carry out, that is less important data of reading a Page, less important data that write a Page.
The method and apparatus that below embodiment of the present invention is provided for to the data erase of flash memories is elaborated.
It should be noted that, in the embodiment of the present invention, " wiping " is similar to " deletion " concept.
The embodiment of the present invention provides a kind of method of data erase, by flash memories, carried out, the data erasure apparatus specifically arranging in flash memories is carried out, wherein, flash memories is connected with main frame, and user operates the data of storing in flash memories by main frame.
As shown in Figure 1, the embodiment of the present invention provides a kind of method of the data erase for flash memories, comprises the steps:
101, receive data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
Preferably, can be that data erasure apparatus receives data erase instruction from main frame HOST.The data erase instruction that main frame sends can designation data erasing apparatus obliterated data or data division corresponding to data at least one data division.
In the embodiment of the present invention, every piece of data is stored in flash memories, in flash memories, in fact corresponding at least one the data division of every piece of data, in the embodiment of the present invention, " corresponding at least one the data division of every piece of data " refers to, while not depositing through any answering when a piece of data is initially stored in flash memories, now, this piece of data is corresponding a data division, the i.e. raw data of this piece of data only; And known according to the description of background technology above, when this piece of data is once deposited again, for example user has carried out revising and directly preserving to the raw data of this piece of data, flash memory server is by when retaining raw data, this piece of data after memory modify, in this case, corresponding two data divisions of this piece of data, one is the raw data of original stored, and one is these amended data of depositing again.By that analogy, often once deposit again, data division corresponding to this piece of data will increase by one.That is to say, in the embodiment of the present invention, data division corresponding to every piece of data comprises the raw data of this piece of data and the data of at every turn depositing again.
It should be noted that, in the embodiment of the present invention, " depositing again " means and repeats to preserve and not separately deposit, and deposits again and represents that user view is with the data cover of this preservation file before., after depositing again, for user, the file that the original before depositing again has been deposited again substitutes, and is sightless.
In the embodiment of the present invention, when carrying out the wiping of this piece of data, user issues data delete instruction by main frame to flash memories, this data erase instruction can be indicated and be wiped this piece of data, wipe all data divisions corresponding to this piece of data, also can indicate certain or some data division of wiping in data division corresponding to this piece of data.
102,, according to described data erase instruction, wipe and in data division corresponding to described data, need the data division wiped;
Optionally, when described data are wiped in data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
Optionally, when at least one data division in data division corresponding to described data is wiped in data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
In the embodiment of the present invention, when data store flash memories into, it is fashionable to be that data are write, recorded the storage address of each data division corresponding to this data, for example, the storage address of each data division of flash memories record can comprise LBA (Logical Block Addressing) (Logic Block Address is called for short LBA) and data block number (Block Number is called for short BN).Here it should be noted that, the LBA recording also can be registered as LBN(Logic Block Number, logical block number (LBN)), the meaning of LBA and LBN is identical, is all logical address, and the storage size just characterizing is different.Wherein, LBA and physical block address (Physics Block Address is called for short PBA) exist corresponding relation, and PBA is the physical location at flash memories for record data, and which Page is data be recorded in.The in the situation that of known LBA, i.e. PBA corresponding to known LBA, thus by PBA, find data.
Concrete, if the storage address of record comprises LBA and BN, flash memories will be determined the data block that needs the data division wiped in flash memories according to BN, according to LBA, specifically according to the mapping relations of LBA and PBA, determine the data division that need to wipe in which page, thereby find the data division that need to wipe and wipe.
Therefore, in this step, if this piece of data is wiped in data erase instruction indication, basis is write to the storage address of fashionable record, finding this piece of data corresponding all data divisions executing data wipes, can wipe all data divisions corresponding to this piece of data completely, realize the secure erase of data.And, if at least one data division in data division corresponding to described data is wiped in data erase instruction indication, can find the storage address of this at least one data division, thereby find this at least one data division and wipe, not affecting the read-write of other data of storing in flash memory storage.
The method of the data erase for flash memories that the embodiment of the present invention provides, when receiving the laggard row data erase of data erase instruction, according to data erase instruction, search the storage address of record, wipe and in data division corresponding to described data, need the data division wiped.Like this, can find the data division writing according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, realize the secure erase of data, but also can wipe certain or a few data divisions of appointment and not affect the read-write of other data except the data that needs are wiped according to customer requirements.
The method of the data erase that as shown in Figure 2, a kind of embodiment of the present invention provides comprises the following steps:
S11, the data division that data writing is corresponding, and the storage address of each data division of writing of record.
In this step, at least two data divisions of every piece of data correspondence, that is to say, in this step, the data division writing comprises at least two.
It should be noted that, in the embodiment of the present invention, " corresponding at least one the data division of every piece of data " refers to, while not depositing through any answering when a piece of data is initially stored in flash memories, now, only corresponding a data division, the i.e. raw data of this piece of data of this piece of data; And known according to the description of background technology above, when this piece of data is once deposited again, for example user has carried out revising and directly preserving to the raw data of this piece of data, flash memory server is by when retaining raw data, this piece of data after memory modify, in this case, corresponding two data divisions of this piece of data, one is the raw data of original stored, and one is these amended data of depositing again.By that analogy, often once deposit again, data division corresponding to this piece of data will increase by one.That is to say, in the embodiment of the present invention, data division corresponding to every piece of data comprises the raw data of this piece of data and the data of at every turn depositing again.
It should be noted that, in the embodiment of the present invention, " depositing again " means and repeats to preserve and not separately deposit, and deposits again and represents that user view is with the data cover of this preservation file before., after depositing again, for user, the file that the original before depositing again has been deposited again substitutes, and is sightless.
Therefore, in this step, write data division corresponding to every piece of data, be actually and first write the raw data of this piece of data, then according to the time sequencing of depositing again, successively write the data that this piece of data is deposited at every turn again, certainly, if this piece of data is through any answering and deposit once, in this step, only write the raw data of this piece of data.
It should be noted that, the ablation process of each data division is same as the prior art, is not repeating here.
Unlike the prior art, in this step, often write a data division, the storage address of this data division in flash memories will be recorded, like this can be by the storage address of record, find any one data division writing corresponding to every piece of data, therefore, when carrying out the wiping of data division corresponding to a piece of data, can pass through recorded storage address, find each data division corresponding to this piece of data, can wipe all data divisions corresponding to this piece of data completely, realize the secure erase of data, but also can wipe certain or a few data divisions of this piece of data and not affect the read-write of other data of storing in flash memory storage according to customer requirements.
Particularly, in this step, the storage address of each data division of flash memories record can comprise LBA (Logical Block Addressing) (Logic Block Address is called for short LBA) and data block number (Block Number is called for short BN).Here it should be noted that, the LBA recording also can be registered as LBN(Logic Block Number, logical block number (LBN)), the meaning of LBA and LBN is identical, is all logical address, and the storage size just characterizing is different.
LBA and physical block address (Physics Block Address is called for short PBA) exist corresponding relation, and PBA is the physical location at flash memories for record data, and which Page is data be recorded in.The in the situation that of known LBA, i.e. PBA corresponding to known LBA, thus by PBA, find data.
Illustrate, suppose data division corresponding to data writing A in this step, the record format of data A storage address can be: (LBA (Logical Block Addressing), data block number).Shown in Fig. 2, in this step, first, user issues storage data A to the instruction of flash memories to main frame, and main frame sends to flash memories by the raw data of data A, and issue write order to flash memories, flash memories is raw data n corresponding to data writing A, and the storage address that has recorded this data division n is (LBAn, BlockN), wherein, n represents the raw data part that data A is corresponding.Next user revises and has been stored in again the data n on flash memories, the data of here user being modified to n and depositing are again called n ', storage principle according to flash memories, flash memories is retaining under the prerequisite that n is constant, n ' is write on the storage area different with n, and the storage address that has recorded this data division n ' upgrading for (LBAn ', BlockM), wherein, n ' represents latest data part corresponding to data A.Be understandable that, although n is still present in flash memories, for user, data n is substituted by n '.Next, user revises and has been stored in again the data n on flash memories ', the data of here user being modified to n ' and depositing are again called n "; and recorded this data division n " storage address for (LBAn "; BlockA); at this moment, n " substituted n ' and become the latest data part that data A is corresponding.Now, be understandable that, although n ' be still present in flash memories, for user, data n ' by n " substitute.It should be noted that, use LBAn here, LBAn ', LBAn " be intended to represent three data division n, n ', the n of record respectively " corresponding LBA (Logical Block Addressing), but LBAn in fact, LBAn ', LBAn " be same value.
That is to say, corresponding three data divisions of data A, are respectively n, n ', n ", in this step, successively write these three data divisions corresponding to data A and also recorded respectively the storage address of these three data divisions.Wherein, n " last i.e. the last writing, can be referred to as the latest data part that data A is corresponding, and data n, n ' are at n " write before, can be referred to as the historical data part that data A is corresponding.Certainly corresponding how many data divisions of every piece of data no matter, the last i.e. the last data division writing is latest data part corresponding to this piece of data, and the data division writing before latest data part is historical data part.For user, historical data is partly sightless, and historical data part has been substituted by latest data part, but historical data part is also present in flash memories.
Be understandable that, in above-mentioned example, the recording mode of storage address is only example, and the present invention is not done to any restriction, and those skilled in the art can select the recording mode of multiple storage address.And, for the ease of understanding, in example, each data division of data A is only written in a Page of a Block, but is understandable that, in fact, each data division of data A can be written in a plurality of Page, even in a plurality of Page in a plurality of Block, in this case, when recording storage address, by the situation that writes according to data division, each data division can be according to a plurality of addresses of certain journal.
It should be noted that, for recording the storage space of the storage address of each data division writing, can distribute at the storage space of flash memories, also can in the external non-volatile media of flash memories, distribute, be not construed as limiting in the present invention.
S12, receives data erase instruction, and at least one data division in described data or data division corresponding to described data is wiped in this data erase instruction indication.
In this step, when user needs certain piece of data on erasing flash memory storer, will to flash memories, send erasing instruction by main frame, so that flash memories is wiped this piece of data.The data erase instruction that main frame sends to flash memories can be indicated and be wiped certain piece of data, also can indicate certain or a few the data divisions wiped in data division corresponding to these data.In the embodiment of the present invention, when certain piece of data is wiped in the data erase instruction indication that main frame sends to flash memories, expression need to be wiped all data divisions corresponding to these data, in the embodiment of the present invention, the data erase instruction of this indication being wiped to all data divisions corresponding to these data is called secure erase instruction.
Concrete, user sends erasing instruction by main frame to flash memories, for example, the secure data erasure instruction issuing by main frame can comprise LBA and data length, this data length is data length corresponding to latest data part, like this, flash memories is according to LBA and data length, all data divisions that to determine data division that the needs of main frame indication wipe be this piece of data.If the erasing instruction that data erase instruction is certain or a few data divisions in data division corresponding to indication obliterated data (at this moment, can be called non-security erasing instruction) time, the secure data erasure instruction issuing by main frame can comprise that LBA, data length and data division identify, the length that wherein data length is the data division that need to wipe, main frame illustrates its indicated data division of wiping by data division label table.Also may be according to LBA and data length, determine data division that the needs of main frame indication wipe and be many piece of data (such as, be greater than 2) data division, at this time the data division of each data is wiped respectively.Certainly, above data security erase instruction is only example, and those skilled in the art can select or change.
S13, according to the storage address of data erase instruction and record, wipes and in the data division of said write, needs the data division wiped.
If the data erase instruction that S12 step receives is secure erase instruction, in this step, flash memories, by according to the storage address of record, finds all data divisions corresponding to these data and all data divisions is all wiped, thereby realizes the secure erase of these data.Concrete, first flash memories can read the storage address of latest data part corresponding to these data of record, according to the storage address reading, wipe latest data part, then, according to write time order from back to front, read the storage address of historical data part corresponding to these data of record, and wipe historical data part corresponding to these data according to the storage address reading.Like this, latest data part and the historical data part of these data on flash memories is wiped free of completely, thereby guarantees that these data are not revealed, thereby improves the security of data.
It should be noted that, if certain or a few data divisions in data division corresponding to these data are wiped in data erase instruction indication, so, flash memories will read the storage address of these data divisions of its record, thereby finds these data divisions and these data divisions are wiped.
Same with the example that is exemplified as in S11 step, shown in Fig. 3, if the data erase instruction that S12 step receives indication obliterated data A, in this step, flash memories is by the latest data part n of its recorded data A first " storage address, according to the storage address reading, find n " and wiped, then according to the write time of data division, read the storage address of historical data part n ', according to the storage address reading, find n ' and wiped, next read historical data part n " storage address, according to the storage address reading, find n " and wiped, so far all data divisions corresponding to data A are all wiped, realized the secure erase of data A.
For the security that effectively guarantees to wipe, effectively guarantee that required data of wiping do not have residual can not recovery, flash memories is when carrying out erase operation, can first make carbon copies the data division that these need to be wiped, storage address corresponding to data division that can first wipe as required, the storage area that finds this data division to deposit, carries out at least one data manifolding of taking turns to this region, unrest is wrongly write or write to the data in this region, then wipe the data division in this region after manifolding.Further improve thus the security of data erase.
It should be noted that, the importance of the data division that the number of times of making carbon copies can be wiped by indication decides, for example, data division can be set with safe class, this data division is more important, the secure erase grade of this data division is higher, and when wiping these data, the number of times of required this data division of manifolding is also just more.As for how setting and the safe class of dividing data part, and the corresponding relation between the safe class of specified data and the number of times of required manifolding how, the present invention does not limit.
The storage address of each data division that each data portion time-sharing recording corresponding to method, data writing of the data erase for flash memories that the embodiment of the present invention provides writes, when receiving the laggard row data erase of data erase instruction, according to the storage address of data erase instruction and record, wipe and in the data division writing, need the data division wiped.Like this, due to the storage address of each data division that write each data portion time-sharing recording, therefore, the data division that can find any one to write according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, realize the secure erase of data, but also can wipe certain or a few data divisions of appointment and not affect the read-write of other data according to customer requirements.
Further, in order effectively to improve the utilization ratio of storage space, in one embodiment of the invention, after the data division of needs being wiped in S13 step is wiped, also the storage address of the data division of wiping of its record can be wiped.
Optionally, in order effectively to improve the utilization ratio of storage space, in one embodiment of the invention, the data erase method for flash memories that the embodiment of the present invention provides also can comprise the following steps:
Data division corresponding to the junk data of erasing flash memory memory stores is to obtain blank storage space;
Wipe the storage address of the data division that the junk data of historical record is corresponding.
In flash memories, have the junk data that the operations such as some read-writes due to flash memories produce, for example, conventionally in flash memories, be provided with mapping table (Map Table), if flash memories is carried out write operation, the content recording in mapping table will change, the partial content of its Central Plains record is invalid, thereby becomes junk data.The method providing according to the embodiment of the present invention, writes fashionablely at these junk datas, also can record the storage address of the data division that these junk datas are corresponding.Therefore,, in order to improve the utilization ratio of storage space, flash memories can be regularly or under instruction triggers, carry out the recovery of junk data, wipe junk data with and storage address, thereby obtain blank storage space, carry out his use, effectively improve the utilization ratio of storage space.
In prior art, generally, in flash memories, be provided with mapping table (Map Table), for recording the storage address of latest data part corresponding to each piece of data, when flash memories has been carried out write operation, while having deposited again data division corresponding to a piece of data, the data division that this time write operation writes becomes latest data part corresponding to this piece of data, now in mapping item, can record the storage address of the latest data part that this write operation writes, and in mapping table originally the storage address of the former latest data part of record will lose efficacy.
In order to carry out compatibility with prior art, in one embodiment of the invention, except mapping table is set, in flash memories, mark off a panel region, be set to posting field, in the present invention by this panel region called after trace log (Trace Log).Wherein, mapping table is still brought into play effect of the prior art, and for recording the storage address of latest data part corresponding to every piece of data, and trace log is for recording the storage address of historical data part corresponding to every piece of data.Take previously described data A equally as example, and as shown in Figure 4, the present embodiment comprises:
Step 21, three data division n corresponding to data writing A successively, n ', n ", and record the storage address of these three data divisions.
Wherein, by the latest data part n finally writing " storage address be recorded in mapping table; will be at latest data part n " the historical data part n that writes before, the storage address of n ' is recorded in trace log, wherein, n ' is at n " last time write, can be referred to as time new data part; and n writes the earliest, can be referred to as old data.
Understandable, owing to writing a data division at every turn, this data division writing must be latest data part, therefore, in this step, concrete, when recording storage address, flash memories is recorded in the storage address of this latest data part in mapping table, and when again writing a latest data part, now, the former latest data part last time writing has become inferior new data part (being historical data part), at this moment, flash memories can read time storage address of new data part from mapping table, and be transplanted on and stored in trace log, and in mapping table, record the storage address of the latest data part of this storage, and the storage address of the inferior new data part recording in the mapping table that lost efficacy.
Therefore, concrete, in this step, flash memories is data writing part n first, and in mapping table, record the storage address of n, then, flash memories data writing part n ', in mapping table, record the storage address of n ', and from mapping table, read the storage address of n and be stored in trace log, and the storage address of the n that records in mapping table was lost efficacy, next, flash memories data writing part n ", in mapping table, record n " storage address, and from mapping table, read the storage address of n ' and be stored in trace log, and the storage address of the n ' that records in mapping table was lost efficacy.
Step 22, receives data erase instruction, described data erase instruction indication obliterated data A.
Step 23, according to the storage address of data erase instruction and record, three data division n that obliterated data A is corresponding, n ', n ", thus realize the secure erase of data A.
Concrete, flash memories reads the latest data part n of record from mapping table " storage address; thereby find n " and wiped, flash memories reads the storage address of the inferior new data part n ' of record from trace log, thereby find n ' and wiped, flash memories reads the storage address of the old data n of record from trace log, thereby finds n and wiped.
Be understandable that, when if one or two in three data divisions of A wiped in data erase instruction indication, suppose to indicate and wipe n and n ', flash memories will read the inferior new data part n ' of record and the storage address of old data n from trace log, thereby finds n ' and n and wiped.
Suppose that indication wipes n ' and n "; flash memories will read the latest data part n of record from mapping table " storage address, thereby find n " and wiped, from trace log, read the inferior new data part n ' storage address of record, thereby find n ' and wiped.
Further, limited storage space due to trace log, in order to guarantee the normal operation of flash memories, flash memories can be at obliterated data part n, n ', n " afterwards, by the data division n being recorded in trace log; the storage address of n ' is wiped, thereby provide enough storage spaces for trace log.
In addition, optionally, can set storage space threshold value for the storage space of trace log, if the idle storage space of trace log is during lower than described storage space threshold value, that is,, when the idle storage space of trace log is not enough, flash memories can be according to the storage address of the historical data part recording in described trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in described trace log.
Be understandable that, in trace log, recorded the storage address of historical data part corresponding to a lot of piece of data, although historical data part is also present in flash memories, but for user, historical data part has been useless capped data, therefore, flash memory server can force to reclaim whole or part historical data part, after reclaiming historical data part, discharge the storage space of the storage address of the historical data part that records described recovery in described trace log, thereby guarantee that trace log has enough storage spaces.
It should be noted that, in the embodiment of the present invention, during memory space inadequate in flash memories, in flash memories, need the data in the not high data block of utilization factor to wipe to reclaim blank data block completely, reach the object of the storage space that discharges flash memories, wherein, the data block that utilization factor is not high refers to, historical data part is more and data block that latest data part is less, for user, historical data part in this data block is more and latest data part is less means, invalid data in this data block is more and valid data are less, therefore the utilization factor of this data block is lower.Therefore during the memory space inadequate in flash memories, latest data in the not high data block of utilization factor partly can be transferred to other data blocks, it is invalid data entirely that the data block that this utilization factor is not high becomes, be that utilization factor is zero complete dirty, now this data block is wiped completely, to reclaim this data block, and then the storage space of release flash memories.Now, the described storage address of having wiped the data division in complete dirty recording in trace log is insignificant, therefore can delete the storage address of the data division of having wiped described in trace log.
The method of the data erase for flash memories provided by the invention, the storage address of each data division that each data portion time-sharing recording that data writing is corresponding writes, when receiving the laggard row data erase of data erase instruction, according to the storage address of data erase instruction and record, wipe and in the data division writing, need the data division wiped.Like this, due to the storage address of each data division that write each data portion time-sharing recording, the data division that can find any one to write according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, realize the secure erase of data, but also can wipe certain or a few data divisions of appointment and not affect the read-write of other data according to customer requirements.
Accordingly, the embodiment of the present invention also provides a kind of data erasure apparatus 30 for flash memories, and as shown in Figure 5, this device 30 comprises:
Receiving element 31, for receiving data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
Erase unit 32, for the data erase instruction receiving according to receiving element 31, wipes and in data division corresponding to described data, needs the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
The device 30 of the data erase for flash memories that the embodiment of the present invention provides, when receiving the laggard row data erase of data erase instruction, according to data erase instruction, search the storage address of record, wipe and in data division corresponding to described data, need the data division wiped.Like this, can find the data division writing according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, realize the secure erase of data, but also can wipe certain or a few data divisions of appointment and not affect the read-write of other data except the data that needs are wiped according to customer requirements.
The embodiment of the present invention can be for carrying out said method embodiment, the description of reference method embodiment in detail.
The embodiment of the present invention also provides a kind of data erasure apparatus 20 for flash memories, and as shown in Figure 6, this device 20 comprises:
Writing unit 201, at least one data division corresponding to data writing, and the storage address of each data division of writing of record;
Receiving element 202, for receiving data erase instruction, at least one data division in the data division that writing unit 201 writes is wiped in this data erase instruction indication;
Erase unit 203, for according to the data erase instruction of receiving element 202 receptions and the storage address of record, wipes the data division that this data erase instruction indication is wiped.
The device 20 of the data erase for flash memories that the embodiment of the present invention provides, the data erase instruction that the storage address of each data division writing according to each data portion time-sharing recording corresponding to writing unit 201 data writings and receiving element 202 receives, erase unit 203 is wiped needs the data division wiped in the data division that writing unit 201 writes.Like this, due to the storage address of each data division that write each data portion time-sharing recording, the data division that therefore can find any one to write according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, realize the secure erase of data, but also can wipe certain or a few data divisions of appointment and not affect the read-write of other data according to customer requirements.
Optionally, in one embodiment of the invention, the storage address of each data division of writing unit 201 records comprises LBA and BN;
Erase unit 203 specifically for:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped; According to described established data piece and page, search and wipe the data division that described needs are wiped.
For the security that effectively guarantees to wipe, effectively guarantee that required data of wiping do not have residual can not recovery, erase unit 203 is when carrying out erase operation, can first make carbon copies the data division that these need to be wiped, be storage address corresponding to data division that erase unit 203 can first be wiped as required, the storage area that finds this data division to deposit, at least one data manifolding of taking turns is carried out in this this region, unrest is wrongly write or write to the data in this region, wipe again the data division in this region after manifolding, further improve thus the security of data erase.
Optionally, in order effectively to improve the utilization ratio of storage space, in one embodiment of the invention, erase unit 203 is also for wiping the storage address of the data division of wiping of writing unit 201 records.
Further, in one embodiment of the invention, erase unit 203 also for data division corresponding to the junk data of erasing flash memory memory stores to obtain blank storage space, and wipe the storage address of the data division that the junk data of historical record is corresponding.
Optionally, in one embodiment of the invention, at least two data divisions of described data correspondence;
In this case, writing unit 201 specifically for:
Write at least two data divisions corresponding to described data, and record the corresponding storage address of latest data part and the storage address of the historical data part that latest data part writes before of data finally writing;
And erase unit 203 specifically for:
If data erase instruction indication obliterated data, read the storage address of the latest data part of record, according to the described storage address reading, wipe described latest data part, and the storage address that reads the described historical data part of record, according to the described storage address reading, wipe described historical data part;
Or
If one or several data division in data division corresponding to obliterated data is indicated in data erase instruction, read the storage address of one or several data division of record, according to the described storage address reading, wipe described one or several data division.
Optionally, in one embodiment of the invention:
Writing unit 201 writes at least two data divisions;
In data erasure apparatus 20, be provided with mapping table and trace log, wherein, mapping table is for recording the storage address of latest data part corresponding to every piece of data, and trace log is for recording the storage address of historical data part corresponding to every piece of data.
In this case, writing unit 201 specifically for:
Successively write at least two data divisions corresponding to these data, the storage address of latest data corresponding to these data that finally write part is recorded in mapping table, the storage address of the historical data part writing before latest data part is recorded in trace log.
Erase unit 203 specifically for:
If described data are wiped in described data erase instruction indication, read the storage address of the described latest data part recording in described mapping table, according to the described storage address reading, wipe described latest data part, and the storage address that reads the described historical data part recording in described trace log, according to the described storage address reading, wipe described historical data part.
Further, in one embodiment of the invention, at least two data divisions that successively write comprise latest data part and in the inferior new data part last time writing of latest data part.
In this case, writing unit 201 specifically for:
Write time new data part, the storage address of record time new data part in mapping table;
Write latest data part, the storage address of the inferior new data part of mapping table record is transferred in trace log, and in mapping table, records the storage address of latest data part.
Further, in one embodiment of the invention, as shown in Figure 7, this device 20 also comprises:
Determining unit 204, for the idle storage space of determining trace log whether lower than storage space threshold value;
Erase unit 203 also for: if the idle storage space of the definite trace log of determining unit 204 is during lower than storage space threshold value, according to the storage address of the historical data recording in trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in trace log.
It should be noted that, the concrete function of each structural unit of the data erasure apparatus 20 that the embodiment of the present invention provides refers to embodiment of the method above.
Figure 8 shows that the another kind of embodiment of data erasure apparatus provided by the invention, as shown in Figure 8, the data erasure apparatus 40 that the present embodiment provides, comprises processor 401, storer 402, communication interface 403 and bus 404.Processor 401, storer 402 and communication interface 403 are connected by bus 404 and complete mutual communication.Described bus 404 can be industry standard architecture (Industry Standard Architecture, referred to as ISA) bus, peripheral component interconnect (Peripheral Component, referred to as PCI) bus or extended industry-standard architecture (Extended Industry Standard Architecture, referred to as EISA) bus etc.Described bus 404 can be divided into address bus, data bus, control bus etc.For ease of representing, in Figure 10, only with a thick line, represent, but do not represent only to have the bus of a bus or a type.Wherein:
Storer 402 is for stores executable programs code, and this program code comprises computer-managed instruction.Storer 402 may comprise high-speed RAM storer, also may also comprise nonvolatile memory (non-volatile memory), for example at least one magnetic disk memory.
Processor 401 moves the program corresponding with described executable program code by the executable program code of storage in read memory 402, for:
Receive data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
According to described data erase instruction, wipe and in data division corresponding to described data, need the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
In one embodiment of the invention, processor 401 for:
The data division that data writing is corresponding, corresponding at least one the data division of data, and the storage address of each data division of writing of record;
Receive data erase instruction, at least one data division in data division corresponding to data erase instruction indication obliterated data or data;
According to the storage address of data erase instruction and record, wipe and in the data division writing, need the data division wiped.
The device of the data erase for flash memories that the embodiment of the present invention provides, processor 401 storage address of each data division and the data erase instruction of reception that according to data writing, time record writes, wipe in the data division writing, need to wipe the data division wiped of data division data erase instruction indication.Like this, the data division that can find any one to write according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, the secure erase that realizes data that is to say, data erasure apparatus 40 not only can be realized the secure erase of data, and can according to customer requirements, wipe the data division of appointment, does not also affect the read-write of other data after wiping specific data.
Optionally, in one embodiment of the invention, the storage address of each data division of processor 401 records comprises logical block number (LBN) LBA and data block number BN;
Described processor specifically for:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped;
According to described established data piece and page, search and wipe the data division that described needs are wiped.
Optionally, in one embodiment of the invention, processor 401 also for:
Wipe the storage address of the data division of wiping of record.
Optionally, in one embodiment of the invention, processor 401 also for:
In the data division of manifolding said write, need the data division of wiping;
Wipe the data division after described manifolding.
Optionally, in order effectively to improve the utilization ratio of storage space, in one embodiment of the invention, processor 401 also for:
Data division corresponding to the junk data of erasing flash memory memory stores to be to obtain blank storage space, and wipe the storage address of the data division that the junk data of historical record is corresponding.
Optionally, in one embodiment of the invention, at least two data divisions of data correspondence;
Processor 401 specifically for:
Write at least two data divisions corresponding to described data, and record the corresponding storage address of latest data part and the storage address of the historical data part that latest data part writes before of data finally writing;
In this case, processor 401 specifically for:
If data erase instruction indication obliterated data, read the storage address of the latest data part of record, according to the storage address reading, wipe latest data part, and the storage address that reads the historical data part of record, according to the storage address reading, wipe historical data part;
Or
If one or several data division in data division corresponding to obliterated data is indicated in data erase instruction, read the storage address of one or several data division of record, according to the storage address reading, wipe one or several data division.
Optionally, in one embodiment of the invention, at least two data divisions of every piece of data correspondence; In data erasure apparatus 40, be provided with mapping table and trace log.Wherein, mapping table is for recording the storage address of latest data part corresponding to every piece of data, and trace log is for recording the storage address of historical data part corresponding to every piece of data.
In this case, processor 401 specifically for:
At least two data divisions corresponding to priority data writing, the storage address of latest data corresponding to the data that finally write part is recorded in mapping table, the storage address of the historical data part writing before latest data part is recorded in trace log;
When carrying out erase operation, processor 401 specifically for:
If data erase instruction indication obliterated data, read the storage address of the latest data part recording in mapping table, according to the storage address reading, wipe latest data part, and the storage address that reads the historical data part recording in trace log, according to the storage address reading, wipe historical data part.
Further, in one embodiment of the invention, at least two data divisions that successively write comprise latest data part and in the inferior new data part last time writing of latest data part.
In this case, processor 401 specifically for:
Write time new data part, the storage address of record time new data part in mapping table;
Write latest data part, the storage address of the inferior new data part of mapping table record is transferred in trace log, and in mapping table, records the storage address of latest data part.
Optionally, in one embodiment of the invention, processor 401 also for: determine that whether the idle storage space of trace log is lower than storage space threshold value, if the idle storage space of definite trace log is during lower than storage space threshold value, according to the storage address of the historical data recording in trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in trace log.
Wherein, processor 401 may be a central processing unit (Central Processing Unit, referred to as CPU), or specific integrated circuit (Application Specific Integrated Circuit, referred to as ASIC), or be configured to implement one or more integrated circuit of the embodiment of the present invention.
It should be noted that, above-mentioned processor 401, except having above-mentioned functions, also can be used for carrying out other flow processs in said method embodiment, does not repeat them here.
Also it should be noted that, in processor 401, the division of each functional unit can, referring to the embodiment of aforesaid data erasure apparatus, not repeat them here.
Accordingly, the embodiment of the present invention also provides a kind of flash memories, in this flash memories, is provided with data erasure apparatus, and any one data erasure apparatus that described data erasure apparatus can provide for previous embodiment repeats no more herein.
The flash memories that the embodiment of the present invention provides, the storage address of each data division that in the time of can be according to data writing, record writes, and the data erase instruction receiving, wipe in the data division writing, need to wipe data division.Like this, the data division that can find any one to write according to the storage address of each data division, therefore, all data divisions corresponding to obliterated data completely, realize the secure erase of data.That is to say, this flash memories has not only been realized the secure erase of data, and can according to customer requirements, wipe the data division of appointment, does not also affect the read-write of other data after wiping specific data.
Optionally, in one embodiment of the invention, flash memories can be following any one flash memories, but is not limited to following several:
Solid state hard disc, smart media SM card, compact flash CF card, multimedia memory mmc card, safe digital SD card, memory stick, XD card and micro harddisk.
It should be noted that, the data erase method for flash memories that the embodiment of the present invention provides, device and flash memories, the NAND Flash(Sheffer stroke gate flash memory that can be widely used in field of storage) control, the SSD(Solid State Disk that is particularly useful for NAND Flash, solid state hard disc) system, does not limit this present invention.
Each embodiment in this instructions all adopts the mode of going forward one by one to describe, between each embodiment identical similar part mutually referring to, each embodiment stresses is the difference with other embodiment.Especially, for device embodiment, because it is substantially similar in appearance to embodiment of the method, so describe fairly simplely, relevant part is referring to the part explanation of embodiment of the method.
It should be noted that, device embodiment described above is only schematic, the wherein said unit as separating component explanation can or can not be also physically to separate, the parts that show as unit can be or can not be also physical locations, can be positioned at a place, or also can be distributed in a plurality of network element.Can select according to the actual needs some or all of module wherein to realize the object of the present embodiment scheme.In addition, in device embodiment accompanying drawing provided by the invention, the annexation between module represents to have communication connection between them, specifically can be implemented as one or more communication bus or signal wire.Those of ordinary skills, in the situation that not paying creative work, are appreciated that and implement.
Through the above description of the embodiments, those skilled in the art can be well understood to the mode that the present invention can add essential common hardware by software and realize, and can certainly comprise that special IC, dedicated cpu, private memory, special-purpose components and parts etc. realize by specialized hardware.Generally, all functions being completed by computer program can realize with corresponding hardware at an easy rate, and the particular hardware structure that is used for realizing same function can be also diversified, such as mimic channel, digital circuit or special circuit etc.But software program realization is better embodiment under more susceptible for the purpose of the present invention condition.Understanding based on such, the part that technical scheme of the present invention contributes to prior art in essence in other words can embody with the form of software product, this computer software product is stored in the storage medium can read, as the floppy disk of computing machine, USB flash disk, portable hard drive, ROM (read-only memory) (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disc or CD etc., comprise that some instructions are with so that a computer equipment (can be personal computer, server, or the network equipment etc.) method described in each embodiment of execution the present invention.
The above; be only the specific embodiment of the present invention, but protection scope of the present invention is not limited to this, is anyly familiar with those skilled in the art in the technical scope that the present invention discloses; can expect easily changing or replacing, within all should being encompassed in protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection domain of described claim.

Claims (29)

1. for a data erase method for flash memories, it is characterized in that, comprising:
Receive data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
According to described data erase instruction, wipe and in data division corresponding to described data, need the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
2. method according to claim 1, is characterized in that,
Described in each of described record, the storage address of data division comprises LBA (Logical Block Addressing) LBA and data block number BN;
Described wiping in data division corresponding to described data needs the data division of wiping to comprise:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped;
According to described established data piece and page, search and wipe the data division that described needs are wiped.
3. method according to claim 1 and 2, is characterized in that,
At least two data divisions of described data correspondence;
Before the instruction of described reception data erase, described method also comprises:
Write at least two data divisions corresponding to described data, and record write each described in the storage address of data division.
4. method according to claim 3, is characterized in that,
In described flash memories, be provided with mapping table and trace log;
At least two data divisions that said write data are corresponding, and record write each described in the storage address of data division comprise:
Successively write at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in described trace log;
Described when described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data and comprise:
When described data are wiped in described data erase instruction indication, search the storage address of the described latest data part recording in described mapping table, according to the described storage address finding, wipe described latest data part, and the storage address of searching the described historical data part recording in described trace log, according to the described storage address finding, wipe described historical data part.
5. method according to claim 4, is characterized in that,
At least two data divisions that described priority writes comprise latest data part and in the inferior new data part last time writing of described latest data part;
Described priority writes at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in to described trace log and comprises:
Write new data part described time, in described mapping table, record the storage address of described new data part;
Write described latest data part, the storage address of described new data part of described mapping table record is transferred in described trace log, and in described mapping table, record the storage address of described latest data part.
6. according to the method described in claim 4-5 any one, it is characterized in that, described method also comprises:
Determine that whether the idle storage space of described trace log is lower than storage space threshold value;
If the idle storage space of described definite trace log is during lower than described storage space threshold value, according to the storage address of the historical data part recording in described trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in described trace log.
7. according to the method described in claim 1-6 any one, it is characterized in that, wiping all data divisions corresponding to described data or wiping after described at least one data division, described method also comprises:
Wipe described record described in the storage address of the data division wiped.
8. according to the method described in claim 1-7 any one, it is characterized in that, described in wipe in data division corresponding to described data and need the data division of wiping to comprise:
Make carbon copies the data division that described needs are wiped;
Wipe the data division after described manifolding.
9. according to the method described in claim 1-8 any one, it is characterized in that, described method also comprises:
Wipe data division that the junk data of described flash memories storage is corresponding to obtain blank storage space;
Wipe the storage address of the data division that the described junk data of historical record is corresponding.
10. for a data erasure apparatus for flash memories, it is characterized in that, comprising:
Receiving element, for receiving data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
Erase unit, for the data erase instruction receiving according to described receiving element, wipes and in data division corresponding to described data, needs the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
11. devices according to claim 10, is characterized in that,
Described in each of described record, the storage address of data division comprises LBA (Logical Block Addressing) LBA and data block number BN;
Described erase unit specifically for:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped;
According to described established data piece and page, search and wipe the data division that described needs are wiped.
12. according to the device described in claim 10 or 11, it is characterized in that,
At least two data divisions of described data correspondence;
Described device also comprises:
Writing unit, for writing at least two data divisions corresponding to described data, and record write each described in the storage address of data division.
13. devices according to claim 12, is characterized in that,
In described flash memories, be provided with mapping table and trace log;
Said write unit specifically for:
Successively write at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in described trace log;
Described erase unit specifically for:
When described data are wiped in described data erase instruction indication, search the storage address of the described latest data part recording in described mapping table, according to the described storage address finding, wipe described latest data part, and the storage address of searching the described historical data part recording in described trace log, according to the described storage address finding, wipe described historical data part.
14. devices according to claim 13, is characterized in that,
At least two data divisions that said write unit successively writes comprise latest data part and in the inferior new data part last time writing of described latest data part;
Said write unit specifically for:
Write new data part described time, in described mapping table, record the storage address of described new data part;
Write described latest data part, the storage address of described new data part of described mapping table record is transferred in described trace log, and in described mapping table, record the storage address of described latest data part.
15. according to the device described in claim 13-14 any one, it is characterized in that, described device also comprises:
Determining unit, for the idle storage space of determining described trace log whether lower than storage space threshold value;
Described erase unit also for: if the idle storage space of the definite trace log of described determining unit is during lower than described storage space threshold value, according to the storage address of the historical data part recording in described trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in described trace log.
16. according to the device described in claim 10-15 any one, it is characterized in that, described erase unit also for wipe described record described in the storage address of the data division wiped.
17. according to the device described in claim 10-16 any one, it is characterized in that, described erase unit specifically for:
Make carbon copies the data division that described needs are wiped;
Wipe the data division after described manifolding.
18. according to the device described in claim 10-17 any one, it is characterized in that,
Described erase unit is also for wiping data division that the junk data of described flash memories storage is corresponding to obtain blank storage space, and wipes the storage address of the data division that the described junk data of historical record is corresponding.
19. 1 kinds of data erasure apparatus for flash memories, is characterized in that, comprising:
Processor, storer, communication interface and bus;
Described processor, described storer and described communication interface are connected by described bus and complete mutual communication;
Described storer is for stores executable programs code;
Described processor moves the program corresponding with described executable program code by reading the executable program code of storing in described storer, for:
Receive data erase instruction, at least one data division in data division corresponding to described data erase instruction indication obliterated data or described data;
According to described data erase instruction, wipe and in data division corresponding to described data, need the data division wiped, wherein:
When described data are wiped in described data erase instruction indication, search the storage address of all data divisions corresponding to the described data of record, and according to the described storage address finding, wipe all data divisions corresponding to described data;
When at least one data division in data division corresponding to described data is wiped in described data erase instruction indication, search the storage address of described at least one data division of record, and according to the described storage address finding, wipe described at least one data division.
20. devices according to claim 19, is characterized in that,
Described in each of described processor for recording, the storage address of data division comprises LBA (Logical Block Addressing) LBA and data block number BN;
Described processor specifically for:
BN in the storage address of the data division of wiping according to described needs, determine the data block of the data division that the described needs of storage are wiped, LBA in the storage address of the data division of wiping according to described needs, the page of the data division that the described needs of definite storage are wiped;
According to described established data piece and page, search and wipe the data division that described needs are wiped.
21. according to the device described in claim 19 or 20, it is characterized in that,
At least two data divisions of described data correspondence;
Described processor specifically for: write at least two data divisions corresponding to described data, and record write each described in the storage address of data division.
22. devices according to claim 21, is characterized in that,
In described flash memories, be provided with mapping table and trace log;
Described processor specifically for:
Successively write at least two data divisions corresponding to described data, the storage address of latest data corresponding to the described data that finally write part is recorded in described mapping table, the storage address of the historical data part writing before described latest data part is recorded in described trace log;
Described processor specifically for:
When described data are wiped in described data erase instruction indication, search the storage address of the described latest data part recording in described mapping table, according to the described storage address finding, wipe described latest data part, and the storage address of searching the described historical data part recording in described trace log, according to the described storage address finding, wipe described historical data part.
23. devices according to claim 22, is characterized in that,
At least two data divisions that described processor successively writes comprise latest data part and in the inferior new data part last time writing of described latest data part;
Described processor specifically for:
Write new data part described time, in described mapping table, record the storage address of described new data part;
Write described latest data part, the storage address of described new data part of described mapping table record is transferred in described trace log, and in described mapping table, record the storage address of described latest data part.
24. according to the device described in claim 22-23 any one, it is characterized in that, described processor also for:
Determine that whether the idle storage space of described trace log is lower than storage space threshold value;
If the idle storage space of described definite trace log is during lower than described storage space threshold value, according to the storage address of the historical data recording in described trace log, force to reclaim the storage space of historical data part, and discharge the storage space of the storage address of the historical data part that records described recovery in described trace log.
25. according to the device described in claim 19-24 any one, it is characterized in that, described processor also for:
Wipe described record described in the storage address of the data division wiped.
26. according to the device described in claim 19-25 any one, it is characterized in that, described processor specifically for:
Make carbon copies the data division that described needs are wiped;
Wipe the data division after described manifolding.
27. according to the device described in claim 19-26 any one, it is characterized in that, described processor also for:
Wipe data division that the junk data of described flash memories storage is corresponding to obtain blank storage space;
Wipe the storage address of the data division that the described junk data of historical record is corresponding.
28. 1 kinds of flash memories, it is characterized in that, in described flash memories, be provided with data erasure apparatus, described data erasure apparatus is data erasure apparatus described in claim 8 to 16 any one or the data erasure apparatus described in claim 17 to 25 any one.
29. flash memories according to claim 28, is characterized in that,
Described flash memories comprise following any one:
Solid state hard disc, smart media SM card, compact flash CF card, multimedia memory mmc card, safe digital SD card, memory stick, XD card and micro harddisk.
CN201380000705.7A 2013-03-15 2013-03-15 Data method for deleting and device for flash memories Active CN103608866B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2013/072773 WO2014139184A1 (en) 2013-03-15 2013-03-15 Data erasing method and device for flash memory

Publications (2)

Publication Number Publication Date
CN103608866A true CN103608866A (en) 2014-02-26
CN103608866B CN103608866B (en) 2018-09-11

Family

ID=50126071

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201380000705.7A Active CN103608866B (en) 2013-03-15 2013-03-15 Data method for deleting and device for flash memories

Country Status (4)

Country Link
US (2) US9823878B2 (en)
EP (1) EP2955633B1 (en)
CN (1) CN103608866B (en)
WO (1) WO2014139184A1 (en)

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104238961A (en) * 2014-09-11 2014-12-24 北京元心科技有限公司 Method and device for realizing security deletion on flash memory medium
CN104268184A (en) * 2014-09-16 2015-01-07 青岛海信移动通信技术股份有限公司 Mobile terminal file deletion method and terminal
CN104932981A (en) * 2014-03-20 2015-09-23 宏达国际电子股份有限公司 Mobile electronic device and method for clearing storage block
CN105302485A (en) * 2015-10-19 2016-02-03 福州瑞芯微电子股份有限公司 Secure erasure method and apparatus
CN106156660A (en) * 2016-07-27 2016-11-23 浪潮(北京)电子信息产业有限公司 The data destruction method of a kind of storage device and system
CN106681653A (en) * 2016-09-14 2017-05-17 合肥兆芯电子有限公司 Method for memory erasing, memory control circuit unit and memory storage device
US9811458B2 (en) 2014-03-19 2017-11-07 Htc Corporation Mobile electronic device and method for clearing memory blocks based on processor determination of physical block to erase in response to GUI input from user specified time and directing controller to erase within the specified time
CN107402715A (en) * 2016-05-20 2017-11-28 华为终端(东莞)有限公司 Method, apparatus, memory and the terminal of data-moving
CN107506136A (en) * 2017-08-07 2017-12-22 成都华为技术有限公司 A kind of method and apparatus of garbage reclamation
CN107562376A (en) * 2017-08-23 2018-01-09 北京小米移动软件有限公司 Data method for deleting and device
CN107678684A (en) * 2017-08-22 2018-02-09 深圳市硅格半导体股份有限公司 Invalid data sweep-out method, device and the memory of memory
CN109542335A (en) * 2017-09-22 2019-03-29 慧荣科技股份有限公司 Data internal moving method of flash memory and device using the same
TWI688861B (en) * 2018-09-18 2020-03-21 新唐科技股份有限公司 Data processing apparatus and data protection method thereof
CN110908593A (en) * 2018-09-17 2020-03-24 北京兆易创新科技股份有限公司 Storage space erasing method and device, storage equipment and storage medium
CN115101109A (en) * 2022-07-08 2022-09-23 山东华芯半导体有限公司 Enterprise-level SSD (solid State disk) non-secure erase formatting method supporting abnormal power failure

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10261897B2 (en) 2017-01-20 2019-04-16 Samsung Electronics Co., Ltd. Tail latency aware foreground garbage collection algorithm
CN107608906A (en) * 2017-09-26 2018-01-19 北京智芯微电子科技有限公司 The method for reducing in-chip FLASH erasing times
CN109343790B (en) * 2018-08-06 2021-07-13 百富计算机技术(深圳)有限公司 A data storage method, terminal device and storage medium based on NAND FLASH
CN109471598B (en) * 2018-11-16 2021-12-10 深圳市得一微电子有限责任公司 Data deleting method and device of storage equipment and computer readable storage medium

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5341339A (en) * 1992-10-30 1994-08-23 Intel Corporation Method for wear leveling in a flash EEPROM memory
CN1767066A (en) * 2004-10-25 2006-05-03 海力士半导体有限公司 Flash memory system and erase method thereof
CN1831786A (en) * 2005-12-14 2006-09-13 兆日科技(深圳)有限公司 Data completeness protection method of flash storage
CN101465164A (en) * 2009-01-12 2009-06-24 成都市华为赛门铁克科技有限公司 Method, device and system for obliterating data
US20090259808A1 (en) * 2003-03-25 2009-10-15 Sandisk Il Ltd. Methods of Sanitizing a Flash-Based Data Storage Device
CN101673243A (en) * 2009-09-29 2010-03-17 威盛电子股份有限公司 Data storage device and method
CN101923516A (en) * 2009-05-15 2010-12-22 旺宏电子股份有限公司 Block-based flash memory device and method of operation thereof
CN102239480A (en) * 2008-12-17 2011-11-09 Lsi公司 Storage system snapshot assisted by ssd technology

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2915625B2 (en) 1991-06-26 1999-07-05 株式会社沖マイクロデザイン宮崎 Data output circuit
JP2006107326A (en) * 2004-10-08 2006-04-20 Oki Electric Ind Co Ltd Semiconductor integrated circuit
JP2009205335A (en) * 2008-02-27 2009-09-10 Hitachi Ltd Storage system using two kinds of memory devices for cache and method for controlling the storage system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5341339A (en) * 1992-10-30 1994-08-23 Intel Corporation Method for wear leveling in a flash EEPROM memory
US20090259808A1 (en) * 2003-03-25 2009-10-15 Sandisk Il Ltd. Methods of Sanitizing a Flash-Based Data Storage Device
CN1767066A (en) * 2004-10-25 2006-05-03 海力士半导体有限公司 Flash memory system and erase method thereof
CN1831786A (en) * 2005-12-14 2006-09-13 兆日科技(深圳)有限公司 Data completeness protection method of flash storage
CN102239480A (en) * 2008-12-17 2011-11-09 Lsi公司 Storage system snapshot assisted by ssd technology
CN101465164A (en) * 2009-01-12 2009-06-24 成都市华为赛门铁克科技有限公司 Method, device and system for obliterating data
CN101923516A (en) * 2009-05-15 2010-12-22 旺宏电子股份有限公司 Block-based flash memory device and method of operation thereof
CN101673243A (en) * 2009-09-29 2010-03-17 威盛电子股份有限公司 Data storage device and method

Cited By (27)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9811458B2 (en) 2014-03-19 2017-11-07 Htc Corporation Mobile electronic device and method for clearing memory blocks based on processor determination of physical block to erase in response to GUI input from user specified time and directing controller to erase within the specified time
CN104932981A (en) * 2014-03-20 2015-09-23 宏达国际电子股份有限公司 Mobile electronic device and method for clearing storage block
CN104932981B (en) * 2014-03-20 2018-05-25 宏达国际电子股份有限公司 Mobile electronic device and method for cleaning memory block
CN104238961B (en) * 2014-09-11 2018-03-02 北京元心科技有限公司 The method and apparatus that safety deleting is realized on flash media
CN104238961A (en) * 2014-09-11 2014-12-24 北京元心科技有限公司 Method and device for realizing security deletion on flash memory medium
CN104268184A (en) * 2014-09-16 2015-01-07 青岛海信移动通信技术股份有限公司 Mobile terminal file deletion method and terminal
CN104268184B (en) * 2014-09-16 2017-11-21 青岛海信移动通信技术股份有限公司 File delet method and terminal in a kind of mobile terminal
CN105302485B (en) * 2015-10-19 2018-01-26 福州瑞芯微电子股份有限公司 A kind of safe method for deleting and device
CN105302485A (en) * 2015-10-19 2016-02-03 福州瑞芯微电子股份有限公司 Secure erasure method and apparatus
CN107402715A (en) * 2016-05-20 2017-11-28 华为终端(东莞)有限公司 Method, apparatus, memory and the terminal of data-moving
CN107402715B (en) * 2016-05-20 2020-05-08 华为终端有限公司 Data moving method and device, memory and terminal
CN106156660A (en) * 2016-07-27 2016-11-23 浪潮(北京)电子信息产业有限公司 The data destruction method of a kind of storage device and system
CN106681653B (en) * 2016-09-14 2019-10-25 合肥兆芯电子有限公司 Memory erasing method, memorizer control circuit unit and memory storage apparatus
CN106681653A (en) * 2016-09-14 2017-05-17 合肥兆芯电子有限公司 Method for memory erasing, memory control circuit unit and memory storage device
CN107506136B (en) * 2017-08-07 2020-07-07 成都华为技术有限公司 Garbage recycling method and device
CN107506136A (en) * 2017-08-07 2017-12-22 成都华为技术有限公司 A kind of method and apparatus of garbage reclamation
CN107678684A (en) * 2017-08-22 2018-02-09 深圳市硅格半导体股份有限公司 Invalid data sweep-out method, device and the memory of memory
CN107678684B (en) * 2017-08-22 2020-11-10 深圳市硅格半导体有限公司 Invalid data clearing method and device of memory and memory
CN107562376A (en) * 2017-08-23 2018-01-09 北京小米移动软件有限公司 Data method for deleting and device
CN109542335A (en) * 2017-09-22 2019-03-29 慧荣科技股份有限公司 Data internal moving method of flash memory and device using the same
CN109542335B (en) * 2017-09-22 2022-04-01 慧荣科技股份有限公司 Data internal moving method of flash memory and device using the same
CN110908593A (en) * 2018-09-17 2020-03-24 北京兆易创新科技股份有限公司 Storage space erasing method and device, storage equipment and storage medium
CN110908593B (en) * 2018-09-17 2024-02-20 兆易创新科技集团股份有限公司 A storage space erasing method, device, storage device and storage medium
TWI688861B (en) * 2018-09-18 2020-03-21 新唐科技股份有限公司 Data processing apparatus and data protection method thereof
US11455401B2 (en) 2018-09-18 2022-09-27 Nuvoton Technology Corporation Data-processing device and data-protection method thereof
CN115101109A (en) * 2022-07-08 2022-09-23 山东华芯半导体有限公司 Enterprise-level SSD (solid State disk) non-secure erase formatting method supporting abnormal power failure
CN115101109B (en) * 2022-07-08 2024-12-06 山东华芯半导体有限公司 An enterprise-level SSD non-secure erasing and formatting method supporting abnormal power failure

Also Published As

Publication number Publication date
EP2955633B1 (en) 2018-05-23
EP2955633A4 (en) 2016-03-09
CN103608866B (en) 2018-09-11
US10007468B2 (en) 2018-06-26
US20160004474A1 (en) 2016-01-07
US9823878B2 (en) 2017-11-21
US20180018126A1 (en) 2018-01-18
EP2955633A1 (en) 2015-12-16
WO2014139184A1 (en) 2014-09-18

Similar Documents

Publication Publication Date Title
CN103608866A (en) Data wiping method and device for flash memory
EP2115595B1 (en) Memory device performance enhancement through pre-erase mechanism
CN102622309B (en) Data security erase method and device
KR101813786B1 (en) System and method for copy on write on an ssd
CN107391774B (en) Garbage Collection Method for Log File System Based on Data Deduplication
US10120795B2 (en) Wear-leveling nandflash memory reading/writing method
CN104461390A (en) Method and device for writing data into imbricate magnetic recording SMR hard disk
KR20150104434A (en) Method for storing metadata of log-structured file system for flash memory
CN102622310A (en) Invalid data erasing method, device and system
CN111007985B (en) A compatible processing method, system and device for storage system space recovery
CN107102900B (en) Management method of shared memory space
CN110515550B (en) Method and device for separating cold data and hot data of SATA solid state disk
CN107797772A (en) A kind of garbage retrieving system and method based on flash media
US9535796B2 (en) Method, apparatus and computer for data operation
CN112181275B (en) A data processor and a data processing method
CN111625482B (en) Sequential flow detection method and device
CN103257928B (en) Flash memory device data managing method and system
US20160124650A1 (en) Data Storage Device and Flash Memory Control Method
US11436105B2 (en) Data processing method and memory controller utilizing the same
US20210303212A1 (en) Data processing method and memory controller utilizing the same
CN108958657A (en) A kind of date storage method, storage equipment and storage system
CN112416811A (en) Garbage recovery method based on data association degree, flash memory and device
CN107544866B (en) Log updating method and device
JP2008134777A (en) Caching method of file allocation table
CN109753240B (en) Data storage method adopting garbage recovery mechanism

Legal Events

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