Method of facilitating reliable access of flash memory
First Claim
1. A method of facilitating reliable access of flash memory comprising the steps of:
- (a) determining whether data is to be read out or write in;
(b) if the result of step (a) is to be write-in, coding a number of N write-in data to generate a number of K extra data, generating a first error correction code (ECC) by using an error-correcting operation to the N write-in data and K extra data, and storing the N write-in data and the generated K extra data into a data area of a target flash-memory page and the first ECC into a spare area of the target flash-memory page; and
(c) if the result of step (a) is to be read out, allocating a plurality of counters in a main memory;
(d) each bit in the data area of the target flash-memory page corresponding to a counter for accumulating a number of differences between the first and a second error correction codes (ECCs) associated to the target flash-memory page;
(e) reading data from the data area of the target flash-memory page to generate the second ECC and reading the first ECC from the spare area of the target flash-memory page, counting with the counter a number of bit differences between the first ECC and the second ECC, and selecting a number of M data from the N write-in data and the K extra data as decoding factors to retrieve the N write-in data by using a reverse operation of the original adopted operation of coding in step (b).
1 Assignment
0 Petitions
Accused Products
Abstract
A method of facilitating reliably accessing flash memory is provided. During the write-in process, the present invention utilizes the steps of coding write-in data to generate extra data, and then generating the first error correction code by performing an error-correcting operation on the write-in data and the extra data. Finally, store the N write-in data and the generated K extra data into the data area and the first ECC into the spare area. During read process, the present invention utilizes the steps of reading data from the data area of the target flash-memory page to generate the second ECC, counting with the counter a number of bit differences between the first ECC and the second ECC, and selecting M data from the N write-in data and the K extra data as decoding factors to retrieve the N write-in data. The higher the counter values, the lower the likelihood the corresponding bit is selected to be retrieved.
32 Citations
7 Claims
-
1. A method of facilitating reliable access of flash memory comprising the steps of:
-
(a) determining whether data is to be read out or write in; (b) if the result of step (a) is to be write-in, coding a number of N write-in data to generate a number of K extra data, generating a first error correction code (ECC) by using an error-correcting operation to the N write-in data and K extra data, and storing the N write-in data and the generated K extra data into a data area of a target flash-memory page and the first ECC into a spare area of the target flash-memory page; and (c) if the result of step (a) is to be read out, allocating a plurality of counters in a main memory; (d) each bit in the data area of the target flash-memory page corresponding to a counter for accumulating a number of differences between the first and a second error correction codes (ECCs) associated to the target flash-memory page; (e) reading data from the data area of the target flash-memory page to generate the second ECC and reading the first ECC from the spare area of the target flash-memory page, counting with the counter a number of bit differences between the first ECC and the second ECC, and selecting a number of M data from the N write-in data and the K extra data as decoding factors to retrieve the N write-in data by using a reverse operation of the original adopted operation of coding in step (b). - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
Specification