KR100736093B1 - Apparatus and method for controlling nand flash - Google Patents

Apparatus and method for controlling nand flash Download PDF

Info

Publication number
KR100736093B1
KR100736093B1 KR1020060004409A KR20060004409A KR100736093B1 KR 100736093 B1 KR100736093 B1 KR 100736093B1 KR 1020060004409 A KR1020060004409 A KR 1020060004409A KR 20060004409 A KR20060004409 A KR 20060004409A KR 100736093 B1 KR100736093 B1 KR 100736093B1
Authority
KR
South Korea
Prior art keywords
sector
value
zero
data
ecc
Prior art date
Application number
KR1020060004409A
Other languages
Korean (ko)
Inventor
이재준
Original Assignee
삼성전자주식회사
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 삼성전자주식회사 filed Critical 삼성전자주식회사
Priority to KR1020060004409A priority Critical patent/KR100736093B1/en
Application granted granted Critical
Publication of KR100736093B1 publication Critical patent/KR100736093B1/en

Links

Images

Classifications

    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C29/00Checking stores for correct operation ; Subsequent repair; Testing stores during standby or offline operation
    • G11C29/04Detection or location of defective memory elements, e.g. cell constructio details, timing of test signals
    • G11C29/08Functional testing, e.g. testing during refresh, power-on self testing [POST] or distributed testing
    • G11C29/12Built-in arrangements for testing, e.g. built-in self testing [BIST] or interconnection details
    • G11C29/38Response verification devices
    • G11C29/42Response verification devices using error correcting codes [ECC] or parity check
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/08Error detection or correction by redundancy in data representation, e.g. by using checking codes
    • G06F11/10Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's
    • G06F11/1008Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices
    • G06F11/1048Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices using arrangements adapted for a specific error detection or correction feature
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/08Error detection or correction by redundancy in data representation, e.g. by using checking codes
    • G06F11/10Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's
    • G06F11/1008Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices
    • G06F11/1068Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices in sector programmable memories, e.g. flash disk
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C16/00Erasable programmable read-only memories
    • G11C16/02Erasable programmable read-only memories electrically programmable
    • G11C16/04Erasable programmable read-only memories electrically programmable using variable threshold transistors, e.g. FAMOS
    • G11C16/0483Erasable programmable read-only memories electrically programmable using variable threshold transistors, e.g. FAMOS comprising cells having several storage transistors connected in series

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Microelectronics & Electronic Packaging (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)
  • Read Only Memory (AREA)

Abstract

An apparatus and a method for controlling a NAND flash are provided to improve program and read performances of the NAND flash. A generation part(205) generates an ECC(Error Correction Check) or CRC(Cyclic Redundancy Check) value of data to be programmed in a flash memory. A read part(210) reads the generated ECC or CRC value. A control part(220) judges whether a sector is a zero sector, by checking the read ECC or CRC value. A write part(230) performs zero marking on a spare region when the sector is a zero sector, and the control part judges the sector as a zero sector when the ECC value or the CRC value corresponds to 0x00 value.

Description

NAND 플래시 제어 장치 및 방법{Apparatus and method for controlling NAND flash}Apparatus and method for controlling NAND flash}

도 1은 종래 NAND 플래시의 동작을 도시한다.1 illustrates the operation of a conventional NAND flash.

도 2는 본 발명의 일 실시예에 따른 NAND 플래시 제어 장치의 블록도이다.2 is a block diagram of a NAND flash control apparatus according to an embodiment of the present invention.

도 3은 본 발명의 일 실시예에 따른 NAND 플래시의 프로그램 순서도이다.3 is a program flow diagram of a NAND flash according to an embodiment of the present invention.

도 4는 본 발명의 일 실시예에 따른 NAND 플래시의 읽기 순서도이다.4 is a read flowchart of a NAND flash according to an embodiment of the present invention.

도 5는 NAND의 프로그램 동작(Operation)을 도시한다.5 illustrates a program operation of a NAND.

<도면의 주요 부분에 관한 부호의 설명><Explanation of symbols on main parts of the drawings>

205: 생성부205: generation unit

210: 판독부210: reading unit

220: 제어부220: control unit

230: 기록부230: record book

본 발명은 NAND 플래시 제어 장치 및 방법에 관한 것으로서, 더욱 상세하게는 섹터의 저장 데이터가 모두 0x00인 경우 프로그램을 회피하여 NAND 플래시의 성 능을 개선하는 NAND 플래시 제어 장치 및 방법에 관한 것이다.The present invention relates to a NAND flash control apparatus and method, and more particularly, to a NAND flash control apparatus and method for improving the performance of the NAND flash by avoiding the program when all the stored data of the sector is 0x00.

플래시 메모리(Flash Memory)는 전원을 꺼도 데이터가 소실되지 않고 보존되는 비휘발성 메모리(Non Volatile Memory)인 EEPROM(Electrically Erasable & Programmable Rom)의 구성과 동작을 변형한 것으로 크게 NOR형과 NAND형으로 나눌 수 있는 데 NOR형 플래시 메모리는 주로 컴퓨터의 BIOS나 이동 전화기의 마이크로 코드 저장용으로 쓰이는 단일 칩 형의 제품에 이용되고, NAND형 플래시 메모리는 컴퓨터의 메모리 카드 및 디지털 카메라의 화상 데이터를 저장하는 데 주로 사용되는 카드형 제품에 이용된다. Flash memory is a modification of the configuration and operation of the EEPROM (Electrically Erasable & Programmable Rom), a non-volatile memory (Non Volatile Memory) that does not lose data even when the power is turned off. It is divided into NOR type and NAND type. NOR flash memory is mainly used for single-chip type products used for computer BIOS or mobile phone microcode storage, and NAND flash memory is used to store image data of computer memory cards and digital cameras. It is mainly used for card type products.

종래에는 코드 저장형인 NOR형 플래시 메모리가 플래시 메모리 시장의 주류를 이루고 있었으나, 최근에는 NAND형 플래시가 플래시 카드, 메모리 스틱, PC, 노트북, 정교한 USB 드라이브가 장착된 MP3 플레이어, 고집적 디지털 카메라 간의 데이터 교환에 사용되는 USB 플래시 드라이브용 저장 매체 등으로 확대되고 있다. 또한, NAND형 플래시는 (메인) 데이터가 저장되는 데이터 영역과 보조적인 기본정보가 저장되는 스페어 영역으로 구분된다. 스페어 영역은 일반적으로 ECC, 불량 블록에 관한 정보, 파일 시스템과 관련된 데이터 등이 기본정보로 저장된다.In the past, code-storage NOR flash memory has become the mainstream of the flash memory market, but recently, NAND flash flash data exchanges between flash cards, memory sticks, PCs, laptops, MP3 players with sophisticated USB drives, and highly integrated digital cameras. It is expanding to a storage medium for a USB flash drive to be used. In addition, the NAND flash is divided into a data area in which (main) data is stored and a spare area in which auxiliary basic information is stored. The spare area generally stores ECC, information on bad blocks, data related to a file system, and the like as basic information.

한편, 본 출원인은 NAND 플래시 메모리의 속도를 크게 높일 수 있는 NAND 플래시 메모리의 읽기 및 프로그램 속도를 빠르게 하는 파일관리 소프트웨어인 RFS(Robust 파일 시스템)를 개발한 바 있다. RFS는 필요한 데이터만 골라 선택적으로 구동시키는 기능을 갖고 있어, NAND 플래시의 읽기속도를 종전의 2MB(초당 데이터전송 속도)에서 최대 4MB까지 2배 가량 향상시킨 것이 특징이다. 또한 프로그램 속도도 최대 10배 빨라진 초당 2MB로 고화질(VGA급)의 동영상을 구현할 수 있다.On the other hand, the applicant has developed RFS (Robust File System), a file management software that speeds up the read and program speed of the NAND flash memory that can significantly increase the speed of the NAND flash memory. RFS has the ability to selectively select only the data that is needed, which doubles the read speed of the NAND flash from the previous 2MB (data transfer rate per second) to up to 4MB. In addition, the program speed is up to 10 times faster than 2MB per second can implement high-quality (VGA-class) video.

도 1은 종래 NAND 플래시의 동작을 도시한다.1 illustrates the operation of a conventional NAND flash.

일반적으로 NAND 플래시의 동작은 삭제(Erase), 프로그램(Program), 읽기(Read)의 세 가지 연산으로 구성된다. In general, the operation of the NAND flash consists of three operations: erase, program, and read.

NAND 플래시의 삭제동작은 블록(Block) 단위로 수행되며 셀(Cell)을 0에서 1로 바꾸는 것을 의미한다. 삭제동작을 수행하기 위해서, 서브스트레이트(Substrate)에서 20V(볼트)(12)를 가해주면 플로팅(Floating) 게이트에 있는 전자들이 아래 방향으로 F-N 튜넬링(Tunneling) 효과에 의해 이동하게 된다(14). The erase operation of the NAND flash is performed in units of blocks, and means to change the cell from 0 to 1. In order to perform the erase operation, applying 20V (volts) 12 in the substrate causes the electrons in the floating gate to move downward by the FN tunneling effect (14). .

NAND 플래시의 프로그램 동작은 바이트(Byte) 또는 페이지(Page) 단위로 수행하며 셀을 1에서 0으로 바꾸는 것을 의미한다. 각 셀의 게이트에 19V(16)를 가해주면 전자들이 플로팅 게이트 방향으로 이동하게 된다(18). 이때, 셀의 상태가 OFF Tr 상태가 되어 Vt 값(+) 상태가 된다. 프로그램은 한번으로 끝내는 것이 아니라 복수개의 단계에 걸쳐 전압 값을 올려주면서 원하는 데이터의 프로그램을 수행한다. Program operation of the NAND flash is performed in units of bytes or pages and changes a cell from 1 to 0. Applying 19V (16) to the gate of each cell causes electrons to move in the floating gate direction (18). At this time, the state of the cell becomes the OFF Tr state and becomes the Vt value (+) state. The program does not end at once, but instead of raising the voltage value in a plurality of stages to program the desired data.

NAND 플래시의 읽기동작은 셀의 상태가 On Tr 또는 Off Tr 상태인가를 확인하여 데이터를 1 또는 0으로 출력시키는 동작(20)이다. NAND 플래시에서 셀은 삭제, 프로그램 및 읽기의 순으로 스트레스를 받으며, 일정 수준의 스트레스 이후에는 더 이상 사용할 수 없는 수준에 이르게 되며 이를 웨어 아웃(Wear-out) 되었다고 한다.The read operation of the NAND flash is an operation 20 for checking whether a cell state is an On Tr or Off Tr state and outputting data to 1 or 0. In NAND flash, cells are stressed in the order of erase, write, and read, and after a certain amount of stress, the cells are no longer available and wear-out.

한편, NAND 플래시를 사용하는 파일 시스템 및 장치 드라이버는 모든 섹터가 0x00로 채워져 있다고 해도 0x00 데이터를 모두 NAND 플래시에 기록하게 된다. 또한 NAND 플래시는 이동식 저장장치, 임베디드(Embedded) 기기의 스토리지(Storage) 등 다양한 기기에서 데이터 저장 용도로 되는 데, 이동식 저장장치 및 임베디드 기기의 경우는 호환성 또는 저장 미디어의 스펙(Specification)등의 이유로 대부분의 경우 FAT 파일 시스템을 사용한다. FAT 파일시스템은 0x00 데이터를 다량 유발시키며, NAND 플래시 입장에서 0x00은 프로그램 되어야 하는 대상이 된다. 이와 같은 0x00 프로그램이 많아 질수록 성능의 저하 및 NAND 어레이(Array)에 프로그램 오퍼레이션(Operation)의 발생으로 인한 수명의 저하를 일으키는 문제점이 있다. On the other hand, file systems and device drivers using NAND flash will write all 0x00 data to the NAND flash even if all sectors are filled with 0x00. In addition, NAND flash is used for data storage in various devices such as mobile storage devices and storage of embedded devices. In the case of mobile storage devices and embedded devices, the reasons for compatibility or storage media specification are required. In most cases, the FAT file system is used. The FAT filesystem causes a lot of 0x00 data, and from the standpoint of NAND flash, 0x00 is something that needs to be programmed. As the number of 0x00 programs increases, there is a problem of deterioration of performance and a decrease in lifespan due to the occurrence of program operations in the NAND array.

참고로, 표 1의 통계는 NAND 플래시를 사용하는 파일 시스템에서 RFS(Robust File System)를 이용하여 섹터의 저장 데이터가 모두 0x00(이하 제로 섹터라 한다)인 개수를 검출한 결과이다. 해당 테스트는 RFS의 fsstress 도구를 사용하여 총 5회 실시하였다. 제로 섹터가 평균 70%정도 차지함을 알 수 있다. For reference, the statistics of Table 1 are the result of detecting the number of all the stored data of the sector 0x00 (hereinafter referred to as zero sector) by using the Robust File System (RFS) in the file system using the NAND flash. The test was performed five times using the fsstress tool of RFS. It can be seen that the zero sector occupies about 70% on average.

총 프로그램 섹터Total program sector 제로 섹터의 개수Number of zero sectors 백분율(%)percentage(%) 6241862418 4643146431 7474 7210072100 5403554035 7575 6940669406 4670746707 6767 6911169111 4711847118 6868 6952469524 4858048580 6969

따라서 제로 섹터의 프로그램을 회피하여, 프로그램 성능 및 NAND 플래시의 수명을 향상시킬 필요성이 제기된다.Therefore, a need arises to avoid program of zero sectors, thereby improving program performance and lifetime of NAND flash.

본 발명은 제로 섹터 회피를 통한 NAND 플래시 제어 장치 및 방법을 제공하 는데 그 목적이 있다.It is an object of the present invention to provide an NAND flash control apparatus and method through zero sector avoidance.

본 발명의 목적들은 이상에서 언급한 목적들로 제한되지 않으며, 언급되지 않은 또 다른 목적들은 아래의 기재로부터 당업자에게 명확하게 이해되어 질 수 있을 것이다.The objects of the present invention are not limited to the above-mentioned objects, and other objects which are not mentioned will be clearly understood by those skilled in the art from the following description.

목적을 달성하기 위하여, 본 발명의 일 실시예에 따른 NAND 플래시 제어 장치는 ECC 값 또는 CRC 값을 판독하는 판독부와 ECC 값 또는 CRC 값을 검사하여 섹터가 제로 섹터인 가능성을 판단하는 제어부 및 섹터가 제로 섹터인 경우 스페어 영역에 제로 마킹하는 기록부를 포함한다. In order to achieve the object, the NAND flash control apparatus according to an embodiment of the present invention includes a readout unit for reading an ECC value or a CRC value and a controller and sector for determining the possibility that the sector is a zero sector by examining the ECC value or the CRC value. Is a zero sector, it includes a recording unit for marking zero in the spare area.

본 발명의 일 실시예에 따른 않는 NAND 플래시 제어 방법은 ECC 값 또는 CRC 값을 판독하는 단계와 ECC 값 또는 CRC 값을 검사하여 섹터가 제로 섹터인 가능성을 판단하는 단계 및 섹터가 제로 섹터인 경우 스페어 영역에 제로 마킹하는 단계를 포함한다.In a non-NAND flash control method according to an embodiment of the present invention, a method of reading an ECC value or a CRC value, checking an ECC value or a CRC value to determine a possibility that the sector is a zero sector, and a spare when the sector is a zero sector Zero marking the area.

기타 실시예들의 구체적인 사항들은 상세한 설명 및 도면들에 포함되어 있다.Specific details of other embodiments are included in the detailed description and the drawings.

본 발명의 이점 및 특징, 그리고 그것들을 달성하는 방법은 첨부되는 도면과 함께 상세하게 후술되어 있는 실시예들을 참조하면 명확해질 것이다. 그러나 본 발명은 이하에서 개시되는 실시예들에 한정되는 것이 아니라 서로 다른 다양한 형태로 구현될 수 있으며, 단지 본 실시예들은 본 발명의 개시가 완전하도록 하고, 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 발명의 범주를 완전하게 알려주기 위해 제공되는 것이며, 본 발명은 청구항의 범주에 의해 정의될 뿐이다. 명세서 전체에 걸쳐 동일 참조 부호는 동일 구성 요소를 지칭한다.Advantages and features of the present invention and methods for achieving them will be apparent with reference to the embodiments described below in detail with the accompanying drawings. However, the present invention is not limited to the embodiments disclosed below, but can be implemented in various different forms, and only the embodiments make the disclosure of the present invention complete, and the general knowledge in the art to which the present invention belongs. It is provided to fully inform the person having the scope of the invention, which is defined only by the scope of the claims. Like reference numerals refer to like elements throughout.

이하, 첨부된 도면을 참조하여 본 발명의 바람직한 실시예를 상세히 설명하기로 한다.Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings.

도 2는 본 발명의 일 실시예에 따른 NAND 플래시 제어 장치의 블록도이다.2 is a block diagram of a NAND flash control apparatus according to an embodiment of the present invention.

NAND 플래시 제어 장치(200)는 생성부(205), 판독부(210), 제어부(220) 및 기록부(230)를 포함한다.The NAND flash control apparatus 200 includes a generation unit 205, a reading unit 210, a control unit 220, and a recording unit 230.

생성부(205)는 NAND 플래시에 프로그램하려는 데이터를 바탕으로 ECC(에러 정정; Error Correction Check) 또는 CRC(에러 검출; Cyclic Redundancy Check) 값을 생성한다. The generation unit 205 generates an ECC (Error Correction Check) or CRC (Error Detection) value based on the data to be programmed into the NAND flash.

판독부(210)는 섹터의 저장 데이터, NAND 플래시의 데이터 영역 및 스페어 영역을 판독한다. 또한 생성된 ECC 값 또는 CRC 값을 판독한다. 이하 도 3 및 도 4에서 보다 더 구체적으로 후술하기로 하고 이하 생략한다.The reading unit 210 reads the stored data of the sector, the data area of the NAND flash, and the spare area. It also reads the generated ECC value or CRC value. 3 and 4 will be described in more detail below and will be omitted below.

제어부(220)는 ECC 값 또는 CRC 값을 검사하여 섹터가 제로 섹터(섹터의 저장 데이터가 모두 0x00)인 가능성을 판단한다. 즉, ECC 값 또는 CRC 값이 0x00에 해당할 경우 섹터의 저장 데이터가 모두 0x00인 가능성이 있다고 판단한다. 다만, ECC 값은 알고리즘의 로직에 따라 0x00에 해당하는 값이 달라질 수 있다. 부언하면, 섹터의 저장 데이터가 모두 0x00인 가능성이 있다는 것은 반드시 섹터의 저장 데이터가 모두 0x00만 존재하지 않을 수도 있으나, 판독부(210)가 판독하는 데이터의 대상 섹터의 개수를 감소시키는 데 의미가 있다. 또한 ECC의 경우에는 알고리즘 의 로직에 따라 달라질 수 있는 데 예를 들어 삼성전자의 OneNAND에서 사용하는 ECC 로직은 0xff 0xff 0xff 값인 경우가 섹터의 저장 데이터가 모두 0x00인 경우에 해당한다.The controller 220 examines the ECC value or the CRC value to determine the possibility that the sector is a zero sector (all stored data of the sector is 0x00). That is, when the ECC value or the CRC value corresponds to 0x00, it is determined that there is a possibility that all stored data of the sector is 0x00. However, the ECC value may vary from 0x00 depending on the logic of the algorithm. In other words, the possibility that the stored data of the sectors are all 0x00 may not necessarily exist in all of the stored data of the sectors, but it is meaningful to reduce the number of target sectors of the data read by the reading unit 210. have. In the case of ECC, it may vary depending on the logic of the algorithm. For example, the ECC logic used in Samsung's OneNAND is 0xff 0xff 0xff when the data stored in the sector is all 0x00.

기록부(230)는 데이터 영역 및 스페어 영역에 각각 데이터 및 기본 정보를 프로그램(기록) 한다. 예를 들어 제어부(220)를 통해 제로 섹터일 가능성이 있다고 판단되고, 판독부(210)를 통해 섹터의 저장 데이터가 모두 0x00인 제로 섹터(즉, 512바이트가 0x00)를 찾으면, 스페어 영역의 특정 어드레스(Address)에 기록부(230)를 통해 소정의 마킹{이하 제로 마킹(Zero Marking)이라 한다}을 한다. 바람직하게는 제로 마킹은 스페어 영역의 특정 어드레스에 1바이트로 0x00 값을 기록한다. 또한 스페어 영역에 ECC 또는 CRC를 기록한 후, 스페어 영역에 기본 정보(예를 들어 제로 마킹, ECC 값, 불량 블록 정보)를 프로그램 한다. The recording unit 230 programs (records) data and basic information in the data area and the spare area, respectively. For example, if it is determined that there is a possibility of zero sector through the control unit 220, and the zero-sector (that is, 512 bytes 0x00) where all of the stored data of the sector is found through the reading unit 210 (i.e., 512 bytes is 0x00), the specific area of the spare area is determined. A predetermined marking (hereinafter referred to as zero marking) is performed through the recording unit 230 at the address. Preferably, the zero marking writes a value of 0x00 in one byte at a specific address of the spare area. In addition, after ECC or CRC is recorded in the spare area, basic information (for example, zero marking, ECC value, and bad block information) is programmed in the spare area.

이하 도 3 및 도 4에서 보다 더 구체적으로 설명하기로 한다. 3 and 4 will be described in more detail below.

도 3은 본 발명의 일 실시예에 따른 NAND 플래시의 프로그램 순서도이다.3 is a program flow diagram of a NAND flash according to an embodiment of the present invention.

예를 들어 FAT 파일 시스템을 사용하는 이동식 저장장치 또는 임베디드 기기의 (메인) 데이터를 NAND 플래시에 기록하기 전에 바람직하게는 NAND 플래시의 최소 프로그램 단위인 섹터{즉, 512바이트(Byte)} 단위로 섹터의 저장 데이터가 모두 0x00인 제로 섹터인지를 판독한다. 이때, (메인) 데이터의 모든 섹터에 포함된 저장 데이터에 대해 0x00인 여부를 판독한다면 오버헤드(Overhead)가 크게 발생하게 된다. 따라서 ECC 또는 CRC 알고리즘을 사용하여 검색 대상 섹터를 감소시킬 수 있다. For example, before writing (main) data from a removable storage device or embedded device using a FAT file system to a NAND flash, it is preferably a sector (ie 512 bytes), which is the minimum program unit of the NAND flash. It is read whether or not the stored data of all are zero sectors of 0x00. At this time, if it is read whether the storage data included in all sectors of the (main) data is 0x00, a large overhead occurs. Therefore, the sector to be searched can be reduced by using the ECC or CRC algorithm.

NAND 플래시에 프로그램하려는 데이터를 바탕으로 ECC 값 또는 CRC 값을 생성부(205)를 통해 생성한다(S302). 예를 들어 NAND D/D 또는 H/W 컨트롤러에서 지원하는 생성 모듈을 통해 ECC 값 또는 CRC 값을 계산할 수 있다.An ECC value or a CRC value is generated through the generation unit 205 based on the data to be programmed into the NAND flash (S302). For example, generation modules supported by NAND D / D or H / W controllers can calculate ECC values or CRC values.

데이터를 NAND 플래시에 프로그램 하기 이전에 생성된 ECC 값 또는 CRC 값을 판독부(210)를 통해 판독한다(S311).The ECC value or CRC value generated before the data is programmed into the NAND flash is read through the reading unit 210 (S311).

ECC 값 또는 CRC 값이 0x00에 해당하는 값인 지를 제어부(220)를 통해 판단하고, ECC 값 또는 CRC 값이 0x00에 해당할 경우, 섹터의 저장 데이터가 모두 0x00인 가능성이 있다고 판단한다(S321, S331). 다만, ECC 값은 알고리즘의 로직에 따라 0x00에 해당하는 값이 달라질 수 있다.The controller 220 determines whether the ECC value or the CRC value corresponds to 0x00, and if the ECC value or the CRC value corresponds to 0x00, it is determined that there is a possibility that all stored data of the sector is 0x00 (S321 and S331). ). However, the ECC value may vary from 0x00 depending on the logic of the algorithm.

섹터의 저장 데이터가 모두 0x00인 섹터(즉, 제로 섹터)를 판독부(210)를 통해 판독하면, 스페어 영역의 특정 어드레스에 기록부(230)를 통해 제로 마킹을 한다(S341). 제로 마킹은 스페어 영역의 특정 어드레스에 1바이트로 0x00 값을 기록하는 것이 바람직하다. 따라서 이와 같이 제로 섹터의 경우, 스페어 영역에 제로 마킹을 하고 데이터 영역에 따로 제로 섹터를 프로그램하지 않아도 되므로, NAND 플래시의 성능을 향상시킬 수 있다.When a sector (i.e., zero sector) whose storage data of the sector is all 0x00 is read through the reading unit 210, zero marking is performed through the recording unit 230 at a specific address of the spare area (S341). In the zero marking, it is preferable to write a value of 0x00 in one byte at a specific address of the spare area. Therefore, in the case of zero sectors as described above, since zero marking is performed on the spare area and zero sectors are not programmed in the data area, the performance of the NAND flash can be improved.

또한 스페어 영역에 ECC 또는 CRC 값을 기록한 후, 스페어 영역에 기본 정보(예를 들어 제로 마킹, ECC 값, 불량 블록 정보)를 기록부(230)를 통해 프로그램(기록) 한다(S351, S361). 이때, 스페어 영역의 ECC 또는 CRC 기록은 NAND를 사용하는 소프트웨어(예를 들어 파일 시스템, FTL, Firmware)들이 데이터의 무결성을 보장하기 위해 사용하는 방식으로 프로그램시에 섹터에 기록된 내용을 바탕으로 특정 값을 생성하여 스페어 영역에 기록하고, 또한 생성된 특정 값과 읽기 시에 판독한 값을 바탕으로 생성된 특정 값과 비교하여 데이터의 무결성을 검사하는 방식이다.After the ECC or CRC value is recorded in the spare area, basic information (for example, zero marking, ECC value, and bad block information) is programmed (recorded) through the recording unit 230 (S351 and S361). At this time, the ECC or CRC recording of the spare area is used by the software (eg, file system, FTL, firmware) using NAND to ensure data integrity. A value is generated and recorded in the spare area, and the integrity of the data is checked by comparing the generated specific value with the generated specific value based on the read value at the time of reading.

섹터의 저장 데이터가 모두 0x00인 가능성이 없는 값인 경우, 스페어 영역에 ECC 또는 CRC를 기록하고, 데이터 영역 및 스페어 영역에 각각 데이터 및 기본정보를 기록부(230)를 통해 프로그램(기록) 한다(S371, S381). If the stored data of the sector is all 0x00, the ECC or CRC is recorded in the spare area, and the data and basic information are programmed (recorded) through the recording unit 230 in the data area and the spare area, respectively (S371, S381).

도 4는 본 발명의 일 실시예에 따른 NAND 플래시의 읽기 순서도이다.4 is a read flowchart of a NAND flash according to an embodiment of the present invention.

데이터를 NAND에서 읽기를 할 경우, 데이터 영역 및 스페어 영역을 판독부(210)를 통해 판독한다(S401). When data is read from the NAND, the data area and the spare area are read through the reading unit 210 (S401).

만약 스페어 영역 내 저장된 ECC 또는 CRC의 값이 0x00에 해당되는 값으로 판독부(210)를 통해 판독되고, 따라서 섹터의 저장 데이터가 모두 0x00인 가능성이 있다고 제어부(220)를 통해 판단된 경우, 판독부(210)를 통해 스페어 영역 내 제로 마킹(즉, 0x00)을 판독하고 제로 마킹이 0x00인 경우, 데이터를 저장할 버퍼를 0x00 값으로 기록부(230)를 통해 저장한다(S411, S421, S431). 따라서 0x00 데이터의 경우, 기존에 ECC 또는 CRC를 통해 데이터가 정상인 것을 판단하는 오류 검출 및 정정의 단계를 생략할 수 있으므로 시간을 절약하는 효과가 있다. If the value of the ECC or CRC stored in the spare area is read through the reading unit 210 with a value corresponding to 0x00, and thus, the control unit 220 determines that there is a possibility that all of the stored data of the sector is 0x00, the reading is performed. When the zero marking (ie, 0x00) in the spare area is read through the unit 210 and the zero marking is 0x00, the buffer for storing data is stored as the 0x00 value through the recording unit 230 (S411, S421, and S431). Therefore, in the case of 0x00 data, the error detection and correction step of determining that the data is normal through ECC or CRC can be omitted, thereby saving time.

만약 스페어 영역 내 저장된 ECC 또는 CRC의 값이 0x00에 해당되는 않은 값으로 판독부(210)를 통해 판독되고, 따라서 섹터의 저장 데이터가 모두 0x00인 가능성이 없다고 제어부(220)를 통해 판단된 경우, 데이터 영역에서 판독한 데이터를 바탕으로 ECC 값 또는 CRC 값을 계산하여 생성하고, 생성된 ECC 값 또는 CRC 값과 저장된 ECC 값 또는 CRC 값을 비교하여 에러가 있을 경우 수정하는 단계를 거친다 (S441, S451). If the value of the ECC or CRC stored in the spare area is read through the reading unit 210 with a value that does not correspond to 0x00, and it is determined by the controller 220 that there is no possibility that the stored data of the sector is all 0x00, The ECC value or CRC value is calculated and generated based on the data read from the data area, and the corrected ECC value or CRC value is compared with the stored ECC value or CRC value and corrected when there is an error (S441, S451). ).

상위 소프트웨어에 수정(보정)된 데이터 및 기본 정보를 출력한다(S461).The modified (corrected) data and basic information are output to the upper software (S461).

도 5는 NAND의 프로그램 동작(Operation)을 도시한다.5 illustrates a program operation of a NAND.

CLE(Command Latch Enable)신호(502)가 High가 되면 현재 버스의 데이터는 명령임을 나타낸다. /CE(Chip Enable)신호(502)는 칩 셀렉터를 나타내며, /WE(Write Enable)신호(506)는 버스 프로그램 신호를 나타낸다. ALE(Address Latch Enable)신호(508)가 High가 되면 현재 버스의 데이터는 주소임을 나타낸다. /RE(Read Enable)신호(510)는 버스 읽기신호를 나타내며, I/O 0~7(Data Inputs/Outputs)신호(512)는 데이터 버스를 나타내고, R/B(Ready/Busy Output)(514)신호가 Low가 되면 현재 작업 중임을 알리는 것이다. When the CLE (Command Latch Enable) signal 502 becomes High, it indicates that the data of the current bus is a command. The / CE (Chip Enable) signal 502 represents a chip selector, and the / WE (Write Enable) signal 506 represents a bus program signal. When the ALE (Address Latch Enable) signal 508 becomes High, it indicates that the data of the current bus is an address. / RE (Read Enable) signal 510 indicates a bus read signal, I / O 0-7 (Data Inputs / Outputs) signal 512 indicates a data bus, and R / B (Ready / Busy Output) 514 When the signal goes low, it indicates that it is currently working.

구간1(520)은 명령과 NAND내 어드레스를 전달하는 시간이다. 또한 구간2(530)는 데이터의 입력 구간을 나타내고, 구간3(540)은 NAND 프로그램의 시간을 나타낸다.Interval 1 520 is a time for transferring a command and an address in the NAND. In addition, section 2 530 represents an input section of data, and section 3 540 represents a time of a NAND program.

이하 본 발명을 적용할 경우, NAN 플래시의 프로그램의 경우 발생하는 성능 향상에 대해 설명한다. 데이터 영역과 스페어 영역에 프로그램 하는 경우, 기존의 Small NAND의 경우 512 바이트와 16 바이트를 합산한 528회의 프로그램을 거쳐야 하는 한편, 본 발명의 적용시 16회의 프로그램을 스페어 영역에만 하면 되므로, 512회의 횟수에 따른 프로그램 시간을 줄일 수 있다. 바람직하게는 프로그램 시간은 표 2와 같은 수식으로 표현할 수 있다. Hereinafter, when the present invention is applied, the performance improvement that occurs in the case of a NAN flash program will be described. In the case of programming in the data area and the spare area, the existing small NAND has to go through 528 programs in which 512 bytes and 16 bytes are added, while in the application of the present invention, only 16 programs need to be performed in the spare area. Program time can be reduced. Preferably, the program time may be expressed by the formula shown in Table 2.

(제로 섹터 개수) * {전체 프로그램(구간2+구간3) - 스페어 영역 프로그램(구간2+구간3)}(Zero sector count) * {whole program (segment 2 + segment 3)-spare area program (segment 2 + segment 3)}

예를 들어, 총 섹터의 개수가 32768인 16M NAND의 경우, 총 섹터 중 3276개수가 제로 섹터라 하면, 수식에서 구간3(540)은 정량적으로 나오는 값이 아니므로 제외하고 구간2(530)에 대해 적용하면 표 3과 같은 수식으로 표현될 수 있다.For example, in the case of 16M NAND having a total number of sectors of 32768, if 3276 of the total sectors are zero sectors, the interval 3 (540) is not quantitative in the equation, and thus the interval 2 (530) is excluded. If applied to, it can be expressed by the formula shown in Table 3.

(제로 섹터 개수) * {전체 프로그램(구간2) - 스페어 영역 프로그램(구간2)}(Zero sector count) * {whole program (section 2)-spare area program (section 2)}

따라서 구간2(530)에서 한 바이트를 프로그램하는 최소 시간이 25ns일 경우 전체 프로그램(구간2)은 (512+16)*25ns, 스페어 영역 프로그램(구간2)은 16*25ns로 해당 수식에 대입하면 41ms란 결과가 나온다. 기존에는 구간2의 총 프로그램 시간은 32768*528*25ns로 432ms 란 시간이 소요되었으므로, 기존대비 약 9퍼센트의 성능 향상을 가져온다.Therefore, if the minimum time to program one byte in section 2 (530) is 25ns, the entire program (section 2) is (512 + 16) * 25ns and the spare area program (section 2) is 16 * 25ns. The result is 41ms. In the past, the total program time of section 2 was 32768 * 528 * 25ns, which took 432ms, resulting in about 9 percent performance improvement.

 본 발명의 적용에 따라, NAN 플래시의 읽기의 경우 발생하는 성능 향상에 대해 살펴보기로 한다. 소프트웨어의 ECC 또는 CRC 구현시, 데이터를 검증하는 것은 순수한 오버헤드이다. 기존의 데이터 검증과정은 CPU 파워가 부족한 임베디드(Embedded) 장비에서는 오버헤드로 작용할 수 있다. 따라서 본 발명을 적용하여 읽기 성능을 향상 시킬 수 있다. 바람직하게는 표 4와 같은 수식으로 표현할 수 있다. 단, 하드웨어의 경우 하드웨어 스펙에 따라 달라질 수 있다.According to the application of the present invention, a performance improvement that occurs in the case of reading a NAN flash will be described. In the ECC or CRC implementation of the software, verifying the data is pure overhead. Existing data verification can be an overhead for embedded equipment that lacks CPU power. Therefore, the read performance can be improved by applying the present invention. Preferably, it can be expressed by the formula shown in Table 4. However, hardware may vary depending on hardware specifications.

(제로 섹터 개수) * (ECC 값 또는 CRC 값 비교 및 에러 수정 시간)(Zero sector count) * (ECC value or CRC value comparison and error correction time)

예를 들어, 총 섹터의 개수가 32768인 16M NAND의 경우, 총 섹터 중 3276 개수가 제로 섹터라 하면, 기존의 ECC 값 또는 CRC 값 비교 및 에러 수정 시간이 100ns라 하면, 본 발명의 적용을 통해 수식에서 3276*100ns로 0.3ms의 시간을 절약할 수 있다. 즉, 도 4의 S411, S421 및 S431단계에서 0x00 데이터의 경우 ECC 또는 CRC를 통해 데이터가 정상인 것을 판단하는 단계를 생략할 수 있으므로 읽기 성능을 향상시킬 수 있다.For example, in the case of 16M NAND having a total number of sectors of 32768, if 3276 of the total sectors are zero sectors, and a comparison time of an existing ECC value or CRC value and an error correction time is 100 ns, In the equation, 3276 * 100ns can save 0.3ms of time. That is, in the case of 0x00 data in steps S411, S421, and S431 of FIG. 4, the step of determining that data is normal through ECC or CRC may be omitted, thereby improving read performance.

이상 첨부된 도면을 참조하여 본 발명의 실시예를 설명하였지만, 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자는 본 발명이 그 기술적 사상이나 필수적인 특징을 변경하지 않고서 다른 구체적인 형태로 실시될 수 있다는 것을 이해할 수 있을 것이다. 그러므로 이상에서 기술한 실시예들은 모든 면에서 예시적인 것이며 한정적이 아닌 것으로 이해해야만 한다.Although embodiments of the present invention have been described above with reference to the accompanying drawings, those skilled in the art to which the present invention pertains may implement the present invention in other specific forms without changing the technical spirit or essential features thereof. I can understand that. Therefore, it should be understood that the embodiments described above are exemplary in all respects and not restrictive.

상기한 바와 같은 본 발명의 NAND 플래시 제어 장치 및 방법에 따르면 NAND 플래시의 프로그램 및 읽기 성능을 향상시킬 수 있으며, ECC/CRC를 사용하는 디바이스에서는 에러 정정하는 시간을 줄일 수 있는 효과가 있다.According to the NAND flash control apparatus and method of the present invention as described above can improve the program and read performance of the NAND flash, the device using ECC / CRC can reduce the time of error correction.

Claims (4)

플래시 메모리에 프로그램하려는 데이터에 대해서 상기 데이터의 ECC(Error Correction Check) 또는 CRC(Cyclic Redundancy Check) 값을 생성하는 생성부;A generator configured to generate an Error Correction Check (ECC) or Cyclic Redundancy Check (CRC) value of the data for data to be programmed into a flash memory; 상기 생성된 ECC 값 또는 CRC 값을 판독하는 판독부; A reading unit that reads the generated ECC value or CRC value; 상기 판독된 ECC 값 또는 CRC 값을 검사하여 섹터가 제로 섹터인지 여부를 판단하는 제어부; 및A controller which determines whether a sector is a zero sector by examining the read ECC value or CRC value; And 상기 섹터가 상기 제로 섹터인 경우 스페어 영역에 제로 마킹하는 기록부를 포함하고, 상기 제어부는 상기 ECC 값 또는 상기 CRC 값이 0x00 값에 해당할 경우 상기 섹터를 제로 섹터인 경우로 판단하는, NAND 플레시 제어 장치.And a recording unit that zero-marks the spare area when the sector is the zero sector, and wherein the controller determines that the sector is a zero sector when the ECC value or the CRC value corresponds to a value of 0x00. Device. 제 1항에 있어서,The method of claim 1, 상기 제로 마킹은 0x00 값으로 상기 스페어 영역에 기록하고, 상기 제로 섹터는 상기 섹터의 저장 데이터가 모두 0x00인 값이고, 상기 제로 섹터를 데이터 영역에 프로그램하지 않는 NAND 플래시 제어 장치.And the zero marking is written to the spare area with a value of 0x00, and the zero sector is a value in which all of the stored data of the sector is 0x00, and the zero sector is not programmed in the data area. ECC 값 또는 CRC 값을 판독하는 단계; Reading an ECC value or a CRC value; 상기 ECC 값 또는 상기 CRC 값을 검사하여 섹터가 제로 섹터인 가능성을 판단하는 단계; 및Examining the ECC value or the CRC value to determine the likelihood that a sector is a zero sector; And 상기 섹터가 상기 제로 섹터인 경우 스페어 영역에 제로 마킹하는 단계를 포함하는 NAND 플래시 제어 방법.And zero marking a spare area when the sector is the zero sector. 제 3항에 있어서,The method of claim 3, wherein 상기 제로 마킹은 0x00 값으로 상기 스페어 영역에 기록하고, 상기 제로 섹터는 상기 섹터의 저장 데이터가 모두 0x00인 값이고, 상기 제로 섹터를 데이터 영역에 프로그램하지 않는 NAND 플래시 제어 방법.And the zero marking is written in the spare area with a value of 0x00, and the zero sector is a value in which all of the stored data of the sector is 0x00, and the zero sector is not programmed in the data area.
KR1020060004409A 2006-01-16 2006-01-16 Apparatus and method for controlling nand flash KR100736093B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020060004409A KR100736093B1 (en) 2006-01-16 2006-01-16 Apparatus and method for controlling nand flash

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020060004409A KR100736093B1 (en) 2006-01-16 2006-01-16 Apparatus and method for controlling nand flash

Publications (1)

Publication Number Publication Date
KR100736093B1 true KR100736093B1 (en) 2007-07-06

Family

ID=38503338

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020060004409A KR100736093B1 (en) 2006-01-16 2006-01-16 Apparatus and method for controlling nand flash

Country Status (1)

Country Link
KR (1) KR100736093B1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100866624B1 (en) * 2007-02-23 2008-11-03 삼성전자주식회사 Method for controlling two or more non-volatile memory device and Apparatus there-of
KR100949471B1 (en) * 2008-04-03 2010-03-29 주식회사 코아로직 Method of inputing and outputing data in NAND flash using softwareS/W error correction codeECC and embedded system using the same method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000124812A (en) 1998-10-12 2000-04-28 Kyocera Corp Error-correcting decoding device
JP2000149598A (en) 1998-11-04 2000-05-30 Hitachi Ltd Semiconductor storage device
JP2001358594A (en) 2000-04-14 2001-12-26 Matsushita Electric Ind Co Ltd Crc computing device and crc computing method
KR20060014320A (en) * 2004-08-10 2006-02-15 삼성전자주식회사 A device and method for using for nand flash memory have multi boot lodor code

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000124812A (en) 1998-10-12 2000-04-28 Kyocera Corp Error-correcting decoding device
JP2000149598A (en) 1998-11-04 2000-05-30 Hitachi Ltd Semiconductor storage device
JP2001358594A (en) 2000-04-14 2001-12-26 Matsushita Electric Ind Co Ltd Crc computing device and crc computing method
KR20060014320A (en) * 2004-08-10 2006-02-15 삼성전자주식회사 A device and method for using for nand flash memory have multi boot lodor code

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100866624B1 (en) * 2007-02-23 2008-11-03 삼성전자주식회사 Method for controlling two or more non-volatile memory device and Apparatus there-of
KR100949471B1 (en) * 2008-04-03 2010-03-29 주식회사 코아로직 Method of inputing and outputing data in NAND flash using softwareS/W error correction codeECC and embedded system using the same method

Similar Documents

Publication Publication Date Title
US9075740B2 (en) Memory system
US9703698B2 (en) Data writing method, memory controller and memory storage apparatus
US9019770B2 (en) Data reading method, and control circuit, memory module and memory storage apparatus and memory module using the same
US9665481B2 (en) Wear leveling method based on timestamps and erase counts, memory storage device and memory control circuit unit
US20170039141A1 (en) Mapping table updating method, memory storage device and memory control circuit unit
CN111078149A (en) Memory management method, memory storage device and memory control circuit unit
US8737126B2 (en) Data writing method, and memory controller and memory storage apparatus using the same
TWI545572B (en) Memory cell programming method, memory control circuit unit and memory storage apparatus
US9582224B2 (en) Memory control circuit unit, memory storage apparatus and data accessing method
KR101468432B1 (en) Flash memory refresh techniques triggered by controlled scrub data reads
US10503433B2 (en) Memory management method, memory control circuit unit and memory storage device
WO2019136968A1 (en) Method for protecting data array and restoring flash memory internal data
US9312013B1 (en) Configuration method of erase operation, memory controlling circuit unit and memory storage device
US8081517B2 (en) Solid state storage system for uniformly using memory area and method controlling the same
TWI644210B (en) Memory management method, memory control circuit unit and memory storage apparatus
KR100736093B1 (en) Apparatus and method for controlling nand flash
US9760456B2 (en) Memory management method, memory storage device and memory control circuit unit
US11307982B2 (en) Memory management method with a data merging process based on risk physical units and distribution counts, memory storage device and memory control circuit unit
CN105761754B (en) Memory cell programming method, memory control circuit unit and memory device
CN111583976B (en) Data writing method, memory control circuit unit and memory storage device
US20060120153A1 (en) System and method for over erase reduction of nitride read only memory
WO2019136980A1 (en) Bad block processing method for multi-channel memory system
JP2005292925A (en) Memory controller, flash memory system, and control method for flash memory
JP4177301B2 (en) Memory controller, flash memory system, and flash memory control method
US11087848B1 (en) Data arranging method, memory control circuit unit and memory storage device for flash memory for improving the performance of valid data merging operation

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
LAPS Lapse due to unpaid annual fee