US20120303879A1 - Memory Device and Method for Programming Flash Memory Utilizing Spare Blocks - Google Patents

Memory Device and Method for Programming Flash Memory Utilizing Spare Blocks Download PDF

Info

Publication number
US20120303879A1
US20120303879A1 US13/524,479 US201213524479A US2012303879A1 US 20120303879 A1 US20120303879 A1 US 20120303879A1 US 201213524479 A US201213524479 A US 201213524479A US 2012303879 A1 US2012303879 A1 US 2012303879A1
Authority
US
United States
Prior art keywords
data
block
spare
memory device
area
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.)
Abandoned
Application number
US13/524,479
Inventor
Wu-Chi Kuo
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.)
Silicon Motion Inc
Original Assignee
Silicon Motion Inc
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 Silicon Motion Inc filed Critical Silicon Motion Inc
Priority to US13/524,479 priority Critical patent/US20120303879A1/en
Assigned to SILICON MOTION, INC. reassignment SILICON MOTION, INC. ASSIGNMENT OF ASSIGNORS INTEREST (SEE DOCUMENT FOR DETAILS). Assignors: KUO, WU-CHI
Publication of US20120303879A1 publication Critical patent/US20120303879A1/en
Abandoned legal-status Critical Current

Links

Images

Classifications

    • 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
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/72Details relating to flash memory management
    • G06F2212/7203Temporary buffering, e.g. using volatile buffer or dedicated buffer blocks
    • 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/7204Capacity control, e.g. partitioning, end-of-life degradation

Definitions

  • the disclosure relates generally to data access methods for memory devices, and, more particularly to data access methods capable of improving access performance of the memory devices.
  • memory devices such as memory cards or USB flash drives with a flash memory
  • a control unit and a flash memory in which the flash memory is used for storing data.
  • the flash memory can be is used in an embedded system, a personal digital assist (PDA), a portable computer, a digital audio player, a digital camera and a mobile phone.
  • PDA personal digital assist
  • the flash memory is one kind of non-volatile memory that can be erased electrically and can be re-programmed, and it is mainly implemented in memory cards or USB flash drives for storing data and transmitting data between computer systems and the digital products.
  • a flash memory may comprise multiple memory blocks and each memory block has multiple storing pages for storing data. Flash memories erase data in one memory block unit and program data in one storing page unit. Further, data can only be programmed to a storing page that does not contain data or an erased storing page. Thus, when data is to be programmed to a specific storing page of a memory block of the flash memory, data contained in the specific storing page must be erased first. And, when data within the flash memory has been erased, all storing pages of that memory block of the flash memory must also be erased at the same time.
  • the control unit needs a waiting time period (e.g. 3 microseconds), to wait for the host to be ready.
  • a waiting time period e.g. 3 microseconds
  • the next data erasing operation may only be performed after the waiting time period is completed, thereby reducing the performance of the memory device.
  • Memory devices and related access methods are provided.
  • an access method for use in a memory device comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks.
  • a spare block is popped from the spare area and the received data is programmed into the popped spare block accordingly.
  • a data block corresponding to the data is pushed to the spare area. The pushed data block is erased when the memory device is waiting for a specific instruction to be issued from the host.
  • An embodiment of a memory device comprises a non-volatile memory and a control unit.
  • the non-volatile memory comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks.
  • the control unit receives data from a host, pops a spare block from the spare area, programs the received data into the popped spare block, pushes a data block corresponding to the received data to the spare area, and erases the pushed data block when the memory device is waiting for a specific instruction to be issued from the host.
  • another access method for use in a memory device comprises a non-volatile memory and the non-volatile memory has a data area having a plurality of data blocks and a spare area having a plurality of spare blocks.
  • the method comprises the following steps. First, data is programmed into a spare block, wherein the spare block is popped from the spare area. Thereafter, a data block corresponding to the data is marked and the marked data block is pushed to the spare area. During a first time period on which the memory device is waiting to receive an instruction, at least one marked data block of the spare area is erased.
  • Access methods for memory devices and memory devices thereof may take the form of a program code embodied in a tangible media.
  • the program code When the program code is loaded into and executed by a machine, the machine becomes an apparatus for practicing the disclosed method.
  • FIG. 1 is a schematic diagram illustrating an embodiment of a computer system of the invention
  • FIG. 2 is a schematic diagram illustrating an embodiment of a flash memory of the invention
  • FIG. 3 is a flowchart of an embodiment of an access method for use in a memory device of the invention
  • FIG. 4 is a flowchart of another embodiment of an access method for use in a memory device of the invention.
  • FIGS. 5A-5D are schematic diagrams illustrating embodiments of data access methods of the invention.
  • FIGS. 1 through 5D generally relates to data access methods for memory devices.
  • FIGS. 1 through 5D generally relates to data access methods for memory devices.
  • FIGS. 1 through 5D generally relates to data access methods for memory devices.
  • FIGS. 1 through 5D generally relates to data access methods for memory devices.
  • FIGS. 1 through 5D generally relates to data access methods for memory devices.
  • FIGS. 1 through 5D generally relates to data access methods for memory devices.
  • FIG. 1 is a schematic diagram illustrating an embodiment of a computer system of the invention.
  • computer system 10 comprises at least one memory device 100 and a host 140 , wherein the memory device 100 receives instructions or data issued from the host 140 or transmits data or messages to the host 140 via a connection interface 130 .
  • the memory device 100 at least comprises a control unit 110 and a non-volatile memory unit such as a flash memory 120 .
  • the non-volatile memory unit may be, for example, a non-volatile NAND-type flash, but it is not limited thereto.
  • the flash memory 120 has a data area 122 and a spare area 124 .
  • the data area comprises M data blocks, DB 1 -DBM, having data stored therein and the spare area comprises N spare blocks, SB 1 -SBN, in which M and N are integers larger than zero and M and N may be set to the same value or may be set to different values.
  • the spare blocks SB 1 -SBN can be directly programmed while the data blocks having data stored therein DB 1 -DBM can only be programmed after they have been erased.
  • FIG. 2 is a schematic diagrams illustrating an embodiment of a flash memory of the invention.
  • the flash memory 200 has a data area 210 and a spare area 220 , wherein the data area 210 comprises 5 data blocks having data stored therein DB 1 -DB 5 and the spare area 220 comprises 4 spare blocks SB 1 -SB 4 .
  • a spare block that is on the top of the spare area 220 i.e. SB 1
  • an area that is under the bottom spare block of the spare area 220 i.e. SB 4
  • a step of popping a spare block from the spare area is performed by popping the top spare block of the spare area while a step of pushing a data block corresponding to the received data to the spare area is performed by pushing the data block to the bottom of the spare area.
  • the erased data block may be re-configured to a spare block to be used as a new spare block.
  • the control unit 110 may perform a computer program or firmware for performing a data access method and controlling data access of the flash memory 120 so as to improve access performance of the memory device 100 .
  • the control unit 110 may receive data from the host 140 and then pop a spare block from the spare area 124 , program the received data into the popped spare block, and thereafter, push a data block corresponding to the received data to the spare area 124 and erase content within the pushed data block when waiting for a specific instruction to be issued from the host 140 .
  • the host 140 may issue or send an instruction related to access/read-write of the memory device such as instructions for reading or writing the flash memory 120 and may issue or send an instruction unrelated to access/read-write of the memory device such as a first instruction Test_unit_ready instruction, a read capacity instruction, read format capacity instruction or the like to the memory device 100 .
  • the first instruction Test_unit_ready is used by the host 140 to test whether the memory device 100 is present in the computer system 10 .
  • the host 140 will issue a Test_unit_ready instruction for testing the memory device 100 .
  • the instructions are used to inspect whether the memory device is ready or to obtain current status of the memory device, which are unrelated to the programming of the flash memory.
  • the specific instruction is an instruction unrelated to access/read-write of the memory device 120 .
  • FIG. 3 is a flowchart of an embodiment of an access method for use in a memory device of the invention.
  • the access method can be stored in a computer program and can be performed by the control unit 110 of the memory device 100 shown in FIG. 1 .
  • the host 140 when the host 140 attempts to program data into the flash memory 120 , it sends data to be programmed to the memory device 120 via an instruction related to access/read-write of the memory device.
  • step S 310 the control unit 110 of the memory device 100 receives data issued from the host 140 .
  • step S 320 the control unit 110 performs a programming procedure to pop a spare block from the spare area 124 so as to program the new data received from the host 140 to the flash memory 120 .
  • the step of popping the spare block from the spare area 124 is performed by popping the top spare block of the spare area 124 .
  • the control unit 110 may pop the top spare block that is on the top of the spare area 220 (i.e. SB 1 ) as a spare block to program (or store) the data.
  • step S 330 the control unit 110 programs the received data to the popped spare block.
  • the control unit 110 will program (write) the data that is from the host and is corresponding to the first data block to the popped spare block.
  • step S 340 the control unit 110 pushes the first data block corresponding to the data to the spare area.
  • the step of pushing the data block to the spare area may be performed by pushing the data block to the bottom of the spare area 124 .
  • step S 350 when the memory device 100 is waiting to receive a specific instruction to be issued from the host 140 , operation for erasing the data blocks will be performed to erase content within the pushed data blocks.
  • the control unit 110 may erase a used block from the spare area and configure the erased data block as a spare block after the data block has been erased.
  • step S 360 when receiving the specific instruction which is issued from the host 140 , the control unit 110 replies by a confirmation signal corresponding to the specific instruction to the host 140 for informing that the memory device 100 is present.
  • the control unit 110 may reply to a confirmation signal corresponding to the check instruction to the host 140 for informing the memory device 100 that the memory device 100 is present.
  • erasing operation of blocks remaining in the spare area and are to be erased can be performed when the control unit 110 is waiting for a specific instruction to be issued from the host, thereby significantly reducing the waiting time period needed and further improve the programming performance of the flash memory.
  • the spare area may comprise more than one data block to be erased and the access method of the invention may also be applied to erase multiple data blocks at one time during a first time period, wherein the memory device waits to receive an instruction during the first time period.
  • FIG. 4 is a flowchart of another embodiment of an access method for use in a memory device of the invention.
  • the access method can be stored in a computer program and can be performed by the control unit 110 of the memory device 100 shown in FIG. 1 .
  • step S 410 when the host 140 attempts to program data into the fish memory 120 , it sends data to be programmed to the memory device 120 via an instruction related to the access/read-write of the memory device so that the control unit 110 of the memory device 100 receives data from the host 140 .
  • step S 420 the control unit 110 performs a programming procedure to pop a spare block from the spare area 124 so as to program the new data received from the host 140 to the flash memory 120 .
  • the step of popping the spare block from the spare area 124 may be performed by popping the top spare block of the spare area 124 , but it is not limited thereto.
  • step S 430 the control unit 110 programs the received data to the popped spare block. Then, in step S 440 , a data block corresponding to the data is marked and the marked data block is pushed to the spare area. For example, the step of pushing the data block to the spare area may be performed by pushing the data block to the bottom of the spare area 124 .
  • step S 440 the control unit 110 programs the data that is from the host and is corresponding to a first data block to the popped spare block and links the physical address of the popped spare block to a first physical address that corresponds to the first data block.
  • step S 450 the memory device 100 is waiting to receive a specific instruction to be issued from the host 140 and in step S 460 , determines whether the specific instruction has been received. It is to be noted that, a time period that the memory device 100 must wait before receiving a specific instruction to be issued from the host 140 , wherein the specific instruction has not been received, is referred to as a waiting cycle.
  • step S 470 is performed such that the control unit 110 will pop a marked block from the spare area 124 to perform a block erasing operation and then step S 460 is repeated to inspect whether the specific instruction has been received. If no specific instruction has been received yet, step S 470 is again performed such that the control unit 110 will pop another marked block from the spare area 124 to perform a block erasing operation. Steps 460 and 170 will be repeated until the specific instruction has been received.
  • step S 480 the control unit 110 replies by a confirmation signal corresponding to the specific instruction to the host 140 for informing the host 140 that the memory device 100 is present.
  • FIGS. 5A to 5D are used for illustrating operational detail of the data access method according to an embodiment of the invention.
  • FIGS. 5A to 5D are schematic diagrams illustrating embodiments of data access methods of the invention.
  • a flash memory 500 has a data area 510 and a spare area 520 , wherein the data area 510 comprises at least 4 data blocks DB 1 -DB 4 and the spare area 520 comprises at least 4 spare blocks SB 1 -SB 4 and a marked block 530 having a mark M for representing that the block is needed to be erased.
  • data blocks DB 1 , DB 3 and DB 4 are used blocks, i.e. each of the data blocks has data stored therein.
  • the control unit 110 When receiving a programming instruction from the host and prepares to program data # 1 to the data block DB 3 , due to the data block DB 3 being a used block, the control unit 110 pops a spare block (e.g. the top spare block SB 1 ) from the spare area 520 and programs the data # 1 to the popped spare block SB 1 . Thereafter, a mark M is added to the original data block DB 3 to represent that the data block DB 3 is a data block needed to be erased and the marked data block is pushed back to the spare area such as pushing the data block to the bottom of the spare area (i.e. an area under the marked block 530 ), as the marked block 540 shown in FIG. 5B . Meanwhile, the control unit may perform a data rearrangement operation to remap the address of the spare block SB 1 and the data block DB 3 .
  • a spare block e.g. the top spare block SB 1
  • a mark M is added to the original data block DB 3 to represent that the data block
  • the control unit After the data rearrangement operation has been completed, the control unit will wait to receive a specific instruction from the host. During a first time period when the memory device is waiting to receive an instruction, the control unit will continually determine whether the specific instruction has been received or not, and if not, pop a marked block from the spare area and erase the popped block. For example, the marked block which is the latest pushed block in the spare area, has a higher priority to be erased, i.e. the marked block nearest to the bottom of the spare area will be erased first, but it is not limited thereto. Thus, the marked block 540 will be erased first and after the marked block 540 has been erased, the block 540 will be re-configured as an available spare block SB for subsequent use, as shown in FIG.
  • the operation of block erasing can be performed during a wait cycle when the memory device is waiting to receive a specific instruction to be issued from the host and when the specific instruction has not be received so that one block or more than one blocks that are marked to be erased can be erased at the same period, thereby erasing not only the data block that was last pushed but also un-erased blocks that should be erased in the spare block. Therefore, waiting time period needed for erasing individual block can be reduced and overall access performance of the memory device can be improved.
  • Systems and method thereof, or certain aspects or portions thereof, may take the form of a program code (i.e., executable instructions) embodied in tangible media, such as floppy diskettes, CD-ROMS, hard drives, or any other machine-readable storage medium, wherein, when the program code is loaded into and executed by a machine, such as a computer, the machine thereby becomes an apparatus for practicing the methods.
  • the methods may also be embodied in the form of a program code transmitted over some transmission medium, such as electrical wiring or cabling, through fiber optics, or via any other form of transmission, wherein, when the program code is received and loaded into and executed by a machine, such as a computer, the machine becomes an apparatus for practicing the disclosed methods.
  • the program code When implemented on a general-purpose processor, the program code combines with the processor to provide a unique apparatus that operates analogously to application specific logic circuits.

Abstract

An access method for use in a memory device. The memory device comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks. First, data from a host is received. A spare block is popped from the spare area and the received data is programmed into the popped spare block accordingly. A data block corresponding to the data is pushed to the spare area. The pushed data block is erased when the memory device is waiting for a specific instruction to be issued from the host.

Description

    CROSS REFERENCE TO RELATED APPLICATIONS
  • This application is a continuation of currently pending U.S. non-provisional utility application Ser. No. 12/404,321, filed Mar. 15, 2009, which in turn claims priority of Taiwan Patent Application No. 097141345, filed on Oct. 28, 2008, the entirety of which is incorporated by reference herein.
  • BACKGROUND OF THE INVENTION
  • 1. Field of the Invention
  • The disclosure relates generally to data access methods for memory devices, and, more particularly to data access methods capable of improving access performance of the memory devices.
  • 2. Description of the Related Art
  • In general, memory devices, such as memory cards or USB flash drives with a flash memory, comprise a control unit and a flash memory in which the flash memory is used for storing data. The flash memory can be is used in an embedded system, a personal digital assist (PDA), a portable computer, a digital audio player, a digital camera and a mobile phone. The flash memory is one kind of non-volatile memory that can be erased electrically and can be re-programmed, and it is mainly implemented in memory cards or USB flash drives for storing data and transmitting data between computer systems and the digital products.
  • A flash memory may comprise multiple memory blocks and each memory block has multiple storing pages for storing data. Flash memories erase data in one memory block unit and program data in one storing page unit. Further, data can only be programmed to a storing page that does not contain data or an erased storing page. Thus, when data is to be programmed to a specific storing page of a memory block of the flash memory, data contained in the specific storing page must be erased first. And, when data within the flash memory has been erased, all storing pages of that memory block of the flash memory must also be erased at the same time.
  • However, each time a data erasing operation of the flash memory is completed, the control unit needs a waiting time period (e.g. 3 microseconds), to wait for the host to be ready. Thus, the next data erasing operation may only be performed after the waiting time period is completed, thereby reducing the performance of the memory device.
  • BRIEF SUMMARY OF THE INVENTION
  • Memory devices and related access methods are provided.
  • In an embodiment, an access method for use in a memory device is provided. The memory device comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks. First, data from a host is received. A spare block is popped from the spare area and the received data is programmed into the popped spare block accordingly. A data block corresponding to the data is pushed to the spare area. The pushed data block is erased when the memory device is waiting for a specific instruction to be issued from the host.
  • An embodiment of a memory device comprises a non-volatile memory and a control unit. The non-volatile memory comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks. The control unit receives data from a host, pops a spare block from the spare area, programs the received data into the popped spare block, pushes a data block corresponding to the received data to the spare area, and erases the pushed data block when the memory device is waiting for a specific instruction to be issued from the host.
  • In an embodiment, another access method for use in a memory device is further provided. The memory device comprises a non-volatile memory and the non-volatile memory has a data area having a plurality of data blocks and a spare area having a plurality of spare blocks. The method comprises the following steps. First, data is programmed into a spare block, wherein the spare block is popped from the spare area. Thereafter, a data block corresponding to the data is marked and the marked data block is pushed to the spare area. During a first time period on which the memory device is waiting to receive an instruction, at least one marked data block of the spare area is erased.
  • Access methods for memory devices and memory devices thereof may take the form of a program code embodied in a tangible media. When the program code is loaded into and executed by a machine, the machine becomes an apparatus for practicing the disclosed method.
  • BRIEF DESCRIPTION OF THE DRAWINGS
  • The invention will become more fully understood by referring to the following detailed description with reference to the accompanying drawings, wherein:
  • FIG. 1 is a schematic diagram illustrating an embodiment of a computer system of the invention;
  • FIG. 2 is a schematic diagram illustrating an embodiment of a flash memory of the invention;
  • FIG. 3 is a flowchart of an embodiment of an access method for use in a memory device of the invention;
  • FIG. 4 is a flowchart of another embodiment of an access method for use in a memory device of the invention; and
  • FIGS. 5A-5D are schematic diagrams illustrating embodiments of data access methods of the invention.
  • DETAILED DESCRIPTION OF THE INVENTION
  • The following description is of the best-contemplated mode of carrying out the invention. This description is made for the purpose of illustrating the general principles of the invention and should not be taken in a limiting sense. The scope of the invention is best determined by reference to the appended claims.
  • The invention is described with reference to FIGS. 1 through 5D, which generally relates to data access methods for memory devices. In the following detailed description, reference is made to the accompanying drawings which from a part hereof, shown by way of illustration of specific embodiments. The embodiments are described in sufficient detail to enable those skilled in the art to practice the invention, and it is to be understood that other embodiments may be utilized and that structural, logical and electrical changes may be made, without departing from the spirit and scope of the invention. The following detailed description is, therefore, not to be taken in a limiting sense. It should be understood that many of the elements described and illustrated throughout the specification are functional in nature and may be embodied in one or more physical entities or may take other forms beyond those described or depicted.
  • FIG. 1 is a schematic diagram illustrating an embodiment of a computer system of the invention. As shown in FIG. 1A, computer system 10 comprises at least one memory device 100 and a host 140, wherein the memory device 100 receives instructions or data issued from the host 140 or transmits data or messages to the host 140 via a connection interface 130. The memory device 100 at least comprises a control unit 110 and a non-volatile memory unit such as a flash memory 120. The non-volatile memory unit may be, for example, a non-volatile NAND-type flash, but it is not limited thereto. The flash memory 120 has a data area 122 and a spare area 124. The data area comprises M data blocks, DB1-DBM, having data stored therein and the spare area comprises N spare blocks, SB1-SBN, in which M and N are integers larger than zero and M and N may be set to the same value or may be set to different values. Moreover, the spare blocks SB1-SBN can be directly programmed while the data blocks having data stored therein DB1-DBM can only be programmed after they have been erased.
  • FIG. 2 is a schematic diagrams illustrating an embodiment of a flash memory of the invention. As shown in FIG. 2, the flash memory 200 has a data area 210 and a spare area 220, wherein the data area 210 comprises 5 data blocks having data stored therein DB1-DB5 and the spare area 220 comprises 4 spare blocks SB1-SB4. As shown, a spare block that is on the top of the spare area 220 (i.e. SB1) is referred to as the top spare block while an area that is under the bottom spare block of the spare area 220 (i.e. SB4) is referred to as the bottom of the spare area 220. In this embodiment, a step of popping a spare block from the spare area is performed by popping the top spare block of the spare area while a step of pushing a data block corresponding to the received data to the spare area is performed by pushing the data block to the bottom of the spare area. After one data block has been erased, the erased data block may be re-configured to a spare block to be used as a new spare block.
  • The control unit 110 may perform a computer program or firmware for performing a data access method and controlling data access of the flash memory 120 so as to improve access performance of the memory device 100. The control unit 110 may receive data from the host 140 and then pop a spare block from the spare area 124, program the received data into the popped spare block, and thereafter, push a data block corresponding to the received data to the spare area 124 and erase content within the pushed data block when waiting for a specific instruction to be issued from the host 140. It is noted that, the host 140 may issue or send an instruction related to access/read-write of the memory device such as instructions for reading or writing the flash memory 120 and may issue or send an instruction unrelated to access/read-write of the memory device such as a first instruction Test_unit_ready instruction, a read capacity instruction, read format capacity instruction or the like to the memory device 100. For example, the first instruction Test_unit_ready is used by the host 140 to test whether the memory device 100 is present in the computer system 10. Typically, after the data to be programmed has been sent for a while, the host 140 will issue a Test_unit_ready instruction for testing the memory device 100. The instructions are used to inspect whether the memory device is ready or to obtain current status of the memory device, which are unrelated to the programming of the flash memory. In this embodiment, the specific instruction is an instruction unrelated to access/read-write of the memory device 120.
  • FIG. 3 is a flowchart of an embodiment of an access method for use in a memory device of the invention. The access method can be stored in a computer program and can be performed by the control unit 110 of the memory device 100 shown in FIG. 1.
  • First, when the host 140 attempts to program data into the flash memory 120, it sends data to be programmed to the memory device 120 via an instruction related to access/read-write of the memory device.
  • In step S310, the control unit 110 of the memory device 100 receives data issued from the host 140.
  • Thereafter, in step S320, the control unit 110 performs a programming procedure to pop a spare block from the spare area 124 so as to program the new data received from the host 140 to the flash memory 120. Note that the step of popping the spare block from the spare area 124 is performed by popping the top spare block of the spare area 124. For example, the control unit 110 may pop the top spare block that is on the top of the spare area 220 (i.e. SB1) as a spare block to program (or store) the data.
  • In step S330, the control unit 110 programs the received data to the popped spare block. In this step, the control unit 110 will program (write) the data that is from the host and is corresponding to the first data block to the popped spare block.
  • In step S340, the control unit 110 pushes the first data block corresponding to the data to the spare area. For example, the step of pushing the data block to the spare area may be performed by pushing the data block to the bottom of the spare area 124.
  • In step S350, when the memory device 100 is waiting to receive a specific instruction to be issued from the host 140, operation for erasing the data blocks will be performed to erase content within the pushed data blocks. In this step, the control unit 110 may erase a used block from the spare area and configure the erased data block as a spare block after the data block has been erased.
  • Next, in step S360, when receiving the specific instruction which is issued from the host 140, the control unit 110 replies by a confirmation signal corresponding to the specific instruction to the host 140 for informing that the memory device 100 is present. For example, if the instruction to be issued from the host 140 is a check instruction, the control unit 110 may reply to a confirmation signal corresponding to the check instruction to the host 140 for informing the memory device 100 that the memory device 100 is present.
  • According the embodiments of the invention, erasing operation of blocks remaining in the spare area and are to be erased can be performed when the control unit 110 is waiting for a specific instruction to be issued from the host, thereby significantly reducing the waiting time period needed and further improve the programming performance of the flash memory.
  • In another embodiment, the spare area may comprise more than one data block to be erased and the access method of the invention may also be applied to erase multiple data blocks at one time during a first time period, wherein the memory device waits to receive an instruction during the first time period.
  • FIG. 4 is a flowchart of another embodiment of an access method for use in a memory device of the invention. The access method can be stored in a computer program and can be performed by the control unit 110 of the memory device 100 shown in FIG. 1.
  • Similarly, in step S410, when the host 140 attempts to program data into the fish memory 120, it sends data to be programmed to the memory device 120 via an instruction related to the access/read-write of the memory device so that the control unit 110 of the memory device 100 receives data from the host 140.
  • Thereafter, in step S420, the control unit 110 performs a programming procedure to pop a spare block from the spare area 124 so as to program the new data received from the host 140 to the flash memory 120. For example, the step of popping the spare block from the spare area 124 may be performed by popping the top spare block of the spare area 124, but it is not limited thereto.
  • In step S430, the control unit 110 programs the received data to the popped spare block. Then, in step S440, a data block corresponding to the data is marked and the marked data block is pushed to the spare area. For example, the step of pushing the data block to the spare area may be performed by pushing the data block to the bottom of the spare area 124.
  • In step S440, the control unit 110 programs the data that is from the host and is corresponding to a first data block to the popped spare block and links the physical address of the popped spare block to a first physical address that corresponds to the first data block.
  • In step S450, the memory device 100 is waiting to receive a specific instruction to be issued from the host 140 and in step S460, determines whether the specific instruction has been received. It is to be noted that, a time period that the memory device 100 must wait before receiving a specific instruction to be issued from the host 140, wherein the specific instruction has not been received, is referred to as a waiting cycle.
  • If no specific instruction (e.g. the Test_unit_ready instruction) has been received in step S460, step S470 is performed such that the control unit 110 will pop a marked block from the spare area 124 to perform a block erasing operation and then step S460 is repeated to inspect whether the specific instruction has been received. If no specific instruction has been received yet, step S470 is again performed such that the control unit 110 will pop another marked block from the spare area 124 to perform a block erasing operation. Steps 460 and 170 will be repeated until the specific instruction has been received. When receiving the specific instruction which is issued from the host 140 (Yes in step S460), in step S480, the control unit 110 replies by a confirmation signal corresponding to the specific instruction to the host 140 for informing the host 140 that the memory device 100 is present.
  • For example, please refer to FIGS. 5A to 5D which are used for illustrating operational detail of the data access method according to an embodiment of the invention.
  • FIGS. 5A to 5D are schematic diagrams illustrating embodiments of data access methods of the invention. As shown in FIG. 5A, a flash memory 500 has a data area 510 and a spare area 520, wherein the data area 510 comprises at least 4 data blocks DB1-DB4 and the spare area 520 comprises at least 4 spare blocks SB1-SB4 and a marked block 530 having a mark M for representing that the block is needed to be erased. In this embodiment, it is assumed that data blocks DB1, DB3 and DB4 are used blocks, i.e. each of the data blocks has data stored therein. When receiving a programming instruction from the host and prepares to program data # 1 to the data block DB3, due to the data block DB3 being a used block, the control unit 110 pops a spare block (e.g. the top spare block SB1) from the spare area 520 and programs the data # 1 to the popped spare block SB1. Thereafter, a mark M is added to the original data block DB3 to represent that the data block DB3 is a data block needed to be erased and the marked data block is pushed back to the spare area such as pushing the data block to the bottom of the spare area (i.e. an area under the marked block 530), as the marked block 540 shown in FIG. 5B. Meanwhile, the control unit may perform a data rearrangement operation to remap the address of the spare block SB1 and the data block DB3.
  • After the data rearrangement operation has been completed, the control unit will wait to receive a specific instruction from the host. During a first time period when the memory device is waiting to receive an instruction, the control unit will continually determine whether the specific instruction has been received or not, and if not, pop a marked block from the spare area and erase the popped block. For example, the marked block which is the latest pushed block in the spare area, has a higher priority to be erased, i.e. the marked block nearest to the bottom of the spare area will be erased first, but it is not limited thereto. Thus, the marked block 540 will be erased first and after the marked block 540 has been erased, the block 540 will be re-configured as an available spare block SB for subsequent use, as shown in FIG. 5C. After the marked block 540 has been erased, again, it is determined whether the specific instruction has been received. Similarly, if it is found that the specific instruction has still not been received, another marked block will be popped from the spare area and the popped block will then be erased. Therefore, the marked block 530 will be erased and after the marked block 530 has been erased, the block 530 will be re-configured as an available spare block SB for subsequent use, as shown in FIG. 5D. If it is found that the specific instruction has been received, the control unit will reply by a confirmation signal corresponding to the specific instruction to the host so as to proceed with subsequent data accessing.
  • In summary, according to embodiments of memory devices and related access methods of the invention, the operation of block erasing can be performed during a wait cycle when the memory device is waiting to receive a specific instruction to be issued from the host and when the specific instruction has not be received so that one block or more than one blocks that are marked to be erased can be erased at the same period, thereby erasing not only the data block that was last pushed but also un-erased blocks that should be erased in the spare block. Therefore, waiting time period needed for erasing individual block can be reduced and overall access performance of the memory device can be improved.
  • Systems and method thereof, or certain aspects or portions thereof, may take the form of a program code (i.e., executable instructions) embodied in tangible media, such as floppy diskettes, CD-ROMS, hard drives, or any other machine-readable storage medium, wherein, when the program code is loaded into and executed by a machine, such as a computer, the machine thereby becomes an apparatus for practicing the methods. The methods may also be embodied in the form of a program code transmitted over some transmission medium, such as electrical wiring or cabling, through fiber optics, or via any other form of transmission, wherein, when the program code is received and loaded into and executed by a machine, such as a computer, the machine becomes an apparatus for practicing the disclosed methods. When implemented on a general-purpose processor, the program code combines with the processor to provide a unique apparatus that operates analogously to application specific logic circuits.
  • Certain term are used throughout the description and claims to refer to particular system components. As one skilled in the art will appreciate, consumer electronic equipment manufacturers may refer to a component by different names. This document does not intend to distinguish between components that differ in name but not function.
  • While the invention has been described by way of example and in terms of preferred embodiment, it is to be understood that the invention is not limited thereto. Those who are skilled in this technology can still make various alterations and modifications without departing from the scope and spirit of this invention. Therefore, the scope of the present invention shall be defined and protected by the following claims and their equivalents.

Claims (18)

1. A method for accessing a memory device, wherein the memory device comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks, comprising:
receiving data from a host;
popping a spare block from the spare area and programming the received data into the popped spare block;
pushing a data block corresponding to the received data to the spare area; and
erasing the pushed data block before the memory device is receiving a specific instruction to be issued from the host.
2. A memory device, comprising:
a non-volatile memory, comprising a data area having a plurality of data blocks and a spare area having a plurality of spare blocks; and
a control unit, receiving data from a host, popping a spare block from the spare area, programming the received data into the popped spare block, pushing a data block corresponding to the received data to the spare area, and erasing the pushed data block before the memory device is receiving a specific instruction to be issued from the host.
3. A method for accessing a memory device, wherein the memory device comprises a non-volatile memory and the non-volatile memory has a data area having a plurality of data blocks and a spare area having a plurality of spare blocks, comprising:
programming data into a spare block, wherein the spare block is popped from the spare area;
marking a data block corresponding to the data and pushing the marked data block to the spare area; and
erasing at least one marked data block of the spare area before the memory device is receiving a specific instruction to be issued from a host.
4. A method for accessing a memory device, wherein the memory device comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks, comprising:
receiving data from a host;
popping a spare block from the spare area and programming the received data into the popped spare block;
pushing a data block of the data blocks to the spare area; and
erasing at least a spare block before the memory device is receiving a specific instruction to be issued from the host.
5. The method of claim 4, wherein the spared block is erased after the data block is pushed to the spare area.
6. The method of claim 4, wherein the spared block is the data block pushed to the spared area.
7. The method of claim 4, wherein the received data is for updating content of the pushed block.
8. A memory device, comprising:
a non-volatile memory, comprising a data area having a plurality of data blocks and a spare area having a plurality of spare blocks; and
a control unit, receiving data from a host, popping a spare block from the spare area, programming the received data into the popped spare block, pushing a data block of the data blocks to the spare area, and erasing at least a spare block before the memory device is receiving a specific instruction to be issued from the host.
9. The memory device of claim 8, wherein the spared block is erased after the data block is pushed to the spare area.
10. The memory device of claim 8, wherein the spared block is the data block pushed to the spared area.
11. The memory device of claim 8, wherein the received data is for updating content of the pushed block.
12. A method for accessing a memory device, wherein the memory device comprises a non-volatile memory and the non-volatile memory has a data area having a plurality of data blocks and a spare area having a plurality of spare blocks, comprising:
programming data into a spare block, wherein the spare block is popped from the spare area;
pushing a data block of the data blocks to the spare area; and
erasing at least a spare block before the memory device is receiving a specific instruction to be issued from the host.
13. The method of claim 12, wherein the spared block is erased after the data block is pushed to the spare area.
14. The method of claim 12, wherein the spared block is the data block pushed to the spared area.
15. The method of claim 12, wherein the received data is for updating content of the pushed block.
16. A method for accessing a memory device, wherein the memory device comprises a data area having a plurality of data blocks and a spare area having a plurality of spare blocks, comprising:
receiving data from a host;
popping a spare block from the spare area and programming the received data into the popped spare block;
pushing a data block which is not empty to the spare area; and
erasing at least a spare block after the data block which is not empty being pushed to the spare area.
17. A memory device, comprising:
a non-volatile memory, comprising a data area having a plurality of data blocks and a spare area having a plurality of spare blocks; and
a control unit, receiving data from a host, popping a spare block from the spare area, programming the received data into the popped spare block, pushing a data block which is not empty to the spare area, and erasing at least a spare block after the data block which is not empty being pushed to the spare area.
18. A method for accessing a memory device, wherein the memory device comprises a non-volatile memory and the non-volatile memory has a data area having a plurality of data blocks and a spare area having a plurality of spare blocks, comprising:
programming data into a spare block, wherein the spare block is popped from the spare area;
pushing a data block of the data blocks to the spare area, wherein the pushed data block is not empty; and
erasing at least a spare block of the spare blocks after the pushed block is pushed to the spare area.
US13/524,479 2008-10-28 2012-06-15 Memory Device and Method for Programming Flash Memory Utilizing Spare Blocks Abandoned US20120303879A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US13/524,479 US20120303879A1 (en) 2008-10-28 2012-06-15 Memory Device and Method for Programming Flash Memory Utilizing Spare Blocks

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
TW097141345A TW201017403A (en) 2008-10-28 2008-10-28 Access methods for memory devices and memory devices and machine readable medium thereof
TW097141345 2008-10-28
US12/404,321 US8225028B2 (en) 2008-10-28 2009-03-15 Memory devices and methods for programming flash memory utilizing spare blocks
US13/524,479 US20120303879A1 (en) 2008-10-28 2012-06-15 Memory Device and Method for Programming Flash Memory Utilizing Spare Blocks

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
US12/404,321 Continuation US8225028B2 (en) 2008-10-28 2009-03-15 Memory devices and methods for programming flash memory utilizing spare blocks

Publications (1)

Publication Number Publication Date
US20120303879A1 true US20120303879A1 (en) 2012-11-29

Family

ID=42118597

Family Applications (2)

Application Number Title Priority Date Filing Date
US12/404,321 Active 2030-10-05 US8225028B2 (en) 2008-10-28 2009-03-15 Memory devices and methods for programming flash memory utilizing spare blocks
US13/524,479 Abandoned US20120303879A1 (en) 2008-10-28 2012-06-15 Memory Device and Method for Programming Flash Memory Utilizing Spare Blocks

Family Applications Before (1)

Application Number Title Priority Date Filing Date
US12/404,321 Active 2030-10-05 US8225028B2 (en) 2008-10-28 2009-03-15 Memory devices and methods for programming flash memory utilizing spare blocks

Country Status (2)

Country Link
US (2) US8225028B2 (en)
TW (1) TW201017403A (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110888593B (en) * 2018-09-07 2024-01-26 慧荣科技股份有限公司 Data storage device and non-volatile memory control method
CN110888820B (en) * 2018-09-07 2022-01-25 慧荣科技股份有限公司 Data storage device and non-volatile memory control method
CN110888591B (en) * 2018-09-07 2023-05-30 慧荣科技股份有限公司 Data storage device and non-volatile memory control method
US10964405B2 (en) * 2018-11-30 2021-03-30 Ati Technologies Ulc Memory initialization reporting and control

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090157947A1 (en) * 2007-12-14 2009-06-18 Silicon Motion, Inc. Memory Apparatus and Method of Evenly Using the Blocks of a Flash Memory
US20100077132A1 (en) * 2008-09-25 2010-03-25 Silicon Motion, Inc. Memory devices and access methods thereof

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7155562B2 (en) * 2003-05-08 2006-12-26 Micron Technology, Inc. Method for reading while writing to a single partition flash memory
CN100428358C (en) 2003-06-24 2008-10-22 群联电子股份有限公司 High speed big block data writing method for flash memory
CN100349138C (en) 2003-08-08 2007-11-14 倚天资讯股份有限公司 Non-volatility memory access system and its cycling usage method of access space
WO2007058617A1 (en) * 2005-11-17 2007-05-24 Chee Keng Chang A controller for non-volatile memories, and methods of operating the memory controller
US8438356B2 (en) * 2007-10-01 2013-05-07 Marvell World Trade Ltd. Flash memory controller

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090157947A1 (en) * 2007-12-14 2009-06-18 Silicon Motion, Inc. Memory Apparatus and Method of Evenly Using the Blocks of a Flash Memory
US20100077132A1 (en) * 2008-09-25 2010-03-25 Silicon Motion, Inc. Memory devices and access methods thereof

Also Published As

Publication number Publication date
US8225028B2 (en) 2012-07-17
US20100106892A1 (en) 2010-04-29
TW201017403A (en) 2010-05-01

Similar Documents

Publication Publication Date Title
US9110786B2 (en) Read operation prior to retrieval of scatter gather list
US8380919B2 (en) Flash storage device, data storage system, and data writing method
US8448046B2 (en) Memory access method capable of reducing usage rate of problematic memory blocks
KR101819014B1 (en) Method and controller for managing memory device
US8392649B2 (en) Memory storage device, controller, and method for responding to host write commands triggering data movement
US9176865B2 (en) Data writing method, memory controller, and memory storage device
US8112682B2 (en) Method and device for bad-block testing
US20070214309A1 (en) Nonvolatile storage device and data writing method thereof
US20130013853A1 (en) Command executing method, memory controller and memory storage apparatus
US10475516B2 (en) Data storage device and data erasing method wherein after erasing process, predetermined value is written to indicate completion of said erasing method
US20150161039A1 (en) Data erasing method, memory control circuit unit and memory storage apparatus
CN103425589A (en) Control apparatus, storage device, and storage control method
US9552287B2 (en) Data management method, memory controller and embedded memory storage apparatus using the same
US20140181372A1 (en) Data reading method, memory controller, and memory storage device
TWI523030B (en) Method for managing buffer memory, memory controllor, and memory storage device
CN111444030A (en) Data storage device and method for preventing firmware from failing
US20120303879A1 (en) Memory Device and Method for Programming Flash Memory Utilizing Spare Blocks
US20130159604A1 (en) Memory storage device and memory controller and data writing method thereof
CN103389942A (en) Control device, storage device, and storage control method
US10340025B2 (en) Data-storage device and block-releasing method
CN104951376A (en) Parameter optimization method and parameter optimization device
CN113885808A (en) Mapping information recording method, memory control circuit unit and memory device
US7979606B2 (en) Method for storing data
US8874981B2 (en) Method of creating target storage layout table referenced for partitioning storage space of storage device and related electronic device and machine-readable medium
US20170115925A1 (en) Valid data merging method, memory controller and memory storage apparatus

Legal Events

Date Code Title Description
AS Assignment

Owner name: SILICON MOTION, INC., TAIWAN

Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNOR:KUO, WU-CHI;REEL/FRAME:028385/0264

Effective date: 20090223

STCB Information on status: application discontinuation

Free format text: ABANDONED -- FAILURE TO RESPOND TO AN OFFICE ACTION