Method for writing data into storage equipment

A storage device and data writing technology, applied in the storage field, can solve the problems of storage device damage, unbalanced erasing and writing, and data loss of storage devices, so as to ensure the service life, achieve wear balance, and reduce the number of erasing and writing.

Active Publication Date: 2014-04-02
FEITIAN TECHNOLOGIES
View PDF3 Cites 10 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0002] With the development of science and technology, the market for smart cards continues to expand. In the process of using smart cards, the smart card cannot work normally due to power failure, power loss or power quality not meeting the requirements under unknown circumstances. If the smart card is in During the erasing and writing operation of the storage device (that is, the non-volatile storage area, including EEPROM, FLASH, etc.), the original data in the storage device will be lost, which greatly reduces the security of the smart card
[0003] In addition, when writing data to a storage device, data needs to be erased and written. In the actual process of erasing and writing, a certain page in the storage device is often erased and written frequently, so that the erase and write cannot be balanced. , and the erasing and writing life cycle of the storage device is generally 100,000 times. Due to excessive erasing and writing of some pages, the storage device will be damaged early, which seriously affects the service life of the storage device.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method for writing data into storage equipment
  • Method for writing data into storage equipment
  • Method for writing data into storage equipment

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0067] Embodiment 1 of the present invention provides a method for writing data to a storage device, such as figure 1 shown, including: In this embodiment, the case where the fast swap page is one page and the cache page is also one page is taken as an example to illustrate: when writing the data to be written into the storage device, the following operations are performed:

[0068] Step S1: Calculate the logical page number and intra-page offset of the data to be written according to the logical address of the data to be written;

[0069] Step S2: according to the logical page number of the data to be written, look up the first mapping table, and learn the physical page number of the data to be written;

[0070] In this embodiment, the first mapping table is used to store the correspondence between the physical page number and the logical page number of the data page;

[0071] Step S3: Determine whether there is a cache page corresponding to the physical page number of the d...

Embodiment 2

[0093] Embodiment 2 of the present invention provides a method for writing data to a storage device, such as figure 2 As shown, this embodiment is described with the case that the fast swap page and the cache page are multiple pages: specifically: when writing the data to be written into the storage device, the following operations are performed:

[0094]For example, in this embodiment, the data to be written is AA BB CC, the logical address of the data to be written is 0x65, and the length of the data to be written is 0x03;

[0095] Step 101: Calculate the logical page number and the offset within the page according to the logical address of the data to be written;

[0096] Specifically: dividing the logical address of the data to be written by the size of the page, using the obtained quotient as the logical page number, and using the obtained remainder as the offset within the page, preferably, the size of the page is 0x64;

[0097] For example, in this embodiment, the log...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a method for writing data into storage equipment and belongs to the technical field of storage. The method comprises the step of when data to be written is written to the storage equipment, writing the data to be written into the storage equipment by the processing on a cache area, a fast change area, a first mapping table, a second mapping table and a mark area according to the data to be written, the length of the data to be written and the logic address of the data to be written. The erasing times of the storage equipment are reduced by adopting cache; the data loss during power off is prevented by adopting the mark area; the abrasion balance of the storage equipment in the use process is realized by adopting the fast change area, and the service life of the storage equipment is ensured; the space of the storage equipment is saved by adopting the mode of storing the mapping tables into the cache area.

Description

technical field [0001] The present invention relates to the technical field of storage, and in particular, to a method for writing data to a storage device. Background technique [0002] With the development of science and technology, the market of smart cards continues to expand, and in the process of using smart cards, the smart card cannot work normally due to power failure, power failure or the quality of the electricity does not meet the requirements under unknown circumstances. In the process of erasing and writing the storage device (ie, the non-volatile storage area, including EEPROM, FLASH, etc.), the original data in the storage device will be lost, which greatly reduces the security of the smart card. [0003] In addition, when writing data to the storage device, the data needs to be erased and written. During the actual erasing operation, a certain page in the storage device is frequently erased and written, so that the erasing and writing cannot reach a balance....

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F3/06G06F12/08G06F12/0882G06F12/1009
Inventor 陆舟于华章
Owner FEITIAN TECHNOLOGIES
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products