JP2009037317A - Memory controller, non-volatile storage device using the same, and non-volatile memory system - Google Patents

Memory controller, non-volatile storage device using the same, and non-volatile memory system Download PDF

Info

Publication number
JP2009037317A
JP2009037317A JP2007199362A JP2007199362A JP2009037317A JP 2009037317 A JP2009037317 A JP 2009037317A JP 2007199362 A JP2007199362 A JP 2007199362A JP 2007199362 A JP2007199362 A JP 2007199362A JP 2009037317 A JP2009037317 A JP 2009037317A
Authority
JP
Japan
Prior art keywords
data
cache
read
memory
physical block
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.)
Granted
Application number
JP2007199362A
Other languages
Japanese (ja)
Other versions
JP5073402B2 (en
Inventor
Toshiyuki Honda
利行 本多
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.)
Panasonic Corp
Original Assignee
Panasonic Corp
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 Panasonic Corp filed Critical Panasonic Corp
Priority to JP2007199362A priority Critical patent/JP5073402B2/en
Publication of JP2009037317A publication Critical patent/JP2009037317A/en
Application granted granted Critical
Publication of JP5073402B2 publication Critical patent/JP5073402B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Read Only Memory (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a memory controller for surely preventing the generation of any bit error due to read disturb, and a non-volatile storage device using the same, and a non-volatile storage system. <P>SOLUTION: This controller (memory controller) 2 for writing and reading data whose logical address is designated from host equipment 51 in and from a non-volatile memory 3 having a plurality of physical blocks 14 is provided with: a reading frequency table 11 for recording reading frequency by physical page units about a plurality of physical pages included in the plurality of physical blocks 14 as the reading frequency of the corresponding physical blocks 14; and a main control part 4 for restricting the reading operation of data to the non-volatile memory 3 by referring to the reading frequency table 11. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、不揮発性メモリの駆動制御を行うメモリーコントローラ、及びこれを用いた不揮発性記憶装置並びに不揮発性記憶システムに関する。   The present invention relates to a memory controller that controls driving of a nonvolatile memory, a nonvolatile storage device using the same, and a nonvolatile storage system.

近年、不揮発性記憶装置、例えばメモリーカードは、デジタルカメラや携帯電話に代表される携帯情報端末等の記憶媒体として使用されるようになってきており、その市場を拡大している。また、メモリーカードには、フラッシュメモリなどの不揮発性メモリが搭載されている。このような不揮発性メモリでは、半導体プロセスでの微細化に伴って、その容量が増加されている。また、不揮発性メモリでは、メモリセルの多値技術を用いることによって、さらなる容量増加が図られており、ビット単価を低下させて安価に入手できるようになってきている。ことに、NANDタイプのフラッシュメモリでは、そのビット単価が他の不揮発性メモリに比べて最も安価であるため、当該フラッシュメモリが広く普及している。しかしながら、このNANDタイプのフラッシュメモリには、いくつかのデータ保持に係わる特性が存在しており、半導体プロセスでの微細化に伴いその特性が顕著に現れることがあった。   In recent years, a nonvolatile storage device such as a memory card has been used as a storage medium for a portable information terminal represented by a digital camera or a mobile phone, and its market has been expanded. In addition, a nonvolatile memory such as a flash memory is mounted on the memory card. In such a non-volatile memory, the capacity thereof is increased with the miniaturization in the semiconductor process. Further, in the nonvolatile memory, the capacity is further increased by using the multi-value technology of the memory cell, and the bit unit price is lowered and it can be obtained at a low cost. In particular, NAND type flash memories are widely used because their bit unit price is the cheapest compared to other nonvolatile memories. However, this NAND-type flash memory has some characteristics related to data retention, and the characteristics may appear remarkably with miniaturization in a semiconductor process.

そこで、従来の不揮発性記憶装置では、例えば下記特許文献1に記載されているように、データの読み出し時にメモリセルに印加する電圧条件を調節することにより、メモリセルのリードディスターブ特性を向上させて、データ保持を高めることが提案されている。   Therefore, in the conventional nonvolatile memory device, for example, as described in Patent Document 1 below, the read disturb characteristic of the memory cell is improved by adjusting the voltage condition applied to the memory cell when reading data. It has been proposed to increase data retention.

また、従来の不揮発性記憶装置には、例えば下記特許文献2に記載されているように、データの読み出し時に誤り訂正符号回路を使用することによってリードディスターブによるビット誤りの進行の程度を検出するとともに、データをリフレッシュすることによってビット誤りの発生を未然に防ぐことが提案されている。
特開2002−298591公報 特開2004−326867公報
In addition, as described in Patent Document 2 below, for example, a conventional nonvolatile memory device detects the progress of bit error due to read disturb by using an error correction code circuit when reading data. It has been proposed to prevent bit errors from occurring by refreshing data.
Japanese Patent Laid-Open No. 2002-298591 JP 2004-326867 A

ところが、上記のような従来の不揮発性記憶装置では、リードディスターブによるビット誤りの発生を確実に防ぐことができないという問題点があった。具体的にいえば、上記特許文献1に記載された従来の不揮発性記憶装置では、メモリセル自身のリードディスターブ特性は確かに向上可能ではあるが、リードディスターブによるビット誤りが発生するのを確実に防ぐことはできなかった。また、上記特許文献2に記載された従来の不揮発性記憶装置では、リードディスターブによるビット誤りの進行の程度を検出するために、データの読み出し動作を行って誤り訂正符号回路を用いているが、このデータの読み出し動作によって、リードディスターブの原因になる劣化を促進して、ビット誤りを招くことがあった。   However, the conventional nonvolatile memory device as described above has a problem that it is impossible to reliably prevent the occurrence of bit errors due to read disturb. Specifically, in the conventional nonvolatile memory device described in Patent Document 1, the read disturb characteristic of the memory cell itself can surely be improved, but it is ensured that a bit error due to read disturb occurs. I couldn't prevent it. In addition, in the conventional nonvolatile memory device described in Patent Document 2, an error correction code circuit is used by performing a data read operation in order to detect the progress of bit error due to read disturb. This data read operation promotes deterioration that causes read disturb and may cause bit errors.

上記の課題に鑑み、本発明は、リードディスターブによるビット誤りの発生を確実に防ぐことができるメモリーコントローラ、及びこれを用いた不揮発性記憶装置並びに不揮発性記憶システムを提供することを目的とする。   In view of the above problems, an object of the present invention is to provide a memory controller that can reliably prevent the occurrence of bit errors due to read disturb, a nonvolatile memory device and a nonvolatile memory system using the memory controller.

上記の目的を達成するために、本発明にかかるメモリーコントローラは、複数の物理ブロックを有する不揮発性メモリに対し、外部からの論理アドレスを指定したデータの書き込み及び読み出しを行うメモリーコントローラであって、
前記論理アドレスと前記物理ブロックのアドレスとを変換するアドレス変換テーブルと、
前記論理アドレスが入力されるとともに、前記アドレス変換テーブルを参照して、前記不揮発性メモリに対するデータの書き込み動作及び読み出し動作を制御する主制御部を備え、
前記複数の各物理ブロックに含まれた複数の物理ページについて、前記物理ページ単位での読み出し回数を、対応する物理ブロックの読み出し回数として記録する読み出し回数テーブルが設けられ、
前記主制御部は、前記読み出し回数テーブルを参照して、前記不揮発性メモリに対するデータの読み出し動作を制限することを特徴とするものである。
In order to achieve the above object, a memory controller according to the present invention is a memory controller that writes and reads data specifying a logical address from the outside to a nonvolatile memory having a plurality of physical blocks,
An address conversion table for converting the logical address and the address of the physical block;
The logical address is input, and referring to the address conversion table, a main control unit that controls a data write operation and a read operation with respect to the nonvolatile memory,
For a plurality of physical pages included in each of the plurality of physical blocks, there is provided a read count table for recording the read count in units of physical pages as the read count of the corresponding physical block,
The main control unit is configured to limit a data read operation to the nonvolatile memory with reference to the read count table.

上記のように構成されたメモリーコントローラでは、不揮発性メモリの各物理ブロックに含まれた物理ページについて、物理ページ単位での読み出し回数を、対応する物理ブロックの読み出し回数として記録する読み出し回数テーブルが設置されるとともに、当該読み出し回数テーブルを参照して、データの読み出し動作を制限する主制御部が設けられている。これにより、上記従来例と異なり、リードディスターブによるビット誤りの発生を確実に防ぐことができる。   The memory controller configured as described above has a read count table that records the number of reads in physical page units as the number of reads of the corresponding physical block for the physical pages contained in each physical block of the nonvolatile memory. In addition, a main control unit that restricts the data read operation is provided with reference to the read count table. Thus, unlike the conventional example, it is possible to reliably prevent the occurrence of bit errors due to read disturb.

また、上記メモリーコントローラにおいて、前記不揮発性メモリの物理ブロックに格納されているデータをキャッシュ可能に構成されるとともに、前記主制御部に対して外部からデータの読み出し動作が要求されたときに、前記不揮発性メモリからデータを読み出すことなく当該データを外部に出力するための出力メモリと、
前記出力メモリにキャッシュされているキャッシュデータの読み出し回数を管理する出力テーブルを備えていることが好ましい。
Further, in the memory controller, the data stored in the physical block of the nonvolatile memory is configured to be cacheable, and when the data read operation is requested from the outside to the main control unit, An output memory for outputting the data to the outside without reading the data from the nonvolatile memory;
It is preferable that an output table for managing the read count of cache data cached in the output memory is provided.

この場合、出力メモリにデータをキャッシュさせることによって、そのデータの読み出し動作が外部から要求されたときに、当該データを不揮発性メモリから読み出すことなく、外部に出力することが可能となり、不揮発性メモリでのリードディスターブによる劣化を効率よく抑制することができる。   In this case, by caching the data in the output memory, when the data read operation is requested from the outside, the data can be output to the outside without being read from the nonvolatile memory. It is possible to efficiently suppress deterioration due to read disturb.

また、上記メモリーコントローラにおいて、前記主制御部には、前記不揮発性メモリの物理ブロックへのデータの書き込み動作が要求されたときに、当該データが前記出力メモリにキャッシュされているか否かについて前記出力テーブルを参照することにより判別し、かつ、当該データがキャッシュされていることを判別した場合には、前記出力メモリに対して当該データのキャッシュを開放することを指示する出力メモリ解放指示部が設けられてもよい。   In the memory controller, when the main control unit is requested to write data to the physical block of the non-volatile memory, the output is performed to determine whether the data is cached in the output memory. When determining by referring to the table and determining that the data is cached, an output memory release instruction unit is provided for instructing the output memory to release the cache of the data. May be.

この場合、出力メモリ解放指示部が出力メモリに対して不揮発性メモリに書き込まれたデータのキャッシュを開放することを指示するので、出力メモリの有効利用を容易に図ることができ、出力メモリの利用効率を高めることができる。   In this case, the output memory release instruction unit instructs the output memory to release the cache of the data written in the non-volatile memory, so that the effective use of the output memory can be facilitated. Efficiency can be increased.

また、上記メモリーコントローラにおいて、前記出力メモリ解放指示部は、前記不揮発性メモリの互いに異なる物理ブロックの間でデータの移動が行われたときに、当該データが前記出力メモリにキャッシュされているか否かについて前記出力テーブルを参照することにより判別し、かつ、当該データがキャッシュされていることを判別した場合には、前記出力メモリに対し当該データのキャッシュを開放することを指示することが好ましい。   In the memory controller, the output memory release instructing unit determines whether the data is cached in the output memory when data is moved between different physical blocks of the nonvolatile memory. In the case of determining by referring to the output table and determining that the data is cached, it is preferable to instruct the output memory to release the cache of the data.

この場合、出力メモリの利用効率をより確実に高めることができる。   In this case, the utilization efficiency of the output memory can be more reliably increased.

また、上記メモリーコントローラにおいて、前記主制御部には、外部からデータの読み出し動作が要求されたときに、前記読み出し回数テーブルから前記読み出し動作が要求されたデータに対応する読み出し回数を取得するとともに、前記出力テーブル及び前記読み出し回数テーブルを参照することにより、前記出力メモリにキャッシュされているキャッシュデータに対応する読み出し回数を求めて、前記読み出し動作が要求されたデータに対応する読み出し回数との比較を行って、データキャッシュの要否を判定するキャッシュ判定部と、
前記キャッシュ判定部により、前記読み出し動作が要求されたデータに対応する読み出し回数が前記キャッシュデータに対応する読み出し回数よりも多いことが判定されたときに、前記読み出し動作が要求されたデータを前記出力メモリにキャッシュさせるキャッシュ指示部が設けられていることが好ましい。
Further, in the memory controller, when a data read operation is requested from the outside, the main controller obtains a read count corresponding to the data for which the read operation is requested from the read count table, By referring to the output table and the read count table, the read count corresponding to the cache data cached in the output memory is obtained and compared with the read count corresponding to the data requested for the read operation. A cache determination unit for determining whether or not a data cache is necessary;
When the cache determination unit determines that the number of reads corresponding to the data requested for the read operation is greater than the number of reads corresponding to the cache data, the data requested for the read operation is output as the output It is preferable that a cache instruction unit for caching in the memory is provided.

この場合、出力メモリにキャッシュされるデータを適切に選ぶことができ、出力メモリの利便性を向上させることができる。   In this case, data cached in the output memory can be selected appropriately, and the convenience of the output memory can be improved.

また、上記メモリーコントローラでは、前記出力メモリに複数のキャッシュデータが存在している場合において、前記キャッシュ判定部は、前記複数のキャッシュデータにそれぞれ対応する複数の読み出し回数のうち、最小の読み出し回数を選択してもよい。   In the memory controller, when there are a plurality of cache data in the output memory, the cache determination unit determines a minimum number of times of reading out of a plurality of times of reading corresponding to the plurality of cache data. You may choose.

この場合、出力メモリにキャッシュされている複数のデータのうち、読み出し回数が最も少ないデータがキャッシュ判定部によって選択されるので、出力メモリにキャッシュされるデータをより適切に選ぶことが可能となり、出力メモリの利便性を容易に向上させることができる。   In this case, the data with the smallest number of reads out of the plurality of data cached in the output memory is selected by the cache determination unit, so that the data cached in the output memory can be selected more appropriately, and the output The convenience of the memory can be easily improved.

また、上記メモリーコントローラにおいて、前記主制御部には、外部からの論理アドレスによって指定された前記不揮発性メモリの物理ブロックからデータを読み出す読み出し動作が要求されたときに、当該物理ブロックの読み出し回数を前記読み出し回数テーブルから取得して、取得した読み出し回数と所定の閾値とを比較する回数比較部と、
前記回数比較部により、前記取得した読み出し回数が前記所定の閾値に達したことが判別されたときに、前記論理アドレスによって指定された前記不揮発性メモリの物理ブロックとは異なる別の物理ブロックに対し、前記読み出し動作が要求されたデータを移動することを指示するデータ移動指示部とが設けられていることが好ましい。
In the memory controller, when a read operation for reading data from the physical block of the nonvolatile memory designated by an external logical address is requested to the main control unit, the number of times of reading the physical block is set. A number comparison unit that is obtained from the read number table and compares the obtained number of reads with a predetermined threshold;
When it is determined by the number comparison unit that the acquired number of readings has reached the predetermined threshold, the physical block different from the physical block of the nonvolatile memory specified by the logical address Preferably, a data movement instructing unit for instructing to move data for which the read operation is requested is provided.

この場合、不揮発性メモリでのデータの保持性が低下するのを防止しつつ、リードディスターブによるビット誤りの発生を確実に防ぐことができる。   In this case, it is possible to reliably prevent the occurrence of bit errors due to read disturb while preventing the data retention in the nonvolatile memory from deteriorating.

また、上記メモリーコントローラにおいて、前記物理ブロックの消去回数を、対応する物理ブロックの書き換え回数として記録する書き換え回数テーブルを備え、
前記主制御部には、前記不揮発性メモリにおける、書き換え回数と許容読み出し回数との関係を示す関数が設定される関数設定部と、
外部からデータの読み出し動作が要求されたときに、前記読み出し回数テーブルから前記読み出し動作が要求されたデータに対応する読み出し回数を取得し、前記読み出し動作が要求されたデータに対応する書き換え回数を前記書き換え回数テーブルから取得し、かつ、前記読み出し動作が要求されたデータに対応する許容読み出し回数を、取得した書き換え回数を基に前記関数設定部から求め、求めた許容読み出し回数から取得した読み出し回数を引き算することにより、当該読み出し動作が要求されたデータについての残許容読み出し回数を算出するとともに、前記出力テーブル及び前記読み出し回数テーブルを参照することにより、前記出力メモリにキャッシュされているキャッシュデータに対応する読み出し回数を取得し、前記キャッシュデータに対応する書き換え回数を前記書き換え回数テーブルから取得し、かつ、前記キャッシュデータに対応する許容読み出し回数を、取得した書き換え回数を基に前記関数設定部から求め、求めた許容読み出し回数から取得した読み出し回数を引き算することにより、当該キャッシュデータについての残許容読み出し回数を算出して、前記読み出し動作が要求されたデータについての残許容読み出し回数との比較を行って、データキャッシュの要否を判定するキャッシュ判定部と、
前記キャッシュ判定部により、前記読み出し動作が要求されたデータに対応する残許容読み出し回数が前記キャッシュデータに対応する残許容読み出し回数よりも少ない場合に、前記読み出し動作が要求されたデータを前記出力メモリにキャッシュさせるキャッシュ指示部が設けられていることが好ましい。
The memory controller further includes a rewrite count table that records the erase count of the physical block as the rewrite count of the corresponding physical block,
In the main control unit, a function setting unit in which a function indicating a relationship between the number of rewrites and the allowable number of reads in the nonvolatile memory is set;
When a data read operation is requested from the outside, the read count corresponding to the data requested for the read operation is obtained from the read count table, and the rewrite count corresponding to the data requested for the read operation is obtained. Obtained from the function setting unit based on the obtained number of rewrites, and obtained the number of readings obtained from the obtained number of permitted readings, obtained from the rewrite number table and corresponding to the data for which the read operation is requested. By subtracting, the remaining allowable number of reads for the data for which the read operation is requested is calculated, and by referring to the output table and the read number table, it corresponds to the cache data cached in the output memory. The number of readings to be performed The rewrite count corresponding to the cache data is obtained from the rewrite count table, and the allowable read count corresponding to the cache data is obtained from the function setting unit based on the obtained rewrite count, and obtained from the obtained allowable read count. By subtracting the read count, the remaining allowable read count for the cache data is calculated and compared with the remaining allowable read count for the data for which the read operation is requested to determine whether the data cache is necessary. A cache determination unit for determining;
When the remaining allowable read count corresponding to the data for which the read operation is requested by the cache determination unit is smaller than the remaining allowable read count corresponding to the cache data, the data for which the read operation is requested is stored in the output memory. It is preferable to provide a cache instruction unit for caching.

この場合、出力メモリにキャッシュされるデータを適切に選ぶことができ、出力メモリの利便性を向上させることができる。また、キャッシュ判定部が、読み出し動作が要求されたデータ及びキャッシュデータにそれぞれ対応する残許容読み出し回数どうしを比較しているので、不揮発性メモリのリードディスターブストレスの程度に応じて、適切なキャッシュデータの選択を行うことができ、リードディスターブによるビット誤りの発生をより確実に防ぐことができる。   In this case, data cached in the output memory can be selected appropriately, and the convenience of the output memory can be improved. In addition, since the cache determination unit compares the remaining allowable read counts corresponding to the data for which the read operation is requested and the cache data, appropriate cache data is determined according to the degree of read disturb stress of the nonvolatile memory. Therefore, it is possible to more reliably prevent the occurrence of bit errors due to read disturb.

また、上記メモリーコントローラにおいて、前記出力メモリに複数のキャッシュデータが存在している場合において、前記キャッシュ判定部は、前記複数のキャッシュデータにそれぞれ対応する複数の読み出し回数のうち、最小の読み出し回数を選択してもよい。   In the memory controller, when there are a plurality of cache data in the output memory, the cache determination unit determines a minimum number of times of reading out of a plurality of times of reading corresponding to the plurality of cache data. You may choose.

この場合、出力メモリにキャッシュされている複数のデータのうち、読み出し回数が最も少ないデータがキャッシュ判定部によって選択されるので、出力メモリにキャッシュされるデータをより適切に選ぶことが可能となり、出力メモリの利便性を容易に向上させることができる。   In this case, the data with the smallest number of reads out of the plurality of data cached in the output memory is selected by the cache determination unit, so that the data cached in the output memory can be selected more appropriately, and the output The convenience of the memory can be easily improved.

また、上記メモリーコントローラにおいて、前記物理ブロックの消去回数を、対応する物理ブロックの書き換え回数として記録する書き換え回数テーブルを備え、
前記主制御部には、前記不揮発性メモリにおける、書き換え回数と許容読み出し回数との関係を示す関数が設定される関数設定部と、
外部からの論理アドレスによって指定された前記不揮発性メモリの物理ブロックからデータを読み出す読み出し動作が要求されたときに、当該物理ブロックの読み出し回数を前記読み出し回数テーブルから取得するとともに、当該物理ブロックの書き換え回数を前記書き換え回数テーブルから求め、かつ、求めた書き換え回数を基に前記関数設定部から許容読み出し回数を取得して、取得した読み出し回数と取得した許容読み出し回数とを比較する回数比較部と、
前記回数比較部により、前記取得した読み出し回数が前記許容読み出し回数に達したことが判別されたときに、前記論理アドレスによって指定された前記不揮発性メモリの物理ブロックとは異なる別の物理ブロックに対し、前記読み出し動作が要求されたデータを移動することを指示するデータ移動指示部とが設けられていることが好ましい。
The memory controller further includes a rewrite count table that records the erase count of the physical block as the rewrite count of the corresponding physical block,
In the main control unit, a function setting unit in which a function indicating a relationship between the number of rewrites and the allowable number of reads in the nonvolatile memory is set;
When a read operation for reading data from a physical block of the nonvolatile memory designated by an external logical address is requested, the physical block read count is acquired from the read count table and the physical block is rewritten. The number comparison unit for obtaining the number of times from the rewrite number table, obtaining the allowable read number from the function setting unit based on the obtained number of rewrites, and comparing the acquired read number and the acquired allowable read number;
When it is determined by the number comparison unit that the acquired number of readings has reached the allowable number of readings, a physical block different from the physical block of the nonvolatile memory specified by the logical address Preferably, a data movement instructing unit for instructing to move data for which the read operation is requested is provided.

この場合、不揮発性メモリでのデータの保持性が低下するのを防止しつつ、リードディスターブによるビット誤りの発生をより確実に防ぐことができる。   In this case, it is possible to more reliably prevent the occurrence of bit errors due to read disturb while preventing the retention of data in the nonvolatile memory from being deteriorated.

また、上記メモリーコントローラにおいて、前記関数では、前記書き換え回数に対して前記許容読み出し回数が単調減少してもよい。   In the memory controller, in the function, the allowable number of readings may monotonously decrease with respect to the number of rewrites.

この場合、上記不揮発性メモリの読み出し及び書き込み特性に応じたより適切な関数が使用されることとなり、上記キャッシュ判定部及びデータコピー移動部での各処理動作をより適切に行わせることができる。   In this case, a more appropriate function according to the read and write characteristics of the nonvolatile memory is used, and each processing operation in the cache determination unit and the data copy migration unit can be performed more appropriately.

また、本発明の不揮発性記憶装置は、複数の物理ブロックを有する不揮発性メモリ、及び
上記いずれかのメモリーコントローラを備えていることを特徴とするものである。
In addition, a nonvolatile memory device of the present invention includes a nonvolatile memory having a plurality of physical blocks, and any one of the above memory controllers.

また、本発明の不揮発性記憶システムは、複数の物理ブロックを有する不揮発性メモリと、前記不揮発性メモリに対し、外部からの論理アドレスを指定したデータの書き込み及び読み出しを行うメモリーコントローラを備えた不揮発性記憶装置、及び前記不揮発性記憶装置に対して論理アドレスを指定したアクセス指示を行うホスト機器を具備する不揮発性記憶システムであって、
前記メモリーコントローラには、上記いずれかのメモリーコントローラが用いられていることを特徴とするものである。
In addition, a nonvolatile memory system of the present invention includes a nonvolatile memory having a plurality of physical blocks, and a memory controller that writes and reads data specifying a logical address from the outside to the nonvolatile memory. A non-volatile storage system comprising: a volatile storage device; and a host device that performs an access instruction specifying a logical address for the non-volatile storage device,
Any of the above memory controllers is used as the memory controller.

上記のように構成された不揮発性記憶装置及び不揮発性記憶システムでは、リードディスターブによるビット誤りの発生を確実に防ぐことができるメモリーコントローラが用いられているので、信頼性の高い不揮発性記憶装置及び不揮発性記憶システムを容易に構成することができる。   In the nonvolatile memory device and the nonvolatile memory system configured as described above, a memory controller that can reliably prevent the occurrence of bit errors due to read disturb is used. Therefore, a highly reliable nonvolatile memory device and A nonvolatile storage system can be easily configured.

本発明によれば、リードディスターブによるビット誤りの発生を確実に防ぐことができるメモリーコントローラ、及びこれを用いた不揮発性記憶装置並びに不揮発性記憶システムを提供することが可能となる。   According to the present invention, it is possible to provide a memory controller that can reliably prevent the occurrence of bit errors due to read disturb, a nonvolatile memory device using the memory controller, and a nonvolatile memory system.

以下、本発明のメモリーコントローラ、不揮発性記憶装置、及び不揮発性記憶システムの好ましい実施形態について、図面を参照しながら説明する。なお、以下の説明では、本発明をメモリーカードに適用した場合を例示して説明する。   Hereinafter, preferred embodiments of a memory controller, a nonvolatile memory device, and a nonvolatile memory system of the present invention will be described with reference to the drawings. In the following description, a case where the present invention is applied to a memory card will be described as an example.

[第1の実施形態]
[不揮発性記憶システムの構成]
図1は、本発明の第1の実施形態にかかるメモリーコントローラを使用したメモリーカード及び不揮発性記憶システムの要部構成を示すブロック図である。図1において、本実施形態の不揮発性記憶システム50には、不揮発性記憶装置としてのメモリーカード1と、このメモリーカード1が着脱可能に接続されるとともに、メモリーカード1に対して論理アドレスを指定したアクセス指示を行うホスト機器51とが設けられている。そして、不揮発性記憶システム50では、これらメモリーカード1とホスト機器51との間で双方向のデータ転送が行えるように構成されている。なお、不揮発性記憶システム50は、デジタルカメラやパーソナルコンピュータ等に組み込まれて、その内部でデータを記憶する記憶システムを構築するようになっている。
[First Embodiment]
[Configuration of non-volatile storage system]
FIG. 1 is a block diagram showing a main configuration of a memory card and a nonvolatile storage system using the memory controller according to the first embodiment of the present invention. In FIG. 1, a nonvolatile memory system 50 according to the present embodiment is connected to a memory card 1 as a nonvolatile memory device, the memory card 1 is detachably connected, and a logical address is designated to the memory card 1. And a host device 51 that performs the access instruction. The nonvolatile storage system 50 is configured such that bidirectional data transfer can be performed between the memory card 1 and the host device 51. The non-volatile storage system 50 is built into a digital camera, personal computer, or the like, and a storage system that stores data therein is constructed.

メモリーカード1は、本発明のメモリーコントローラを用いて構成されたコントローラ2と、コントローラ2によってデータの書き込み制御及び読み出し制御が行われる不揮発性メモリ3とを備えている。具体的にいえば、不揮発性メモリ3には、例えばNANDタイプのフラッシュメモリが用いられており、その書き換え回数が100000回程度に制限されている。また、不揮発性メモリ3には、後に詳述するように、複数個の物理ブロック14が含まれている。   The memory card 1 includes a controller 2 configured using the memory controller of the present invention, and a nonvolatile memory 3 in which data writing control and reading control are performed by the controller 2. Specifically, for example, a NAND type flash memory is used as the nonvolatile memory 3, and the number of rewrites is limited to about 100,000. The nonvolatile memory 3 includes a plurality of physical blocks 14 as will be described in detail later.

コントローラ2は、不揮発性メモリ3に対し、外部からの論理アドレスを指定したデータの書き込み及び読み出しを行うように構成されている。すなわち、コントローラ2は、メモリーカード1の外部に設けられたホスト機器51から論理アドレスを指定した書き込み要求とともに転送されてきたデータを不揮発性メモリ3に書き込んだり、ホスト機器51から論理アドレスを指定した読み出し要求に応じて、データを不揮発性メモリ3から読み出して当該ホスト機器51に転送したりする。   The controller 2 is configured to write and read data specifying an external logical address with respect to the nonvolatile memory 3. That is, the controller 2 writes the data transferred together with the write request specifying the logical address from the host device 51 provided outside the memory card 1 to the nonvolatile memory 3 or specifies the logical address from the host device 51. In response to a read request, data is read from the nonvolatile memory 3 and transferred to the host device 51.

また、コントローラ2は、不揮発性メモリ3のデータ信頼性を向上させるための管理や制御を行うよう構成されている。すなわち、コントローラ2は、主制御部4と、ホスト機器51側及び不揮発性メモリ3側にそれぞれ設けられたインターフェースとしてのホストI/F 5及びメモリI/F 7と、これらのホストI/F 5とメモリI/F 7との間に設けられたバッファ6及び誤り検出訂正回路部(以下、“ECC”と略記する。)8を備えている。主制御部4には、CPUやDSPなどが用いられており、ホスト機器51から上記書き込み要求及び読み出し要求が入力されるようになっている。   The controller 2 is configured to perform management and control for improving the data reliability of the nonvolatile memory 3. That is, the controller 2 includes the main control unit 4, the host I / F 5 and the memory I / F 7 as interfaces provided on the host device 51 side and the nonvolatile memory 3 side, and the host I / F 5. And a memory I / F 7 are provided with a buffer 6 and an error detection / correction circuit section (hereinafter abbreviated as “ECC”) 8. A CPU, DSP, or the like is used for the main control unit 4, and the above write request and read request are input from the host device 51.

そして、コントローラ2では、主制御部4に書き込み要求が入力されると、ホスト機器51からのデータはホストI/F 5、バッファ6、及びメモリI/F 7を順次経由して不揮発性メモリ3へと転送されて、書き込み動作が行われる。また、このデータの書き込み動作の際には、ECC 8は当該データに誤り訂正用の符号を付加する。一方、主制御部4に読み出し要求が入力されて、読み出し動作が不揮発性メモリ3で行われると、その不揮発性メモリ3からのデータはメモリI/F 7、バッファ6、及びホストI/F 5を順次経由してホスト機器51へと転送される。また、このデータの読み出し動作の際には、ECC 8は付加した誤り訂正用の符号を使用して、当該データの誤りを訂正する。   In the controller 2, when a write request is input to the main control unit 4, the data from the host device 51 sequentially passes through the host I / F 5, the buffer 6, and the memory I / F 7 to the nonvolatile memory 3. And the write operation is performed. Further, in the data writing operation, the ECC 8 adds a code for error correction to the data. On the other hand, when a read request is input to the main control unit 4 and a read operation is performed in the nonvolatile memory 3, data from the nonvolatile memory 3 is stored in the memory I / F 7, the buffer 6, and the host I / F 5. Are sequentially transferred to the host device 51. In the data read operation, the ECC 8 corrects an error in the data by using the added error correction code.

また、コントローラ2は、アドレス変換テーブル9、書き換え回数テーブル10、及び読み出し回数テーブル11を備えている。さらに、コントローラ2には、不揮発性メモリ3の物理ブロック14に格納されているデータをキャッシュ可能に構成された出力メモリとしてのキャッシュメモリ12と、キャッシュメモリ12にキャッシュされているキャッシュデータの読み出し回数などの情報を管理する出力テーブルとしてのキャッシュテーブル13とが設けられており、主制御部4に対してホスト機器51からデータの読み出し動作が要求されたときに、不揮発性メモリ3からデータを読み出すことなく、当該データをキャッシュメモリ12からホスト機器51に出力可能に構成されている。また、キャッシュメモリ12には、複数、例えば0〜1023のページ番号が割り当てられた1024個のページが含まれている。また、各ページは、例えば2Kバイトのデータ領域を有している。   The controller 2 also includes an address conversion table 9, a rewrite count table 10, and a read count table 11. Further, the controller 2 includes a cache memory 12 as an output memory configured to cache data stored in the physical block 14 of the nonvolatile memory 3, and the number of times the cache data cached in the cache memory 12 is read. The cache table 13 is provided as an output table for managing information such as, and the data is read from the nonvolatile memory 3 when the main control unit 4 is requested to read data from the host device 51. The data can be output from the cache memory 12 to the host device 51 without any problem. The cache memory 12 includes a plurality of, for example, 1024 pages assigned with page numbers 0 to 1023. Each page has a data area of 2 Kbytes, for example.

そして、コントローラ2では、主制御部4がアドレス変換テーブル9、書き換え回数テーブル10、読み出し回数テーブル11、及びキャッシュテーブル13を適宜参照することにより、コントローラ2の各部の駆動制御を行うようになっている。さらに、コントローラ2では、主制御部4が読み出し回数テーブル11を参照して、不揮発性メモリ3からのデータの読み出し動作を制限するようになっており、不揮発性メモリ3にリードディスターブによるビット誤りの発生を確実に防止できるように構成されている(詳細は後述。)。   In the controller 2, the main control unit 4 performs drive control of each unit of the controller 2 by appropriately referring to the address conversion table 9, the rewrite count table 10, the read count table 11, and the cache table 13. Yes. Further, in the controller 2, the main control unit 4 refers to the number-of-reads table 11, and restricts the data reading operation from the nonvolatile memory 3, and the nonvolatile memory 3 has a bit error caused by read disturb. It is comprised so that generation | occurrence | production can be prevented reliably (details are mentioned later).

ここで、図2を参照して、主制御部4について具体的に説明する。   Here, the main control unit 4 will be described in detail with reference to FIG.

図2は、図1に示した主制御部の具体的な機能ブロックを示すブロック図である。   FIG. 2 is a block diagram showing specific functional blocks of the main control unit shown in FIG.

主制御部4には、回数比較部40、データ移動指示部41、及びキャッシュ制御部42が機能的に設けられている。また、主制御部4には、所定の閾値としての規定回数が予め設定されて、記憶する上限回数記憶部43が設置されている。回数比較部40は、ホスト機器51からの論理アドレスによって指定された不揮発性メモリ3の物理ブロック14からデータを読み出す読み出し動作が要求されたときに、当該物理ブロック14の読み出し回数を読み出し回数テーブル11から取得する。そして、回数比較部40は、取得した読み出し回数と、上限回数記憶部43に記憶されている規定回数との比較を行い、その比較結果をデータ移動指示部41に通知するようになっている。また、上記規定回数は、不揮発性メモリ3の物理ブロック14において、リードディスターブによるビット誤りを発生させない、読み出し動作の上限読み出し回数である。   The main control unit 4 is functionally provided with a number comparison unit 40, a data movement instruction unit 41, and a cache control unit 42. The main control unit 4 is provided with an upper limit number storage unit 43 that stores a predetermined number of times as a predetermined threshold in advance. When the read operation for reading data from the physical block 14 of the nonvolatile memory 3 designated by the logical address from the host device 51 is requested, the number comparison unit 40 indicates the number of times the physical block 14 has been read. Get from. The number comparison unit 40 compares the acquired number of readings with the specified number of times stored in the upper limit number storage unit 43 and notifies the data movement instruction unit 41 of the comparison result. The specified number of times is the upper limit number of times of reading operation that does not cause a bit error due to read disturb in the physical block 14 of the nonvolatile memory 3.

データ移動指示部41は、回数比較部40からの比較結果により、読み出し動作が要求されたデータの読み出し回数が上記規定回数に達したことが判別されたときに、ホスト機器51によって指定された論理アドレスとは相異なる論理アドレスで指定される、不揮発性メモリ3の別の物理ブロック14に対し、当該データを移動することを指示するようになっている。これにより、不揮発性メモリ3では、2つの物理ブロック14の間で読み出し動作が要求されたデータの移動処理が行われて、当該データの移動処理が完了される。   When the data movement instruction unit 41 determines from the comparison result from the number comparison unit 40 that the number of times of reading of data for which a read operation has been requested has reached the specified number of times, The other physical block 14 of the non-volatile memory 3 designated by a logical address different from the address is instructed to move the data. Thereby, in the nonvolatile memory 3, the data movement process for which the read operation is requested between the two physical blocks 14 is performed, and the data movement process is completed.

キャッシュ制御部42は、キャッシュメモリ12でのデータの書き込み制御及び読み出し制御を行うものであり、キャッシュ制御部42には、キャッシュ判定部42a、キャッシュ指示部42b、及びキャッシュ解放指示部42cが設けられている。キャッシュ判定部42aは、ホスト機器51からデータの読み出し動作が要求されたときに、キャッシュテーブル13を参照することにより、キャッシュメモリ12にデータキャッシュ可能なページが存在するか否かについて判定して、その判定結果をキャッシュ指示部42bに通知する。   The cache control unit 42 performs data write control and data read control in the cache memory 12, and the cache control unit 42 includes a cache determination unit 42a, a cache instruction unit 42b, and a cache release instruction unit 42c. ing. The cache determination unit 42a determines whether there is a data cacheable page in the cache memory 12 by referring to the cache table 13 when a data read operation is requested from the host device 51, and The determination result is notified to the cache instruction unit 42b.

また、キャッシュ判定部42aは、キャッシュメモリ12にデータキャッシュ可能なページが存在しないと判定したときには、読み出し動作が要求されたデータに対応する読み出し回数(すなわち、当該データが書き込まれている物理ブロック14の読み出し回数)を読み出し回数テーブル11から取得する。さらに、キャッシュ判定部42aは、読み出し回数テーブル11及びキャッシュテーブル13を参照することにより、キャッシュメモリ12にキャッシュされているキャッシュデータに対応する読み出し回数(つまり、当該キャッシュデータと同じデータが書き込まれている不揮発性メモリ3の物理ブロック14の読み出し回数)を求める。そして、キャッシュ判定部42aは、読み出し動作が要求されたデータに対応する読み出し回数と、キャッシュデータに対応する読み出し回数との比較を行って、データキャッシュの要否を判定して、その判定結果をキャッシュ指示部42bに通知するようになっている。   When the cache determination unit 42a determines that there is no page that can be cached in the cache memory 12, the cache determination unit 42a reads the number of times corresponding to the data for which the read operation is requested (that is, the physical block 14 in which the data is written). Is read from the read count table 11. Further, the cache determination unit 42 a refers to the read count table 11 and the cache table 13 to read the read count corresponding to the cache data cached in the cache memory 12 (that is, the same data as the cache data is written). The number of reads of the physical block 14 of the non-volatile memory 3 is determined. Then, the cache determination unit 42a compares the number of reads corresponding to the data for which the read operation is requested with the number of reads corresponding to the cache data, determines whether the data cache is necessary, and determines the determination result. The cache instruction unit 42b is notified.

また、キャッシュ判定部42aは、キャッシュメモリ12に複数のキャッシュデータが存在している場合には、複数のキャッシュデータにそれぞれ対応する複数の読み出し回数のうち、最小の読み出し回数を選択するように構成されている。   Further, the cache determination unit 42a is configured to select the minimum number of times of reading out of a plurality of times of reading corresponding to each of the plurality of cache data, when there are a plurality of pieces of cache data in the cache memory 12. Has been.

キャッシュ指示部42bは、キャッシュ判定部42aから、キャッシュメモリ12にデータキャッシュ可能なページが存在していること、または読み出し動作が要求されたデータに対応する読み出し回数がキャッシュデータに対応する読み出し回数よりも多いことが通知されたときに、読み出し動作が要求されたデータをキャッシュメモリ12にキャッシュさせるようになっている。   The cache instruction unit 42b determines that there is a page that can be cached in the cache memory 12 from the cache determination unit 42a, or the number of reads corresponding to the data for which the read operation is requested is greater than the number of reads corresponding to the cache data. When it is notified that there are too many, the data requested to be read out is cached in the cache memory 12.

キャッシュ解放指示部42cは、出力メモリ解放指示部を構成するものであり、ホスト機器51から不揮発性メモリ3へ論理アドレスを指定してデータの書き込み動作が要求されたときに、当該データがキャッシュメモリ12にキャッシュされているか否かについて、キャッシュテーブル13を参照することにより判別する。さらに、キャッシュ解放指示部42cは、データがキャッシュされていることを判別した場合には、キャッシュメモリ12に対して当該データのキャッシュを開放することを指示するようになっている。   The cache release instruction unit 42c constitutes an output memory release instruction unit, and when the host device 51 designates a logical address to the nonvolatile memory 3 and a data write operation is requested, the data is stored in the cache memory. 12 is determined by referring to the cache table 13. Further, when it is determined that the data is cached, the cache release instruction unit 42c instructs the cache memory 12 to release the cache of the data.

また、キャッシュ解放指示部42cは、不揮発性メモリ3の互いに異なる物理ブロック14の間でデータの移動が行われたときでも、当該データがキャッシュメモリ12にキャッシュされているか否かについて、キャッシュテーブル13を参照することにより判別し、かつ、当該データがキャッシュされていることを判別した場合には、キャッシュメモリ12に対し当該データのキャッシュを開放することを指示するようになっている。   Further, the cache release instruction unit 42 c determines whether or not the data is cached in the cache memory 12 even when the data is moved between the different physical blocks 14 of the nonvolatile memory 3. When it is determined that the data is cached, the cache memory 12 is instructed to release the cache of the data.

図1に戻って、不揮発性メモリ3は、例えばブロック番号0〜4095の4096個の物理ブロック14を有している。各物理ブロック14は、例えば256Kバイトのデータ領域と、2Kバイトの管理領域とを備えている。また、各物理ブロック14では、ホスト機器51からのデータがデータ領域に書き込まれ、誤り訂正用の符号などが管理領域に書き込まれる。さらに、物理ブロック14は、不揮発性メモリ3のデータの消去単位であり、不揮発性メモリ3では、データを書き換える際には消去単位である物理ブロック14単位でデータの書き換えが行われる。   Returning to FIG. 1, the nonvolatile memory 3 includes 4096 physical blocks 14 having block numbers 0 to 4095, for example. Each physical block 14 includes, for example, a 256 Kbyte data area and a 2 Kbyte management area. In each physical block 14, data from the host device 51 is written in the data area, and a code for error correction is written in the management area. Further, the physical block 14 is a data erasure unit of the nonvolatile memory 3. In the nonvolatile memory 3, data is rewritten in units of the physical block 14 which is an erasure unit when data is rewritten.

次に、物理ブロック14について、その構成を示す図3を参照して具体的に説明する。   Next, the physical block 14 will be specifically described with reference to FIG.

図3に例示するように、物理ブロック14には、ページ番号0〜127の128個の物理ページ14aが設けられている。各物理ページ14aは、例えば2Kバイトのデータ領域と、64バイトの管理領域とを有している。また、この物理ページ14aはデータの書き込み単位でもあり、データの読み出し単位でもある。それゆえ、不揮発性メモリ3において、物理ブロック14のデータを全て読み出した場合には、128回の読み出し動作が当該物理ブロック14に対して行われたことになる。   As illustrated in FIG. 3, 128 physical pages 14 a with page numbers 0 to 127 are provided in the physical block 14. Each physical page 14a has, for example, a 2K byte data area and a 64 byte management area. The physical page 14a is both a data write unit and a data read unit. Therefore, when all the data of the physical block 14 is read in the nonvolatile memory 3, 128 read operations are performed on the physical block 14.

次に、図4〜図7を参照して、コントローラ4の内部に設けられたアドレス変換テーブル、書き換え回数テーブル、読み出し回数テーブル、及びキャッシュテーブルについて具体的に説明する。   Next, an address conversion table, a rewrite count table, a read count table, and a cache table provided in the controller 4 will be specifically described with reference to FIGS.

図4は図1に示したアドレス変換テーブルの構成を示す図であり、図5は図1に示した書き換え回数テーブルの構成を示す図である。図6は図1に示した読み出し回数テーブルの構成を示す図であり、図7は図1に示したキャッシュテーブルの構成を示す図である。   4 is a diagram showing the configuration of the address conversion table shown in FIG. 1, and FIG. 5 is a diagram showing the configuration of the rewrite count table shown in FIG. 6 is a diagram showing the configuration of the read count table shown in FIG. 1, and FIG. 7 is a diagram showing the configuration of the cache table shown in FIG.

図4に示すように、アドレス変換テーブル9には、論理ブロックの論理アドレスが書き込まれた列9aと、物理ブロック14のアドレスが書き込まれた列9bとが設けられており、このアドレス変換テーブル9は、互いに関連付けられた論理アドレス及び物理アドレスを相互に変換可能に構成されている。また、主制御部4がアドレス変換テーブル9を使用することにより、ホスト機器51からの論理アドレスを、不揮発性メモリ3の対応する物理ブロック14のアドレスに変換し、その変換したアドレスを用いてメモリI/F 7を制御することによって、不揮発性メモリ3での該当する物理ブロック14を指定することができるようになっている。   As shown in FIG. 4, the address conversion table 9 is provided with a column 9a in which the logical address of the logical block is written and a column 9b in which the address of the physical block 14 is written. Is configured to be able to convert a logical address and a physical address associated with each other. In addition, the main control unit 4 uses the address conversion table 9 to convert the logical address from the host device 51 into the address of the corresponding physical block 14 of the nonvolatile memory 3, and uses the converted address to store the memory. By controlling the I / F 7, the corresponding physical block 14 in the nonvolatile memory 3 can be designated.

図5に示すように、書き換え回数テーブル10には、物理ブロック14の番号が書き込まれた列10aと、対応する物理ブロック14に有効なデータが書き込まれているかどうかを示すフラグが書き込まれる列10bと、対応する物理ブロック14の書き換え回数が書き込まれる列10cとが設けられている。また、この列10cには、対応する物理ブロック14の消去回数が当該物理ブロック14の書き換え回数として記録されるようになっており、書き換え回数テーブル10は、物理ブロック14の消去回数を物理ブロック14単位に管理するように構成されている。   As shown in FIG. 5, in the rewrite count table 10, a column 10a in which the number of the physical block 14 is written, and a column 10b in which a flag indicating whether valid data is written in the corresponding physical block 14 is written. And a column 10c in which the number of rewrites of the corresponding physical block 14 is written. In this column 10c, the erase count of the corresponding physical block 14 is recorded as the rewrite count of the physical block 14, and the rewrite count table 10 indicates the erase count of the physical block 14 as the physical block 14. It is configured to manage in units.

図6に示すように、読み出し回数テーブル11には、物理ブロック14の番号が書き込まれた列11aと、対応する物理ブロック14の読み出し回数が書き込まれる列11bとが設けられている。また、読み出し回数テーブル11では、各物理ブロック14に含まれた複数の物理ページ14aについて、物理ページ14a単位での読み出し回数を、対応する物理ブロック14の読み出し回数として列11bに記録するようになっており、読み出し回数テーブル11は、物理ページ14a単位の読み出し回数を管理可能に構成されている。つまり、この読み出し回数テーブル11では、任意の物理ブロック14において、その先頭の物理ページ14aであるページ0から最終の物理ページ14aであるページ127まで順に読み出し動作が行われたとき、それら物理ページ14aの延べ読み出し回数である、128回が今回の読み出し動作における読み出し回数として当該任意の物理ブロック14での列11bの読み出し回数に加算される。   As illustrated in FIG. 6, the read count table 11 includes a column 11 a in which the number of the physical block 14 is written and a column 11 b in which the read count of the corresponding physical block 14 is written. In the read count table 11, the read count in units of physical pages 14 a is recorded in the column 11 b as the read count of the corresponding physical block 14 for a plurality of physical pages 14 a included in each physical block 14. The read count table 11 is configured to be able to manage the read count in units of physical pages 14a. In other words, in this read count table 11, when an arbitrary physical block 14 is read in order from page 0, which is the first physical page 14a, to page 127, which is the last physical page 14a, those physical pages 14a The total number of readings of 128 is added to the number of readings of the column 11b in the arbitrary physical block 14 as the number of readings in the current reading operation.

また、アドレス変換テーブル9、書き換え回数テーブル10、及び読み出し回数テーブル11には、いずれも不揮発性メモリ、好ましくは書き換え回数が十分大きいMRAM(Magnetoresistive Random Access Memory)などが用いられている。なお、アドレス変換テーブル9と書き換え回数テーブル10に関しては、SRAM(Static Random Access Memory)などの揮発性メモリで構成することも可能ではある。但し、この場合、不揮発性メモリ3にその情報を書き込んでおき、メモリーカード1に電源投入された後にアドレス変換テーブル9と書き換え回数テーブル10を作成するために不揮発性メモリ3からデータを読み出す必要がある。一方、読み出し回数テーブル11については、揮発性メモリで構成することは適切ではない。それというのは、読み出し回数を書き換え回数の制限の厳しい不揮発性メモリ3に書き込んでおくことはできないからである。   The address conversion table 9, the rewrite count table 10, and the read count table 11 all use a nonvolatile memory, preferably an MRAM (Magnetoresistive Random Access Memory) with a sufficiently large number of rewrites. Note that the address conversion table 9 and the rewrite count table 10 can be configured by a volatile memory such as SRAM (Static Random Access Memory). However, in this case, it is necessary to read the data from the non-volatile memory 3 in order to write the information in the non-volatile memory 3 and create the address conversion table 9 and the rewrite count table 10 after the memory card 1 is powered on. is there. On the other hand, it is not appropriate to configure the read count table 11 with a volatile memory. This is because the read count cannot be written in the non-volatile memory 3 where the limit of the rewrite count is severe.

図7に示すように、キャッシュテーブル13には、キャッシュメモリ12内のページアドレスが書き込まれた列13aと、対応するページにキャッシュされているキャッシュデータが有効であるか無効であるかを示すフラグが書き込まれる列13bとが設けられており、主制御部4が列13bに書き込まれたフラグを参照することで対応するページにデータがキャッシュされているか、あるいはそのページが空きページで新たなデータをキャッシュすることができるかについて判別できるようになっている。   As shown in FIG. 7, the cache table 13 includes a column 13a in which the page address in the cache memory 12 is written, and a flag indicating whether the cache data cached in the corresponding page is valid or invalid. Is stored in the corresponding page by referring to the flag written in the column 13b, or the page is an empty page and new data is stored. It can be determined whether or not can be cached.

また、キャッシュテーブル13には、対応するページにキャッシュされているキャッシュデータのページ単位の論理アドレスが書き込まれる列13cが設けられており、主制御部4がキャッシュデータのキャッシュ元を検索できるようになっている。つまり、主制御部4が、列13cに書き込まれた論理アドレスを用いることにより、キャッシュデータと同じデータが書き込まれている不揮発性メモリ3の物理ブロック14の物理ページ14aを特定可能になっている。   In addition, the cache table 13 is provided with a column 13c in which the logical address of the cache data cached in the corresponding page is written, so that the main control unit 4 can search the cache source of the cache data. It has become. That is, the main control unit 4 can specify the physical page 14a of the physical block 14 of the nonvolatile memory 3 in which the same data as the cache data is written by using the logical address written in the column 13c. .

また、キャッシュテーブル13には、対応するページにキャッシュされているキャッシュデータの読み出し回数が書き込まれる列13dが設けられており、そのページにデータキャッシュされた後、キャッシュメモリ12からホスト機器51に当該キャッシュデータが読み出された回数、つまりキャッシュヒットした回数が読み出し回数として列13dに記録されている。   Further, the cache table 13 is provided with a column 13d in which the read count of cache data cached in the corresponding page is written, and after the data is cached in the page, the cache memory 12 sends the data to the host device 51. The number of times the cache data is read, that is, the number of cache hits is recorded in the column 13d as the number of read times.

以下、上記のように構成された本実施形態でのデータの処理動作について、図1〜図15を参照して具体的に説明する。   Hereinafter, the data processing operation in the present embodiment configured as described above will be specifically described with reference to FIGS.

[データの読み出し動作]
まず、図8を参照して、データの読み出し動作について説明する。
[Data read operation]
First, a data read operation will be described with reference to FIG.

図8は、上記メモリーカードでの読み出し動作を示すフローチャートである。   FIG. 8 is a flowchart showing a read operation in the memory card.

図8において、主制御部4に対し、ホスト機器51から論理アドレスを指定したデータの読み出し動作が要求されると、主制御部4は、そのデータがキャッシュヒットするかどうかについて判定する(ステップS1)。具体的には、主制御部4は、キャッシュテーブル13の列13cを検索して、ホスト機器51からの論理アドレスが当該列13cに書き込まれているか否かを調べることにより、要求されたデータがキャッシュメモリ12にキャッシュされているか否かについて判定する。そして、列13cに該当する論理アドレスが書き込まれている場合には、さらに列13bのフラグを確認し、フラグが有効である場合に主制御部4は、キャッシュヒットしたとして、列13aからキャッシュメモリ12内の該当するページアドレスを求めて、その求めたページアドレスに基づいて、キャッシュメモリ13からキャッシュデータを読み出し、ホスト機器51に出力する(ステップS2)。また、このキャッシュメモリ12からホスト機器51へのデータ読み出し動作が完了すると、主制御部4は、キャッシュテーブル13の対応する列13d内の読み出し回数に1を加算して、当該読み出し回数を更新し、読み出し動作を終了する。   In FIG. 8, when the host controller 51 requests the main controller 4 to read data specifying a logical address, the main controller 4 determines whether or not the data hits the cache (step S1). ). Specifically, the main control unit 4 searches the column 13c of the cache table 13 and checks whether or not the logical address from the host device 51 is written in the column 13c. It is determined whether or not it is cached in the cache memory 12. When the logical address corresponding to the column 13c is written, the flag of the column 13b is further confirmed. When the flag is valid, the main control unit 4 determines that a cache hit has occurred and starts the cache memory from the column 13a. The corresponding page address in 12 is obtained, the cache data is read from the cache memory 13 based on the obtained page address, and is output to the host device 51 (step S2). When the data read operation from the cache memory 12 to the host device 51 is completed, the main control unit 4 adds 1 to the read count in the corresponding column 13d of the cache table 13 and updates the read count. The read operation is finished.

一方、上記ステップS1において、キャッシュヒットしなかった場合、つまりミスヒットである場合には、主制御部4は、アドレス変換テーブル9を参照することにより、不揮発性メモリ3の読み出し対象の物理ブロック14及び物理ページ14aを判別する。そして、主制御部4は、判別した物理ページ14aに基づいて、メモリI/F 7を制御して当該物理ページ14aからデータをバッファ6に読み出し、さらに、主制御部4は、ホストI/F 5を制御してバッファ6からホスト機器51にデータを出力する(ステップS3)。   On the other hand, if no cache hit occurs in step S1, that is, if there is a miss hit, the main control unit 4 refers to the address conversion table 9 to read the physical block 14 to be read from the nonvolatile memory 3. And the physical page 14a. Then, the main control unit 4 controls the memory I / F 7 based on the determined physical page 14a to read data from the physical page 14a into the buffer 6, and the main control unit 4 further reads the host I / F. 5 is output to the host device 51 from the buffer 6 (step S3).

続いて、主制御部4は、上記ステップS3にてデータが読み出された物理ブロック14に対応する読み出し回数テーブル11のカウンタをインクリメントする(ステップS4)。つまり、主制御部4は、データが読み出された物理ページ14aのページ数分の回数を、対応する列11bの読み出し回数に加算する。   Subsequently, the main control unit 4 increments the counter of the read count table 11 corresponding to the physical block 14 from which data has been read in step S3 (step S4). That is, the main control unit 4 adds the number of times of the number of physical pages 14a from which data has been read to the number of times of reading of the corresponding column 11b.

次に、主制御部4では、回数比較部40が上記ステップS4にて加算された後の読み出し回数と、上記規定回数との比較を行って、当該読み出し回数が規定回数に達したかどうかについて判別する(ステップS5)。そして、読み出し回数が規定回数に達していなければ、主制御部4は、キャッシュメモリ12に対して、上記ステップS3で読み出したデータをキャッシュするかどうかを判定する読み出しキャッシュ処理を実行して(ステップS6)、読み出し動作を終了する。   Next, the main control unit 4 compares the number of readings after the number comparison unit 40 adds in step S4 with the specified number of times, and whether or not the number of readings reaches the specified number of times. A determination is made (step S5). If the read count has not reached the specified count, the main control unit 4 executes a read cache process for determining whether or not to cache the data read in step S3 with respect to the cache memory 12 (step S3). S6) The read operation is terminated.

一方、上記ステップS5において、読み出し回数が規定回数に達したことが判別されると、主制御部4は、次にそのデータの読み出し動作が行われると、その読み出し回数が規定回数を超過して、リードディスターブによるビット誤りが、対応する物理ブロック14に生じるおそれがあると判断し、データ移動指示部41が当該データを別の物理ブロック14に移動させるデータ移動処理を実行して(ステップS7)、読み出し動作を終了する。   On the other hand, when it is determined in step S5 that the number of readings has reached the specified number, the main control unit 4 causes the number of readings to exceed the specified number when the next data reading operation is performed. Then, it is determined that a bit error due to read disturb may occur in the corresponding physical block 14, and the data movement instruction unit 41 executes a data movement process for moving the data to another physical block 14 (step S7). The read operation is finished.

[データ移動処理]
次に、図9〜図13を参照して、上記ステップS7のデータ移動処理について具体的に説明する。
[Data movement processing]
Next, with reference to FIGS. 9 to 13, the data movement process in step S <b> 7 will be specifically described.

図9は、図8に示したデータ移動処理の具体的な動作を示すフローチャートである。   FIG. 9 is a flowchart showing a specific operation of the data movement process shown in FIG.

まず、上記データ移動処理が実行される前の状態として、読み出し回数テーブル11、書き換え回数テーブル10、アドレス変換テーブル9、及び不揮発性メモリ3が、それぞれ図10(a)、(b)、(c)、及び(d)に示す状態である場合を例示して説明する。すなわち、不揮発性メモリ3では、図10(d)に示すように、ブロック番号0002の物理ブロック14に、論理ブロックのブロック番号0005の有効なデータが書き込まれており、このブロック番号0005が上記ステップS1において、ホスト機器51から指定された論理アドレスに相当するとする。また、ブロック番号0003の物理ブロック14には、無効なデータが存在しているものとする。さらに、このような不揮発性メモリ3の状態に対応して、アドレス変換テーブル9では、図10(c)に示すように、ブロック番号0005の論理ブロックに対応する物理ブロック14として、物理ブロック14のブロック番号0002が記録されている。   First, as a state before the data movement process is executed, the read count table 11, the rewrite count table 10, the address conversion table 9, and the nonvolatile memory 3 are shown in FIGS. 10A, 10B, and 10C, respectively. ) And (d) will be described as an example. That is, in the nonvolatile memory 3, as shown in FIG. 10D, valid data of the block number 0005 of the logical block is written in the physical block 14 of the block number 0002. In S1, it is assumed that it corresponds to the logical address designated by the host device 51. It is assumed that invalid data exists in the physical block 14 with the block number 0003. Further, in correspondence with the state of the nonvolatile memory 3, in the address conversion table 9, as shown in FIG. 10C, as the physical block 14 corresponding to the logical block with the block number 0005, Block number 0002 is recorded.

また、書き換え回数テーブル10では、図10(b)に示すように、列10bに、ブロック番号0002及び0003の物理ブロック14のフラグとして、有効及び無効を示すフラグがそれぞれ記録されている。また、列10cには、ブロック番号0002及び0003の物理ブロック14の書き換え回数として、それぞれ100回及び10回が記録されているとする。また、読み出し回数テーブル11には、図10(a)に示すように、ブロック番号0002及び0003の物理ブロック14の読み出し回数として、10000000回及び1000回がそれぞれ記録されているとする。また、上記ステップS5において、規定回数に到達したと判定されることによってステップS7のデータ移動処理が行われるが、ここでは規定回数が10000000回であり、ブロック番号0002の物理ブロック14の読み出し回数が上記規定回数に到達したことがデータ移動指示部41で判別されているとする。   Further, in the rewrite count table 10, as shown in FIG. 10B, flags indicating validity and invalidity are recorded in the column 10b as the flags of the physical blocks 14 having the block numbers 0002 and 0003, respectively. In the column 10c, 100 times and 10 times are recorded as the number of rewrites of the physical block 14 with the block numbers 0002 and 0003, respectively. Further, as shown in FIG. 10A, it is assumed that 10000000 times and 1000 times are recorded in the read count table 11 as the read counts of the physical blocks 14 with the block numbers 0002 and 0003, respectively. In step S5, it is determined that the specified number of times has been reached, and the data movement processing in step S7 is performed. Here, the specified number of times is 10000000, and the number of reads of the physical block 14 with the block number 0002 is It is assumed that the data movement instructing unit 41 has determined that the specified number of times has been reached.

以上のように、ブロック番号0002の物理ブロック14の読み出し回数が規定回数に到達したことが判別されているので、図9のステップS8に示すように、データ移動指示部41は、書き換え回数テーブル10の列10b及び列10cを参照して、無効な物理ブロック14のうち書き換え回数の少ない物理ブロック14を検索する。ここではブロック番号0003の物理ブロック14が無効であり、かつ、書き換え回数が最も少ない物理ブロック14として検索されたとする。   As described above, since it has been determined that the read count of the physical block 14 with the block number 0002 has reached the specified count, the data movement instruction unit 41, as shown in step S8 of FIG. Referring to the column 10b and the column 10c, the physical block 14 having a smaller number of rewrites among the invalid physical blocks 14 is searched. Here, it is assumed that the physical block 14 having the block number 0003 is invalid and searched as the physical block 14 having the smallest number of rewrites.

続いて、データ移動指示部41は、図9のステップS9に示すように、ステップS8で検索されたブロック番号0003の物理ブロック14をメモリI/F 7を制御して消去する。この結果、図11(d)に示すように、不揮発性メモリ3のブロック番号0003の物理ブロック14では、無効なデータが消去されている。尚、図11(a)〜(c)にそれぞれ示すように、読み出し回数テーブル11、書き換え回数テーブル10、及びアドレス変換テーブル9では、図10(a)〜(c)に示した状態から変更されていない。   Subsequently, as shown in step S9 in FIG. 9, the data movement instruction unit 41 controls the memory I / F 7 to erase the physical block 14 having the block number 0003 searched in step S8. As a result, as shown in FIG. 11D, invalid data is erased in the physical block 14 of the block number 0003 of the nonvolatile memory 3. 11A to 11C, the read count table 11, the rewrite count table 10, and the address conversion table 9 are changed from the states shown in FIGS. 10A to 10C. Not.

次に、データ移動指示部41は、図9のステップS10に示すように、アドレス変換テーブル9から旧データとなる移動元の論理アドレスのデータが存在する物理ブロック14のアドレスを取得する。この処理は上記ステップS3での物理ブロック14の読み出し処理と同じアドレスが用いられる。具体的には、アドレス変換テーブル9のブロック番号0005の論理ブロックに対応する物理ブロック14のブロック番号が0002と記録されているので、移動元の物理ブロック14のアドレスとして0002が取得される。   Next, the data movement instruction unit 41 acquires the address of the physical block 14 where the data of the movement source logical address that is the old data exists from the address conversion table 9 as shown in step S10 of FIG. This process uses the same address as the read process of the physical block 14 in step S3. Specifically, since the block number of the physical block 14 corresponding to the logical block of the block number 0005 in the address conversion table 9 is recorded as 0002, 0002 is acquired as the address of the physical block 14 of the movement source.

続いて、データ移動指示部41は、図9のステップS11に示すように、変数Xに先頭ページを設定し、さらにステップS10で取得した移動元である旧データの存在する物理ブロック14のページXのデータをバッファ6に読み出させて、ステップS8で検索した移動先となる消去済みの物理ブロック14のページXに、バッファ6に読み出させたデータを書き込ませる(ステップS12)。   Subsequently, as shown in step S11 of FIG. 9, the data movement instruction unit 41 sets the first page in the variable X, and further, the page X of the physical block 14 in which the old data that is the movement source acquired in step S10 exists. Is read out to the buffer 6 and the data read out to the buffer 6 is written to the page X of the erased physical block 14 to be moved in step S8 (step S12).

次に、データ移動指示部41は、図9のステップS13に示すように、変数Xが最終ページを示しているか否かについて判定して、最終ページでなければ、変数Xをインクリメントして(ステップS14)、ステップS12に戻ってページの移動処理を繰り返す。   Next, as shown in step S13 of FIG. 9, the data movement instructing unit 41 determines whether or not the variable X indicates the final page. If the variable X is not the final page, the data movement instructing unit 41 increments the variable X (step S13). S14), returning to step S12, the page moving process is repeated.

一方、上記ステップS13において、最終ページであることが判別されると、データ移動指示部41はデータの移動処理が終了したと判断する。この結果、図12(d)に示すように、不揮発性メモリ3のブロック番号0003の物理ブロック14では、ブロック番号0005の論理ブロックのデータが移動されて保持されている。尚、図12(a)〜(c)にそれぞれ示すように、読み出し回数テーブル11、書き換え回数テーブル10、及びアドレス変換テーブル9では、図10(a)〜(c)に示した状態から変更されていない。   On the other hand, if it is determined in step S13 that the page is the last page, the data movement instructing unit 41 determines that the data movement process has been completed. As a result, as shown in FIG. 12D, in the physical block 14 with the block number 0003 in the nonvolatile memory 3, the data of the logical block with the block number 0005 is moved and held. As shown in FIGS. 12A to 12C, the read count table 11, the rewrite count table 10, and the address conversion table 9 are changed from the states shown in FIGS. 10A to 10C. Not.

続いて、主制御部4は、図9のステップS15に示すように、書き換え回数テーブル10を更新する。その後、主制御部4は、アドレス変換テーブル9を更新し(ステップS16)、さらに、読み出し回数テーブル11のブロック番号0003の物理ブロック14に対応するカウンタをリセットさせる(ステップS17)。この結果、書き換え回数テーブル10では、図13(b)に示すように、消去が行われたブロック番号0003の物理ブロック14に対応する列10cの書き換え回数がインクリメントされて11回に変更されている。また、書き換え回数テーブル10の列10bでは、ブロック番号0002及び0003の物理ブロック14のフラグがそれぞれ無効及び有効に更新されている。これにより、不揮発性メモリ3では、ブロック番号0002の物理ブロック14にもブロック番号0005の論理ブロックのデータ(旧データ)が存在しているが、メモリーカード1では、以降無効なデータの存在する物理ブロック14として認識される。   Subsequently, the main control unit 4 updates the rewrite count table 10 as shown in step S15 of FIG. Thereafter, the main control unit 4 updates the address conversion table 9 (step S16), and further resets the counter corresponding to the physical block 14 with the block number 0003 in the read count table 11 (step S17). As a result, in the rewrite count table 10, as shown in FIG. 13B, the rewrite count of the column 10c corresponding to the physical block 14 of the block number 0003 that has been erased is incremented and changed to 11 times. . In the column 10b of the rewrite count table 10, the flags of the physical block 14 with the block numbers 0002 and 0003 are updated to invalid and valid, respectively. As a result, in the nonvolatile memory 3, the logical block data (old data) of the block number 0005 exists in the physical block 14 of the block number 0002, but in the memory card 1, the physical data in which invalid data exists thereafter. Recognized as block 14.

また、アドレス変換テーブル9では、ブロック番号0005の論理ブロックに対応する物理ブロック14がブロック番号0003に更新される。また、読み出し回数テーブル11では、消去が行われたブロック番号0003の物理ブロック14の読み出し回数が0回にリセットされる。   In the address conversion table 9, the physical block 14 corresponding to the logical block with the block number 0005 is updated to the block number 0003. In the read count table 11, the read count of the physical block 14 with the block number 0003 that has been erased is reset to zero.

[読み出しキャッシュ処理]
続いて、図14を参照して、上記ステップS6の読み出しキャッシュ処理について具体的に説明する。
[Read cache processing]
Next, with reference to FIG. 14, the read cache process in step S6 will be specifically described.

図14は、図8に示した読み出しキャッシュ処理の具体的な動作を示すフローチャートである。   FIG. 14 is a flowchart showing a specific operation of the read cache process shown in FIG.

図14のステップS18に示すように、キャッシュ判定部42aは、キャッシュテーブル13の列13bを参照して、キャッシュメモリ12内に無効なページが存在しているか否かについて判定する。具体的には、キャッシュ判定部42aは、無効なページが存在していると判定すると、キャッシュメモリ12に空きありと判断して、その判定結果をキャッシュ指示部42bに通知する。そして、キャッシュメモリ12に空きがあることがキャッシュ判定部42aから通知されると、キャッシュ指示部42bは、キャッシュメモリ12にデータをキャッシュさせて、キャッシュテーブル13に登録する(ステップS19)。   As illustrated in step S <b> 18 of FIG. 14, the cache determination unit 42 a refers to the column 13 b of the cache table 13 and determines whether there is an invalid page in the cache memory 12. Specifically, when the cache determination unit 42a determines that there is an invalid page, the cache determination unit 42a determines that the cache memory 12 has a free space, and notifies the cache instruction unit 42b of the determination result. When the cache determination unit 42a notifies that the cache memory 12 has a free space, the cache instruction unit 42b caches the data in the cache memory 12 and registers it in the cache table 13 (step S19).

具体的には、キャッシュ指示部42bは、上記ステップS3で読み出されたデータを、ステップS18で検索された無効なページに対しコピーすることでデータキャッシュさせる。さらに、キャッシュ指示部42bは、データキャッシュさせたキャッシュメモリ12のページアドレスを基に、キャッシュテーブル13の対応する列13bのフラグを有効に更新させ、対応する列13cの論理ページにページ単位の論理アドレスを記録させ、対応する列13dの読み出し回数に0回を記録させる。   Specifically, the cache instruction unit 42b causes the data read by copying the data read in step S3 to the invalid page retrieved in step S18 to cause data cache. Further, the cache instruction unit 42b effectively updates the flag of the corresponding column 13b of the cache table 13 based on the page address of the cache memory 12 that has been subjected to data caching, and the logical page of the corresponding column 13c is logically updated in page units. The address is recorded, and 0 is recorded as the number of readings of the corresponding column 13d.

一方、上記ステップS18において、無効なページが存在していないことが判定されると、キャッシュ判定部42aはキャッシュメモリ12に空きなしと判断する。さらに、キャッシュ判定部42aは、ステップS3で読み出されたデータが存在する物理ブロック14の読み出し回数を読み出し回数テーブル11から取得する(ステップS20)。   On the other hand, when it is determined in step S18 that there is no invalid page, the cache determination unit 42a determines that there is no space in the cache memory 12. Further, the cache determination unit 42a acquires the number of reads of the physical block 14 in which the data read in step S3 is present from the number-of-reads table 11 (step S20).

続いて、キャッシュ判定部42aは、キャッシュテーブル13の列13dを参照して、読み出し回数が最も少ない、つまりキャッシュヒット回数が最も少ないキャッシュメモリ12内のページを検索し、かつ、アドレス変換テーブル9を参照することにより、検索したページに対応する不揮発性メモリ3の物理ブロック14のアドレスを求める(ステップS21)。その後、キャッシュ判定部42aは、ステップS21で求めたアドレスを用いることにより、検索したページにキャッシュされているキャッシュデータに対応する不揮発性メモリ3の物理ブロック14の読み出し回数を読み出し回数テーブル11から取得する(ステップS22)。   Subsequently, the cache determination unit 42a refers to the column 13d of the cache table 13 to search for a page in the cache memory 12 with the smallest number of reads, that is, with the smallest number of cache hits. By referencing, the address of the physical block 14 of the nonvolatile memory 3 corresponding to the retrieved page is obtained (step S21). Thereafter, the cache determination unit 42a obtains, from the read count table 11, the read count of the physical block 14 of the nonvolatile memory 3 corresponding to the cache data cached in the searched page by using the address obtained in step S21. (Step S22).

次に、キャッシュ判定部42aは、ステップS20で取得したデータに対応する読み出し回数と、ステップS22で取得したキャッシュデータに対応する読み出し回数との比較を行い(ステップS23)、キャッシュデータに対応する読み出し回数の方が多ければ、キャッシュ判定部42aは、ステップS3で読み出されたデータをキャッシュする必要がないと判断して、読み出しキャッシュ処理を終了する。   Next, the cache determination unit 42a compares the number of reads corresponding to the data acquired in step S20 with the number of reads corresponding to the cache data acquired in step S22 (step S23), and reads corresponding to the cache data. If the number of times is larger, the cache determination unit 42a determines that the data read in step S3 does not need to be cached, and ends the read cache process.

一方、ステップS23において、キャッシュデータに対応する読み出し回数の方が少なければ、キャッシュ判定部42aは、ステップS3で読み出されたデータをキャッシュした方がよいと判定し、その判定結果をキャッシュ指示部42bに通知する。これにより、上記ステップS19の処理が、キャッシュ指示部42bにより実行される。但し、このステップS19では、キャッシュ指示部42bはステップS21で検索された検索ページに対して、ステップS3で読み出されたデータをコピーすることでデータキャッシュさせる。さらに、キャッシュ指示部42bは、データキャッシュさせた上記検索ページについてのキャッシュメモリ12のページアドレスを基に、キャッシュテーブル13の対応する列13bのフラグを有効に更新させ、対応する列13cの論理ページにページ単位の論理アドレスを記録させ、対応する列13dの読み出し回数に0回を記録させる。   On the other hand, if the number of reads corresponding to the cache data is smaller in step S23, the cache determination unit 42a determines that it is better to cache the data read in step S3, and the determination result is used as the cache instruction unit. 42b is notified. Thereby, the process of step S19 is executed by the cache instruction unit 42b. However, in this step S19, the cache instruction unit 42b causes the data retrieved by copying the data read in step S3 to be the data cache for the search page retrieved in step S21. Further, the cache instruction unit 42b effectively updates the flag of the corresponding column 13b of the cache table 13 based on the page address of the cache memory 12 for the search page that has been data cached, and the logical page of the corresponding column 13c. To record the logical address in page units, and record 0 times as the number of reads in the corresponding column 13d.

以上のようにデータをキャッシュするかどうかの判定処理は、キャッシュしようとしているページの不揮発性メモリ3での物理ブロック14単位での読み出し回数(ステップS20にて取得)と、キャッシュされているページのキャッシュ元である不揮発性メモリ3での物理ブロック14単位での読み出し回数(ステップS22)を用いて、実行される。   As described above, whether or not data is cached is determined by the number of readings in units of physical blocks 14 (obtained in step S20) in the nonvolatile memory 3 of the page to be cached and the cached page. This is executed using the number of readings in units of physical blocks 14 in the nonvolatile memory 3 that is the cache source (step S22).

[データの書き込み動作]
次に、図15を参照して、データの書き込み動作について具体的に説明する。
[Data write operation]
Next, the data write operation will be specifically described with reference to FIG.

図15は、上記メモリーカードでの書き込み動作を示すフローチャートである。   FIG. 15 is a flowchart showing a write operation in the memory card.

図15において、主制御部4に対し、ホスト機器51から論理アドレスを指定したデータの書き込み動作が要求されると、主制御部4は、書き換え回数テーブル10の列10b及び列10cを参照して、無効な物理ブロック14のうち、書き換え回数の少ない物理ブロック14を検索する(ステップS24)。その後、主制御部4は、メモリI/F 7を制御することにより、ステップS24で検索した物理ブロック14に書き込まれているデータを消去する(ステップS25)。   In FIG. 15, when the host controller 51 requests the main controller 4 to write data specifying a logical address, the main controller 4 refers to the columns 10b and 10c of the rewrite count table 10. Among the invalid physical blocks 14, a physical block 14 with a small number of rewrites is searched (step S24). Thereafter, the main control unit 4 controls the memory I / F 7 to erase the data written in the physical block 14 searched in step S24 (step S25).

次に、主制御部4は、ステップS25でデータ消去を施した物理ブロック14に対して、ホスト機器51からホストI/F 5を経由してバッファ6に転送されているデータを書き込み(ステップS26)、さらには、主制御部4は、当該物理ブロック14に対応する、書き換え回数テーブル10の列10bのフラグを有効に変更するとともに、列10cの書き換え回数をインクリメントして更新する(ステップS27)。   Next, the main control unit 4 writes the data transferred from the host device 51 to the buffer 6 via the host I / F 5 to the physical block 14 from which data has been erased in step S25 (step S26). Furthermore, the main control unit 4 effectively changes the flag of the column 10b of the rewrite count table 10 corresponding to the physical block 14, and increments and updates the rewrite count of the column 10c (step S27). .

続いて、主制御部4は、ステップS26でデータを書き込んだ物理ブロック14に関して、アドレス変換テーブル9を更新し(ステップS28)、さらには、主制御部4は、読み出し回数テーブル11の当該物理ブロック14に対応する列11bの読み出し回数を0回に変更する(ステップS29)。   Subsequently, the main control unit 4 updates the address conversion table 9 with respect to the physical block 14 in which the data is written in step S26 (step S28), and the main control unit 4 further updates the physical block in the read count table 11. The number of readings of the column 11b corresponding to 14 is changed to 0 (step S29).

その後、主制御部4では、キャッシュ解放指示部42cがステップS26で書き込まれたデータ(つまり、今回書き込み動作が要求されたデータ)がキャッシュメモリ12にキャッシュデータとして保持されているか否かについて判別し、かつ、キャッシュメモリ12に保持されているときには、そのキャッシュデータを解放するキャッシュ解放処理を実行する(ステップS30)。具体的には、キャッシュ解放指示部42cは、キャッシュテーブル13の列13cを参照することにより、上記データに含まれる論理ページが存在するか否かについて検索し、存在している場合には、そのページの列13bのフラグを無効に変更する。これはステップS26でのデータの書き込み処理によって、ステップS29で読み出し回数テーブル11の読み出し回数が0回にリセットされるデータについては、リードディスターブによるビット誤りを回避するために、キャッシュメモリ12にデータをキャッシュする必要がないからである。つまり、本実施形態では、キャッシュ解放指示部42cが書き込まれたデータに対応するキャッシュを必ず解放するようになっている。これにより、キャッシュメモリ12の有効利用を容易に図ることができ、当該キャッシュメモリ12の利用効率を高めることができる。   Thereafter, in the main control unit 4, the cache release instruction unit 42c determines whether or not the data written in step S26 (that is, data requested to be written this time) is held as cache data in the cache memory 12. If it is held in the cache memory 12, a cache release process for releasing the cache data is executed (step S30). Specifically, the cache release instruction unit 42c refers to the column 13c of the cache table 13 to search whether or not a logical page included in the data exists, and if it exists, The flag in the page column 13b is changed to invalid. This is because data is written to the cache memory 12 in order to avoid bit errors due to read disturb for data whose read count in the read count table 11 is reset to 0 in step S29 by the data write processing in step S26. This is because there is no need to cache. In other words, in the present embodiment, the cache release instruction unit 42c always releases the cache corresponding to the written data. As a result, effective use of the cache memory 12 can be facilitated, and the use efficiency of the cache memory 12 can be increased.

また、このキャッシュ解放処理は、ホスト機器51から書き込み動作が要求されたデータが物理ブロック14の容量、256Kバイトよりも小さく、データを書き換えるためにホスト機器51からのデータ以外のデータをメモリーカード1内で巻き込んで移動による書き込みの場合も同様である。つまり、本実施形態において、キャッシュ解放処理の対象となるデータは、メモリーカード1外部のホスト機器51からのデータだけでなく、不揮発性メモリ3の複数の物理ブロック14の間でのデータ移動されるデータを含んだものであり、不揮発性メモリ3の物理ブロックに14に対して書き込みが行われた全てのデータについて、キャッシュ解放を実施できるか否かついて判別される。このように、本実施形態では、互いに異なる物理ブロック14の間でデータ移動が行われたときも、キャッシュ解放処理を実行しているので、キャッシュメモリ12の利用効率をより確実に高めることができる。   Also, in this cache release process, the data requested to be written by the host device 51 is smaller than the capacity of the physical block 14 and 256 Kbytes, and data other than the data from the host device 51 is rewritten to the memory card 1 in order to rewrite the data. The same applies to the case of writing by moving around the inside. In other words, in the present embodiment, not only the data from the host device 51 outside the memory card 1 but also the data to be subjected to the cache release process is moved between the plurality of physical blocks 14 of the nonvolatile memory 3. It is determined whether or not cache release can be performed for all data that includes data and has been written to the physical block 14 of the nonvolatile memory 3. As described above, in the present embodiment, even when data movement is performed between different physical blocks 14, the cache release process is executed, so that the utilization efficiency of the cache memory 12 can be improved more reliably. .

以上のように、本実施形態のコントローラ(メモリーコントローラ)2では、ホスト機器(外部)51からの論理アドレスによって指定された不揮発性メモリ3の物理ブロック14からデータを読み出す読み出し動作が要求されたときに、回数比較部40が当該物理ブロック14の読み出し回数を読み出し回数テーブル11から取得して、取得した読み出し回数と上限回数記憶部43内の規定回数(所定の閾値)とを比較している。また、取得した読み出し回数が規定回数に達したことが判別されたときに、データ移動指示部41が、論理アドレスによって指定された不揮発性メモリ3の物理ブロック14とは異なる別の物理ブロック14に対し、読み出し動作が要求されたデータを移動することを指示している。これにより、本実施形態のコントローラ2では、不揮発性メモリ3にNANDタイプのフラッシュメモリが用いられたときでも、上記従来例と異なり、リードディスターブによるビット誤りの発生を確実に防ぐことができる。また、このようにリードディスターブによるビット誤りの発生を確実に防ぐことができるコントローラ2が用いられているので、信頼性の高いメモリーカード(不揮発性記憶装置)1及び不揮発性記憶システム50を容易に構成することができる。   As described above, in the controller (memory controller) 2 of the present embodiment, when a read operation for reading data from the physical block 14 of the nonvolatile memory 3 designated by the logical address from the host device (external) 51 is requested. In addition, the number comparison unit 40 acquires the number of readings of the physical block 14 from the number-of-reads table 11 and compares the acquired number of readings with a specified number (predetermined threshold) in the upper limit number storage unit 43. Further, when it is determined that the acquired number of readings has reached the specified number, the data movement instruction unit 41 moves to a different physical block 14 different from the physical block 14 of the nonvolatile memory 3 designated by the logical address. On the other hand, it instructs to move the data for which the read operation is requested. As a result, in the controller 2 of this embodiment, even when a NAND type flash memory is used as the nonvolatile memory 3, unlike the conventional example, it is possible to reliably prevent the occurrence of bit errors due to read disturb. In addition, since the controller 2 that can reliably prevent the occurrence of bit errors due to read disturb is used, a highly reliable memory card (nonvolatile storage device) 1 and nonvolatile storage system 50 can be easily obtained. Can be configured.

また、本実施形態では、キャッシュ判定部42aがステップS23に示した読み出し回数の比較を行うとともに、読み出し動作が要求されたデータに対応する読み出し回数がキャッシュメモリ(出力メモリ)12内のキャッシュデータに対応する読み出し回数よりも多いことが判定されたときに、キャッシュ指示部42bが読み出し動作が要求されたデータをキャッシュメモリ12にキャッシュさせている。これにより、本実施形態では、キャッシュメモリ12にキャッシュされるデータを適切に選ぶことができ、キャッシュメモリ12の利便性(データキャッシュ機能)を向上させることができる。さらに、本実施形態では、ステップS21に示したように、キャッシュ判定部42aが複数のキャッシュデータにそれぞれ対応する複数の読み出し回数のうち、最小の読み出し回数を選択し検索しているので、キャッシュメモリ12にキャッシュされるデータをより適切に選ぶことが可能となり、キャッシュメモリ12の利便性を容易に向上させることができる。   In this embodiment, the cache determination unit 42a compares the number of reads shown in step S23, and the number of reads corresponding to the data for which the read operation is requested is stored in the cache data in the cache memory (output memory) 12. When it is determined that the number is larger than the corresponding number of reads, the cache instruction unit 42b causes the cache memory 12 to cache the data requested for the read operation. Thereby, in this embodiment, the data cached in the cache memory 12 can be selected appropriately, and the convenience (data cache function) of the cache memory 12 can be improved. Furthermore, in this embodiment, as shown in step S21, the cache determination unit 42a selects and searches the minimum number of times of reading out of a plurality of times of reading corresponding to each of a plurality of cache data. The data cached in the cache memory 12 can be selected more appropriately, and the convenience of the cache memory 12 can be easily improved.

[第2の実施形態]
図16は、本発明の第2の実施形態にかかるメモリーコントローラの主制御部の具体的な機能ブロックを示すブロック図である。図において、本実施形態と上記第1の実施形態との主な相違点は、上限回数記憶部に代えて、不揮発性メモリにおける、書き換え回数と許容読み出し回数との関係を示す関数が設定される関数設定部を主制御部に設けるとともに、キャッシュ判定部が、関数設定部に設定された関数を用いて、データキャッシュの要否を判定する点である。なお、上記第1の実施形態と共通する要素については、同じ符号を付して、その重複した説明を省略する。
[Second Embodiment]
FIG. 16 is a block diagram showing specific functional blocks of the main controller of the memory controller according to the second embodiment of the present invention. In the figure, the main difference between this embodiment and the first embodiment is that a function indicating the relationship between the number of rewrites and the number of allowable reads in the nonvolatile memory is set instead of the upper limit number storage unit. The function setting unit is provided in the main control unit, and the cache determination unit determines whether the data cache is necessary by using the function set in the function setting unit. In addition, about the element which is common in the said 1st Embodiment, the same code | symbol is attached | subjected and the duplicate description is abbreviate | omitted.

すなわち、図16に示すように、本実施形態の主制御部4には、関数設定部44が設けられており、不揮発性メモリ3における、書き換え回数と許容読み出し回数との関係を示す関数が設定されるようになっている。また、キャッシュ制御部42には、第1の実施形態のキャッシュ判定部42の機能が付与されるとともに、関数設定部44に設定されている関数を用いて、データキャッシュの要否を判定するキャッシュ判定部42a’とが設けられている。   That is, as shown in FIG. 16, the main control unit 4 of the present embodiment is provided with a function setting unit 44, and a function indicating the relationship between the number of rewrites and the allowable number of reads in the nonvolatile memory 3 is set. It has come to be. In addition, the cache control unit 42 is provided with the function of the cache determination unit 42 of the first embodiment, and uses a function set in the function setting unit 44 to determine whether or not a data cache is necessary. A determination unit 42a 'is provided.

関数設定部44には、図17に例示するように、書き換え回数に対して許容読み出し回数が単調減少する直線60で規定される関数が設定されている。この関数は、不揮発性メモリ3の物理ブロック14単位での書き換え回数に対する、不揮発性メモリ3の物理ページ14a単位でのリードディスターブストレスに対する耐性に応じて定められたものであり、回数比較部40での比較処理に用いられるようになっており、この処理結果を反映したデータ移動指示部41での処理動作をより適切に行わせることができるようになっている。また、この関数は、キャッシュ判定部42a’での処理動作にも使用されるようになっており、この判定結果を反映した読み出しキャッシュ処理をより適切に行わせることができるようになっている。   In the function setting unit 44, as illustrated in FIG. 17, a function defined by a straight line 60 in which the allowable number of readings monotonously decreases with respect to the number of rewritings is set. This function is determined according to the resistance against the read disturb stress in the physical page 14a unit of the nonvolatile memory 3 with respect to the number of rewrites in the physical block 14 unit of the nonvolatile memory 3, and the number comparison unit 40 The data movement instructing unit 41 reflecting the processing result can be more appropriately performed. This function is also used for the processing operation in the cache determination unit 42a ', and the read cache process reflecting the determination result can be performed more appropriately.

キャッシュ判定部42a’は、ホスト機器51からデータの読み出し動作が要求されたときに、キャッシュテーブル13を参照することにより、キャッシュメモリ12にデータキャッシュ可能なページが存在するか否かについて判定して、その判定結果をキャッシュ指示部42bに通知する。   The cache determination unit 42a ′ determines whether or not there is a page that can be cached in the cache memory 12 by referring to the cache table 13 when a data read operation is requested from the host device 51. The determination result is notified to the cache instruction unit 42b.

また、キャッシュ判定部42a’は、キャッシュメモリ12にデータキャッシュ可能なページが存在しないと判定したときには、読み出し回数テーブル11から読み出し動作が要求されたデータに対応する読み出し回数を取得する。また、キャッシュ判定部42a’は、当該読み出し動作が要求されたデータに対応する書き換え回数を書き換え回数テーブル10から取得し、かつ、当該読み出し動作が要求されたデータに対応する許容読み出し回数を、取得した書き換え回数を基に関数設定部44から求め、求めた許容読み出し回数から取得した読み出し回数を引き算することにより、当該読み出し動作が要求されたデータについての残許容読み出し回数を算出する。   When the cache determination unit 42 a ′ determines that there is no data cacheable page in the cache memory 12, the cache determination unit 42 a ′ acquires the number of reads corresponding to the data requested for the read operation from the read number table 11. Further, the cache determination unit 42a ′ acquires the number of rewrites corresponding to the data for which the read operation is requested from the rewrite number table 10, and acquires the allowable number of reads corresponding to the data for which the read operation is requested. Based on the number of rewrites performed, the function setting unit 44 obtains the remaining allowable read count for the data for which the read operation is requested by subtracting the acquired read count from the obtained allowable read count.

さらに、キャッシュ判定部42a’は、読み出し回数テーブル11及びキャッシュテーブル13を参照することにより、キャッシュメモリ12にキャッシュされているキャッシュデータに対応する読み出し回数を取得する。また、キャッシュ判定部42a’は、当該キャッシュデータに対応する書き換え回数を書き換え回数テーブル10から取得し、かつ、当該キャッシュデータに対応する許容読み出し回数を、取得した書き換え回数を基に関数設定部44から求め、求めた許容読み出し回数から取得した読み出し回数を引き算することにより、当該キャッシュデータについての残許容読み出し回数を算出する。そして、キャッシュ判定部42a’は、読み出し動作が要求されたデータ及びキャッシュデータについての残許容読み出し回数どうし比較して、データキャッシュの要否を判定して、その判定結果をキャッシュ指示部42bに通知する。   Further, the cache determination unit 42 a ′ refers to the read count table 11 and the cache table 13 to obtain the read count corresponding to the cache data cached in the cache memory 12. Further, the cache determination unit 42a ′ acquires the number of rewrites corresponding to the cache data from the rewrite number table 10, and sets the allowable number of reads corresponding to the cache data based on the acquired number of rewrites. The remaining allowable read count for the cache data is calculated by subtracting the acquired read count from the calculated allowable read count. Then, the cache determination unit 42a ′ compares the data for which the read operation is requested and the remaining allowable number of read operations for the cache data, determines whether the data cache is necessary, and notifies the cache instruction unit 42b of the determination result. To do.

また、キャッシュ判定部42a’は、キャッシュメモリ12に複数のキャッシュデータが存在している場合には、複数のキャッシュデータにそれぞれ対応する複数の読み出し回数のうち、最小の読み出し回数を選択するように構成されている。   In addition, when a plurality of cache data exists in the cache memory 12, the cache determination unit 42a ′ selects the minimum number of readings from among a plurality of readings corresponding to each of the plurality of cache data. It is configured.

キャッシュ指示部42bは、キャッシュ判定部42a’から、キャッシュメモリ12にデータキャッシュ可能なページが存在していること、または読み出し動作が要求されたデータに対応する残許容読み出し回数がキャッシュデータに対応する残許容読み出し回数よりも少ないことが通知されたときに、読み出し動作が要求されたデータをキャッシュメモリ12にキャッシュさせるようになっている。   The cache instruction unit 42b indicates that there is a page that can be cached in the cache memory 12 from the cache determination unit 42a ′, or the remaining allowable read count corresponding to the data for which the read operation is requested corresponds to the cache data. When it is notified that the number is less than the remaining allowable number of reads, the cache memory 12 is made to cache the data requested for the read operation.

[データの読み出し動作]
以下、図18を参照して、本実施形態でのデータの読み出し動作について説明する。
[Data read operation]
Hereinafter, a data read operation according to the present embodiment will be described with reference to FIG.

図18は、図16に示した主制御部による読み出し動作を示すフローチャートである。   FIG. 18 is a flowchart showing a read operation by the main control unit shown in FIG.

図18において、本実施形態の主制御部4では、ステップS1、S3、及びS4に示した動作が終了されると、回数比較部40が読み出し回数テーブル11からステップS4にて加算された後の物理ブロック14の読み出し回数を取得するとともに、当該物理ブロック14の書き換え回数を書き換え回数テーブル10から取得する(ステップS31)。その後、回数比較部40は、ステップS31で取得した書き換え回数を基に関数設定部43から許容読み出し回数を取得する(ステップS32)。具体的には、回数比較部40は、ステップS31において、例えば図17に示す書き換え回数W1を取得し、ステップS32において、当該書き換え回数W1から求められる許容読み出し回数r1を取得する。   In FIG. 18, in the main control unit 4 of the present embodiment, after the operations shown in steps S1, S3, and S4 are finished, the number comparison unit 40 is added from the number-of-reads table 11 in step S4. The number of reads of the physical block 14 is acquired and the number of rewrites of the physical block 14 is acquired from the rewrite number table 10 (step S31). Thereafter, the number comparison unit 40 acquires the allowable number of readings from the function setting unit 43 based on the number of rewrites acquired in step S31 (step S32). Specifically, the number comparison unit 40 acquires, for example, the number of rewrites W1 illustrated in FIG. 17 in step S31, and acquires the allowable number of reads r1 obtained from the number of rewrites W1 in step S32.

続いて、回数比較部40は、取得した読み出し回数及び許容読み出し回数の比較を行って、当該読み出し回数が許容読み出し回数に達したかどうかについて判別する(ステップS33)。そして、読み出し回数が許容読み出し回数に達していなければ、主制御部4は、キャッシュメモリ12に対して、ステップS3で読み出したデータをキャッシュするかどうかを判定する読み出しキャッシュ処理を実行して(ステップS6)、読み出し動作を終了する。   Subsequently, the number comparison unit 40 compares the acquired number of readings and the allowable number of readings to determine whether or not the number of readings has reached the allowable number of readings (step S33). If the read count does not reach the allowable read count, the main control unit 4 executes a read cache process for determining whether or not the data read in step S3 is cached in the cache memory 12 (step S3). S6) The read operation is terminated.

一方、上記ステップS33において、読み出し回数が許容読み出し回数に達したことが判別されると、主制御部4は、第1の実施形態のものと同様に、データ移動指示部41によるデータ移動処理を実行させて、ステップS3で読み出したデータを元の物理ブロック14とは異なる別の物理ブロック14に移動させて、読み出し動作を終了する。   On the other hand, when it is determined in step S33 that the number of readings has reached the allowable number of readings, the main control unit 4 performs the data movement processing by the data movement instruction unit 41 as in the first embodiment. The data read in step S3 is moved to another physical block 14 different from the original physical block 14, and the read operation is terminated.

[読み出しキャッシュ処理]
続いて、図19を参照して、本実施形態での読み出しキャッシュ処理について具体的に説明する。
[Read cache processing]
Next, with reference to FIG. 19, the read cache processing in the present embodiment will be specifically described.

図19は、図18に示した読み出しキャッシュ処理の具体的な動作を示すフローチャートである。   FIG. 19 is a flowchart showing a specific operation of the read cache process shown in FIG.

図18において、本実施形態の主制御部4では、キャッシュ判定部42a’がステップS18に示した動作を実行して、キャッシュメモリ12での空き(無効なページ)の有無を判定する。そして、キャッシュメモリ12に空きがあることを判別したときには、第1の実施形態と同様に、キャッシュ指示部42bによってステップS19の処理が実行され、上記ステップS3で読み出されたデータがキャッシュメモリ12にキャッシュされて、キャッシュテーブル13に登録される。   In FIG. 18, in the main control unit 4 of the present embodiment, the cache determination unit 42 a ′ executes the operation shown in step S <b> 18 to determine whether there is a free space (invalid page) in the cache memory 12. When it is determined that there is a free space in the cache memory 12, the process of step S19 is executed by the cache instruction unit 42b as in the first embodiment, and the data read in step S3 is stored in the cache memory 12 as described above. And is registered in the cache table 13.

一方、上記ステップS18において、無効なページが存在していないことが判定されると、キャッシュ判定部42a’はキャッシュメモリ12に空きなしと判断する。さらに、キャッシュ判定部42a’は、ステップS3で読み出されたデータが存在する物理ブロック14の読み出し回数を読み出し回数テーブル11から取得するとともに、当該物理ブロック14の書き換え回数を書き換え回数テーブル10から取得する(ステップS34)。   On the other hand, if it is determined in step S18 that there is no invalid page, the cache determination unit 42a 'determines that there is no free space in the cache memory 12. Furthermore, the cache determination unit 42a ′ acquires the number of reads of the physical block 14 in which the data read in step S3 exists from the read number table 11, and acquires the number of rewrites of the physical block 14 from the number of rewrites table 10. (Step S34).

続いて、キャッシュ判定部42a’は、キャッシュテーブル13の列13dを参照して、読み出し回数が最も少ない、つまりキャッシュヒット回数が最も少ないキャッシュメモリ12内のページを検索し、かつ、アドレス変換テーブル9を参照することにより、検索したページに対応する不揮発性メモリ3の物理ブロック14のアドレスを求める(ステップS21)。   Subsequently, the cache determination unit 42a ′ refers to the column 13d of the cache table 13 to search for a page in the cache memory 12 with the smallest number of reads, that is, with the smallest number of cache hits, and the address conversion table 9 , The address of the physical block 14 of the nonvolatile memory 3 corresponding to the retrieved page is obtained (step S21).

次に、キャッシュ判定部42a’は、ステップS21で求めたアドレスを用いることにより、検索したページにキャッシュされているキャッシュデータに対応する不揮発性メモリ3の物理ブロック14の読み出し回数を読み出し回数テーブル11から取得する。また、キャッシュ判定部42a’は、ステップS21で求めたアドレスを用いることにより、検索したページにキャッシュされているキャッシュデータに対応する不揮発性メモリ3の物理ブロック14の書き換え回数を書き換え回数テーブル10から取得する(ステップS35)。   Next, the cache determination unit 42a ′ uses the address obtained in step S21 to calculate the number of reads of the physical block 14 of the nonvolatile memory 3 corresponding to the cache data cached in the retrieved page. Get from. Further, the cache determination unit 42a ′ uses the address obtained in step S21 to calculate the number of rewrites of the physical block 14 of the nonvolatile memory 3 corresponding to the cache data cached in the retrieved page from the rewrite number table 10. Obtain (step S35).

続いて、キャッシュ判定部42a’は、ステップ3で読み出されたデータとステップ21で求められたキャッシュデータの各々に関して、許容読み出し回数と読み出し回数との差分、つまり上記残許容読み出し回数を求めて比較する(ステップS36)。ステップ3で読み出されたデータについての残許容読み出し回数がステップ21で求められたキャッシュデータについての残許容読み出し回数よりも多ければ、キャッシュ判定部42a’は、ステップ3で読み出されたデータをキャッシュする必要がないと判断して、読み出しキャッシュ処理を終了する。   Subsequently, for each of the data read in step 3 and the cache data obtained in step 21, the cache determination unit 42a ′ obtains the difference between the allowable read count and the read count, that is, the remaining allowable read count. Compare (step S36). If the remaining allowable read count for the data read in step 3 is greater than the remaining allowable read count for the cache data obtained in step 21, the cache determination unit 42a ′ determines the data read in step 3 as the data. It is determined that there is no need to cache, and the read cache process is terminated.

一方、ステップS36において、ステップ3で読み出されたデータについての残許容読み出し回数がステップ21で求められたキャッシュデータについての残許容読み出し回数よりも少なければ、キャッシュ判定部42a’は、ステップS3で読み出されたデータをキャッシュした方がよいと判定して、その判定結果をキャッシュ指示部42bに通知する。これにより、上記ステップS19の処理が、キャッシュ指示部42bにより実行される。但し、このステップS19では、キャッシュ指示部42bはステップS21で検索された検索ページに対して、ステップS3で読み出されたデータをコピーすることでデータキャッシュさせる。さらに、キャッシュ指示部42bは、データキャッシュさせた上記検索ページについてのキャッシュメモリ12のページアドレスを基に、キャッシュテーブル13の対応する列13bのフラグを有効に更新させ、対応する列13cの論理ページにページ単位の論理アドレスを記録させ、対応する列13dの読み出し回数に0回を記録させる。   On the other hand, in step S36, if the remaining allowable read count for the data read in step 3 is less than the remaining allowable read count for the cache data obtained in step 21, the cache determination unit 42a ′ determines in step S3. It is determined that it is better to cache the read data, and the determination result is notified to the cache instruction unit 42b. Thereby, the process of step S19 is executed by the cache instruction unit 42b. However, in this step S19, the cache instruction unit 42b causes the data retrieved by copying the data read in step S3 to be the data cache for the search page retrieved in step S21. Further, the cache instruction unit 42b effectively updates the flag of the corresponding column 13b of the cache table 13 based on the page address of the cache memory 12 for the search page that has been data cached, and the logical page of the corresponding column 13c. To record the logical address in page units, and record 0 times as the number of reads in the corresponding column 13d.

具体的には、キャッシュ判定部42a’は、ステップS34において、ステップS3で読み出されたデータに対応する書き換え回数及び許容読み出し回数として、例えば図17に示す書き換え回数W1及び当該書き換え回数W1から求められる許容読み出し回数r1をそれぞれ取得する。また、キャッシュ判定部42a’は、読み出し回数テーブル11から当該データに対応する読み出し回数r1’を取得し、許容読み出し回数r1と読み出し回数r1’との差の値を演算して、ステップS3で読み出されたデータについての残許容読み出し回数を求める。   Specifically, in step S34, the cache determination unit 42a ′ obtains the number of rewrites and the allowable number of reads corresponding to the data read in step S3 from, for example, the number of rewrites W1 and the number of rewrites W1 shown in FIG. The permissible read count r1 is acquired. Further, the cache determination unit 42a ′ obtains the read count r1 ′ corresponding to the data from the read count table 11, calculates the difference value between the allowable read count r1 and the read count r1 ′, and reads it in step S3. The remaining allowable number of readings for the output data is obtained.

さらに、キャッシュ判定部42a’は、ステップS35において、ステップS21で検索されたキャッシュデータに対応する書き換え回数及び許容読み出し回数として、例えば図17に示す書き換え回数W2及び当該書き換え回数W2から求められる許容読み出し回数r2をそれぞれ取得する。また、キャッシュ判定部42a’は、読み出し回数テーブル11から当該キャッシュデータに対応する読み出し回数r2’を取得し、許容読み出し回数r2と読み出し回数r2’との差の値を演算して、ステップS21で検索されたキャッシュデータについての残許容読み出し回数を求める。そして、キャッシュ判定部42a’は、ステップS36において、ステップS3で読み出されたデータ及びステップS21で検索されたキャッシュデータについての残許容読み出し回数どうしの比較を行う。   Furthermore, in step S35, the cache determination unit 42a ′, as the number of rewrites and the allowable number of reads corresponding to the cache data searched in step S21, for example, the number of rewrites W2 shown in FIG. The number of times r2 is acquired. Further, the cache determination unit 42a ′ acquires the read count r2 ′ corresponding to the cache data from the read count table 11, calculates the difference between the allowable read count r2 and the read count r2 ′, and in step S21. The number of remaining allowable reads for the retrieved cache data is obtained. In step S 36, the cache determination unit 42 a ′ compares the remaining allowable read counts for the data read in step S 3 and the cache data searched in step S 21.

以上の構成により、本実施形態は、上記第1の実施形態のものと同様な作用効果を奏することができる。また、本実施形態では、回数比較部40がデータの読み出し動作が要求された物理ブロック14の書き換え回数を書き換え回数テーブル10から求め、かつ、求めた書き換え回数を基に関数設定部44から許容読み出し回数を取得して、当該物理ブロック14の読み出し回数との比較を行っている。さらに、データ移動指示部41は、読み出し回数が許容読み出し回数に達したときに、読み出し動作が要求されたデータを別の物理ブロック14に移動させている。これにより、本実施形態では、第1の実施形態のものに比べて、リードディスターブによるビット誤りの発生をより確実に防ぐことができる。   With the above configuration, the present embodiment can achieve the same operational effects as those of the first embodiment. Further, in the present embodiment, the number comparison unit 40 obtains the number of rewrites of the physical block 14 for which the data read operation is requested from the rewrite number table 10, and based on the obtained number of rewrites, permits reading from the function setting unit 44. The number of times is acquired and compared with the number of reads of the physical block 14. Further, the data movement instruction unit 41 moves the data requested for the read operation to another physical block 14 when the read count reaches the allowable read count. As a result, in this embodiment, it is possible to prevent the occurrence of bit errors due to read disturb more reliably than in the first embodiment.

すなわち、不揮発性メモリ3では、リードディスターブによるビット誤りの発生は、書き換え回数にも大きく依存する。言い換えれば、不揮発性メモリ3では、書き換え回数の少ない物理ブロック14の方が良好なリードディスターブ特性であり、書き換え回数が増加すればするほどリードディスターブ特性が低下していくという傾向がある。従って、ステップS31〜S33に示したように、読み出し回数と書き換え回数の両方を使用して、上記ビット誤りを防ぐために、データを移動するか否かを判断する方がより適切な判定を行うことができる。   That is, in the nonvolatile memory 3, the occurrence of a bit error due to read disturb greatly depends on the number of rewrites. In other words, in the nonvolatile memory 3, the physical block 14 with a smaller number of rewrites has a better read disturb characteristic, and the read disturb characteristic tends to decrease as the number of rewrites increases. Therefore, as shown in steps S31 to S33, it is more appropriate to determine whether to move data in order to prevent the bit error by using both the number of times of reading and the number of times of rewriting. Can do.

具体的には、本実施形態では、例えば書き換え回数が100回であれば、10000000回の許容読み出し回数を閾値とし、書き換え回数が1000000回になれば、1000回の許容読み出し回数を閾値として、物理ブロック14の使用状態に応じた適切な閾値が、回数比較部40での比較処理に用いられて、より適切な判定を行うことができる。   Specifically, in the present embodiment, for example, when the number of rewrites is 100, the allowable number of reads of 10000000 is set as a threshold, and when the number of rewrites reaches 1000000, the number of allowable reads is set as a threshold of 1000. An appropriate threshold value corresponding to the use state of the block 14 is used for the comparison process in the number comparison unit 40, so that a more appropriate determination can be made.

また、本実施形態では、キャッシュ判定部42a’が、読み出し動作が要求されたデータ及びキャッシュデータについての残許容読み出し回数どうしを比較しているので、不揮発性メモリ3のリードディスターブストレスの程度に応じて、適切なキャッシュデータの選択を行うことができ、リードディスターブによるビット誤りの発生をより確実に防ぐことができる。   Further, in the present embodiment, the cache determination unit 42a ′ compares the remaining allowable read counts for the data for which the read operation is requested and the cache data, so that it depends on the read disturb stress level of the nonvolatile memory 3. Therefore, it is possible to select appropriate cache data, and it is possible to more reliably prevent occurrence of bit errors due to read disturb.

尚、上記の実施形態はすべて例示であって制限的なものではない。本発明の技術的範囲は特許請求の範囲によって規定され、そこに記載された構成と均等の範囲内のすべての変更も本発明の技術的範囲に含まれる。   The above embodiments are all illustrative and not restrictive. The technical scope of the present invention is defined by the claims, and all modifications within the scope equivalent to the configurations described therein are also included in the technical scope of the present invention.

例えば、上記の説明では、メモリーカード(不揮発性記憶装置)に本発明を適用した場合について説明したが、本発明のメモリーコントローラはこれに限定されるものではなく、フラッシュディスクなどの他の不揮発性記憶装置及びこれを含んだ不揮発性記憶システムに適用することもできる。   For example, in the above description, the case where the present invention is applied to a memory card (nonvolatile memory device) has been described. However, the memory controller of the present invention is not limited to this, and other nonvolatile memory such as a flash disk is used. The present invention can also be applied to a storage device and a nonvolatile storage system including the storage device.

また、上記の説明では、読み出し動作が要求されたデータについての上記読み出し回数が、規定回数(所定の閾値)または許容読み出し回数に達したことが回数比較部により判別されたときに、データ移動指示部が当該データを不揮発性メモリの別の物理ブロックに移動することを指示する構成について説明した。しかしながら、本発明は、不揮発性メモリの各物理ブロックに含まれた物理ページについて、物理ページ単位での読み出し回数を、対応する物理ブロックの読み出し回数として記録する読み出し回数テーブルを設けるとともに、主制御部が読み出し回数テーブルを参照して、不揮発性メモリに対するデータの読み出し動作を制限するものであれば何等限定されない。   Further, in the above description, when the number comparison unit determines that the number of readings for the data for which a reading operation is requested has reached the specified number (predetermined threshold) or the allowable number of readings, a data movement instruction A configuration has been described in which the unit instructs to move the data to another physical block of the nonvolatile memory. However, the present invention provides a read count table for recording the read count in units of physical pages as the read count of the corresponding physical block for the physical pages included in each physical block of the nonvolatile memory, and the main control unit However, there is no limitation as long as it refers to the read count table and restricts the data read operation to the nonvolatile memory.

但し、上記の各実施形態のように、別の物理ブロックにデータを移動させる場合の方が、不揮発性メモリでのデータの保持性が低下するのを防止することができ、かつ、リードディスターブによるビット誤りの発生を確実に防ぐことができる点で好ましい。   However, when data is moved to another physical block as in each of the above embodiments, it is possible to prevent the data retention in the nonvolatile memory from being reduced, and read disturb This is preferable in that the occurrence of bit errors can be surely prevented.

また、上記の説明では、読み出し対象の物理ページからデータを読み出した後、回数比較部が読み出し回数と所定の閾値または許容読み出し回数との比較を行う場合について説明したが、本発明は、データの読み出し動作が要求されたときに上記の比較が行われるものであればよく、データの読み出し動作よりも前に当該比較を実行するものでもよい。   Further, in the above description, the case where the number comparison unit compares the number of readings with a predetermined threshold value or the allowable number of readings after reading data from the physical page to be read has been described. It is sufficient that the above comparison is performed when a read operation is requested, and the comparison may be executed before the data read operation.

また、上記の説明では、キャッシュメモリ(出力メモリ)を有するコントローラ(メモリーコントローラ)について説明したが、本発明のメモリーコントローラはこれに限定されるものではなく、出力メモリが設置されていないメモリーコントローラにも適用することができる。   In the above description, a controller (memory controller) having a cache memory (output memory) has been described. However, the memory controller of the present invention is not limited to this, and a memory controller in which no output memory is installed is used. Can also be applied.

但し、上記の各実施形態のように、出力メモリを設置してデータをキャッシュ可能に構成する場合の方が、データの読み出し動作が外部から要求されたときに、当該データを不揮発性メモリから読み出すことなく、ホスト機器(外部)に出力することが可能となり、不揮発性メモリでのリードディスターブによる劣化を効率よく抑制することができる点で好ましい。   However, as in the above embodiments, when the output memory is installed and the data can be cached, the data is read from the non-volatile memory when a data read operation is requested from the outside. Therefore, it is possible to output the data to the host device (external), and it is preferable in that deterioration due to read disturb in the nonvolatile memory can be efficiently suppressed.

また、上記の説明では、不揮発性メモリにNANDタイプのフラッシュメモリを用いた場合について説明したが、本発明はこれに限定されるものではなく、MONOS型やAND型などの他のタイプのフラッシュメモリにも適用することができる。   In the above description, the case where a NAND type flash memory is used as the nonvolatile memory has been described. However, the present invention is not limited to this, and other types of flash memory such as a MONOS type and an AND type are used. It can also be applied to.

本発明は、リードディスターブによるビット誤りが不揮発性メモリに発生するのを確実に防止することができるメモリーコントローラ、及びデータの信頼性が向上された不揮発性メモリを有する不揮発性記憶装置並びに不揮発性記憶システムに有用である。   The present invention relates to a memory controller that can reliably prevent bit errors caused by read disturb in a nonvolatile memory, a nonvolatile memory device having a nonvolatile memory with improved data reliability, and nonvolatile memory Useful for systems.

本発明の第1の実施形態にかかるメモリーコントローラを使用したメモリーカード及び不揮発性記憶システムの要部構成を示すブロック図である。It is a block diagram which shows the principal part structure of the memory card using the memory controller concerning the 1st Embodiment of this invention, and a non-volatile storage system. 図1に示した主制御部の具体的な機能ブロックを示すブロック図である。It is a block diagram which shows the specific functional block of the main control part shown in FIG. 図1に示した不揮発性メモリの物理ブロックの構成を示す図である。It is a figure which shows the structure of the physical block of the non-volatile memory shown in FIG. 図1に示したアドレス変換テーブルの構成を示す図である。It is a figure which shows the structure of the address conversion table shown in FIG. 図1に示した書き換え回数テーブルの構成を示す図である。It is a figure which shows the structure of the rewrite frequency table shown in FIG. 図1に示した読み出し回数テーブルの構成を示す図である。It is a figure which shows the structure of the reading frequency table shown in FIG. 図1に示したキャッシュテーブルの構成を示す図である。It is a figure which shows the structure of the cache table shown in FIG. 上記メモリーカードでの読み出し動作を示すフローチャートである。It is a flowchart which shows read-out operation | movement with the said memory card. 図8に示したデータ移動処理の具体的な動作を示すフローチャートである。It is a flowchart which shows the specific operation | movement of the data movement process shown in FIG. (a)、(b)、(c)及び(d)は、上記データ移動処理が行われる前における、読み出し回数テーブル、書き換え回数テーブル、アドレス変換テーブル、及び不揮発性メモリの具体的な状態をそれぞれ説明する図である。(A), (b), (c), and (d) are specific states of the read count table, the rewrite count table, the address conversion table, and the nonvolatile memory, respectively, before the data movement process is performed. It is a figure explaining. (a)、(b)、(c)及び(d)は、図9のステップS9の動作が行われた後における、読み出し回数テーブル、書き換え回数テーブル、アドレス変換テーブル、及び不揮発性メモリの具体的な状態をそれぞれ説明する図である。(A), (b), (c), and (d) are specific examples of the read count table, the rewrite count table, the address conversion table, and the nonvolatile memory after the operation of step S9 in FIG. 9 is performed. It is a figure explaining each state. (a)、(b)、(c)及び(d)は、図9のステップS15の動作が行われる前における、読み出し回数テーブル、書き換え回数テーブル、アドレス変換テーブル、及び不揮発性メモリの具体的な状態をそれぞれ説明する図である。(A), (b), (c), and (d) are specific examples of the read count table, the rewrite count table, the address conversion table, and the nonvolatile memory before the operation of step S15 in FIG. 9 is performed. It is a figure explaining a state, respectively. (a)、(b)、(c)及び(d)は、図9のステップS17の動作が行われた後における、読み出し回数テーブル、書き換え回数テーブル、アドレス変換テーブル、及び不揮発性メモリの具体的な状態をそれぞれ説明する図である。(A), (b), (c), and (d) are specific examples of the read count table, the rewrite count table, the address conversion table, and the nonvolatile memory after the operation of step S17 in FIG. 9 is performed. It is a figure explaining each state. 図8に示した読み出しキャッシュ処理の具体的な動作を示すフローチャートである。FIG. 9 is a flowchart showing a specific operation of read cache processing shown in FIG. 8. FIG. 上記メモリーカードでの書き込み動作を示すフローチャートである。It is a flowchart which shows the write-in operation | movement with the said memory card. 本発明の第2の実施形態にかかるメモリーコントローラの主制御部の具体的な機能ブロックを示すブロック図である。It is a block diagram which shows the concrete functional block of the main control part of the memory controller concerning the 2nd Embodiment of this invention. 上記不揮発性メモリでの書き換え回数と許容読み出し回数との相関関係の具体例を示すグラフである。It is a graph which shows the specific example of the correlation between the frequency | count of rewriting in the said non-volatile memory, and the frequency | count of permissible reading. 図16に示した主制御部による読み出し動作を示すフローチャートである。17 is a flowchart showing a read operation by the main control unit shown in FIG. 16. 図18に示した読み出しキャッシュ処理の具体的な動作を示すフローチャートである。19 is a flowchart showing a specific operation of the read cache process shown in FIG. 18.

符号の説明Explanation of symbols

1 メモリーカード
2 コントローラ(メモリーコントローラ)
3 不揮発性メモリ
4 主制御部
40 回数比較部
41 データビット誤り指示部
42a、42a’ キャッシュ判定部
42b キャッシュ指示部
42c キャッシュ解放指示部(出力メモリ解放指示部)
43 関数設定部
9 アドレス変換テーブル
10 書き換え回数テーブル
11 読み出し回数テーブル
12 キャッシュメモリ(出力メモリ)
13 キャッシュテーブル(出力テーブル)
14 物理ブロック
14a 物理ページ
50 不揮発性記憶システム
51 ホスト機器
1 Memory card 2 Controller (memory controller)
Reference Signs List 3 Nonvolatile memory 4 Main control unit 40 Number comparison unit 41 Data bit error instruction unit 42a, 42a 'Cache determination unit 42b Cache instruction unit 42c Cache release instruction unit (output memory release instruction unit)
43 Function Setting Unit 9 Address Conversion Table 10 Rewrite Count Table 11 Read Count Table 12 Cache Memory (Output Memory)
13 Cache table (output table)
14 Physical Block 14a Physical Page 50 Nonvolatile Storage System 51 Host Device

Claims (13)

複数の物理ブロックを有する不揮発性メモリに対し、外部からの論理アドレスを指定したデータの書き込み及び読み出しを行うメモリーコントローラであって、
前記論理アドレスと前記物理ブロックのアドレスとを変換するアドレス変換テーブルと、
前記論理アドレスが入力されるとともに、前記アドレス変換テーブルを参照して、前記不揮発性メモリに対するデータの書き込み動作及び読み出し動作を制御する主制御部を備え、
前記複数の各物理ブロックに含まれた複数の物理ページについて、前記物理ページ単位での読み出し回数を、対応する物理ブロックの読み出し回数として記録する読み出し回数テーブルが設けられ、
前記主制御部は、前記読み出し回数テーブルを参照して、前記不揮発性メモリに対するデータの読み出し動作を制限する、
ことを特徴とするメモリーコントローラ。
A memory controller for writing and reading data specifying a logical address from the outside to a nonvolatile memory having a plurality of physical blocks,
An address conversion table for converting the logical address and the address of the physical block;
The logical address is input, and referring to the address conversion table, a main control unit that controls a data write operation and a read operation with respect to the nonvolatile memory,
For a plurality of physical pages included in each of the plurality of physical blocks, there is provided a read count table for recording the read count in units of physical pages as the read count of the corresponding physical block,
The main control unit refers to the read count table and restricts a data read operation to the nonvolatile memory.
This is a memory controller.
前記不揮発性メモリの物理ブロックに格納されているデータをキャッシュ可能に構成されるとともに、前記主制御部に対して外部からデータの読み出し動作が要求されたときに、前記不揮発性メモリからデータを読み出すことなく当該データを外部に出力するための出力メモリと、
前記出力メモリにキャッシュされているキャッシュデータの読み出し回数を管理する出力テーブルを備えている請求項1に記載のメモリーコントローラ。
The data stored in the physical block of the non-volatile memory is configured to be cacheable, and the data is read from the non-volatile memory when the main control unit is requested to read data from the outside. Output memory to output the data to the outside without,
The memory controller according to claim 1, further comprising an output table for managing a read count of cache data cached in the output memory.
前記主制御部には、前記不揮発性メモリの物理ブロックへのデータの書き込み動作が要求されたときに、当該データが前記出力メモリにキャッシュされているか否かについて前記出力テーブルを参照することにより判別し、かつ、当該データがキャッシュされていることを判別した場合には、前記出力メモリに対して当該データのキャッシュを開放することを指示する出力メモリ解放指示部が設けられている請求項2に記載のメモリーコントローラ。 When the main control unit is requested to write data to the physical block of the nonvolatile memory, the main control unit determines whether the data is cached in the output memory by referring to the output table. And an output memory release instruction unit that instructs the output memory to release the cache of the data when it is determined that the data is cached. The described memory controller. 前記出力メモリ解放指示部は、前記不揮発性メモリの互いに異なる物理ブロックの間でデータの移動が行われたときに、当該データが前記出力メモリにキャッシュされているか否かについて前記出力テーブルを参照することにより判別し、かつ、当該データがキャッシュされていることを判別した場合には、前記出力メモリに対し当該データのキャッシュを開放することを指示する請求項3に記載のメモリーコントローラ。 The output memory release instruction unit refers to the output table as to whether or not the data is cached in the output memory when data is moved between different physical blocks of the nonvolatile memory. 4. The memory controller according to claim 3, wherein when the data is determined and when it is determined that the data is cached, the output memory is instructed to release the data cache. 前記主制御部には、外部からデータの読み出し動作が要求されたときに、前記読み出し回数テーブルから前記読み出し動作が要求されたデータに対応する読み出し回数を取得するとともに、前記出力テーブル及び前記読み出し回数テーブルを参照することにより、前記出力メモリにキャッシュされているキャッシュデータに対応する読み出し回数を求めて、前記読み出し動作が要求されたデータに対応する読み出し回数との比較を行って、データキャッシュの要否を判定するキャッシュ判定部と、
前記キャッシュ判定部により、前記読み出し動作が要求されたデータに対応する読み出し回数が前記キャッシュデータに対応する読み出し回数よりも多いことが判定されたときに、前記読み出し動作が要求されたデータを前記出力メモリにキャッシュさせるキャッシュ指示部が設けられている請求項2〜4のいずれか1項に記載のメモリーコントローラ。
When a data read operation is requested from the outside, the main control unit obtains the read count corresponding to the data requested for the read operation from the read count table, and also outputs the output table and the read count. By referring to the table, the number of reads corresponding to the cache data cached in the output memory is obtained and compared with the number of reads corresponding to the data for which the read operation is requested. A cache determination unit for determining NO,
When the cache determination unit determines that the number of reads corresponding to the data requested for the read operation is greater than the number of reads corresponding to the cache data, the data requested for the read operation is output as the output The memory controller according to claim 2, further comprising a cache instruction unit that causes the memory to cache.
前記出力メモリに複数のキャッシュデータが存在している場合において、前記キャッシュ判定部は、前記複数のキャッシュデータにそれぞれ対応する複数の読み出し回数のうち、最小の読み出し回数を選択する請求項5に記載のメモリーコントローラ。 6. The cache determination unit according to claim 5, wherein when there are a plurality of cache data in the output memory, the cache determination unit selects a minimum number of read times out of a plurality of read times corresponding to the plurality of cache data. Memory controller. 前記主制御部には、外部からの論理アドレスによって指定された前記不揮発性メモリの物理ブロックからデータを読み出す読み出し動作が要求されたときに、当該物理ブロックの読み出し回数を前記読み出し回数テーブルから取得して、取得した読み出し回数と所定の閾値とを比較する回数比較部と、
前記回数比較部により、前記取得した読み出し回数が前記所定の閾値に達したことが判別されたときに、前記論理アドレスによって指定された前記不揮発性メモリの物理ブロックとは異なる別の物理ブロックに対し、前記読み出し動作が要求されたデータを移動することを指示するデータ移動指示部とが設けられている請求項1〜6のいずれか1項に記載のメモリーコントローラ。
When the main control unit is requested to perform a read operation for reading data from the physical block of the nonvolatile memory specified by an external logical address, the main control unit acquires the read count of the physical block from the read count table. A number comparison unit that compares the acquired number of readings with a predetermined threshold;
When it is determined by the number comparison unit that the acquired number of readings has reached the predetermined threshold, the physical block different from the physical block of the nonvolatile memory specified by the logical address The memory controller according to claim 1, further comprising: a data movement instructing unit that instructs to move data for which the read operation is requested.
前記物理ブロックの消去回数を、対応する物理ブロックの書き換え回数として記録する書き換え回数テーブルを備え、
前記主制御部には、前記不揮発性メモリにおける、書き換え回数と許容読み出し回数との関係を示す関数が設定される関数設定部と、
外部からデータの読み出し動作が要求されたときに、前記読み出し回数テーブルから前記読み出し動作が要求されたデータに対応する読み出し回数を取得し、前記読み出し動作が要求されたデータに対応する書き換え回数を前記書き換え回数テーブルから取得し、かつ、前記読み出し動作が要求されたデータに対応する許容読み出し回数を、取得した書き換え回数を基に前記関数設定部から求め、求めた許容読み出し回数から取得した読み出し回数を引き算することにより、当該読み出し動作が要求されたデータについての残許容読み出し回数を算出するとともに、前記出力テーブル及び前記読み出し回数テーブルを参照することにより、前記出力メモリにキャッシュされているキャッシュデータに対応する読み出し回数を取得し、前記キャッシュデータに対応する書き換え回数を前記書き換え回数テーブルから取得し、かつ、前記キャッシュデータに対応する許容読み出し回数を、取得した書き換え回数を基に前記関数設定部から求め、求めた許容読み出し回数から取得した読み出し回数を引き算することにより、当該キャッシュデータについての残許容読み出し回数を算出して、前記読み出し動作が要求されたデータについての残許容読み出し回数との比較を行って、データキャッシュの要否を判定するキャッシュ判定部と、
前記キャッシュ判定部により、前記読み出し動作が要求されたデータに対応する残許容読み出し回数が前記キャッシュデータに対応する残許容読み出し回数よりも少ない場合に、前記読み出し動作が要求されたデータを前記出力メモリにキャッシュさせるキャッシュ指示部が設けられている請求項2〜4のいずれか1項に記載のメモリーコントローラ。
A rewrite count table for recording the number of erases of the physical block as the rewrite count of the corresponding physical block;
In the main control unit, a function setting unit in which a function indicating a relationship between the number of rewrites and the allowable number of reads in the nonvolatile memory is set;
When a data read operation is requested from the outside, the read count corresponding to the data requested for the read operation is obtained from the read count table, and the rewrite count corresponding to the data requested for the read operation is obtained. Obtained from the function setting unit based on the obtained number of rewrites, and obtained the number of readings obtained from the obtained number of permitted readings, obtained from the rewrite number table and corresponding to the data for which the read operation is requested. By subtracting, the remaining allowable number of reads for the data for which the read operation is requested is calculated, and by referring to the output table and the read number table, it corresponds to the cache data cached in the output memory. The number of readings to be performed The rewrite count corresponding to the cache data is obtained from the rewrite count table, and the allowable read count corresponding to the cache data is obtained from the function setting unit based on the obtained rewrite count, and obtained from the obtained allowable read count. By subtracting the read count, the remaining allowable read count for the cache data is calculated and compared with the remaining allowable read count for the data for which the read operation is requested to determine whether the data cache is necessary. A cache determination unit for determining;
When the remaining allowable read count corresponding to the data for which the read operation is requested by the cache determination unit is smaller than the remaining allowable read count corresponding to the cache data, the data for which the read operation is requested is stored in the output memory. The memory controller according to any one of claims 2 to 4, further comprising a cache instruction unit that caches the memory controller.
前記出力メモリに複数のキャッシュデータが存在している場合において、前記キャッシュ判定部は、前記複数のキャッシュデータにそれぞれ対応する複数の読み出し回数のうち、最小の読み出し回数を選択する請求項8に記載のメモリーコントローラ。 The cache determination unit selects a minimum number of read times from among a plurality of read times corresponding to the plurality of cache data when a plurality of cache data exists in the output memory. Memory controller. 前記物理ブロックの消去回数を、対応する物理ブロックの書き換え回数として記録する書き換え回数テーブルを備え、
前記主制御部には、前記不揮発性メモリにおける、書き換え回数と許容読み出し回数との関係を示す関数が設定される関数設定部と、
外部からの論理アドレスによって指定された前記不揮発性メモリの物理ブロックからデータを読み出す読み出し動作が要求されたときに、当該物理ブロックの読み出し回数を前記読み出し回数テーブルから取得するとともに、当該物理ブロックの書き換え回数を前記書き換え回数テーブルから求め、かつ、求めた書き換え回数を基に前記関数設定部から許容読み出し回数を取得して、取得した読み出し回数と取得した許容読み出し回数とを比較する回数比較部と、
前記回数比較部により、前記取得した読み出し回数が前記許容読み出し回数に達したことが判別されたときに、前記論理アドレスによって指定された前記不揮発性メモリの物理ブロックとは異なる別の物理ブロックに対し、前記読み出し動作が要求されたデータを移動することを指示するデータ移動指示部とが設けられている請求項1〜4、8、及び9のいずれか1項に記載のメモリーコントローラ。
A rewrite count table for recording the number of erases of the physical block as the rewrite count of the corresponding physical block;
In the main control unit, a function setting unit in which a function indicating a relationship between the number of rewrites and the allowable number of reads in the nonvolatile memory is set;
When a read operation for reading data from a physical block of the nonvolatile memory designated by an external logical address is requested, the physical block read count is acquired from the read count table and the physical block is rewritten. The number comparison unit for obtaining the number of times from the rewrite number table, obtaining the allowable read number from the function setting unit based on the obtained number of rewrites, and comparing the acquired read number and the acquired allowable read number;
When it is determined by the number comparison unit that the acquired number of readings has reached the allowable number of readings, a physical block different from the physical block of the nonvolatile memory specified by the logical address 10. The memory controller according to claim 1, further comprising a data movement instruction unit that instructs to move data for which the read operation is requested. 10.
前記関数では、前記書き換え回数に対して前記許容読み出し回数が単調減少する請求項8〜10のいずれか1項に記載のメモリーコントローラ。 The memory controller according to claim 8, wherein in the function, the allowable number of readings monotonously decreases with respect to the number of rewritings. 複数の物理ブロックを有する不揮発性メモリ、及び
請求項1〜11のいずれか1項に記載のメモリーコントローラ
を備えていることを特徴とする不揮発性記憶装置。
A non-volatile storage device comprising: a non-volatile memory having a plurality of physical blocks; and the memory controller according to claim 1.
複数の物理ブロックを有する不揮発性メモリと、前記不揮発性メモリに対し、外部からの論理アドレスを指定したデータの書き込み及び読み出しを行うメモリーコントローラを備えた不揮発性記憶装置、及び前記不揮発性記憶装置に対して論理アドレスを指定したアクセス指示を行うホスト機器を具備する不揮発性記憶システムであって、
前記メモリーコントローラには、請求項1〜11のいずれか1項に記載のメモリーコントローラが用いられている、
ことを特徴とする不揮発性記憶システム。
A non-volatile memory device having a non-volatile memory having a plurality of physical blocks, a non-volatile memory device provided with a memory controller for writing and reading data specifying a logical address from the outside, and the non-volatile memory device A non-volatile storage system including a host device that performs an access instruction specifying a logical address.
The memory controller according to any one of claims 1 to 11 is used as the memory controller.
A non-volatile storage system.
JP2007199362A 2007-07-31 2007-07-31 MEMORY CONTROLLER, NONVOLATILE MEMORY DEVICE USING THE SAME, AND NONVOLATILE MEMORY SYSTEM Expired - Fee Related JP5073402B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007199362A JP5073402B2 (en) 2007-07-31 2007-07-31 MEMORY CONTROLLER, NONVOLATILE MEMORY DEVICE USING THE SAME, AND NONVOLATILE MEMORY SYSTEM

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007199362A JP5073402B2 (en) 2007-07-31 2007-07-31 MEMORY CONTROLLER, NONVOLATILE MEMORY DEVICE USING THE SAME, AND NONVOLATILE MEMORY SYSTEM

Publications (2)

Publication Number Publication Date
JP2009037317A true JP2009037317A (en) 2009-02-19
JP5073402B2 JP5073402B2 (en) 2012-11-14

Family

ID=40439181

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007199362A Expired - Fee Related JP5073402B2 (en) 2007-07-31 2007-07-31 MEMORY CONTROLLER, NONVOLATILE MEMORY DEVICE USING THE SAME, AND NONVOLATILE MEMORY SYSTEM

Country Status (1)

Country Link
JP (1) JP5073402B2 (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013504836A (en) * 2009-09-11 2013-02-07 サンディスク テクノロジーズ インコーポレイテッド Identification of hazardous condition data in non-volatile storage
JP2013125303A (en) * 2011-12-13 2013-06-24 Lapis Semiconductor Co Ltd Semiconductor memory control device and control method
US8656085B2 (en) 2009-06-29 2014-02-18 Samsung Electronics Co., Ltd. Flash memory device and method for programming flash memory device
JP2015118572A (en) * 2013-12-18 2015-06-25 富士通株式会社 Storage control device, control method and control program
JP2016024779A (en) * 2014-07-24 2016-02-08 株式会社東芝 Information processor, data accessing method and program
US9449673B2 (en) 2013-01-03 2016-09-20 Samsung Electronics Co., Ltd. Memory device and memory system having the same
US9798656B2 (en) 2013-06-28 2017-10-24 Samsung Electronics Co., Ltd. Memory controller, method of operating, and apparatus including same
US10049755B2 (en) 2016-06-30 2018-08-14 Samsung Electronics Co., Ltd. Storage device including nonvolatile memory device and controller with varied read weights
JP2019160197A (en) * 2018-03-16 2019-09-19 富士通株式会社 Storage device, control program and control method
CN110287130A (en) * 2018-03-19 2019-09-27 爱思开海力士有限公司 Storage device and its operating method

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH06215589A (en) * 1993-01-18 1994-08-05 Hitachi Ltd Semiconductor memory
JPH08279295A (en) * 1995-04-05 1996-10-22 Toshiba Corp Storage system including nonvolatile semiconductor memory
JP2001290791A (en) * 2000-04-06 2001-10-19 Nec Microsystems Ltd Microcomputer with built-in nonvolatile semiconductor memory and its control method
JP2003139927A (en) * 2001-11-06 2003-05-14 Matsushita Electric Ind Co Ltd Reflection plate, liquid crystal display device using the same and photo mask
JP2004335365A (en) * 2003-05-09 2004-11-25 Alps Electric Co Ltd Push-button switch
JP2007004234A (en) * 2005-06-21 2007-01-11 Hitachi Ltd Storage device
JP2007334533A (en) * 2006-06-14 2007-12-27 Hitachi Ltd Storage system
JP2008139927A (en) * 2006-11-30 2008-06-19 Toshiba Corp Memory system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH06215589A (en) * 1993-01-18 1994-08-05 Hitachi Ltd Semiconductor memory
JPH08279295A (en) * 1995-04-05 1996-10-22 Toshiba Corp Storage system including nonvolatile semiconductor memory
JP2001290791A (en) * 2000-04-06 2001-10-19 Nec Microsystems Ltd Microcomputer with built-in nonvolatile semiconductor memory and its control method
JP2003139927A (en) * 2001-11-06 2003-05-14 Matsushita Electric Ind Co Ltd Reflection plate, liquid crystal display device using the same and photo mask
JP2004335365A (en) * 2003-05-09 2004-11-25 Alps Electric Co Ltd Push-button switch
JP2007004234A (en) * 2005-06-21 2007-01-11 Hitachi Ltd Storage device
JP2007334533A (en) * 2006-06-14 2007-12-27 Hitachi Ltd Storage system
JP2008139927A (en) * 2006-11-30 2008-06-19 Toshiba Corp Memory system

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8656085B2 (en) 2009-06-29 2014-02-18 Samsung Electronics Co., Ltd. Flash memory device and method for programming flash memory device
JP2013504836A (en) * 2009-09-11 2013-02-07 サンディスク テクノロジーズ インコーポレイテッド Identification of hazardous condition data in non-volatile storage
JP2013125303A (en) * 2011-12-13 2013-06-24 Lapis Semiconductor Co Ltd Semiconductor memory control device and control method
US9449673B2 (en) 2013-01-03 2016-09-20 Samsung Electronics Co., Ltd. Memory device and memory system having the same
US9798656B2 (en) 2013-06-28 2017-10-24 Samsung Electronics Co., Ltd. Memory controller, method of operating, and apparatus including same
JP2015118572A (en) * 2013-12-18 2015-06-25 富士通株式会社 Storage control device, control method and control program
JP2016024779A (en) * 2014-07-24 2016-02-08 株式会社東芝 Information processor, data accessing method and program
US10049755B2 (en) 2016-06-30 2018-08-14 Samsung Electronics Co., Ltd. Storage device including nonvolatile memory device and controller with varied read weights
JP2019160197A (en) * 2018-03-16 2019-09-19 富士通株式会社 Storage device, control program and control method
CN110287130A (en) * 2018-03-19 2019-09-27 爱思开海力士有限公司 Storage device and its operating method
KR20190109985A (en) * 2018-03-19 2019-09-27 에스케이하이닉스 주식회사 Storage device and operating method thereof
CN110287130B (en) * 2018-03-19 2024-03-08 爱思开海力士有限公司 Memory device and method of operating the same

Also Published As

Publication number Publication date
JP5073402B2 (en) 2012-11-14

Similar Documents

Publication Publication Date Title
JP5073402B2 (en) MEMORY CONTROLLER, NONVOLATILE MEMORY DEVICE USING THE SAME, AND NONVOLATILE MEMORY SYSTEM
JP5612514B2 (en) Nonvolatile memory controller and nonvolatile storage device
JP4256175B2 (en) Nonvolatile semiconductor memory
JP4633802B2 (en) Nonvolatile storage device, data read method, and management table creation method
US8621139B2 (en) Data writing method for writing data into block of multi-level cell NAND flash memory by skipping a portion of upper page addresses and storage system and controller using the same
JP4787266B2 (en) Scratch pad block
KR101102634B1 (en) Memory system
TWI457756B (en) Memory system and operation method thereof
US20080181018A1 (en) Memory system and control method thereof
US20090089484A1 (en) Data protection method for power failure and controller using the same
US20090292839A1 (en) Semiconductor memory device, memory system and data recovery methods thereof
JPWO2006067923A1 (en) MEMORY CONTROLLER, NONVOLATILE MEMORY DEVICE, NONVOLATILE MEMORY SYSTEM, AND MEMORY CONTROL METHOD
US20090235015A1 (en) Memory system
KR20100094241A (en) Nonvolatile memory device not including reserved blocks
KR20220005111A (en) Memory system, memory controller, and operating method of memory system
US20090132757A1 (en) Storage system for improving efficiency in accessing flash memory and method for the same
JP2009211215A (en) Memory system
JP5592478B2 (en) Nonvolatile storage device and memory controller
JP2004303238A (en) Flash memory access device and method
JP5300496B2 (en) Semiconductor memory device, host device, and semiconductor memory system
KR20200116375A (en) Memory system, memory controller and operating method of thereof
JP5494086B2 (en) Nonvolatile storage device and nonvolatile memory controller
KR20210130341A (en) Memory system, memory controller, and operating method of memory system
JP3808842B2 (en) Storage device having rewritable nonvolatile memory and control method of nonvolatile memory for storage device
JP2012068765A (en) Memory controller, flash memory system with memory controller, and control method of flash memory

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100318

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120529

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120709

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20120802

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20120822

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20150831

Year of fee payment: 3

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313113

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees