Data Writing Method and Data Storage Device
First Claim
1. A data writing method for a memory, wherein the memory comprises a data area and a spare area, the data area comprises a plurality of data blocks storing data, and the spare area comprises a plurality of spare blocks having no data stored therein, comprising:
- receiving a write command for writing a write data to a first data block of the memory from a host;
sorting the spare blocks of the spare area according to the erase counts of the spare blocks;
selecting a first spare block with the least erase counts from the spare blocks of the spare area;
writing the write data to the first spare block; and
erasing data from the first data block to convert the first data block to a spare block.
1 Assignment
0 Petitions
Accused Products
Abstract
The invention provides a data writing method for a memory. In one embodiment, the memory comprises a data area and a spare area, the data area comprises a plurality of data blocks storing data, and the spare area comprises a plurality of spare blocks having no data stored therein. First, a write command for writing a write data to a first data block of the memory is received from a host. The spare blocks of the spare area are then sorted according to the erase counts of the spare blocks. A first spare block with the least erase counts is then selected from the spare blocks of the spare area. The write data is then written to the first spare block. Data is then erased from the first data block to convert the first data block to a spare block.
19 Citations
14 Claims
-
1. A data writing method for a memory, wherein the memory comprises a data area and a spare area, the data area comprises a plurality of data blocks storing data, and the spare area comprises a plurality of spare blocks having no data stored therein, comprising:
-
receiving a write command for writing a write data to a first data block of the memory from a host; sorting the spare blocks of the spare area according to the erase counts of the spare blocks; selecting a first spare block with the least erase counts from the spare blocks of the spare area; writing the write data to the first spare block; and erasing data from the first data block to convert the first data block to a spare block. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. A data storage device, comprising:
-
a memory, comprising a data area and a spare area, wherein the data area comprises a plurality of data blocks storing data, and the spare area comprises a plurality of spare blocks having no data stored therein; and a controller, receiving a write command for writing a write data to a first data block of the memory from a host, sorting the spare blocks of the spare area according to the erase counts of the spare blocks, selecting a first spare area, writing the write data to the first spare block, and erasing data from the first data block to convert the first data block to a spare block. - View Dependent Claims (9, 10, 11, 12, 13, 14)
-
Specification