Memory management method, memory control circuit unit and memory storage apparatus
First Claim
1. A memory management method for a rewritable non-volatile memory module, wherein the rewritable non-volatile memory module having a plurality of physical erasing units, the memory management method comprising:
- recording an erasing count of each of the physical erasing units;
grouping the physical erasing units at least into a spare area and a data area;
determining whether a use count of the rewritable non-volatile memory module is greater than a use count threshold;
if the use count of the rewritable non-volatile memory module is not greater than the use count threshold, sorting each of the physical erasing units in the spare area in an ascending manner according to the erasing count of each of the physical erasing units in the spare area to form a plurality of sorted physical erasing units;
if the use count of the rewritable non-volatile memory module is greater than the use count threshold, sorting each of the physical erasing units in the spare area in the ascending manner according to the number of maximum bit errors of the physical erasing units in the spare area to form the sorted physical erasing units; and
selecting a first physical erasing unit from the spare area to write data according to the sorted physical erasing units, wherein the first physical erasing unit is a foremost physical erasing unit of the sorted physical erasing units.
1 Assignment
0 Petitions
Accused Products
Abstract
A memory management method, a memory control circuit unit using the method, and a memory storage apparatus using the method are provided. The memory management method includes determining whether a use count of the rewritable non-volatile memory module is greater than a use count threshold; based on a result of the determination, sorting each physical erasing unit in a spare area in an ascending manner according to an erasing count of each physical erasing unit in the spare area or according to the number of maximum bit errors of the physical erasing units in the spare area, so as to form a plurality of sorted physical erasing units; and selecting the foremost physical erasing unit from the spare area to write data according to the sorted physical erasing units. By applying the memory management method, the lifespan of the rewritable non-volatile memory module may be effectively prolonged.
14 Citations
21 Claims
-
1. A memory management method for a rewritable non-volatile memory module, wherein the rewritable non-volatile memory module having a plurality of physical erasing units, the memory management method comprising:
-
recording an erasing count of each of the physical erasing units; grouping the physical erasing units at least into a spare area and a data area; determining whether a use count of the rewritable non-volatile memory module is greater than a use count threshold; if the use count of the rewritable non-volatile memory module is not greater than the use count threshold, sorting each of the physical erasing units in the spare area in an ascending manner according to the erasing count of each of the physical erasing units in the spare area to form a plurality of sorted physical erasing units; if the use count of the rewritable non-volatile memory module is greater than the use count threshold, sorting each of the physical erasing units in the spare area in the ascending manner according to the number of maximum bit errors of the physical erasing units in the spare area to form the sorted physical erasing units; and selecting a first physical erasing unit from the spare area to write data according to the sorted physical erasing units, wherein the first physical erasing unit is a foremost physical erasing unit of the sorted physical erasing units. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. A memory control circuit unit for controlling a rewritable non-volatile memory module, the memory control circuit unit comprising:
-
a host interface configured to be coupled to a host system; and a memory interface configured to be coupled to the rewritable non-volatile memory module, wherein the rewritable non-volatile memory module has a plurality of physical erasing units; and a memory management circuit coupled to the host interface and the memory interface and configured to record an erasing count of each of the physical erasing units, wherein the memory management circuit is further configured to group the physical erasing units at least into a spare area and a data area, wherein the memory management circuit is further configured to determine whether a use count of the rewritable non-volatile memory module is greater than a use count threshold, if the use count of the rewritable non-volatile memory module is not greater than the use count threshold, the memory management circuit is further configured to sort each of the physical erasing units in the spare area in an ascending manner according to the erasing count of each of the physical erasing units in the spare area to form a plurality of sorted physical erasing units, and if the use count of the rewritable non-volatile memory module is greater than the use count threshold, the memory management circuit is further configured to sort each of the physical erasing units in the spare area in the ascending manner according to the number of maximum bit errors of the physical erasing units in the spare area to form the sorted physical erasing units, wherein the memory management circuit is further configured to issue a command sequence to the rewritable non-volatile memory module, the command sequence indicates selecting a first physical erasing unit from the spare area to write data according to the sorted physical erasing units, and the first physical erasing unit is a foremost physical erasing unit of the sorted physical erasing units. - View Dependent Claims (9, 10, 11, 12, 13, 14)
-
-
15. A memory storage apparatus comprising:
-
a connection interface unit configured to be coupled to a host system; a rewritable non-volatile memory module having a plurality of physical erasing units; and a memory control circuit unit coupled to the connection interface unit and the rewritable non-volatile memory module and configured to record an erasing count of each of the physical erasing units, wherein the memory control circuit unit is further configured to group the physical erasing units at least into a spare area and a data area, wherein the memory control circuit unit is further configured to determine whether a use count of the rewritable non-volatile memory module is greater than a use count threshold, if the use count of the rewritable non-volatile memory module is not greater than the use count threshold, the memory control circuit unit is further configured to sort each of the physical erasing units in the spare area in an ascending manner according to the erasing count of each of the physical erasing units in the spare area to form a plurality of sorted physical erasing units, and if the use count of the rewritable non-volatile memory module is greater than the use count threshold, the memory control circuit unit is further configured to sort each of the physical erasing units in the spare area in the ascending manner according to the number of maximum bit errors of the physical erasing units in the spare area to form the sorted physical erasing units, wherein the memory control circuit unit is further configured to select a first physical erasing unit from the spare area to write data according to the sorted physical erasing units, and the first physical erasing unit is a foremost physical erasing unit of the sorted physical erasing units. - View Dependent Claims (16, 17, 18, 19, 20, 21)
-
Specification