JP3621051B2 - MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD - Google Patents

MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD Download PDF

Info

Publication number
JP3621051B2
JP3621051B2 JP2001129160A JP2001129160A JP3621051B2 JP 3621051 B2 JP3621051 B2 JP 3621051B2 JP 2001129160 A JP2001129160 A JP 2001129160A JP 2001129160 A JP2001129160 A JP 2001129160A JP 3621051 B2 JP3621051 B2 JP 3621051B2
Authority
JP
Japan
Prior art keywords
block
page
data
flash memory
stored
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.)
Expired - Lifetime
Application number
JP2001129160A
Other languages
Japanese (ja)
Other versions
JP2002324008A (en
Inventor
幸夫 寺崎
直樹 向田
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.)
TDK Corp
Original Assignee
TDK 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 TDK Corp filed Critical TDK Corp
Priority to JP2001129160A priority Critical patent/JP3621051B2/en
Publication of JP2002324008A publication Critical patent/JP2002324008A/en
Application granted granted Critical
Publication of JP3621051B2 publication Critical patent/JP3621051B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Images

Description

【0001】
【発明の属する技術分野】
本発明は、メモリコントローラ、フラッシュメモリシステム及びフラッシュメモリの制御方法に関し、特に、フラッシュメモリに対する一連のデータ書き込み処理をより高速に行うことができるメモリコントローラ、フラッシュメモリシステム及びフラッシュメモリの制御方法に関する。
【0002】
【従来の技術】
近年、メモリカードやシリコンディスクなどに用いられる半導体メモリとして、フラッシュメモリ、特にNAND型フラッシュメモリが用いられることが多い。NAND型フラッシュメモリは、メモリセルを消去状態(論理値=1)から書込状態(論理値=0)に変化させる場合は、これをメモリセル単位で行うことが可能である一方、メモリセルを書込状態(0)から消去状態(1)に変化させる場合は、これをメモリセル単位で行うことができず、複数のメモリセルからなる所定の消去単位でしかこれを行うことができない。かかる一括消去動作は、一般的に「ブロック消去」と呼ばれる。
【0003】
このように、フラッシュメモリでは、ブロック単位でしかメモリセルを書込状態から消去状態に変化させることができないので、既にデータの書き込まれたブロックに対して新しいデータを書き込むためには、一旦、このブロックに含まれるメモリセルを全て消去状態とし、その後に新しいデータを書き込むという処理が必要となる。したがって、すでにデータが格納されているブロックに新しいデータを書き込む場合、このブロックにすでに格納されているデータが消失するのを防ぐためには、このブロックに含まれるデータを、他の消去済みブロックに移動させる必要がある。
【0004】
このため、すでにデータが格納されているブロックに新しいデータを書き込むようホストコンピュータから指示されると、当該新しいデータと、このブロックにすでに格納されているデータとが、消去済みブロックに書き込まれる。かかる処理は、「ブロック間転送」と呼ばれる。その後、転送元のブロックに含まれるメモリセルが全て消去状態とされ、これにより、転送元のブロックは新たに消去済みブロックとなる。
【0005】
このように、従来のフラッシュメモリシステムにおいては、すでにデータが格納されているブロックに新しいデータを書き込むよう、ホストコンピュータから要求されるたびにブロック間転送を実行する必要があった。
【0006】
【発明が解決しようとする課題】
しかしながら、一連のブロック間転送処理には、多くの時間を要するという問題がある。
【0007】
すなわち、ブロック間転送処理においては、転送元ブロックに格納されているデータをメモリコントローラが読み出し、かかるデータを転送先のブロックに書き込むという処理を1ページずつ行う必要があるため、転送元ブロックの各ページに格納されているデータを全て転送先のブロックに転送するには、1ブロックを構成するページ数にほぼ比例した時間が必要となってしまう。
【0008】
したがって、ホストコンピュータから書き込みを要求されたデータがたとえ1ページ分のデータであっても、当該データを書き込むべきブロックにすでに何らかのデータが格納されていれば、一連の処理が完了するまでには多大な時間が必要となっていた。
【0009】
このため、ホストコンピュータからデータの書き込みが要求された場合に、当該データの書き込みに必要な一連の処理をより高速に行うことができるメモリコントローラ、フラッシュメモリシステム及びフラッシュメモリの制御方法が望まれていた。
【0010】
したがって、本発明の目的は、ホストコンピュータからデータの書き込みを要求された場合に、当該データを書き込むべきブロックにすでに何らかのデータが格納されている場合であっても、与えられたデータの書き込みに必要な一連の処理をより高速に行うことができるメモリコントローラ及びこのようなメモリコントローラを備えるフラッシュメモリシステムを提供することである。
【0011】
また、本発明の他の目的は、ホストコンピュータからデータの書き込みを要求された場合に、当該データを書き込むべきブロックにすでに何らかのデータが格納されている場合であっても、与えられたデータの書き込みに必要な一連の処理をより高速に行うことができるフラッシュメモリの制御方法を提供することである。
【0012】
【課題を解決するための手段】
本発明のかかる目的は、複数のブロックからなるメモリにアクセスするメモリコントローラであって、既にデータが格納されている第1のブロックに対応する論理アドレスに対して、新たに新データの書き込みが指示されたことに応答して、前記第1のブロックに格納されているデータの一部を第2のブロックの同じページに転送する第1の手段と、前記新データを前記第2のブロックに書き込む第2の手段と、前記第1のブロックと前記第2のブロックとの対応関係を保持する第3の手段と、前記論理アドレスに対して、さらに、新たに追記データの書き込みが指示されたことに応答して、前記追記データを前記第2のブロックに追加的に書き込み可能か否かを判断する第4の手段と、前記第4の手段が追加的に書き込み可能であると判断したことに応答して、前記第1のブロックに格納されているデータの一部を前記第2のブロックの同じページに転送するとともに、前記追記データを前記第2のブロックに書き込む第5の手段と、前記第4の手段が追加的に書き込み不可能であると判断したことに応答して、前記第2のブロック中の全ての空きページに、前記第1のブロックの同じページに格納されているデータを転送する第6の手段と、前記第2のブロックの全てのページにデータが書き込まれたことに応答して、前記第1のブロックをブロック消去する第7の手段とを備えたことを特徴とするメモリコントローラによって達成される。
【0013】
本発明の好ましい実施態様においては、前記第1の手段が、前記第1のブロックの先頭ページから前記新データを格納すべきページに対応するページの一つ前のページに格納されているデータを、前記第2のブロックの同じページに転送するように構成さている。
【0014】
本発明のさらに好ましい実施態様においては、前記第3の手段が、さらに、前記第2のブロックの空きページに関する情報を保持し、前記第4の手段が、前記空きページに関する情報に基づき、前記追記データを前記第2のブロックに追加的に書き込み可能か否かを判断するように構成されている。
【0015】
本発明のさらに好ましい実施態様においては、前記第2のブロックにおける前記空きページが、前記第2の手段により前記新データが書き込まれたページの次のページから最終ページまで連続している。
【0016】
本発明のさらに好ましい実施態様においては、前記第2のブロックにおける前記追記データを格納するべきページが前記空きページでない場合に、前記第6の手段が、前記第2のブロック中の空きページに前記第1のブロックの同じページに格納されているデータを転送し、その後に、前記第7の手段が、前記第1のブロックに格納されているすべての前記データを消去するように構成されている。
【0017】
本発明のさらに好ましい実施態様においては、メモリコントローラは、さらに、前記第2のブロックにおける前記追記データを格納するべきページが前記空きページでない場合に、前記第2のブロックに格納されているデータの一部を第3のブロックの同じページに転送する第8の手段と、前記追記データを前記第3のブロックに書き込む第9の手段とを備え、前記第3の手段が、さらに、前記第2のブロックと前記第3のブロックとの対応関係を保持するように構成されている。
【0018】
本発明のさらに好ましい実施態様においては、前記第3の手段が、さらに、前記第3のブロックの空きページに関する情報を保持している。
【0019】
本発明のさらに好ましい実施態様においては、メモリコントローラは、さらに、前記追記データの書き込み先のページが、前記第2のブロックにおける空きページ群の先頭ページか否かを判断する第10の手段を備え、前記第10の手段が前記書き込み先のページが前記先頭ページでないと判断したことに応答して、前記第5の手段が、前記空きページ群の先頭ページから前記追記データの書き込み先の一つ前のページに対応する各ページに、前記第1のブロックの同じページに格納されているデータを転送するように構成されている。
【0020】
本発明の前記目的はまた、複数のブロックからなるメモリにアクセスするメモリコントローラであって、前記各ブロックを複数のグループに分類する手段と、
互いに異なるグループに属する複数のブロックを仮想的に結合することにより仮想ブロックを形成する手段と、前記仮想ブロックを構成する所定のブロックに対して、新たに新データの書き込みが指示されたことに応答して、前記所定のブロックに格納されているデータの一部を他のブロックに転送する手段と、新たに書き込みが指示された前記新データを前記他のブロックに書き込む手段と、前記所定のブロックと前記他のブロックとの対応関係を保持する手段と、前記新データの後に、追記データが与えられて、前記所定のブロックに対応する論理アドレスに対して、前記追記データの書き込みが指示されたことに応答して、前記追記データが前記他のブロックに前記追記データを追加的に書き込み可能か否かを判断する手段と、前記他のブロックに前記追記データが追加的に書き込み可能であると判断されたことに応答して、前記所定のブロックに格納されているデータの一部を前記他のブロックの同じページに転送するとともに、前記追記データを前記他のブロックに書き込む手段と、前記他のブロックに前記追記データを追加的に書き込み不可能であると判断されたことに応答して、前記他のブロック中の全ての空きページに、前記所定のブロックの同じページに格納されているデータを転送する手段と、前記他のブロックの全てのページにデータが書き込まれたことに応答して、前記所定のブロックをブロック消去する手段とを備えたことを特徴とするメモリコントローラによって達成される。
【0021】
本発明の前記目的はまた、前記メモリコントローラのいずれかと、複数のブロックからなるフラッシュメモリとを備えたことを特徴とするフラッシュメモリシステムによって達成される。
【0022】
本発明の好ましい実施態様においては、前記フラッシュメモリシステムが、同一の筐体に収容されている。
【0023】
本発明のさらに好ましい実施態様においては、前記筐体がカード状をなしている。
【0024】
本発明の好ましい実施態様においては、前記第3の手段が、前記第2のブロックの空きページに関する情報をさらに保持している。
【0025】
本発明の前記目的は、所定の論理アドレスに対して、新たに新データの書き込みが指示されたことに応答して、アドレス変換テーブル内の前記所定の論理アドレスに対応するブロックを第1のブロックから第2のブロックに変更するステップと、前記第1のブロックと前記第2のブロックの対応関係を示す変数を作成するステップと、前記第1のブロックに格納されているデータの一部を第2のブロックに転送するステップと、前記新データを前記第2のブロックに書き込むステップと、前記所定の論理アドレスに対して、さらに、新たな追記データの書き込みが指示されたことに応答して、前記追記データを前記第2のブロックに追加的に書き込み可能か否かを判断するステップと、前記追記データを追加的に書き込み可能であると判断したことに応答して、前記第1のブロックに格納されているデータの一部を前記第2のブロックの同じページに転送するとともに、前記追記データを前記第2のブロックに書き込むステップと、前記追記データを追加的に書き込み可能でないと判断したことに応答して、前記第2のブロック中の全ての空きページに、前記第1のブロックの同じページに格納されているデータを転送するステップと、前記第2のブロックの全てのページにデータが書き込まれたことに応答して、前記第1のブロックをブロック消去するステップとを備えたことを特徴とするフラッシュメモリの制御方法によって達成される。
【0038】
【発明の実施の形態】
以下、添付図面を参照しながら、本発明の好ましい実施態様について詳細に説明する。
【0039】
図1は、本発明の好ましい実施態様にかかるフラッシュメモリシステム1を概略的に示すブロック図である。
【0040】
フラッシュメモリシステム1はカード形状であり、図1に示されるように、4個のフラッシュメモリチップ2−0〜2−3と、コントローラ3と、コネクタ4とが、一つのカード内に集積されて構成される。フラッシュメモリシステム1は、ホストコンピュータ5に着脱可能に装着されて使用され、ホストコンピュータ5に対する一種の外部記憶装置として用いられる。ホストコンピュータ5としては、文字、音声、あるいは画像情報等の種々の情報を処理するパーソナルコンピュータやデジタルスチルカメラをはじめとする各種情報処理装置が挙げられる。
【0041】
各フラッシュメモリチップ2−0〜2−3は、それぞれ128Mバイト(1Gビット)の記憶容量を有する半導体チップである。フラッシュメモリシステム1においては、512バイトを1ページとし、これを最小アクセス単位としている。したがって、これら各フラッシュメモリチップ2−0〜2−3は、それぞれ256Kページのアドレス空間を含み、フラッシュメモリチップ2−0〜2−3の合計で、1Mページのアドレス空間を備えることになる。また、フラッシュメモリシステム1においては、これら4つのフラッシュメモリチップ2−0〜2−3は、512Mバイト(4Gビット)の記憶容量を有し、1Mページのアドレス空間を備える一つの大きなメモリとして取り扱われる。このため、これら1Mページからなるアドレス空間から特定のページにアクセスするためには、20ビットのアドレス情報が必要となる。したがって、ホストコンピュータ5は、フラッシュメモリシステム1に対し、20ビットのアドレス情報を供給することによって、特定のページに対するアクセスを行う。以下、ホストコンピュータ5よりフラッシュメモリシステム1に供給される20ビットのアドレス情報を「ホストアドレス」と呼ぶ。
【0042】
コントローラ3は、マイクロプロセッサ6と、ホストインターフェースブロック7と、SRAMワークエリア8と、バッファ9と、フラッシュメモリインターフェースブロック10と、ECC(エラー・コレクション・コード)ブロック11と、フラッシュシーケンサブロック12とから構成される。これら機能ブロックによって構成されるコントローラ3は、一つの半導体チップ上に集積されている。
【0043】
マイクロプロセッサ6は、コントローラ3を構成する各機能ブロック全体の動作を制御するための機能ブロックである。
【0044】
ホストインターフェースブロック7は、バス13を介してコネクタ4に接続されており、マイクロプロセッサ6による制御のもと、ホストコンピュータ5とのデータやアドレス情報、ステータス情報、外部コマンド情報の授受を行う。すなわち、フラッシュメモリシステム1がホストコンピュータ5に装着されると、フラッシュメモリシステム1とホストコンピュータ5とは、バス13、コネクタ4及びバス14を介して相互に接続され、かかる状態において、ホストコンピュータ5よりフラッシュメモリシステム1に供給されるデータ等は、ホストインターフェースブロック7を入口としてコントローラ3の内部に取り込まれ、また、コントローラ3よりホストコンピュータ5に供給されるデータ等は、ホストインターフェースブロック7を出口としてホストコンピュータ5に供給される。さらに、ホストインターフェースブロック7は、ホストコンピュータ5より供給されるホストアドレス及び外部コマンドを一時的に格納するタスクファイルレジスタ(図示せず)及びエラーが発生した場合にセットされるエラーレジスタ等(図示せず)を有している。
【0045】
SRAMワークエリア8は、マイクロプロセッサ6によるフラッシュメモリチップ2−0〜2−3の制御に必要なデータが一時的に格納される作業領域であり、複数のSRAMセルによって構成される。
【0046】
バッファ9は、フラッシュメモリチップ2−0〜2−3から読み出されたデータ及びフラッシュメモリチップ2−0〜2−3に書き込むべきデータを一時的に蓄積するバッファである。すなわち、フラッシュメモリチップ2−0〜2−3から読み出されたデータは、ホストコンピュータ5が受け取り可能な状態となるまでバッファ9に保持され、フラッシュメモリチップ2−0〜2−3に書き込むべきデータは、フラッシュメモリチップ2−0〜2−3が書き込み可能な状態となるとともに、後述するECCブロック11によってエラーコレクションコードが生成されるまでバッファ9に保持される。
【0047】
フラッシュメモリインターフェースブロック10は、バス15を介して、フラッシュメモリチップ2−0〜2−3とのデータやアドレス情報、ステータス情報、内部コマンド情報の授受を行うとともに、各フラッシュメモリチップ2−0〜2−3に対して対応するチップ選択信号#0〜#3を供給するための機能ブロックである。チップ選択信号#0〜#3は、ホストコンピュータ5からデータの読み出しまたは書き込みが要求された場合、ホストコンピュータ5より供給されるホストアドレスに基づいて生成される内部アドレスの上位2ビットに基づいて、そのいずれかが活性化される信号である。具体的には、内部アドレスの上位2ビットが「00」であればチップ選択信号#0が活性化され、「01」であればチップ選択信号#1が活性化され、「10」であればチップ選択信号#2が活性化され、「11」であればチップ選択信号#3が活性化される。対応するチップ選択信号が活性化されたフラッシュメモリチップ2−0〜2−3は選択状態となり、データの読み出しまたは書き込みが可能となる。尚、「内部コマンド」とは、コントローラ3がフラッシュメモリチップ2−0〜2−3を制御するためのコマンドであり、ホストコンピュータ5がフラッシュメモリシステム1を制御するための「外部コマンド」と区別される。
【0048】
ECCブロック11は、フラッシュメモリチップ2−0〜2−3に書き込むデータに付加すべきエラーコレクションコードを生成するとともに、読み出しデータに付加されたエラーコレクションコードに基づいて、読み出しデータに含まれる誤りを訂正するための機能ブロックである。
【0049】
フラッシュシーケンサブロック12は、フラッシュメモリチップ2−0〜2−3とバッファ9とのデータの転送を制御するための機能ブロックである。フラッシュシーケンサブロック12は、複数のレジスタ(図示せず)を備え、マイクロプロセッサ6による制御のもと、フラッシュメモリチップ2−0〜2−3からのデータの読み出しまたはフラッシュメモリチップ2−0〜2−3へのデータの書き込みに必要な値がこれらレジスタに設定されると、データの読み出しまたは書き込みに必要な一連の動作を自動的に実行する。
【0050】
次に、各フラッシュメモリチップ2−0〜2−3を構成する各フラッシュメモリセルの具体的な構造について説明する。
【0051】
図2は、フラッシュメモリチップ2−0〜2−3を構成する各フラッシュメモリセル16の構造を概略的に示す断面図である。
【0052】
図2に示されるように、フラッシュメモリセル16は、P型半導体基板17に形成されたN型のソース拡散領域18及びドレイン拡散領域19と、ソース拡散領域18とドレイン拡散領域19との間のP型半導体基板17を覆って形成されたトンネル酸化膜20と、トンネル酸化膜20上に形成されたフローティングゲート電極21と、フローティングゲート電極21上に形成された絶縁膜22と、絶縁膜22上に形成されたコントロールゲート電極23とから構成される。このような構成を有するフラッシュメモリセル16は、フラッシュメモリチップ2−0〜2−3内において、複数個直列に接続されて、NAND型フラッシュメモリを構成する。
【0053】
フラッシュメモリセル16は、フローティングゲート電極21に電子が注入されているか否かによって、「消去状態」と「書込状態」のいずれかの状態が示される。フラッシュメモリセル16が消去状態であることは、当該フラッシュメモリセル16にデータ「1」が保持されていることを意味し、フラッシュメモリセル16が書込状態であることは、当該フラッシュメモリセル16にデータ「0」が保持されていることを意味する。すなわち、フラッシュメモリセル16は、1ビットのデータを保持することが可能である。
【0054】
図2に示されるように、消去状態とは、フローティングゲート電極21に電子が注入されていない状態を指す。消去状態におけるフラッシュメモリセル16は、デプレッション型のトランジスタとなり、コントロールゲート電極23に読み出し電圧が印加されているか否かに関わらず、ソース拡散領域18とドレイン拡散領域19との間のP型半導体基板17の表面にはチャネル24が形成される。したがって、ソース拡散領域18とドレイン拡散領域19とは、コントロールゲート電極23に読み出し電圧が印加されているか否かに関わらず、チャネル24によって常に電気的に接続状態となる。
【0055】
図3は、書込状態であるフラッシュメモリセル16を概略的に示す断面図である。
【0056】
図3に示されるように、書込状態とは、フローティングゲート電極21に電子が蓄積されている状態を指す。フローティングゲート電極21はトンネル酸化膜20及び絶縁膜22に挟まれているため、一旦、フローティングゲート電極21に注入された電子は、きわめて長時間フローティングゲート電極21内にとどまる。書込状態におけるフラッシュメモリセル16は、エンハンスメント型のトランジスタとなり、コントロールゲート電極23に読み出し電圧が印加されていないときには、ソース拡散領域18とドレイン拡散領域19との間のP型半導体基板17の表面にはチャネルが形成されず、コントロールゲート電極23に読み出し電圧が印加されているときには、ソース拡散領域18とドレイン拡散領域19との間のP型半導体基板17の表面にチャネル(図示せず)が形成される。したがって、コントロールゲート電極23に読み出し電圧が印加されていない状態では、ソース拡散領域18とドレイン拡散領域19とは電気的に絶縁され、コントロールゲート電極23に読み出し電圧が印加された状態では、ソース拡散領域18とドレイン拡散領域19とが電気的に接続される。
【0057】
ここで、選択されたフラッシュメモリセル16が消去状態であるか書込状態であるかは、次のようにして読み出すことができる。すなわち、複数個直列に接続されたフラッシュメモリセル16のうち、選択されたフラッシュメモリセル16以外の全てのフラッシュメモリセル16のコントロールゲート電極23に読み出し電圧が印加され、この状態において、これらフラッシュメモリセル16の直列体に電流が流れるか否かの検出が行われる。その結果、かかる直列体に電流が流れれば、選択されたフラッシュメモリセル16が消去状態であると判断され、かかる直列体に電流が流れなければ、選択されたフラッシュメモリセル16が書込状態であると判断される。このようにして、直列体に含まれる任意のフラッシュメモリセル16に保持されたデータが「0」であるのか「1」であるのかを読み出すことができる。但し、NAND型フラッシュメモリにおいては、ひとつの直列体に含まれる2以上のフラッシュメモリセル16に保持されたデータを同時に読み出すことはできない。
【0058】
また、消去状態であるフラッシュメモリセル16を書込状態に変化させる場合、コントロールゲート電極23に正の高電圧が印加され、これによって、トンネル酸化膜20を介してフローティングゲート電極21へ電子が注入される。フローティングゲート電極21への電子の注入は、FNトンネル電流による注入が可能である。一方、書込状態であるフラッシュメモリセル16を消去状態に変化させる場合、コントロールゲート電極23に負の高電圧が印加され、これによって、トンネル酸化膜20を介してフローティングゲート電極21に蓄積された電子が排出される。
【0059】
次に、各フラッシュメモリチップ2−0〜2−3の持つアドレス空間の具体的な構成について説明する。
【0060】
図4は、フラッシュメモリチップ2−0のアドレス空間の構造を概略的に示す図である。
【0061】
図4に示されるように、フラッシュメモリチップ2−0のアドレス空間は、ブロック#0〜#8191からなる8192個のブロックによって構成される。また、図4には示されていないが、フラッシュメモリチップ2−1〜2−3も、フラッシュメモリチップ2−0と同様にブロック#0〜#8191からなる8192個のブロックによって構成されている。これら各ブロックは、いずれも16Kバイトの記憶容量を有する。
【0062】
ここで、上記各ブロックは、データの消去単位である。すなわち、フラッシュメモリチップ2−0〜2−3では、各フラッシュメモリセル16ごとに、その状態を書込状態から消去状態に変化させることはできず、フラッシュメモリセル16を書込状態から消去状態に変化させる場合は、当該フラッシュメモリセル16が属するブロックに含まれる全てのフラッシュメモリセル16が一括して消去状態とされる。逆に、フラッシュメモリチップ2−0〜2−3では、各フラッシュメモリセル16ごとに、その状態を消去状態から書込状態に変化させることは可能である。
【0063】
さらに、図4に示されるように、フラッシュメモリチップ2−0を構成する各ブロック#0〜#8191は、それぞれページ#0〜#31からなる32個のページによって構成されている。また、フラッシュメモリチップ2−1〜2−3を構成する各ブロック#0〜#8191も、フラッシュメモリチップ2−0を構成する各ブロック#0〜#8191と同様に、それぞれ32個のページによって構成されている。
【0064】
これら各ページはデータの読み出し及び書き込みにおけるアクセス単位であり、図4に示されるように、ビットb0〜b7からなる8ビットを1バイトとして、それぞれ512バイトのユーザ領域25と16バイトの冗長領域26によって構成される。ユーザ領域25は、ホストコンピュータ5より供給されるユーザデータが格納される領域であり、冗長領域26は、対応するユーザ領域25に格納されたユーザデータに対するエラーコレクションコードの他、対応論理ブロックアドレスが格納される領域である。対応論理ブロックアドレスとは、当該ブロックがいかなる論理ブロックアドレスによりアクセスされるかを示す情報であり、その詳細については後述する。
【0065】
このように、各ページは、512バイトのユーザ領域25と16バイトの冗長領域26からなるので、各ページは、8×(512バイト+16バイト)=4224個のフラッシュメモリセルによって構成されることになる。
【0066】
このように、各フラッシュメモリチップ2−0〜2−3は8192個の物理ブロックによって構成されるが、このうち、8000個の物理ブロックは実際にデータを格納することができるブロック(以下、「実使用ブロック」という)として取り扱われ、残りの192個のブロックは「冗長ブロック」として取り扱われる。冗長ブロックは、データ書き込みに備えて待機している空きブロックである。フラッシュメモリチップ2−0〜2−3のアドレス空間は、実使用ブロックのみによって構成される。ある物理ブロックに不良が発生し、使用不能となった場合には、不良が発生したブロックの数だけ冗長ブロックとして割り当てられる物理ブロックの数が減らされる。
【0067】
このような構成からなるフラッシュメモリチップ2−0〜2−3は、上述のとおり、1Mページのアドレス空間を備える一つの大きなメモリとして取り扱われるので、これら1Mページからなるアドレス空間から特定のページにアクセスするためには、上述のとおり、20ビットのホストアドレスが用いられる。20ビットのホストアドレスのうち、上位15ビットは、フラッシュメモリチップの特定及び特定されたフラッシュメモリチップに含まれるブロックの特定に用いられ、残りの5ビット(下位5ビット)は、特定されたブロックに含まれるページの特定に用いられる。
【0068】
ホストアドレスの上位15ビットを用いたフラッシュメモリチップ及びブロックの特定は、ホストアドレスの上位15ビットを「8000」で除することによって行われ、かかる除算によって得られた商(0〜3)によってアクセスすべきフラッシュメモリチップが決定され、剰余(0〜7999)によって「論理ブロックアドレス」が決定される。かかる論理ブロックアドレスは、後述する「アドレス変換テーブル」にて、「物理ブロックアドレス」に変換され、これにより実際にアクセスすべきブロックが特定される。
【0069】
ここで、アドレス変換テーブルを用いて論理ブロックアドレスを物理ブロックアドレスに変換する必要性について説明する。
【0070】
上述のとおり、フラッシュメモリチップ2−0〜2−3を構成するフラッシュメモリセル16は、これをメモリセル単位にて消去状態から書込状態へ変化させることはできる一方、これを書込状態から消去状態へ変化させることは、メモリセル単位で行うことができず、ブロック単位でしか行うことができない。このため、あるページにデータを書き込む際には、そのページのユーザ領域25を構成する全てのフラッシュメモリセル16が消去状態となっている必要があり、既に何らかのデータが書き込まれているページ、すなわち、そのページのユーザ領域25を構成するフラッシュメモリセル16が一つでも書込状態となっているページに、これと異なるデータを直接上書きすることはできない。したがって、既にデータの書き込まれたページに対し、これと異なる新しいデータを書き込むためには、一旦、このページが属するブロックを構成するフラッシュメモリセル16を全て消去状態とし、その後に新しいデータを書き込むという処理が必要となる。
【0071】
したがって、あるページに格納された古いデータに新しいデータを上書きしようとする場合、このページが属するブロックに含まれる他のページに格納されたデータが消失するのを防ぐためには、当該他のページに格納されたデータを、他のブロックに移動させるという処理が必要となる。したがって、ホストアドレスより得られた論理ブロックアドレスと、当該論理ブロックアドレスに対応するフラッシュメモリチップ2−0〜2−3上の物理ブロックアドレスとの関係は、ホストコンピュータ5からデータの上書きが指示される度に動的に変化する。このような理由から、ホストコンピュータ5からフラッシュメモリチップ2−0〜2−3をアクセスするためには、論理ブロックアドレスと、当該論理ブロックアドレスに対応するフラッシュメモリ上の物理ブロックアドレスとの関係を示す情報が格納されるアドレス変換テーブルが必要となるのである。アドレス変換テーブルの詳細については後述する。
【0072】
次に、SRAMワークエリア8に格納される各種作業データについて説明する。SRAMワークエリア8には、少なくとも、アドレス変換テーブル27、消去済みブロックキュー28及び内部変数30が格納される。
【0073】
図5は、SRAMワークエリア8に格納されるアドレス変換テーブル27のデータ構造を示す概略図である。
【0074】
図5に示されるように、アドレス変換テーブル27は、テーブル#0〜#3からなる4つのテーブルによって構成され、これら各テーブルは、8000個のフラグ及び8000個の物理ブロックアドレス格納領域によって構成される。これらテーブル#0〜#3は、それぞれフラッシュメモリチップ2−0〜2−3に対応している。
【0075】
各テーブル#0〜#3内の8000個の物理ブロックアドレス格納領域#0〜#7999には、それぞれ対応する物理ブロックアドレス(13ビット)が格納され、これによって、論理ブロックアドレスと物理ブロックアドレスとの対応関係を示すアドレス変換情報が形成される。すなわち、テーブル#0内の物理ブロックアドレス格納領域#0〜#7999には、フラッシュメモリチップ2−0を構成する8000個の実使用ブロックの物理ブロックアドレスが割り当てられ、これら割り当てられた論理ブロックアドレスと、これに格納された物理ブロックアドレスとが、対応関係を有することになる。同様に、テーブル#1〜#3内の物理ブロックアドレス格納領域#0〜#7999には、それぞれフラッシュメモリチップ2−1〜2−3を構成する8000個の実使用ブロックの物理ブロックアドレスが割り当てられる。
【0076】
例えば、ホストコンピュータ5から供給されたホストアドレスの上位15ビットが「101010101010101B」であれば、これを8000で除した場合の商は「2」であり、剰余は「5845」であるから、テーブル#2内の物理ブロックアドレス格納領域#5845が選択され、ここに格納されている物理ブロックアドレス、例えば、格納されている物理ブロックアドレスが「0000000011111B」であれば、物理ブロックアドレスとして「31」が読み出され、これにより、フラッシュメモリチップ2−2における論理ブロックアドレス#5845から、フラッシュメモリチップ2−2における物理ブロックアドレス#31への変換が完了する。
【0077】
また、各テーブル#0〜#3内の8000個のフラグ#0〜#7999は、当該テーブル内の物理ブロックアドレス格納領域#0〜#7999にそれぞれ対応しており、対応する物理ブロックアドレス格納領域に格納された物理ブロックアドレスが有効な値であるか否かを示す。具体的には、かかるフラグが「1」であれば対応する物理ブロックアドレス格納領域に格納された物理ブロックアドレスが有効な値であることを示し、かかるフラグが「0」であれば対応する物理ブロックアドレス格納領域に格納された物理ブロックアドレスが有効な値ではないことを示す。したがって、対応するフラグが「0」である論理ブロックアドレスには、まだ物理ブロックアドレスが関連づけられていないことを意味する。
【0078】
上述のように、アドレス変換テーブル27は、32000個のフラグと32000個の物理ブロック格納領域によって構成されており、各フラグには1ビットの情報を格納する必要があり、各物理ブロック格納領域には13ビットの情報を格納する必要があるから、アドレス変換テーブル27は、SRAMワークエリア8の記憶容量のうち、約56kバイトを占有することとなる。
【0079】
アドレス変換テーブル27の生成は、次のように行われる。
【0080】
フラッシュメモリチップ2−0〜2−3を構成する各ブロックのうち、データが格納されているブロックの各先頭ページ(ページ#0)に含まれる冗長領域26には、上述のとおり、当該ブロックがいかなる論理ブロックアドレスに対応するかを示す対応論理ブロックアドレスが含まれており、各ブロックの各先頭ページに格納されている対応論理ブロックアドレスがマイクロプロセッサ6による制御のもと、フラッシュメモリインターフェースブロック10を介して読み出される。対応論理ブロックアドレスが読み出されると、マイクロプロセッサ6による制御のもと、当該ブロックが消去済みの空きブロックであるか否かが判断される。
【0081】
ここで、消去済みの空きブロックにおいては、冗長領域26に格納されている対応論理ブロックアドレスは「オール1(1111111111111B)」となっているはずである。すなわち、対応論理ブロックアドレスは、上述のとおり、#0(0000000000000B)〜#7999(1111100111111B)までしかなく、したがって、これがオール1(1111111111111B)である場合には、当該ブロックが消去済みの空きブロックであると判断することができる。一方、対応論理ブロックアドレスが「0000000000000B」〜「1111100111111B」である場合には、当該対応論理ブロックアドレスは有効な論理ブロックアドレスである。
【0082】
したがって、マイクロプロセッサ6は、各ブロックのページ#0〜#3の冗長領域26に含まれる対応論理ブロックアドレスを参照し、これがオール1ではなく有効な論理ブロックアドレスの番号を示していれば、チップ番号に対応するテーブルに属する物理ブロックアドレス格納領域のうち、読み出された対応論理ブロックアドレスと同じ論理ブロックアドレスが割り当てられた物理ブロックアドレス格納領域に、かかる対応論理ブロックアドレスを読み出したブロックの物理ブロックアドレスを格納するとともに、対応するフラグを「1」とする。例えば、対応論理ブロックアドレスを読み出したブロックがフラッシュメモリチップ2−0に属し、その物理ブロックアドレスが「10」であり、読み出された対応論理ブロックアドレスが「123」であれば、テーブル#0に属する物理ブロックアドレス格納領域のうち、論理ブロックアドレスとして「123」が割り当てられた物理ブロックアドレス格納領域#123に、物理ブロックアドレスとして「10」が書き込まれ、さらに、対応するフラグ#123が「1」にされる。
【0083】
以上のような処理が、データの格納されている全てのブロックについて行われ、これによりアドレス変換テーブル27の作成作業が完了する。
【0084】
次に、SRAMワークエリア8に格納される消去済みブロックキュー28のデータ構造について説明する。
【0085】
図6は、SRAMワークエリア8に格納される消去済みブロックキュー28のデータ構造を示す概略図である。
【0086】
図6に示されるように、消去済みブロックキュー28は、キュー#0〜#7からなる8つのキューによって構成される。これら各キュー#0〜#7は、それぞれSRAMワークエリア8の2バイトの記憶領域を使用しており、それぞれには物理ブロックアドレスが13ビットのデータによって格納されている。したがって、消去済みブロックキュー28は、SRAMワークエリア8の記憶容量のうち、16バイトを占有することとなる。
【0087】
消去済みブロックキュー28を構成するキュー#0〜#7のうち、キュー#0及び#1は、フラッシュメモリ2−0用のキューであり、キュー#0及び#1には、フラッシュメモリ2−0に含まれる消去済みブロック、すなわち、ユーザ領域25及び冗長領域26を構成する全てのフラッシュメモリセル16が消去状態となっているブロックの物理ブロックアドレスが格納される。同様に、キュー#2及び#3は、フラッシュメモリ2−1用のキューであり、キュー#4及び#5は、フラッシュメモリ2−2用のキューであり、キュー#6及び#7は、フラッシュメモリ2−3用のキューである。
【0088】
消去済みブロックキュー28の生成は、マイクロプロセッサ6による制御のもと、上述したアドレス変換テーブル27の生成の際に行われる。
【0089】
すなわち、フラッシュメモリチップ2−0〜2−3を構成する各ブロックのページ#0〜ページ#3に含まれる冗長領域26には、上述のとおり、対応論理ブロックアドレスが含まれており、アドレス変換テーブル27が生成される際、マイクロプロセッサ6による制御のもと、対応論理ブロックアドレスが「オール1(1111111111111B)」となっているブロックが検索される。かかる検索により、各フラッシュメモリチップついて、最大192個の消去済みブロックが検出されて冗長ブロックとなり、さらにこの中から最大2つの冗長ブロックが選択されて、その物理ブロックアドレスが、対応するフラッシュメモリチップ用の2つのキューに格納される。
【0090】
次に、SRAMワークエリア8に格納される内部変数30のデータ構造について説明する。
【0091】
図7は、SRAMワークエリア8に格納される内部変数30のデータ構造を示す概略図である。
【0092】
図7に示されるように、内部変数30は、変数#0〜#3によって構成される。これら変数#0〜#3は、それぞれフラッシュメモリチップ#2−0〜#2−3用の変数であり、それぞれ転送先ブロックアドレス格納領域31、転送元ブロックアドレス格納領域32、スタートページ格納領域33及びフラグ34によって構成されている。転送先ブロックアドレス格納領域31及び転送元ブロックアドレス格納領域32には、いずれも物理ブロックアドレスが13ビットのデータによって格納されており、スタートページ格納領域33には、ページ番号が5ビットのデータによって格納されている。また、フラグ34は1ビットのデータである。したがって、内部変数30は、SRAMワークエリア8の記憶容量のうち、16バイトを占有することとなる。
【0093】
転送先ブロックアドレス格納領域31に格納された物理ブロックアドレスは、以下に詳述する「部分転送」において転送先となったブロックの物理ブロックアドレスであり、転送元ブロックアドレス格納領域32に格納された物理ブロックアドレスは、「部分転送」において転送元となったブロックの物理ブロックアドレスである。また、スタートページ格納領域33に格納されたページ番号は、転送先ブロックアドレス格納領域31に格納された物理ブロックアドレスにより示される物理ブロック内のページ#0〜#31のうち、最終ページ(ページ#31)を含む1または2以上の連続した空きページ中の先頭のページのページ番号である。したがって、上記物理ブロック内において、スタートページ以降のページは、データの格納されていない空きページであることが保証される。また、フラグ34は、「1」であれば、対応する転送先ブロックアドレス格納領域31、転送元ブロックアドレス格納領域32及びスタートページ格納領域33の内容が有効であることを示し、「0」であればこれらが有効な値ではないことを示す。
【0094】
次に、本実施態様にかかるフラッシュメモリシステム1によるデータの書き込み動作について説明する。
【0095】
本実施態様にかかるフラッシュメモリシステム1によるデータの書き込み動作は、新規書込動作、部分転送動作、追書込動作の3つに分類される。
【0096】
図8は、いずれの書込動作が行われるかを決定するためのフローチャートである。以下、図8に示されるフローチャートを参照しながら、いずれの書込動作が選択されるかについて説明する。
【0097】
まず、ホストコンピュータ5より、ホストアドレス及び外部書き込みコマンドがコントローラ3に供給されると(ステップS1)、これらホストアドレス及び外部書き込みコマンドは、ホストインターフェースブロック7が有するタスクファイルレジスタ(図示せず)に一時的に格納される。さらに、書き込みデータがコントローラ3に供給されると、マイクロプロセッサ6による制御のもと、ECCブロック11に送出される。書き込みデータの供給を受けたECCブロック11は、これを解析してエラーコレクションコードを生成し、これを一時的に保持する。
【0098】
次に、タスクファイルレジスタ(図示せず)に格納されたホストアドレスが正しいアドレスであるか否か、すなわち、これらホストアドレスが、本来存在しないアドレスや無効なアドレスを示していないか否かが、ホストインターフェースブロック7によって判定される。
【0099】
かかる判定の結果、タスクファイルレジスタ(図示せず)に格納されたホストアドレスが有効なアドレスであると判断されれば、ホストアドレスが内部アドレスに変換される。一方、これが異常なアドレスであると判断されれば、ホストインターフェースブロック7が有するエラーレジスタ(図示せず)がセットされ、ホストコンピュータ5は、かかるレジスタの内容を参照することにより、エラーの発生を知ることができる。
【0100】
内部アドレスへの変換は、次のように行われる。
【0101】
まず、マイクロプロセッサ6による制御のもと、20ビットのホストアドレスから上位15ビットが取り出され、これが「8000」で除される(ステップS2)。かかる除算によって得られた商(0〜3)及び剰余(0〜7999)は、それぞれ「チップ番号」及び「論理ブロックアドレス」となり、かかるチップ番号及び論理ブロックアドレスに基づいて、アドレス変換テーブル27内の対応するフラグが読み出される(ステップS3)。例えば、ホストアドレスの上位15ビットが「000000111110100B」であれば、8000で除した場合の商は「00B(0)」であり、剰余は「0111110100B(500)」であるから、この場合、チップ番号は#0、論理ブロックアドレスは#500となり、これに基づいてテーブル#0内のフラグ#500が読み出される。
【0102】
このようにして、アドレス変換テーブル27内の対応するフラグが読み出されると、次に、その内容が「1」であるか「0」であるかが判断される(ステップS4)。その結果、読み出されたフラグの内容が「0」であれば、対応する物理ブロックアドレス格納領域に有効な物理ブロックアドレスが格納されていないことを意味するので、新規書込動作が選択される(ステップS5)。新規書込動作の詳細については後述する。
【0103】
一方、読み出されたフラグの内容が「1」であれば、対応する物理ブロックアドレス格納領域に有効な物理ブロックアドレスが格納されていることを意味するので、その内容が読み出される。読み出された13ビットの物理ブロックアドレスは、チップ番号及びホストアドレスの下位5ビットとともに、内部アドレスを構成する。以上により、内部アドレスへの変換が完了する(ステップS6)。
【0104】
次に、チップ番号(内部アドレスの上位2ビット)に基づいて、内部変数30内の対応するフラグ34が読み出される(ステップS7)。例えば、チップ番号が「00B(0)」であれば、変数#0に含まれるフラグ34が読み出される。このようにして、内部変数30内の対応するフラグ34が読み出されると、次に、その内容が「1」であるか「0」であるかが判断される(ステップS8)。その結果、読み出されたフラグ34の内容が「0」であれば、以下に詳述する部分転送動作が選択される(ステップS9)。
【0105】
一方、読み出されたフラグ34の内容が「1」であれば、追書込動作の実行が可能であるか否かを判定する追書込判定(ステップS10)が行われ、かかる判定において追書込動作の実行が可能であると判定されれば、以下に詳述する追書込動作が選択され、追書込動作の実行が不可能であると判定されれば、部分転送動作が選択される。
【0106】
以上のようにして、新規書込動作、部分転送動作、追書込動作のいずれを実行すべきかが決定される。
【0107】
次に、新規書込動作について説明する。
【0108】
図9は、新規書込動作を示すフローチャートである。
【0109】
図9に示されるように、新規書込動作(ステップS5)においては、まず、マイクロプロセッサ6による制御のもと、消去済みブロックキュー28を構成するキュー#0〜#7のうち所定のキューが選択され、格納されている物理ブロックアドレスが読み出される(ステップS11)。上述のとおり、消去済みブロックキュー28の各キューに格納された物理ブロックアドレスは、消去済みブロック、すなわち、ユーザ領域25及び冗長領域26を構成する全てのフラッシュメモリセル16が消去状態となっているブロックの物理ブロックアドレス(13ビット)である。
【0110】
消去済みブロックの物理ブロックアドレスが読み出されると、これがアドレス変換テーブル27内の対応する物理ブロックアドレス格納領域に格納されるとともに、対応するフラグが「1」に書き換えられる(ステップS12)。例えば、上述の例と同様に、ホストアドレスの上位15ビットが「000000111110100B」であれば、8000で除した場合の商は「00B(0)」であり、剰余は「0111110100B(500)」であるから、アドレス変換テーブル27のテーブル#0内の物理ブロックアドレス格納領域#500に消去済みブロックの物理ブロックアドレスが格納されるとともに、テーブル#0内のフラグ#500が「1」に書き換えられる。
【0111】
そして、マイクロプロセッサ6による制御のもと、チップ番号、物理ブロックアドレス、及びホストアドレスの下位5ビットがこの順に結合され、結合されたアドレスは内部アドレスとなる(ステップS13)。
【0112】
このようにして内部アドレスの生成が完了すると、次にマイクロプロセッサ6による制御のもと、フラッシュシーケンサブロック12が有するレジスタ(図示せず)に対する所定の設定がなされ、完了すると、フラッシュシーケンサブロック12による一連の書き込み動作が実行される(ステップS14)。これにより、内部アドレスにより示される所定のブロックの所定のページに対して、ホストコンピュータ5より与えられたユーザデータが書き込まれる。
【0113】
この場合、書き込みの対象となったブロックに対しては、ユーザデータの書き込み対象となったページのみならず、当該ブロックを構成する全てのページ#0〜#31の冗長領域26に対応論理ブロックアドレスが書き込まれる。これにより、当該ブロックは「使用済みブロック」となり、以後、ユーザデータを直接上書きすることはできなくなる。
【0114】
以上により、新規書込動作(ステップS5)が完了する。
【0115】
次に、部分転送動作について説明する。
【0116】
図10は、部分転送動作を示すフローチャートであり、図11(a)及び(b)は、部分転送動作における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【0117】
図10に示されるように、部分転送動作(ステップS9)においては、まず、マイクロプロセッサ6による制御のもと、消去済みブロックキュー28を構成するキュー#0〜#7のうち所定のキューが選択され、格納されている物理ブロックアドレスが読み出される(ステップS21)。
【0118】
消去済みブロックの物理ブロックアドレスが読み出されると、これに基づいて内部変数30が更新される(ステップS22)。ここで、内部変数30の更新においては、まずチップ番号に基づいて変数#0〜#3のいずれかが選択され、選択された変数を構成する転送先ブロックアドレス格納領域31に消去済みブロックキュー28より読み出された物理ブロックアドレスが格納され、転送元ブロックアドレス格納領域32にアドレス変換テーブル27より読み出された物理ブロックアドレスが格納され、スタートページ格納領域33に書き込み対象のページ(ページ#i)の次のページのページ番号(ページ#i+1)が格納される。また、フラグ34が「1」にセットされる。ここで、書き込み対象のページ(ページ#i)とは、内部アドレスの下位5ビットにより特定されるページを指す。以下、転送先ブロックアドレス格納領域31に格納された物理ブロックアドレスにより特定されるブロックを「転送先ブロック」と呼び、転送元ブロックアドレス格納領域32に格納された物理ブロックアドレスにより特定されるブロックを「転送元ブロック」と呼ぶ。
【0119】
内部変数30の更新が完了すると、次に、アドレス変換テーブル27の更新が行われる(ステップS23)。アドレス変換テーブル27の更新においては、対応する物理ブロックアドレス格納領域に、消去済みブロックキュー28より読み出された物理ブロックアドレスが上書きされる。
【0120】
次に、転送元ブロック内のページ#0から書き込み対象のページ(ページ#i)の1つ前のページ(ページ#i−1)までのページに格納されたデータが、転送先ブロックの同じページに転送される(ステップS24)。すなわち、ブロック間転送の前半部分の動作が行われる。ステップS24が完了すると、図11(a)に示されるように、転送先ブロックのページ#0〜#i−1が有効ページ(ハッチングされた部分)となり、ページ#i〜#31が空きページとなる。ここで、「有効ページ」とは、実際に有効なユーザデータが格納されているか否かを問わず、書き込み動作が禁止されるページを意味する。有効ページには、対応する冗長領域26に対応論理ブロックアドレスが書き込まれており、空きページには、対応する冗長領域26内の対応論理ブロックアドレスがオール1(1111111111111B)となっている。
【0121】
ステップS24が完了すると、次に、ホストコンピュータ5より書き込みが指示されたデータが、転送先ブロックの書き込み対象のページ(ページ#i)に書き込まれる(ステップS25)。ステップS25が完了すると、図11(b)に示されるように、転送先ブロックのページ#0〜#iが有効ページとなり、ページ#i+1〜#31が空きページとなる。
【0122】
以上により、部分転送動作(ステップS9)が完了する。部分転送動作においては、ブロック間転送の後半部分の動作が省略されている点が重要である。したがって、部分転送動作が行われた場合、ある論理ブロックアドレスに対して2つの物理ブロックが割り当てられた状態となる。
【0123】
次に、追書込判定について説明する。
【0124】
図12は、追書込判定を示すフローチャートである。
【0125】
図12に示されるように、追書込判定(ステップS10)においては、まず、チップ番号(内部アドレスの上位2ビット)に基づいて、内部変数30内の対応する転送先ブロックアドレス格納領域31の内容が読み出される(ステップS31)。次に、読み出された13ビットの物理ブロックアドレスと、アドレス変換テーブル27より読み出された物理ブロックアドレスとが比較され、これらが一致している否かが判断される(ステップS32)。
【0126】
その結果、両者が一致しない場合、転送元ブロックアドレス格納領域32及びスタートページ格納領域33の内容が読み出され(ステップS33)、転送元ブロック内のページ#i+1から最終ページ(ページ#31)までのページに格納されたデータが、転送先ブロックの同じページに転送される(ステップS34)。すなわち、ブロック間転送の後半部分の動作が行われる。
【0127】
図13は、ステップS34における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【0128】
図13に示されるように、ステップS34においては、上述した部分転送動作(ステップS9)において省略されたブロック間転送の後半部分の動作が行われ、これにより、転送先ブロックを構成する全てのページ#0〜#31が有効ページとなる。
【0129】
ステップS34が完了すると、次に、転送元ブロックがブロック消去されて、新たな空きブロックとされ(ステップS35)、さらに、対応するフラグ34が「0」にリセットされる(ステップS36)。これにより、1つの論理ブロックアドレスに対して2つの物理ブロックが割り当てられた状態が解消される。その後、上述した部分転送動作(ステップS9)が行われ、これにより、ホストコンピュータ5より書き込みが指示されたデータが所定のブロックに書き込まれる。
【0130】
一方、ステップS32における判定の結果、両者が一致した場合には、スタートページ格納領域33の内容が読み出され(ステップS37)、内部アドレスの下位5ビット、すなわち書き込み対象のページ(ページ#j)と、スタートページ(ページ#i+1)とが比較される(ステップS38)。
【0131】
その結果、書き込み対象のページ(ページ#j)のページ番号がスタートページ(ページ#i+1)のページ番号よりも小さければ、上述したステップS33〜S36が実行され、その後部分転送動作(ステップS9)が実行される。一方、書き込み対象のページ(ページ#j)のページ番号がスタートページ(ページ#i+1)のページ番号と同じかそれ以上であれば、以下に詳述する追書込動作が選択される(ステップS39)。
【0132】
以上により、追書込判定(ステップS10)が完了する。このように、追書込判定(ステップS10)においては、追書込動作(ステップS39)及び部分転送動作(ステップS9)のいずれかが選択されることになる。
【0133】
次に、追書込動作について説明する。
【0134】
図14は、追書込動作を示すフローチャートであり、図15(a)〜(c)は、追書込動作における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【0135】
追書込動作(ステップS39)は、書き込み対象のページ(ページ#j)が、スタートページ(ページ#i+1)と一致する場合(j=i+1)と、一致しない場合(j>i+1)によって動作が異なる。このため、図14に示されるように、追書込動作においては、まず書き込み対象のページ(ページ#j)がスタートページ(ページ#i+1)と一致するか否かが判定される(ステップS41)。
【0136】
その結果、書き込み対象のページ(ページ#j)とスタートページ(ページ#i+1)とが一致する場合(j=i+1)には、転送先ブロック内の書き込み対象のページ(ページ#j)に対してデータが書き込まれ(ステップS43)、これにより、図15(a)に示されるように、転送先ブロックのページ#0〜#j(=i+1)が有効ページ、ページ#j+1〜#31が空きページとなる。ステップS43が完了すると、次に、内部変数30のスタートページ格納領域33の内容が、書き込み対象のページ(ページ#j)の次のページのページ番号(ページ#j+1)に更新される(ステップS44)。
【0137】
一方、書き込み対象のページ(ページ#j)とスタートページ(ページ#i+1)とが一致しない場合(j>i+1)には、転送元ブロック内のスタートページ(ページ#i+1)から書き込み対象のページ(ページ#j)の一つ前のページ(ページ#j−1)までのページに格納されたデータが、転送先ブロックの同じページに転送される(ステップS42)。すなわち、中間転送が行われる。これにより、図15(b)に示されるように、転送先ブロックのページ#0〜#j−1が有効ページ、ページ#j〜#31が空きページとなる。ステップS42が完了すると、上述したステップS43によりページ#jに対してデータが書き込まれ、これにより、図15(c)に示されるように、転送先ブロックのページ#0〜#j(=i+1)が有効ページ、ページ#j+1〜#31が空きページとなる。その後、上述したステップS44が実行され、スタートページ格納領域33の内容がページ#j+1に更新される。
【0138】
このようにしてデータの書き込みが完了すると、次に、書き込み対象のページ(ページ#j)が最終ページ(ページ#31)であるか否かが判断される(ステップS45)。その結果、書き込み対象のページ(ページ#j)が最終ページ(ページ#31)であれば、転送元ブロックをブロック消去して空きブロックとし(ステップS46)、対応するフラグ34を「0」にリセットする(ステップS47)。一方、書き込み対象のページ(ページ#j)が最終ページ(ページ#31)以外であれば、上記ステップS46及びステップS47を実行することなく、一連の処理を終了する。
【0139】
以上により、追書込動作(ステップS39)が完了する。
【0140】
以上が、本実施態様にかかるフラッシュメモリシステム1によるデータ書き込み動作である。
【0141】
本実施態様にかかるフラッシュメモリシステム1においては、部分転送動作(ステップS9)が行われることにより、1つの論理ブロックアドレスに対して2つの物理ブロックが割り当てられた状態が生じる。このため、ホストコンピュータ5より当該ブロックに対するデータの読み出しが指示された場合には、内部変数30を参照することによって、正しいデータが書き込まれた物理ブロックに対する読み出しを実行することができる。
【0142】
但し、この場合には、ホストコンピュータ5よりデータの読み出しが指示される度に内部変数30を参照する必要があることから、部分転送動作が行われた後、同じ論理ブロックアドレスに対するデータの書き込み指示以外の指示がホストコンピュータ5より発行された場合には、当該指示を実行する前に、上述したステップS33〜ステップS35の処理を実行することによって、ブロック間転送を完結させても構わない。この場合には、ホストコンピュータ5よりいかなる論理ブロックアドレスに対するデータの読み出しが指示された場合であっても、通常のフラッシュメモリシステム1と同じ読み出し処理によってこれを行うことができる。
【0143】
次に、部分転送動作(ステップS9)が行われることにより、1つの論理ブロックアドレスに対して2つの物理ブロックが割り当てられた状態において電源が遮断され、その後、再び電源が投入された場合の動作について説明する。
【0144】
1つの論理ブロックアドレスに対して2つの物理ブロックが割り当てられた状態において電源が遮断されると、起動時に行われるアドレス変換テーブル27の作成において、ある論理ブロックアドレスに対応する物理ブロックとして2つの物理ブロックが発見されるはずである。すなわち、同じ対応論理ブロックアドレスを持つ2つの物理ブロックが発見されるはずである。このような論理ブロックアドレスが発見されると、マイクロプロセッサ6による制御のもと、以下に詳述する完結動作が実行される。
【0145】
図16は、完結動作を示すフローチャートであり、図17は、完結動作における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【0146】
図16に示されるように、完結動作においては、まず、同じ対応論理ブロックアドレスを持つ2つの物理ブロックの最終ページ(ページ#31)をそれぞれ読み出し、いずれが空きページであるかが判定される。ここで、いずれが空きページであるかの判定は、これらページの冗長領域26に含まれる対応論理ブロックアドレスに基づいて行われ、対応論理ブロックアドレスがオール1(1111111111111B)である方が空きページであると判定される。かかる判定により、最終ページ(ページ#31)が空きページとなっているブロックが部分転送動作における転送先ブロックであり、最終ページ(ページ#31)が有効ページとなっているブロックが部分転送動作における転送元ブロックであると判別することができる(ステップS51)。
【0147】
このようにして、上記2つの物理ブロックに対する転送先ブロック/転送元ブロックの判別が完了すると、アドレス変換テーブル27内の対応する物理ブロックアドレス格納領域に、転送先ブロックの物理ブロックアドレスが格納されるとともに、対応するフラグが「1」にセットされる(ステップS52)。
【0148】
次に、転送先ブロックを構成するページを、ページ#30から順に遡って次々と読み出し、これによって空きページの範囲を検出する(ステップS53)。例えば、ページ#20において有効な対応論理ブロックアドレスが読み出されれば、ページ#21〜#31が空きブロックであることが検出される。
【0149】
空きブロックの範囲が検出されると、次に、転送先ブロックの各空きページに対して、転送元ブロックの対応するページのデータがそれぞれ転送される(ステップS54)。すなわち、ブロック間転送の後半部分の動作が行われる。これにより、図17に示されるように、転送先ブロックの全てのページ#0〜#31が有効ページとなる。尚、図17においては、ステップS53において転送先ブロックのページ#21〜#31が空きブロックであると検出された場合の動作が示されている。そして、転送元ブロックをブロック消去して空きブロックとし(ステップS55)、一連の処理を終了する。
【0150】
以上により、完結動作が完了する。
【0151】
このように、本実施態様にかかるフラッシュメモリシステム1では、既にデータが割り当てられている論理ブロックアドレス、すなわち、アドレス変換テーブル27内の対応するフラグが「1」となっている論理ブロックアドレスに対してホストコンピュータ5よりデータの書き込みが指示された場合であっても、従来のように直ちにブロック間転送を行うのではなく、ブロック間転送の後半部分の動作を省略した部分書込動作を行っているので、次にホストコンピュータ5より同じブロックに対してデータの書き込みが指示された場合に、追書込動作を行うことができる。追書込動作では、上述のとおり、転送すべきページ数がゼロか、若しくは少ない数であるため、ホストコンピュータ5からデータの書き込みが指示される度にブロック間転送を行う場合と比べて、一連の処理に要する時間は大きく短縮される。特に、連続する複数ページに対し、ホストコンピュータ5よりデータの書き込みが1ページずつ次々と指示されるような状況下においては、本実施態様にかかるフラッシュメモリシステム1による高速化の効果は著しい。
【0152】
次に、本発明の好ましい他の実施態様について説明する。
【0153】
本発明の好ましい他の実施態様にかかるフラッシュメモリシステム39の構成は、図1に示されるように上記実施態様にかかるフラッシュメモリシステム1と基本的に同様であり、SRAMワークエリア8に格納される内部変数30が内部変数40に置き換えられている点において異なる。
【0154】
図18は、SRAMワークエリア8に格納される内部変数40のデータ構造を示す概略図である。
【0155】
図18に示されるように、内部変数40は、変数#0〜#3によって構成され、それぞれ第1のブロックアドレス格納領域41、第2のブロックアドレス格納領域42、第3のブロックアドレス格納領域43、第1のスタートページ格納領域44、第2のスタートページ格納領域45、第1のフラグ46及び第2のフラグ47によって構成されている。第1〜第3のブロックアドレス格納領域41〜43には、それぞれ物理ブロックアドレスが13ビットのデータによって格納されており、第1及び第2のスタートページ格納領域44、45には、それぞれページ番号が5ビットのデータによって格納されている。また、第1及び第2のフラグ46、47はそれぞれ1ビットのデータである。したがって、内部変数40は、SRAMワークエリア8の記憶容量のうち、28バイトを占有することとなる。
【0156】
第1のフラグ46は、「1」であれば当該変数の内容が有効であることを示し、「0」であれば当該変数の内容が無効であることを示す。すなわち、第1のフラグ46は、上記実施態様におけるフラグ34に対応するフラグである。また、第2のフラグ47は、第1のフラグ46が「1」である場合にのみ有効なフラグであり、これが「1」であれば、第1〜第3のブロックアドレス格納領域41〜43、第1及び第2のスタートページ格納領域44、45の内容が全て有効であることを示し、「0」であれば、第1及び第2のブロックアドレス格納領域41、42、第1のスタートページ格納領域44の内容が全て有効であり、第3のブロックアドレス格納領域43、第2のスタートページ格納領域45の内容が無効であることを示す。
【0157】
また、第1のブロックアドレス格納領域41は、上記実施態様における転送元ブロックアドレス格納領域32に対応し、第2のブロックアドレス格納領域42は、上記実施態様における転送先ブロックアドレス格納領域31に対応する。されに、第1のスタートページ格納領域44は、上記実施態様におけるスタートページ格納領域33に対応する。
【0158】
次に、本実施態様にかかるフラッシュメモリシステム39によるデータの書き込み動作について説明する。
【0159】
本実施態様にかかるフラッシュメモリシステム39におけるデータの書き込み動作は、新規書込動作、第1及び第2の部分転送動作、第1及び第2の追書込動作の5つに分類される。これら書込動作のいずれが選択されるかを決定する方法は、基本的に図8に示したフローチャートと同様であるが、ステップS7においては、チップ番号(内部アドレスの上位2ビット)に基づいて、内部変数40内の対応する第1のフラグ46が読み出される。その結果、これが「0」であれば、第1の部分転送動作が選択される。
【0160】
第1の部分転送動作は、上記実施態様における部分転送動作(ステップS9)と基本的に同様であるが、ステップS22においては、まずチップ番号に基づいて変数#0〜#3のいずれかが選択され、選択された変数を構成する第2のブロックアドレス格納領域42に消去済みブロックキュー28より読み出された物理ブロックアドレスが格納され、第1のブロックアドレス格納領域41にアドレス変換テーブル27より読み出された物理ブロックアドレスが格納され、第1のスタートページ格納領域44に書き込み対象のページ(ページ#i)の次のページのページ番号(ページ#i+1)が格納される。また、第1のフラグ46が「1」にセットされ、第2のフラグ47が「0」にリセットされる。
【0161】
以下、第1のブロックアドレス格納領域41に格納された物理ブロックアドレスにより特定されるブロックを「第1のブロック」と呼び、第2のブロックアドレス格納領域42に格納された物理ブロックアドレスにより特定されるブロックを「第2のブロック」と呼ぶ。また、第3のブロックアドレス格納領域43に格納された物理ブロックアドレスにより特定されるブロックを「第3のブロック」と呼ぶ。
【0162】
そして、ステップS24において、第1のブロック内のページ#0から書き込み対象のページ(ページ#i)の1つ前のページ(ページ#i−1)までのページに格納されたデータが、第2のブロックの同じページに転送され、ステップS25において、ホストコンピュータ5より書き込みが指示されたデータが、第2のブロックの書き込み対象のページ(ページ#i)に書き込まれる。
【0163】
次に、本実施態様における追書込判定について説明する。
【0164】
図19は、本実施態様にかかるフラッシュメモリシステム39による追書込判定を示すフローチャートである。
【0165】
図19に示されるように、本実施態様における追書込判定(ステップS10)では、まず、チップ番号(内部アドレスの上位2ビット)に基づいて、内部変数40内の対応する第2のフラグ47の内容が読み出される(ステップS61)。内部変数40内の対応する第2のフラグ47が読み出されると、次に、その内容が「1」であるか「0」であるかが判断される(ステップS62)。その結果、読み出された第2のフラグ47の内容が「0」であれば、第2のブロックアドレス格納領域42の内容が読み出され(ステップS63)、「1」であれば、第3のブロックアドレス格納領域43の内容が読み出される(ステップS64)。
【0166】
第2のフラグ47の内容が「0」であるために第2のブロックアドレス格納領域42の内容が読み出された場合(ステップS63)、その内容とアドレス変換テーブル27より読み出された物理ブロックアドレスとが比較され、これらが一致している否かが判断される(ステップS65)。
【0167】
その結果、両者が一致しない場合、第1のブロックアドレス格納領域41及び第1のスタートページ格納領域44の内容が読み出され(ステップS66)、第1のブロックアドレス格納領域41の内容にて特定される第1のブロック内のページのうち、第1のスタートページ格納領域44の内容にて特定されるページ(ページ#i+1)から最終ページ(ページ#31)までのページに格納されたデータが、第2のブロックアドレス格納領域42の内容にて特定される第2のブロック内の同じページに転送される(ステップS67)。すなわち、ブロック間転送の後半部分の動作が行われる。かかる動作は、図13に示した転送動作と同様である。
【0168】
ステップS67が完了すると、次に、第1のブロックがブロック消去されて、新たな空きブロックとされ(ステップS68)、さらに、対応する第1のフラグ46が「0」にリセットされる(ステップS69)。これにより、1つの論理ブロックアドレスに対して2つの物理ブロックが割り当てられた状態が解消される。その後、上述した第1の部分転送動作(ステップS9)が行われる。
【0169】
一方、ステップS65における判定の結果、両者が一致した場合には、第1のスタートページ格納領域44の内容が読み出され(ステップS70)、内部アドレスの下位5ビット、すなわち書き込み対象のページ(ページ#j)と、スタートページ(ページ#i+1)とが比較される(ステップS71)。
【0170】
その結果、書き込み対象のページ(ページ#j)のページ番号がスタートページ(ページ#i+1)のページ番号よりも小さければ、以下に詳述する第2の部分転送動作(ステップS72)が行われ、書き込み対象のページ(ページ#j)のページ番号がスタートページ(ページ#i+1)のページ番号以上であれば、第1の追書込動作が選択される(ステップS39)。第1の追書込動作は、上記実施態様における部分転送動作(ステップS39)と基本的に同様であるが、ステップS44においては、内部変数40の対応する第1のスタートページ格納領域44の内容が、書き込み対象のページ(ページ#j)の次のページのページ番号(ページ#j+1)に更新される。また、ステップS47においては、内部変数40の対応する第1のフラグ46が「0」にリセットされる。
【0171】
ここで、第2の部分転送動作(ステップS72)について説明する。
【0172】
図20は、第2の部分転送動作を示すフローチャートであり、図21(a)及び(b)は、第2の部分転送動作における第1〜第3のブロックのデータ格納状態を示す概略図である。
【0173】
図20に示されるように、第2の部分転送動作(ステップS72)においては、まず、マイクロプロセッサ6による制御のもと、消去済みブロックキュー28を構成するキュー#0〜#7のうち所定のキューが選択され、格納されている物理ブロックアドレスが読み出される(ステップS91)。
【0174】
消去済みブロックの物理ブロックアドレスが読み出されると、これに基づいて内部変数40が更新される(ステップS92)。ここで、内部変数40の更新においては、まずチップ番号に基づいて変数#0〜#3のいずれかが選択され、選択された変数を構成する第3のブロックアドレス格納領域43に消去済みブロックキュー28より読み出された物理ブロックアドレスが格納され、第2のスタートページ格納領域45に書き込み対象のページ(ページ#j)の次のページのページ番号(ページ#j+1)が格納される。また、第2のフラグ47が「1」にセットされる。
【0175】
内部変数40の更新が完了すると、次に、アドレス変換テーブル27の更新が行われる(ステップS93)。アドレス変換テーブル27の更新においては、対応する物理ブロックアドレス格納領域に、消去済みブロックキュー28より読み出された物理ブロックアドレスが上書きされる。
【0176】
次に、第2のブロック内のページ#0から書き込み対象のページ(ページ#j)の1つ前のページ(ページ#j−1)までのページに格納されたデータが、第3のブロックの同じページに転送される(ステップS94)。すなわち、ブロック間転送の前半部分の動作が行われる。ステップS94が完了すると、図21(a)に示されるように、第3のブロックのページ#0〜#j−1が有効ページとなり、ページ#j〜#31が空きページとなる。
【0177】
ステップS94が完了すると、次に、ホストコンピュータ5より書き込みが指示されたデータが、転送先ブロックの書き込み対象のページ(ページ#j)に書き込まれる(ステップS95)。ステップS95が完了すると、図21(b)に示されるように、第3のブロックのページ#0〜#jが有効ページとなり、ページ#j+1〜#31が空きページとなる。
【0178】
以上により、第2の部分転送動作(ステップS72)が完了する。図21に示されるように、第2の部分転送動作が行われた場合、ある論理ブロックアドレスに対して3つの物理ブロックが割り当てられた状態となる。
【0179】
図19に戻って、再び追書込判定について説明する。
【0180】
ステップS62において、第2のフラグ47の内容が「1」であるために第3のブロックアドレス格納領域43の内容が読み出された場合(ステップS64)、その内容とアドレス変換テーブル27より読み出された物理ブロックアドレスとが比較され、これらが一致している否かが判断される(ステップS73)。
【0181】
その結果、両者が一致しない場合、第1のブロックアドレス格納領域41、第2のブロックアドレス格納領域42、第1のスタートページ格納領域44及び第2のスタートページ格納領域45の内容が読み出される(ステップS74)。次に、
第2のブロック内のページのうち、第2のスタートページ(ページ#j+1)から第1のスタートページ(ページ#i+1)の1つ前のページ(ページ#i)までのページに格納されたデータが、第3のブロック内の同じページに転送される(ステップS75)。これにより、図22(a)に示されるように、第3のブロックのページ#0〜#iが有効ページとなり、ページ#i+1が空きページとなる。
【0182】
次に、第1のブロック内のページのうち、第1のスタートページ(ページ#i+1)から最終ページ(ページ#31)までのページに格納されたデータが、第3のブロック内の同じページに転送される(ステップS76)。これにより、図22(b)に示されるように、第3のブロックの全てのページ#0〜#31が有効ページとなる。
【0183】
そして、第1のブロック及び第2のがブロック消去されて、新たな空きブロックとされ(ステップS77)、さらに、対応する第1のフラグ46及び第2のフラグ47が「0」にリセットされる(ステップS69)。これにより、1つの論理ブロックアドレスに対して3つの物理ブロックが割り当てられた状態が解消される。その後、上述した第1の部分転送動作(ステップS9)が行われる。
【0184】
一方、ステップS73において、両者が一致した場合には、第2のスタートページ格納領域45の内容が読み出され(ステップS78)、内部アドレスの下位5ビット、すなわち書き込み対象のページ(ページ#k)と、第2のスタートページ(ページ#j+1)とが比較される(ステップS79)。
【0185】
その結果、書き込み対象のページ(ページ#k)のページ番号が第2のスタートページ(ページ#j+1)のページ番号よりも小さければ、第2のブロック内のページのうち、第2のスタートページ(ページ#j+1)から第1のスタートページ(ページ#i+1)の1つ前のページ(ページ#i)までのページに格納されたデータが、第3のブロック内の同じページに転送され(ステップS80)、次に、第2のブロックがブロック消去される(ステップS81)。これにより、第3のブロックが新たに第2のブロックとなり、第2のブロックが空きブロックとなるので、これに基づいて内部変数40が更新される(ステップS82)。ここで、内部変数40の更新においては、対応する第3のブロックアドレス格納領域43の内容が第2のブロックアドレス格納領域42にコピーされるとともに、第2のフラグ47が「0」にリセットされる。内部変数40の更新が完了すると、上述した第2の部分転送動作(ステップS72)が実行される。
【0186】
一方、ステップS73において、書き込み対象のページ(ページ#k)のページ番号が第2のスタートページ(ページ#j+1)のページ番号以上であれば、以下に詳述する第2の追書込動作が選択される(ステップS83)。
【0187】
以上により、追書込判定(ステップS10)が完了する。このように、本実施態様における追書込判定(ステップS10)においては、第1の部分転送動作(ステップS9)、第2の部分転送動作(ステップS72)、第1の追書込動作(ステップS39)、第2の追書込動作(ステップS83)のいずれかが選択されることになる。
【0188】
次に、第2の追書込動作(ステップS83)について説明する。
【0189】
図23は、第2の追書込動作を示すフローチャートであり、図24(a)〜(c)及び図25(a)〜(c)は、第2の追書込動作における第1〜第3のブロックのデータ格納状態を示す概略図である。
【0190】
第2の追書込動作(ステップS83)は、書き込み対象のページ(ページ#k)が、第2のスタートページ(ページ#j+1)と一致する場合(k=j+1)と、一致しない場合(k>j+1)によって動作が異なる。このため、図23に示されるように、第2の追書込動作においては、まず書き込み対象のページ(ページ#k)が第2のスタートページ(ページ#j+1)と一致するか否かが判定される(ステップS101)。
【0191】
その結果、書き込み対象のページ(ページ#k)と第2のスタートページ(ページ#j+1)とが一致する場合(k=j+1)には、第3のブロック内の書き込み対象のページ(ページ#k)に対してデータが書き込まれ(ステップS102)、これにより、図24(a)に示されるように、第3のブロックのページ#0〜#k(=j+1)が有効ページ、ページ#k+1〜#31が空きページとなる。ステップS102が完了すると、次に、書き込み対象のページ(ページ#k)が第1のスタートページの一つ前のページ(ページ#i)と一致するか否かが判定される(ステップS103)。その結果、書き込み対象のページ(ページ#k)と第1のスタートページの一つ前のページ(ページ#i)とが一致しない場合には(k≠i)、内部変数40の第2のスタートページ格納領域45の内容が、書き込み対象のページ(ページ#k)の次のページのページ番号(ページ#k+1)に更新される(ステップS104)。
【0192】
一方、書き込み対象のページ(ページ#k)と第1のスタートページの一つ前のページ(ページ#i)とが一致する場合には(k=i)、第2のブロックをブロック消去して空きブロックとした後(ステップS105)、内部変数40が更新される(ステップS106)。ここで、内部変数40の更新においては、対応する第3のブロックアドレス格納領域43の内容が第2のブロックアドレス格納領域42にコピーされるとともに、第2のフラグ47が「0」にリセットされる。これにより、第3のブロックが新たに第2のブロックとなり、第2のブロックが空きブロックとなる。
【0193】
また、ステップS101において、書き込み対象のページ(ページ#k)と第2のスタートページ(ページ#j+1)とが一致しない場合(k>j+1)には、書き込み対象のページ(ページ#k)と第1のスタートページ(ページ#i+1)とが比較される(ステップS107)。その結果、書き込み対象のページ(ページ#k)が第1のスタートページ(ページ#i+1)以下であれば、第2のブロック内の第2のスタートページ(ページ#j+1)から書き込み対象のページ(ページ#k)の一つ前のページ(ページ#k−1)までのページに格納されたデータが、第3のブロックの同じページに転送される(ステップS108)。これにより、図24(b)に示されるように、第3のブロックのページ#0〜#k−1が有効ページ、ページ#k〜#31が空きページとなる。ステップS108が完了すると、上述したステップS102によりページ#kに対してデータが書き込まれ、これにより、図24(c)に示されるように、第3のブロックのページ#0〜#k(=j+1)が有効ページ、ページ#k+1〜#31が空きページとなる。その後、上述したステップS102におけるデータの書き込み及びステップS103における比較が実行され、その結果に基づいてステップS104またはステップS105、S106が実行される。
【0194】
また、ステップS107による比較の結果、書き込み対象のページ(ページ#k)が第1のスタートページ(ページ#i+1)よりも大きければ、第2のブロック内の第2のスタートページ(ページ#j+1)から第1のスタートページ(ページ#i+1)の1つ前のページ(ページ#i)までのページに格納されたデータが、第3のブロックの同じページに転送される(ステップS109)。これにより、図25(a)に示されるように、第3のブロックのページ#0〜#iが有効ページ、ページ#i+1〜#31が空きページとなる。ステップS109が完了すると、次に、第1のブロック内の第1のスタートページ(ページ#i+1)から書き込み対象のページ(ページ#k)の1つ前のページ(ページ#k−1)までのページに格納されたデータが、第3のブロックの同じページに転送される(ステップS110)。これにより、図25(b)に示されるように、第3のブロックのページ#0〜#k−1が有効ページ、ページ#k〜#31が空きページとなる。このようにして、第2のブロックから第3のブロックへの転送動作(ステップS109)及び第1のブロックから第3のブロックへの転送動作(ステップS110)が完了すると、第3のブロック内の書き込み対象のページ(ページ#k)に対してデータが書き込まれ(ステップS111)、これにより、図25(c)に示されるように、第3のブロックのページ#0〜#k(=j+1)が有効ページ、ページ#k+1〜#31が空きページとなる。
【0195】
このようにしてデータの書き込みが完了すると、次に、書き込み対象のページ(ページ#k)が最終ページ(ページ#31)であるか否かが判断される(ステップS112)。その結果、書き込み対象のページ(ページ#k)が最終ページ(ページ#31)であれば、第1及び第2のブロックをブロック消去して空きブロックとし(ステップS113)、対応する第1のフラグ46を「0」にリセットする(ステップS114)。一方、書き込み対象のページ(ページ#k)が最終ページ(ページ#31)以外であれば、上述したステップS105、S106が実行され、これにより、第3のブロックが新たに第2のブロックとなり、第2のブロックが空きブロックとなる。
【0196】
以上により、第2の追書込動作(ステップS83)が完了する。
【0197】
以上が、本実施態様にかかるフラッシュメモリシステム39によるデータ書き込み動作である。
【0198】
また、第1の部分転送動作(ステップS9)や第2の部分転送動作(ステップS72)が行われることにより、1つの論理ブロックアドレスに対して2つまたは3つの物理ブロックが割り当てられた状態において電源が遮断され、その後、再び電源が投入された場合には、上記実施態様における完結動作と同様の動作により、ブロック間転送が完結される。
【0199】
このように、本実施態様にかかるフラッシュメモリシステム39では、上記実施態様にかかるフラッシュメモリシステム1による効果に加え、1つの論理ブロックアドレスに対して3つの物理ブロックを割り当て可能に構成されているので、追書込動作が選択される可能性がより高められている。これにより、一連のデータ書込動作を、上記実施態様にかかるフラッシュメモリシステム1よりもさらに高速に実行することが可能となる。
【0200】
次に、本発明の好ましいさらに他の実施態様について説明する。
【0201】
本発明の好ましいさらに他の実施態様にかかるフラッシュメモリシステム49の構成は、図1に示されるように上記実施態様にかかるフラッシュメモリシステム1と基本的に同様であり、SRAMワークエリア8に格納されるアドレス変換テーブル27がアドレス変換テーブル57に置き換えられ、消去済みブロックキュー28が消去済みブロックキュー58に置き換えられ、内部変数30が内部変数50に置き換えられている点において異なる。
【0202】
本実施態様にかかるフラッシュメモリシステム49は、「仮想ブロック方式」によるフラッシュメモリシステムである。まず、仮想ブロック方式について説明する。
【0203】
仮想ブロック方式のフラッシュメモリシステムにおいては、各フラッシュメモリチップ2−0〜2−3から一つずつ選ばれた4つの実使用ブロックが仮想的に結合されて「仮想ブロック」を構成する。これにより、仮想ブロック#0〜#7999からなる8000個の仮想ブロックが構成される。
【0204】
図26は、仮想ブロックのマッピングの一例を示す図である。
【0205】
図26に示される例では、フラッシュメモリチップ2−0に含まれる物理ブロック#150、フラッシュメモリチップ2−1に含まれる物理ブロック#6811、フラッシュメモリチップ2−2に含まれる物理ブロック#8191、フラッシュメモリチップ2−3に含まれる物理ブロック#3048が仮想的に結合され、一つの仮想ブロックを構成している。このように、本実施態様においては、ひとつの仮想ブロックを構成する4つの物理ブロックは互いに異なるフラッシュメモリチップに含まれていることが必要である。このようにして、最大8000個の仮想ブロックが構成される。
【0206】
図27は、図26に示された仮想ブロックの仮想ページ構造を示す図である。
【0207】
図27に示されるように、仮想ブロックは、仮想ページ#0〜ページ#127からなる128個の仮想ページによって構成される一つのブロックとして取り扱われる。ここで、仮想ブロックのうち、物理ブロック#150からなる部分に含まれる32個のページは、仮想ページ番号として4i(iは、物理ページ番号)が与えられ、物理ブロック#6811からなる部分に含まれる32個のページは、仮想ページ番号として4i+1が与えられ、物理ブロック#8191からなる部分に含まれる32個のページは、仮想ページ番号として4i+2が与えられ、物理ブロック#3048からなる部分に含まれる32個のページは、仮想ページ番号として4i+3が与えられる。これら仮想ページ番号は、ホストアドレスの下位7ビットと対応している。したがって、これら仮想ページ#0から仮想ページ#127は、連続するホストアドレスによってそれぞれアクセスされることになる。このため、ホストコンピュータ5より連続するホストアドレスに対してデータの書き込みが指示された場合、各ブロックにおいて並列動作を行うことができるので、通常のフラッシュメモリシステムと比べ、一連の書き込み動作をより高速に実行することができる。
【0208】
次に、仮想ブロックとこれを構成する4つの物理ブロックとの関係について説明する。
【0209】
図28は、8000個の仮想ブロックと、これら各仮想ブロックを構成する4つの物理ブロックとの関係を示すアドレス変換テーブル57のデータ構造を示す概略図である。
【0210】
図28に示されるように、アドレス変換テーブル57は、仮想ブロック#0〜#7999からなる8000個の仮想ブロックがこの順に並んで構成され、これら各仮想ブロック#0〜#7999は、それぞれセル#j−0〜セル#j−3(jは、仮想ブロックアドレス)からなる4個のセル及び1個のフラグによって構成される。例えば、仮想ブロック#0はセル#0−0〜セル#0−3とフラグとによって構成され、仮想ブロック#1はセル#1−0〜セル#1−3とフラグとによって構成される。したがって、アドレス変換テーブル57は、32000個のセルと8000個のフラグによって構成されることになる。ここで、セル#j−0を構成するスロット#0はフラッシュメモリチップ2−0に対応し、セル#j−1を構成するスロット#1はフラッシュメモリチップ2−1に対応し、セル#j−2を構成するスロット#2はフラッシュメモリチップ2−2に対応し、セル#j−3を構成するスロット#3はフラッシュメモリチップ2−3に対応している。
【0211】
各仮想ブロックに含まれるセル#j−0〜#j−3には、それぞれ当該仮想ブロックを構成する物理ブロックのアドレス(物理ブロックアドレス)が格納される。
【0212】
また、各仮想ブロックに含まれるフラグは、当該仮想ブロックが有効であるか無効であるかを示している。具体的には、フラグが「1」を示していれば当該仮想ブロックは有効であり、フラグが「0」を示していれば当該仮想ブロックは無効である。したがって、フラグが「0」を示している仮想ブロックについては、これに含まれるセル#j−0〜#j−3に格納されている内容は無視される。
【0213】
アドレス変換テーブル57の生成は、次のように行われる。
【0214】
仮想ブロック方式においては、フラッシュメモリチップ2−0〜2−3を構成する各物理ブロックのうち、データが格納されているブロックの各先頭ページ(物理ページ#0)に含まれる冗長領域26には、当該ブロックがどの仮想ブロックに属するかを示す仮想ブロックアドレスが含まれており、各ブロックの各先頭ページに格納されている仮想ブロックアドレスがマイクロプロセッサ6による制御のもと、フラッシュメモリインターフェースブロック10を介して読み出される。
【0215】
そして、各物理ブロックの先頭ページ(物理ページ#0)の冗長領域26に含まれる仮想ブロックアドレスがオール1ではなく、有効な仮想ブロックのアドレスを示していれば、アドレス変換テーブル57を構成するセルのうち、チップ番号及び読み出された仮想ブロックアドレスによって特定されるセルに、当該物理ブロックの物理ブロックアドレスを格納する。例えば、フラッシュメモリチップ2−0に属する物理ブロック#12より、読み出された仮想ブロックアドレスが「123」であれば、セル#123−0に、物理ブロックアドレスとして「12」が書き込まれる。
【0216】
このような処理が、データが格納されている全ての物理ブロックについて行われる。これにより、アドレス変換テーブル57の生成が完了する。
【0217】
次に、SRAMワークエリア8に格納される消去済みブロックキュー58のデータ構造について説明する。
【0218】
図29は、SRAMワークエリア8に格納される消去済みブロックキュー58のデータ構造を示す概略図である。
【0219】
図29に示されるように、消去済みブロックキュー58は、キューセット#0〜#5からなる6つのキューセットによって構成され、これらは、それぞれキュー#k−0〜キュー#k−3(kは、キューセット番号)からなる4個のキューによって構成される。例えば、キューセット#0はキュー#0−0〜キュー#0−3によって構成され、キューセット#1はキュー#1−0〜キュー#1−3によって構成される。したがって、消去済みブロックキュー30は、24個のキューによって構成される。ここで、キュー#k−0はフラッシュメモリチップ2−0に対応し、キュー#k−1はフラッシュメモリチップ2−1に対応し、キュー#k−2はフラッシュメモリチップ2−2に対応し、キュー#k−3はフラッシュメモリチップ2−3に対応している。
【0220】
各キューセット#0〜#5を構成するキュー#k−0〜#k−3には、ユーザ領域25を構成する全てのフラッシュメモリセル16が消去状態となっている物理ブロックの物理ブロックアドレスが格納される。したがって、例えば、フラッシュメモリチップ2−0に属する消去済みの物理ブロック#153を消去済みブロックキュー58に登録する場合、当該物理ブロックアドレスである「0000010011001B」がキュー#0−0〜#5−0のいずれかに格納される。同様にして、例えば、フラッシュメモリチップ2−2に属する消去済みのブロック#6552を消去済みブロックキュー30に登録する場合、当該物理ブロックアドレスである「1100110011000B」がキュー#0−2〜#5−2のいずれかに格納される。
【0221】
このようにして、各フラッシュメモリチップ2−0〜2−3ごとに最大6つの消去済みブロックの物理ブロックアドレスが消去済みブロックキュー58に登録され、これによって最大6つのキューセット#0〜#5が生成される。
【0222】
消去済みブロックキュー58の生成は、マイクロプロセッサ6による制御のもと、上述したアドレス変換テーブル57の生成の際に行われ、データ書き込みに備えて待機している冗長ブロックの中から、これらキューに登録すべき物理ブロックが選ばれる。
【0223】
次に、SRAMワークエリア8に格納される内部変数50のデータ構造について説明する。
【0224】
内部変数50は、図7に示した内部変数30と同じデータ構造を有している。内部変数50を構成する変数#0〜#3は、それぞれ仮想ブロックのスロット#0〜#3に対応する。
【0225】
次に、本実施態様にかかるフラッシュメモリシステム49によるデータの書き込み動作について説明する。
【0226】
まず、既にデータが格納されている使用済みの仮想ブロックのある仮想ページに対して、ホストコンピュータ5よりデータの書き込みが指示された場合、上述した部分転送動作(ステップS9)と基本的に同じ動作によって、当該仮想ブロックを構成する4つの物理ブロックのうち、対応する物理ブロックのみに対して部分転送が行われる。
【0227】
図30は、仮想ブロック#nの仮想ページ4i+1に対してホストコンピュータ5よりデータの書き込みが指示された場合における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【0228】
仮想ページ4i+1は、仮想ブロック#nを構成する4つの物理ブロックのうち、スロット#1に属する物理ブロックの物理ページ#iに対応する。したがって、仮想ページ4i+1に対してホストコンピュータ5よりデータの書き込みが指示された場合、まず、マイクロプロセッサ6による制御のもと、消去済みブロックキュー58を構成するキューセット#0〜#7のうち所定のキューセットのスロット#1が選択され、格納されている物理ブロックアドレスが読み出される(ステップS21)。
【0229】
消去済みブロックの物理ブロックアドレスが読み出されると、これに基づいて内部変数50が更新される(ステップS22)。ここで、内部変数50の更新においては、まずスロット番号に基づいて変数#1が選択され、選択された変数を構成する転送先ブロックアドレス格納領域31に消去済みブロックキュー58より読み出された物理ブロックアドレスが格納され、転送元ブロックアドレス格納領域32にアドレス変換テーブル57より読み出された物理ブロックアドレスが格納され、スタートページ格納領域33に書き込み対象の物理ページ(ページ#i)の次のページのページ番号(ページ#i+1)が格納される。また、フラグ34が「1」にセットされる。
【0230】
内部変数50の更新が完了すると、次に、アドレス変換テーブル57の更新が行われる(ステップS23)。アドレス変換テーブル57の更新においては、対応するセル#n−1に、消去済みブロックキュー58より読み出された物理ブロックアドレスが上書きされる。
【0231】
次に、転送元ブロック内の物理ページ#0から書き込み対象の物理ページ(ページ#i)の1つ前のページ(ページ#i−1)までのページに格納されたデータが、転送先ブロックの同じページに転送される(ステップS24)。すなわち、ブロック間転送の前半部分の動作が行われる。ステップS24が完了すると、図30(a)に示されるように、転送先ブロックのページ#0〜#i−1が有効ページとなり、ページ#i〜#31が空きページとなる。
【0232】
ステップS24が完了すると、次に、ホストコンピュータ5より書き込みが指示されたデータが、転送先ブロックの書き込み対象の物理ページ(ページ#i)に書き込まれる(ステップS25)。ステップS25が完了すると、図30(b)に示されるように、転送先ブロックの物理ページ#0〜#iが有効ページとなり、物理ページ#i+1〜#31が空きページとなる。
【0233】
以上により、部分転送動作(ステップS9)が完了する。
【0234】
このような部分転送が行われた後、仮想ブロック#nの仮想ページ4j+1(j>i)に対してホストコンピュータ5よりデータの書き込みが指示された場合、上述した追書込動作(ステップS39)と同じ動作が行われ、これにより、一連のデータ書き込み動作が高速に実行される。
【0235】
また、部分転送動作(ステップS9)が行われることにより、1つのセルに対して2つの物理ブロックが割り当てられた状態において電源が遮断され、その後、再び電源が投入された場合には、上記実施態様における完結動作と同様の動作により、ブロック間転送が完結される。
【0236】
このように、本発明は、仮想ブロック方式のフラッシュメモリシステム49に対しても適用することができる。
【0237】
本発明は、以上の実施態様に限定されることなく、特許請求の範囲に記載された発明の範囲内で種々の変更が可能であり、それらも本発明の範囲内に包含されるものであることはいうまでもない。
【0238】
例えば、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、内部変数30、40、50がフラッシュメモリチップ2−0〜2−3にそれぞれ対応する変数#0〜#3からなり、これによって、各フラッシュメモリチップにおいて転送先ブロックと転送元ブロックからなる組を1つずつ記録できるように構成されているが、転送先ブロックと転送元ブロックからなる組が各フラッシュメモリチップにおいて1つに限定されることはなく、2以上の組を記録できるように構成しても構わない。
【0239】
また、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、起動時において、同じ対応論理ブロックアドレスを有する2つの物理ブロックが発見された場合、ステップS51〜ステップS55からなる完結動作を実行することによってブロック間転送を完結させているが、本発明においてかかる完結動作を行うことは必須ではなく、これら2つのブロックの物理ブロックアドレス及び転送先ブロックのスタートページを用いて、内部変数30、40、50の内容を電源が遮断される直前の状態に再現しても構わない。
【0240】
また、上記実施態様にかかるフラッシュメモリシステム1、49においては、1つの論理ブロックアドレス(セル)に対して2つの物理ブロックを割り当て可能に構成され、上記実施態様にかかるフラッシュメモリシステム39においては、1つの論理ブロックアドレスに対して3つの物理ブロックを割り当て可能に構成されているが、1つの論理ブロックアドレスに対して4以上の物理ブロックを割り当て可能に構成しても構わない。
【0241】
また、上記実施態様にかかるフラッシュメモリシステム49においては、各フラッシュメモリチップ2−0〜2−3より一つずつ選ばれた物理ブロックによって仮想ブロックを構成しているが、独立したレジスタを有する複数のバンクに分割された「バンクタイプ」と呼ばれるフラッシュメモリチップを用い、それぞれ異なるバンクに属する複数のブロックによって仮想ブロックを構成しても構わない。「バンクタイプ」のフラッシュメモリチップ用いれば、1つのフラッシュメモリチップによって仮想ブロックを構成することができる。
【0242】
また、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、各ブロックを32個のページによって構成しているが、各ブロックを構成するページ数は32個には限定されず、他の数、例えば、16個や64個であってもよい。本発明は、各ブロックを構成するページ数が多いほど、より顕著な効果を得ることができる。
【0243】
また、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、空きブロックに対してデータの書き込みを行う場合、ユーザデータを書き込むべきページとは無関係に当該ブロックの全てのページ#0〜#31の冗長領域26に、対応論理ブロックアドレスを格納しているが、全てのページ#0〜#31の冗長領域26に対応論理ブロックアドレスを格納することは必須ではなく、少なくとも、先頭ページ(ページ#0)及び最終ページ(ページ#31)の冗長領域26にこれを書き込めば足りる。
【0244】
さらに、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、データの格納された全ての物理ブロックに関わるアドレス変換テーブル27、57をSRAMワークエリア8上に展開しているが、本発明において、これら全ての物理ブロックに関わるアドレス変換テーブルを展開することは必須ではなく、これらの一部のみを展開してもよい。この場合、SRAMワークエリア8に必要とされる記憶容量を削減することができる。但し、このように一部の物理ブロックに関わるアドレス変換テーブルのみを展開する場合、アドレス変換テーブルに含まれていない物理ブロックへのアクセスが要求される度に、アドレス変換テーブルを更新する必要がある。
【0245】
また、上記実施態様においては、フラッシュメモリシステム1、39、49はカード形状であり、4個のフラッシュメモリチップ2−0〜2−3とコントローラ3とが、一つのカード内に集積されて構成されているが、本発明にかかるフラッシュメモリシステムがカード形状に限定されることはなく、他の形状、例えばスティック状であってもよい。
【0246】
さらに、上記実施態様においては、フラッシュメモリシステム1、39、49は、4個のフラッシュメモリチップ2−0〜2−3とコントローラ3とが、一つのカード内に集積されて構成されているが、フラッシュメモリチップ2−0〜2−3とコントローラ3とが、同一筐体に集積されている必要はなく、それぞれ別個の筐体にパッケージングされてもよい。この場合、フラッシュメモリチップ2−0〜2−3がパッケージングされた筐体及びコントローラ3がパッケージングされた筐体には、それぞれ他方との電気的及び機械的接続を実現するためのコネクタが必要とされ、かかるコネクタによって、フラッシュメモリチップ2−0〜2−3がパッケージングされた筐体が、コントローラ3がパッケージングされた筐体に着脱可能に装着される。さらに、フラッシュメモリチップ2−0〜2−3についても、これらが同一筐体に集積されている必要はなく、それぞれ別個の筐体にパッケージングされてもよい。
【0247】
また、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、各フラッシュメモリチップ2−0〜2−3は、それぞれ128Mバイト(1Gビット)の記憶容量を有する半導体チップであるが、各フラッシュメモリチップ2−0〜2−3の記憶容量は128Mバイト(1Gビット)に限定されず、これとは異なる容量、例えば32Mバイト(256Mビット)であってもよい。
【0248】
さらに、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、512バイトを1ページとし、これを最小アクセス単位としているが、最小アクセス単位としては512バイトに限定されず、これとは異なる容量であってもよい。
【0249】
また、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、フラッシュメモリチップ2−0〜2−3を構成する各フラッシュメモリセル16が、1ビットのデータを保持しているが、フローティングゲート電極21に注入すべき電子の量を複数段階に制御することによって、2ビット以上のデータを保持可能に構成してもよい。
【0250】
また、上記実施態様にかかるフラッシュメモリシステム1、39においては、フラッシュメモリチップ2−0〜2−3に対してそれぞれ2個のキューを割り当てることによって、消去済みブロックキュー30が構成されているが、各フラッシュメモリチップ2−0〜2−3に対して割り当てられるキューの数としては2個に限定されず、他の数、例えば、1個や8個であってもよい。
【0251】
さらに、上記実施態様にかかるフラッシュメモリシステム1、39、49においては、フラッシュメモリチップ2としてNAND型のフラッシュメモリチップを用いているが、本発明により制御可能なフラッシュメモリがNAND型に限定されるものではなく、他の種類、例えば、AND型のフラッシュメモリを制御することも可能である。
【0252】
また、本発明において、手段とは、必ずしも物理的手段を意味するものではなく、各手段の機能がソフトウエアによって実現される場合も包含する。さらに、一つの手段の機能が二以上の物理的手段により実現されても、二以上の手段の機能が一つの物理的手段により実現されてもよい。
【0253】
尚、本発明は、PCMCIA(Personal Computer Memory Card International Association)が発表した統一規格に基づくPCカードとして実現することが可能である。さらに、近年、半導体素子の高集積化技術の発展に伴い、より小型化された小型メモリカード、例えば、CFA(CompactFlash Association)が提唱する「CompactFlash」や、MultiMediaCardAssociationの提唱する「MMC(MultiMediaCard)」、ソニー株式会社が提唱する「メモリースティック」、松下電器産業株式会社等が提唱する「SDメモリーカード」などに本発明を適用することが可能である。
【0254】
【発明の効果】
以上説明したように、本発明によれば、ホストコンピュータからデータの書き込みを要求された場合に、当該データを書き込むべきブロックにすでに何らかのデータが格納されている場合であっても、与えられたデータの書き込みに必要な一連の処理をより高速に行うことができるメモリコントローラ及びこのようなメモリコントローラを備えるフラッシュメモリシステムが提供される。
【0255】
また、本発明によれば、ホストコンピュータからデータの書き込みを要求された場合に、当該データを書き込むべきブロックにすでに何らかのデータが格納されている場合であっても、与えられたデータの書き込みに必要な一連の処理をより高速に行うことができるフラッシュメモリの制御方法が提供される。
【図面の簡単な説明】
【図1】本発明の好ましい実施態様にかかるフラッシュメモリシステム1を概略的に示すブロック図である。
【図2】フラッシュメモリチップ2−0〜2−3を構成する各フラッシュメモリセル16の構造を概略的に示す断面図である。
【図3】書込状態であるフラッシュメモリセル16を概略的に示す断面図である。
【図4】フラッシュメモリチップ2−0のアドレス空間の構造を概略的に示す図である。
【図5】SRAMワークエリア8に格納されるアドレス変換テーブル27のデータ構造を示す概略図である。
【図6】SRAMワークエリア8に格納される消去済みブロックキュー28のデータ構造を示す概略図である。
【図7】SRAMワークエリア8に格納される内部変数30のデータ構造を示す概略図である。
【図8】書込動作の種類を決定するためのフローチャートである。
【図9】新規書込動作を示すフローチャートである。
【図10】部分転送動作を示すフローチャートである。
【図11】部分転送動作における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【図12】追書込判定を示すフローチャートである。
【図13】ステップS34における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【図14】追書込動作を示すフローチャートである。
【図15】追書込動作における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【図16】完結動作を示すフローチャートである。
【図17】完結動作における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【図18】SRAMワークエリア8に格納される内部変数40のデータ構造を示す概略図である。
【図19】追書込判定を示すフローチャートである。
【図20】第2の部分転送動作を示すフローチャートである。
【図21】第2の部分転送動作における第1〜第3のブロックのデータ格納状態を示す概略図である。
【図22】ステップS75〜ステップS77における第1〜第3のブロックのデータ格納状態を示す概略図である。
【図23】第2の追書込動作を示すフローチャートである。
【図24】第2の追書込動作における第1〜第3のブロックのデータ格納状態を示す概略図である。
【図25】第2の追書込動作における第1〜第3のブロックのデータ格納状態を示す概略図である。
【図26】仮想ブロックのマッピングの一例を示す図である。
【図27】図26に示された仮想ブロックの仮想ページ構造を示す図である。
【図28】アドレス変換テーブル57のデータ構造を示す概略図である。
【図29】SRAMワークエリア8に格納される消去済みブロックキュー58のデータ構造を示す概略図である。
【図30】仮想ブロック#nの仮想ページ4i+1に対してホストコンピュータ5よりデータの書き込みが指示された場合における転送元ブロック及び転送先ブロックのデータ格納状態を示す概略図である。
【符号の説明】
1 フラッシュメモリシステム
2−0〜2−3 フラッシュメモリチップ
3 コントローラ
4 コネクタ
5 ホストコンピュータ
6 マイクロプロセッサ
7 ホストインターフェースブロック
8 SRAMワークエリア
9 バッファ
10 フラッシュメモリインターフェースブロック
11 ECCブロック
12 フラッシュシーケンサブロック
13〜15 バス
16 フラッシュメモリセル
17 P型半導体基板
18 ソース拡散領域
19 ドレイン拡散領域
20 トンネル酸化膜
21 フローティングゲート電極
22 絶縁膜
23 コントロールゲート電極
24 チャネル
25 ユーザ領域
26 冗長領域
27 アドレス変換テーブル
28 消去済みブロックキュー
30 内部変数
31 転送先ブロックアドレス格納領域
32 転送元ブロックアドレス格納領域
33 スタートページ格納領域
34 フラグ
39 フラッシュメモリシステム
40 内部変数
41 第1のブロックアドレス格納領域
42 第2のブロックアドレス格納領域
43 第3のブロックアドレス格納領域
44 第2のスタートページ格納領域
45 第1のスタートページ格納領域
46 第1のフラグ
47 第2のフラグ
49 フラッシュメモリシステム
50 内部変数
57 アドレス変換テーブル
58 消去済みブロックキュー
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a memory controller, a flash memory system, and a flash memory control method, and more particularly, to a memory controller, a flash memory system, and a flash memory control method capable of performing a series of data write processing on the flash memory at higher speed.
[0002]
[Prior art]
In recent years, flash memories, particularly NAND flash memories, are often used as semiconductor memories used for memory cards, silicon disks, and the like. In the NAND flash memory, when a memory cell is changed from an erased state (logical value = 1) to a written state (logical value = 0), this can be performed in units of memory cells. When changing from the written state (0) to the erased state (1), this cannot be performed in units of memory cells, and can be performed only in predetermined erase units composed of a plurality of memory cells. Such a batch erase operation is generally called “block erase”.
[0003]
As described above, in the flash memory, the memory cell can be changed from the written state to the erased state only in units of blocks. Therefore, in order to write new data to a block in which data has already been written, A process is required in which all memory cells included in the block are erased, and then new data is written. Therefore, when writing new data to a block that already contains data, to prevent the data already stored in this block from being lost, move the data contained in this block to another erased block. It is necessary to let
[0004]
Therefore, when the host computer instructs to write new data to a block in which data is already stored, the new data and data already stored in this block are written into the erased block. Such processing is called “inter-block transfer”. Thereafter, all the memory cells included in the transfer source block are erased, so that the transfer source block becomes a new erased block.
[0005]
As described above, in the conventional flash memory system, it is necessary to execute inter-block transfer every time the host computer requests to write new data to a block in which data is already stored.
[0006]
[Problems to be solved by the invention]
However, there is a problem that a long time is required for a series of transfer processing between blocks.
[0007]
That is, in the inter-block transfer process, the memory controller needs to read the data stored in the transfer source block and write the data to the transfer destination block one page at a time. In order to transfer all the data stored in the page to the transfer destination block, a time substantially proportional to the number of pages constituting one block is required.
[0008]
Therefore, even if the data requested to be written by the host computer is data for one page, if some data has already been stored in the block where the data is to be written, a large amount of data is required until the series of processing is completed. Time was needed.
[0009]
For this reason, there is a demand for a memory controller, a flash memory system, and a flash memory control method capable of performing a series of processes necessary for writing the data at a higher speed when the host computer requests data writing. It was.
[0010]
Therefore, an object of the present invention is necessary for writing given data even when some data is already stored in a block to which the data is written when the host computer requests data writing. A memory controller capable of performing a series of processes at a higher speed and a flash memory system including such a memory controller are provided.
[0011]
Another object of the present invention is to write the given data even when some data is already stored in the block to which the data is written when the host computer requests the data writing. It is an object to provide a flash memory control method capable of performing a series of processes necessary for the above at a higher speed.
[0012]
[Means for Solving the Problems]
An object of the present invention is a memory controller that accesses a memory composed of a plurality of blocks, and instructs to write new data to a logical address corresponding to a first block in which data is already stored. In response to this, a first means for transferring a part of the data stored in the first block to the same page of the second block, and writing the new data in the second block The second means, the third means for maintaining the correspondence between the first block and the second block, and a new instruction to write additional data to the logical address. In response to, a fourth means for determining whether or not the additional data can be additionally written to the second block, and a determination that the fourth means is additionally writable In response to this, fifth means for transferring a part of the data stored in the first block to the same page of the second block and writing the additional data to the second block And in response to determining that the fourth means is additionally not writable, all empty pages in the second block are stored in the same page of the first block. And a seventh means for erasing the first block in response to data being written to all pages of the second block. This is achieved by a memory controller characterized by:
[0013]
In a preferred embodiment of the present invention, the first means stores the data stored in the page immediately preceding the page corresponding to the page in which the new data is to be stored from the first page of the first block. Configured to transfer to the same page of the second block This ing.
[0014]
In a further preferred aspect of the present invention, the third means further holds information relating to the empty page of the second block, and the fourth means performs the additional writing based on the information relating to the empty page. It is configured to determine whether or not data can be additionally written to the second block.
[0015]
In a further preferred aspect of the present invention, the empty pages in the second block are continuous from the next page to the last page where the new data is written by the second means.
[0016]
In a further preferred aspect of the present invention, when the page to store the additional data in the second block is not the empty page, the sixth means adds the empty page in the second block to the empty page. Transferring data stored in the same page of the first block, after which the seventh means is arranged to erase all the data stored in the first block .
[0017]
In a further preferred aspect of the present invention, the memory controller further includes the data stored in the second block when the page in which the additional data in the second block is to be stored is not the empty page. An eighth means for transferring a part to the same page of the third block; and a ninth means for writing the additional data to the third block, wherein the third means further comprises the second The correspondence between the block and the third block is maintained.
[0018]
In a further preferred aspect of the present invention, the third means further holds information relating to an empty page of the third block.
[0019]
In a further preferred aspect of the present invention, the memory controller further comprises tenth means for determining whether or not the page to which the additional data is written is the first page of the empty page group in the second block. In response to determining that the tenth means is not the first page, the fifth means is one of the write destinations of the additional data from the first page of the empty page group. Data stored in the same page of the first block is transferred to each page corresponding to the previous page.
[0020]
The object of the present invention is also a memory controller for accessing a memory composed of a plurality of blocks, the means for classifying the blocks into a plurality of groups,
A means for forming a virtual block by virtually combining a plurality of blocks belonging to different groups, and responding to a new data write instruction for a predetermined block constituting the virtual block Means for transferring a part of the data stored in the predetermined block to another block, means for writing the new data newly instructed to write to the other block, and the predetermined block. Means for maintaining the correspondence relationship between the new block and the other block, additional data is given after the new data, and the writing of the additional data is instructed to the logical address corresponding to the predetermined block. In response, the means for determining whether the additional data can be additionally written to the other block, and the other In response to determining that the additional data can be additionally written to a block, a part of the data stored in the predetermined block is transferred to the same page of the other block, and In response to the means for writing the additional write data in the other block, and in response to determining that the additional write data cannot be additionally written to the other block, all the empty pages in the other block Means for transferring data stored in the same page of the predetermined block; means for erasing the predetermined block in response to data being written to all pages of the other block; This is achieved by a memory controller characterized by comprising:
[0021]
The object of the present invention is also achieved by a flash memory system comprising any one of the memory controllers and a flash memory composed of a plurality of blocks.
[0022]
In a preferred embodiment of the present invention, the flash memory system is housed in the same housing.
[0023]
In a further preferred embodiment of the present invention, the housing has a card shape.
[0024]
In a preferred embodiment of the present invention, the third means further holds information relating to a free page of the second block.
[0025]
The object of the present invention is to provide a block corresponding to the predetermined logical address in the address conversion table as a first block in response to an instruction to newly write new data to the predetermined logical address. Changing from the first block to the second block, creating a variable indicating the correspondence between the first block and the second block, and converting a part of the data stored in the first block to the second block In response to the instruction to write new additional data to the predetermined logical address, the step of transferring to the second block; the step of writing the new data to the second block; Determining whether or not the additional data can be additionally written to the second block; and determining that the additional data can be additionally written. In response, a part of the data stored in the first block is transferred to the same page of the second block, and the additional data is written to the second block; Responsive to determining that the data cannot be additionally written, transferring the data stored on the same page of the first block to all free pages in the second block; And a step of erasing the block of the first block in response to data being written to all pages of the second block.
[0038]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, preferred embodiments of the present invention will be described in detail with reference to the accompanying drawings.
[0039]
FIG. 1 is a block diagram schematically showing a flash memory system 1 according to a preferred embodiment of the present invention.
[0040]
The flash memory system 1 has a card shape, and as shown in FIG. 1, four flash memory chips 2-0 to 2-3, a controller 3, and a connector 4 are integrated in one card. Composed. The flash memory system 1 is used by being detachably attached to the host computer 5 and used as a kind of external storage device for the host computer 5. Examples of the host computer 5 include various information processing apparatuses such as a personal computer and a digital still camera that process various information such as characters, sounds, and image information.
[0041]
Each of the flash memory chips 2-0 to 2-3 is a semiconductor chip having a storage capacity of 128 Mbytes (1 Gbit). In the flash memory system 1, 512 bytes are used as one page, and this is the minimum access unit. Accordingly, each of these flash memory chips 2-0 to 2-3 includes an address space of 256K pages, and the flash memory chips 2-0 to 2-3 have a total of 1M pages of address space. In the flash memory system 1, these four flash memory chips 2-0 to 2-3 have a storage capacity of 512M bytes (4G bits) and are handled as one large memory having an address space of 1M pages. It is. Therefore, in order to access a specific page from the address space consisting of these 1M pages, 20-bit address information is required. Therefore, the host computer 5 accesses a specific page by supplying 20-bit address information to the flash memory system 1. Hereinafter, the 20-bit address information supplied from the host computer 5 to the flash memory system 1 is referred to as a “host address”.
[0042]
The controller 3 includes a microprocessor 6, a host interface block 7, an SRAM work area 8, a buffer 9, a flash memory interface block 10, an ECC (error collection code) block 11, and a flash sequencer block 12. Composed. The controller 3 constituted by these functional blocks is integrated on one semiconductor chip.
[0043]
The microprocessor 6 is a functional block for controlling the operation of the entire functional blocks constituting the controller 3.
[0044]
The host interface block 7 is connected to the connector 4 via the bus 13 and exchanges data, address information, status information, and external command information with the host computer 5 under the control of the microprocessor 6. That is, when the flash memory system 1 is attached to the host computer 5, the flash memory system 1 and the host computer 5 are connected to each other via the bus 13, the connector 4, and the bus 14, and in this state, the host computer 5 The data supplied to the flash memory system 1 is taken into the controller 3 through the host interface block 7 as an entrance, and the data etc. supplied from the controller 3 to the host computer 5 exits the host interface block 7. To the host computer 5. The host interface block 7 further includes a task file register (not shown) for temporarily storing a host address and an external command supplied from the host computer 5 and an error register (not shown) that is set when an error occurs. Z).
[0045]
The SRAM work area 8 is a work area in which data necessary for controlling the flash memory chips 2-0 to 2-3 by the microprocessor 6 is temporarily stored, and includes a plurality of SRAM cells.
[0046]
The buffer 9 is a buffer for temporarily storing data read from the flash memory chips 2-0 to 2-3 and data to be written to the flash memory chips 2-0 to 2-3. That is, data read from the flash memory chips 2-0 to 2-3 is held in the buffer 9 until the host computer 5 can receive the data, and should be written to the flash memory chips 2-0 to 2-3. The data is held in the buffer 9 until the flash memory chips 2-0 to 2-3 are writable and an error correction code is generated by the ECC block 11 described later.
[0047]
The flash memory interface block 10 exchanges data, address information, status information, and internal command information with the flash memory chips 2-0 to 2-3 via the bus 15, and each flash memory chip 2-0. This is a functional block for supplying corresponding chip selection signals # 0 to # 3 to 2-3. The chip selection signals # 0 to # 3 are based on the upper 2 bits of the internal address generated based on the host address supplied from the host computer 5 when data reading or writing is requested from the host computer 5. One of them is a signal to be activated. Specifically, if the upper 2 bits of the internal address are “00”, the chip selection signal # 0 is activated, if it is “01”, the chip selection signal # 1 is activated, and if it is “10”. The chip selection signal # 2 is activated, and if it is “11”, the chip selection signal # 3 is activated. The flash memory chips 2-0 to 2-3 in which the corresponding chip selection signal is activated are in a selected state, and data can be read or written. The “internal command” is a command for the controller 3 to control the flash memory chips 2-0 to 2-3, and is distinguished from an “external command” for the host computer 5 to control the flash memory system 1. Is done.
[0048]
The ECC block 11 generates an error correction code to be added to the data to be written to the flash memory chips 2-0 to 2-3, and based on the error correction code added to the read data, the error included in the read data is corrected. This is a functional block for correction.
[0049]
The flash sequencer block 12 is a functional block for controlling data transfer between the flash memory chips 2-0 to 2-3 and the buffer 9. The flash sequencer block 12 includes a plurality of registers (not shown), and reads data from the flash memory chips 2-0 to 2-3 or flash memory chips 2-0 to 2 under the control of the microprocessor 6. When values necessary for writing data to -3 are set in these registers, a series of operations necessary for reading or writing data is automatically executed.
[0050]
Next, a specific structure of each flash memory cell constituting each flash memory chip 2-0 to 2-3 will be described.
[0051]
FIG. 2 is a cross-sectional view schematically showing the structure of each flash memory cell 16 constituting the flash memory chips 2-0 to 2-3.
[0052]
As shown in FIG. 2, the flash memory cell 16 includes an N-type source diffusion region 18 and a drain diffusion region 19 formed in the P-type semiconductor substrate 17, and between the source diffusion region 18 and the drain diffusion region 19. Tunnel oxide film 20 formed so as to cover P-type semiconductor substrate 17, floating gate electrode 21 formed on tunnel oxide film 20, insulating film 22 formed on floating gate electrode 21, and insulating film 22 And a control gate electrode 23 formed on the substrate. A plurality of flash memory cells 16 having such a configuration are connected in series in the flash memory chips 2-0 to 2-3 to form a NAND flash memory.
[0053]
The flash memory cell 16 is in either “erased state” or “written state” depending on whether electrons are injected into the floating gate electrode 21. The fact that the flash memory cell 16 is in the erased state means that the data “1” is held in the flash memory cell 16, and the fact that the flash memory cell 16 is in the written state means that the flash memory cell 16 This means that data “0” is held in. That is, the flash memory cell 16 can hold 1-bit data.
[0054]
As shown in FIG. 2, the erased state refers to a state where electrons are not injected into the floating gate electrode 21. The flash memory cell 16 in the erased state is a depletion type transistor, and a P-type semiconductor substrate between the source diffusion region 18 and the drain diffusion region 19 regardless of whether or not a read voltage is applied to the control gate electrode 23. A channel 24 is formed on the surface 17. Therefore, the source diffusion region 18 and the drain diffusion region 19 are always electrically connected by the channel 24 regardless of whether or not the read voltage is applied to the control gate electrode 23.
[0055]
FIG. 3 is a cross-sectional view schematically showing the flash memory cell 16 in the written state.
[0056]
As shown in FIG. 3, the writing state refers to a state in which electrons are accumulated in the floating gate electrode 21. Since the floating gate electrode 21 is sandwiched between the tunnel oxide film 20 and the insulating film 22, the electrons once injected into the floating gate electrode 21 stay in the floating gate electrode 21 for a very long time. The flash memory cell 16 in the write state is an enhancement type transistor, and when the read voltage is not applied to the control gate electrode 23, the surface of the P-type semiconductor substrate 17 between the source diffusion region 18 and the drain diffusion region 19 is used. When a read voltage is applied to the control gate electrode 23, a channel (not shown) is formed on the surface of the P-type semiconductor substrate 17 between the source diffusion region 18 and the drain diffusion region 19. It is formed. Therefore, the source diffusion region 18 and the drain diffusion region 19 are electrically insulated when the read voltage is not applied to the control gate electrode 23, and the source diffusion region when the read voltage is applied to the control gate electrode 23. The region 18 and the drain diffusion region 19 are electrically connected.
[0057]
Here, whether the selected flash memory cell 16 is in the erased state or in the written state can be read as follows. That is, a read voltage is applied to the control gate electrodes 23 of all the flash memory cells 16 other than the selected flash memory cell 16 among a plurality of flash memory cells 16 connected in series. It is detected whether or not a current flows through the series body of cells 16. As a result, if a current flows through the series body, it is determined that the selected flash memory cell 16 is in an erased state. If no current flows through the series body, the selected flash memory cell 16 is in a writing state. It is judged that. In this way, it is possible to read out whether the data held in any flash memory cell 16 included in the serial body is “0” or “1”. However, in the NAND flash memory, data held in two or more flash memory cells 16 included in one serial body cannot be read simultaneously.
[0058]
When the flash memory cell 16 that is in the erased state is changed to the written state, a positive high voltage is applied to the control gate electrode 23, whereby electrons are injected into the floating gate electrode 21 through the tunnel oxide film 20. Is done. Electrons can be injected into the floating gate electrode 21 using an FN tunnel current. On the other hand, when the flash memory cell 16 that is in the written state is changed to the erased state, a negative high voltage is applied to the control gate electrode 23, and as a result, it is accumulated in the floating gate electrode 21 through the tunnel oxide film 20. Electrons are discharged.
[0059]
Next, a specific configuration of the address space of each flash memory chip 2-0 to 2-3 will be described.
[0060]
FIG. 4 is a diagram schematically showing the structure of the address space of the flash memory chip 2-0.
[0061]
As shown in FIG. 4, the address space of the flash memory chip 2-0 is configured by 8192 blocks including blocks # 0 to # 8191. Although not shown in FIG. 4, the flash memory chips 2-1 to 2-3 are also configured by 8192 blocks including blocks # 0 to # 8191 as in the flash memory chip 2-0. . Each of these blocks has a storage capacity of 16 Kbytes.
[0062]
Here, each block is a data erasing unit. That is, in the flash memory chips 2-0 to 2-3, the state of each flash memory cell 16 cannot be changed from the written state to the erased state, and the flash memory cell 16 is changed from the written state to the erased state. In the case of changing to, all flash memory cells 16 included in the block to which the flash memory cell 16 belongs are collectively erased. On the contrary, in the flash memory chips 2-0 to 2-3, the state of each flash memory cell 16 can be changed from the erased state to the written state.
[0063]
Further, as shown in FIG. 4, each block # 0 to # 8191 constituting the flash memory chip 2-0 includes 32 pages each including pages # 0 to # 31. Also, the blocks # 0 to # 8191 constituting the flash memory chips 2-1 to 2-3 are each composed of 32 pages, as are the blocks # 0 to # 8191 constituting the flash memory chip 2-0. It is configured.
[0064]
Each of these pages is an access unit for reading and writing data. As shown in FIG. 4, 8 bits consisting of bits b0 to b7 are defined as 1 byte, and a user area 25 of 512 bytes and a redundant area 26 of 16 bytes, respectively. Consists of. The user area 25 is an area in which user data supplied from the host computer 5 is stored, and the redundant area 26 has an error correction code for the user data stored in the corresponding user area 25 and a corresponding logical block address. This is the area to be stored. The corresponding logical block address is information indicating by which logical block address the block is accessed, and details thereof will be described later.
[0065]
Thus, each page is composed of a 512-byte user area 25 and a 16-byte redundant area 26, so that each page is composed of 8 × (512 bytes + 16 bytes) = 4224 flash memory cells. Become.
[0066]
As described above, each of the flash memory chips 2-0 to 2-3 is configured by 8192 physical blocks. Of these, 8000 physical blocks are blocks that can actually store data (hereinafter, “ The remaining 192 blocks are treated as “redundant blocks”. The redundant block is an empty block waiting for data writing. The address space of the flash memory chips 2-0 to 2-3 is composed only of actual use blocks. When a defect occurs in a physical block and becomes unusable, the number of physical blocks allocated as redundant blocks is reduced by the number of blocks in which the defect has occurred.
[0067]
Since the flash memory chips 2-0 to 2-3 having such a configuration are handled as one large memory having an address space of 1M pages as described above, the address space consisting of these 1M pages is changed to a specific page. To access, a 20-bit host address is used as described above. Of the 20-bit host address, the upper 15 bits are used to specify the flash memory chip and the block included in the specified flash memory chip, and the remaining 5 bits (lower 5 bits) are the specified block. Used to specify the pages included in the.
[0068]
The flash memory chip and block using the upper 15 bits of the host address are identified by dividing the upper 15 bits of the host address by “8000” and accessed by the quotient (0 to 3) obtained by the division. The flash memory chip to be determined is determined, and the “logical block address” is determined by the remainder (0 to 7999). Such a logical block address is converted into a “physical block address” in an “address conversion table” to be described later, whereby a block to be actually accessed is specified.
[0069]
Here, the necessity of converting a logical block address into a physical block address using an address conversion table will be described.
[0070]
As described above, the flash memory cells 16 constituting the flash memory chips 2-0 to 2-3 can be changed from the erased state to the written state in units of memory cells. Changing to the erased state cannot be performed in units of memory cells, but can be performed only in units of blocks. For this reason, when data is written to a certain page, it is necessary that all flash memory cells 16 constituting the user area 25 of the page are in an erased state. The page in which even one flash memory cell 16 constituting the user area 25 of the page is in a write state cannot be directly overwritten with data different from this. Therefore, in order to write new data different from this to a page in which data has already been written, all the flash memory cells 16 constituting the block to which this page belongs are temporarily erased, and then new data is written. Processing is required.
[0071]
Therefore, when overwriting old data stored in a page with new data, in order to prevent the data stored in the other page included in the block to which this page belongs from being lost, It is necessary to move the stored data to another block. Therefore, the relationship between the logical block address obtained from the host address and the physical block address on the flash memory chips 2-0 to 2-3 corresponding to the logical block address is instructed by the host computer 5 to overwrite data. Change dynamically every time. For this reason, in order to access the flash memory chips 2-0 to 2-3 from the host computer 5, the relationship between the logical block address and the physical block address on the flash memory corresponding to the logical block address is determined. This is because an address conversion table in which the information shown is stored is required. Details of the address conversion table will be described later.
[0072]
Next, various work data stored in the SRAM work area 8 will be described. In the SRAM work area 8, at least an address conversion table 27, an erased block queue 28, and an internal variable 30 are stored.
[0073]
FIG. 5 is a schematic diagram showing the data structure of the address conversion table 27 stored in the SRAM work area 8.
[0074]
As shown in FIG. 5, the address conversion table 27 is composed of four tables consisting of tables # 0 to # 3, and each table is composed of 8000 flags and 8000 physical block address storage areas. The These tables # 0 to # 3 correspond to the flash memory chips 2-0 to 2-3, respectively.
[0075]
Corresponding physical block addresses (13 bits) are stored in 8000 physical block address storage areas # 0 to # 7999 in the tables # 0 to # 3, respectively. The address conversion information indicating the corresponding relationship is formed. That is, the physical block address storage areas # 0 to # 7999 in the table # 0 are assigned physical block addresses of 8000 actual used blocks constituting the flash memory chip 2-0, and these assigned logical block addresses. And the physical block address stored therein have a correspondence relationship. Similarly, the physical block address storage areas # 0 to # 7999 in the tables # 1 to # 3 are allocated with physical block addresses of 8000 actually used blocks constituting the flash memory chips 2-1 to 2-3, respectively. It is done.
[0076]
For example, if the upper 15 bits of the host address supplied from the host computer 5 are “101010101010101B”, the quotient when this is divided by 8000 is “2” and the remainder is “5845”. 2 is selected, and if the physical block address stored here, for example, the stored physical block address is “0000000011111B”, “31” is read as the physical block address. Thus, the conversion from the logical block address # 5845 in the flash memory chip 2-2 to the physical block address # 31 in the flash memory chip 2-2 is completed.
[0077]
The 8000 flags # 0 to # 7999 in each table # 0 to # 3 correspond to the physical block address storage areas # 0 to # 7999 in the table, respectively, and the corresponding physical block address storage areas Indicates whether the physical block address stored in is a valid value. Specifically, if the flag is “1”, it indicates that the physical block address stored in the corresponding physical block address storage area is a valid value, and if the flag is “0”, the corresponding physical block address is stored. Indicates that the physical block address stored in the block address storage area is not a valid value. Therefore, it means that a physical block address is not yet associated with a logical block address whose corresponding flag is “0”.
[0078]
As described above, the address conversion table 27 includes 32000 flags and 32000 physical block storage areas. Each flag needs to store 1-bit information. Needs to store 13-bit information, the address conversion table 27 occupies about 56 kbytes of the storage capacity of the SRAM work area 8.
[0079]
The address conversion table 27 is generated as follows.
[0080]
Of the blocks constituting the flash memory chips 2-0 to 2-3, the redundant area 26 included in each head page (page # 0) of the block storing data has the block as described above. A corresponding logical block address indicating which logical block address corresponds is included, and the corresponding logical block address stored in each head page of each block is controlled by the microprocessor 6 under the control of the flash memory interface block 10. Is read through. When the corresponding logical block address is read, it is determined whether or not the block is an erased empty block under the control of the microprocessor 6.
[0081]
Here, in the erased empty block, the corresponding logical block address stored in the redundant area 26 should be “all 1 (1111111111111B)”. That is, as described above, the corresponding logical block address is only from # 0 (0000000000000000B) to # 7999 (1111100111111B). Therefore, when this is all 1 (1111111111111B), the corresponding block is an erased empty block. It can be judged that there is. On the other hand, when the corresponding logical block address is “0000000000000000B” to “1111100111111B”, the corresponding logical block address is a valid logical block address.
[0082]
Therefore, the microprocessor 6 refers to the corresponding logical block address included in the redundant area 26 of the pages # 0 to # 3 of each block, and if this indicates a valid logical block address number instead of all 1, the chip Among the physical block address storage areas belonging to the table corresponding to the number, the physical block address storage area to which the same logical block address as the read corresponding logical block address is assigned is stored in the physical block address. The block address is stored and the corresponding flag is set to “1”. For example, if the block from which the corresponding logical block address is read belongs to the flash memory chip 2-0, the physical block address is “10”, and the read corresponding logical block address is “123”, table # 0 "10" is written as the physical block address to the physical block address storage area # 123 to which "123" is assigned as the logical block address, and the corresponding flag # 123 is set to " 1 ”.
[0083]
The processing as described above is performed for all the blocks in which data is stored, whereby the creation of the address conversion table 27 is completed.
[0084]
Next, the data structure of the erased block queue 28 stored in the SRAM work area 8 will be described.
[0085]
FIG. 6 is a schematic diagram showing the data structure of the erased block queue 28 stored in the SRAM work area 8.
[0086]
As shown in FIG. 6, the erased block queue 28 is configured by eight queues including queues # 0 to # 7. Each of these queues # 0 to # 7 uses a 2-byte storage area of the SRAM work area 8, and a physical block address is stored as 13-bit data. Therefore, the erased block queue 28 occupies 16 bytes of the storage capacity of the SRAM work area 8.
[0087]
Of the queues # 0 to # 7 constituting the erased block queue 28, the queues # 0 and # 1 are queues for the flash memory 2-0, and the queues # 0 and # 1 include the flash memory 2-0. Are stored, that is, physical block addresses of blocks in which all flash memory cells 16 constituting the user area 25 and the redundant area 26 are in the erased state. Similarly, queues # 2 and # 3 are queues for the flash memory 2-1, queues # 4 and # 5 are queues for the flash memory 2-2, and queues # 6 and # 7 are flash queues. This is a queue for the memory 2-3.
[0088]
The generation of the erased block queue 28 is performed when the above-described address conversion table 27 is generated under the control of the microprocessor 6.
[0089]
That is, as described above, the redundant area 26 included in page # 0 to page # 3 of each block constituting the flash memory chips 2-0 to 2-3 includes the corresponding logical block address, and the address conversion. When the table 27 is generated, a block whose corresponding logical block address is “all 1 (1111111111111B)” is searched under the control of the microprocessor 6. As a result of such a search, a maximum of 192 erased blocks are detected for each flash memory chip to become redundant blocks, and a maximum of two redundant blocks are selected from these, and the physical block address corresponds to the corresponding flash memory chip. Are stored in two queues.
[0090]
Next, the data structure of the internal variable 30 stored in the SRAM work area 8 will be described.
[0091]
FIG. 7 is a schematic diagram showing the data structure of the internal variable 30 stored in the SRAM work area 8.
[0092]
As shown in FIG. 7, the internal variable 30 is composed of variables # 0 to # 3. These variables # 0 to # 3 are variables for the flash memory chips # 2-0 to # 2-3, respectively, a transfer destination block address storage area 31, a transfer source block address storage area 32, and a start page storage area 33, respectively. And a flag 34. In both the transfer destination block address storage area 31 and the transfer source block address storage area 32, the physical block address is stored as 13-bit data, and in the start page storage area 33, the page number is determined as 5-bit data. Stored. The flag 34 is 1-bit data. Therefore, the internal variable 30 occupies 16 bytes of the storage capacity of the SRAM work area 8.
[0093]
The physical block address stored in the transfer destination block address storage area 31 is the physical block address of the block that is the transfer destination in the “partial transfer” described in detail below, and is stored in the transfer source block address storage area 32. The physical block address is the physical block address of the block that is the transfer source in the “partial transfer”. The page number stored in the start page storage area 33 is the last page (page #) among the pages # 0 to # 31 in the physical block indicated by the physical block address stored in the transfer destination block address storage area 31. 31) is the page number of the first page in one or two or more consecutive empty pages. Therefore, in the physical block, pages after the start page are guaranteed to be empty pages in which no data is stored. If the flag 34 is “1”, it indicates that the contents of the corresponding transfer destination block address storage area 31, transfer source block address storage area 32, and start page storage area 33 are valid. If present, it indicates that these are not valid values.
[0094]
Next, a data write operation by the flash memory system 1 according to the present embodiment will be described.
[0095]
The data write operation by the flash memory system 1 according to the present embodiment is classified into three, a new write operation, a partial transfer operation, and an additional write operation.
[0096]
FIG. 8 is a flowchart for determining which write operation is performed. Hereinafter, the writing operation to be selected will be described with reference to the flowchart shown in FIG.
[0097]
First, when a host address and an external write command are supplied from the host computer 5 to the controller 3 (step S1), the host address and the external write command are stored in a task file register (not shown) included in the host interface block 7. Stored temporarily. Further, when write data is supplied to the controller 3, it is sent to the ECC block 11 under the control of the microprocessor 6. The ECC block 11 that has received the supply of the write data analyzes this to generate an error collection code, and temporarily holds it.
[0098]
Next, whether or not the host addresses stored in the task file register (not shown) are correct addresses, that is, whether or not these host addresses indicate an originally nonexistent address or an invalid address. Determined by the host interface block 7.
[0099]
As a result of the determination, if it is determined that the host address stored in the task file register (not shown) is a valid address, the host address is converted into an internal address. On the other hand, if it is determined that this is an abnormal address, an error register (not shown) of the host interface block 7 is set, and the host computer 5 refers to the contents of the register to generate an error. I can know.
[0100]
Conversion to the internal address is performed as follows.
[0101]
First, under the control of the microprocessor 6, the upper 15 bits are extracted from the 20-bit host address and divided by "8000" (step S2). The quotient (0-3) and remainder (0-7999) obtained by the division are “chip number” and “logical block address”, respectively, and the address conversion table 27 is based on the chip number and logical block address. Are read out (step S3). For example, if the upper 15 bits of the host address are “00000011110100B”, the quotient when dividing by 8000 is “00B (0)” and the remainder is “0111110100B (500)”. Is # 0 and the logical block address is # 500. Based on this, the flag # 500 in the table # 0 is read.
[0102]
When the corresponding flag in the address conversion table 27 is read in this way, it is next determined whether the content is “1” or “0” (step S4). As a result, if the content of the read flag is “0”, it means that a valid physical block address is not stored in the corresponding physical block address storage area, and a new write operation is selected. (Step S5). Details of the new writing operation will be described later.
[0103]
On the other hand, if the content of the read flag is “1”, it means that a valid physical block address is stored in the corresponding physical block address storage area, so that the content is read. The read 13-bit physical block address constitutes an internal address together with the chip number and the lower 5 bits of the host address. Thus, the conversion to the internal address is completed (step S6).
[0104]
Next, the corresponding flag 34 in the internal variable 30 is read based on the chip number (the upper 2 bits of the internal address) (step S7). For example, if the chip number is “00B (0)”, the flag 34 included in the variable # 0 is read. In this manner, when the corresponding flag 34 in the internal variable 30 is read, it is next determined whether the content is “1” or “0” (step S8). As a result, if the content of the read flag 34 is “0”, the partial transfer operation described in detail below is selected (step S9).
[0105]
On the other hand, if the content of the read flag 34 is “1”, an additional writing determination (step S10) is performed to determine whether or not the additional writing operation can be performed. If it is determined that the write operation can be performed, the additional write operation described below is selected, and if it is determined that the additional write operation cannot be performed, the partial transfer operation is selected. Is done.
[0106]
As described above, it is determined which of the new writing operation, the partial transfer operation, and the additional writing operation should be executed.
[0107]
Next, a new write operation will be described.
[0108]
FIG. 9 is a flowchart showing a new writing operation.
[0109]
As shown in FIG. 9, in the new write operation (step S5), first, a predetermined queue among the queues # 0 to # 7 constituting the erased block queue 28 is controlled under the control of the microprocessor 6. The physical block address selected and stored is read (step S11). As described above, the physical block address stored in each queue of the erased block queue 28 is the erased block, that is, all the flash memory cells 16 constituting the user area 25 and the redundant area 26 are in the erased state. This is the physical block address (13 bits) of the block.
[0110]
When the physical block address of the erased block is read, this is stored in the corresponding physical block address storage area in the address conversion table 27, and the corresponding flag is rewritten to “1” (step S12). For example, if the upper 15 bits of the host address are “00000011110100B” as in the above example, the quotient when divided by 8000 is “00B (0)”, and the remainder is “0111110100B (500)”. Thus, the physical block address of the erased block is stored in the physical block address storage area # 500 in the table # 0 of the address conversion table 27, and the flag # 500 in the table # 0 is rewritten to “1”.
[0111]
Then, under the control of the microprocessor 6, the chip number, the physical block address, and the lower 5 bits of the host address are combined in this order, and the combined address becomes an internal address (step S13).
[0112]
When the generation of the internal address is completed in this manner, a predetermined setting is made for a register (not shown) included in the flash sequencer block 12 under the control of the microprocessor 6, and when the generation is completed, the flash sequencer block 12 A series of write operations are executed (step S14). As a result, the user data given from the host computer 5 is written to a predetermined page in a predetermined block indicated by the internal address.
[0113]
In this case, for the block to be written, not only the page to which user data is to be written, but also the logical block addresses corresponding to the redundant areas 26 of all pages # 0 to # 31 constituting the block. Is written. As a result, the block becomes a “used block”, and the user data cannot be directly overwritten thereafter.
[0114]
Thus, the new writing operation (step S5) is completed.
[0115]
Next, the partial transfer operation will be described.
[0116]
FIG. 10 is a flowchart showing the partial transfer operation, and FIGS. 11A and 11B are schematic diagrams showing the data storage states of the transfer source block and the transfer destination block in the partial transfer operation.
[0117]
As shown in FIG. 10, in the partial transfer operation (step S9), first, a predetermined queue is selected from the queues # 0 to # 7 constituting the erased block queue 28 under the control of the microprocessor 6. Then, the stored physical block address is read (step S21).
[0118]
When the physical block address of the erased block is read, the internal variable 30 is updated based on this (Step S22). Here, in updating the internal variable 30, any one of the variables # 0 to # 3 is first selected based on the chip number, and the erased block queue 28 is stored in the transfer destination block address storage area 31 constituting the selected variable. The physical block address read out is stored, the physical block address read out from the address conversion table 27 is stored in the transfer source block address storage area 32, and the write target page (page #i) is stored in the start page storage area 33. ) Is stored as the page number (page # i + 1) of the next page. Further, the flag 34 is set to “1”. Here, the page to be written (page #i) refers to a page specified by the lower 5 bits of the internal address. Hereinafter, the block specified by the physical block address stored in the transfer destination block address storage area 31 is referred to as “transfer destination block”, and the block specified by the physical block address stored in the transfer source block address storage area 32 is referred to as “transfer destination block”. This is called a “transfer source block”.
[0119]
When the update of the internal variable 30 is completed, the address conversion table 27 is then updated (step S23). In updating the address conversion table 27, the physical block address read from the erased block queue 28 is overwritten in the corresponding physical block address storage area.
[0120]
Next, the data stored in the pages from page # 0 in the transfer source block to the page (page # i-1) immediately before the page to be written (page #i) is the same page in the transfer destination block. (Step S24). That is, the operation of the first half of inter-block transfer is performed. When step S24 is completed, as shown in FIG. 11A, pages # 0 to # i-1 of the transfer destination block become valid pages (hatched portions), and pages #i to # 31 become empty pages. Become. Here, “valid page” means a page in which a write operation is prohibited regardless of whether or not actually valid user data is stored. In the valid page, the corresponding logical block address is written in the corresponding redundant area 26, and in the empty page, the corresponding logical block address in the corresponding redundant area 26 is all 1 (1111111111111B).
[0121]
When step S24 is completed, the data instructed to be written by the host computer 5 is then written to the write target page (page #i) of the transfer destination block (step S25). When step S25 is completed, as shown in FIG. 11B, pages # 0 to #i of the transfer destination block become valid pages, and pages # i + 1 to # 31 become empty pages.
[0122]
Thus, the partial transfer operation (step S9) is completed. In the partial transfer operation, it is important that the operation in the latter half of the inter-block transfer is omitted. Therefore, when a partial transfer operation is performed, two physical blocks are assigned to a certain logical block address.
[0123]
Next, additional writing determination will be described.
[0124]
FIG. 12 is a flowchart showing the additional write determination.
[0125]
As shown in FIG. 12, in the additional write determination (step S10), first, based on the chip number (the upper 2 bits of the internal address), the corresponding transfer destination block address storage area 31 in the internal variable 30 is stored. The contents are read (step S31). Next, the read 13-bit physical block address is compared with the physical block address read from the address conversion table 27, and it is determined whether or not they match (step S32).
[0126]
As a result, if they do not match, the contents of the transfer source block address storage area 32 and the start page storage area 33 are read (step S33), from page # i + 1 to the last page (page # 31) in the transfer source block. The data stored in this page is transferred to the same page in the transfer destination block (step S34). That is, the operation of the latter half of inter-block transfer is performed.
[0127]
FIG. 13 is a schematic diagram showing the data storage state of the transfer source block and the transfer destination block in step S34.
[0128]
As shown in FIG. 13, in step S34, the operation of the latter half of the inter-block transfer omitted in the above-described partial transfer operation (step S9) is performed, whereby all pages constituting the transfer destination block are performed. # 0 to # 31 are valid pages.
[0129]
When step S34 is completed, the transfer source block is then erased as a new empty block (step S35), and the corresponding flag 34 is reset to “0” (step S36). As a result, the state in which two physical blocks are assigned to one logical block address is eliminated. Thereafter, the partial transfer operation (step S9) described above is performed, whereby the data instructed to be written by the host computer 5 is written into a predetermined block.
[0130]
On the other hand, if the result of determination in step S32 is that they match, the contents of the start page storage area 33 are read (step S37), and the lower 5 bits of the internal address, that is, the page to be written (page #j) And the start page (page # i + 1) are compared (step S38).
[0131]
As a result, if the page number of the page to be written (page #j) is smaller than the page number of the start page (page # i + 1), steps S33 to S36 described above are executed, and then the partial transfer operation (step S9) is performed. Executed. On the other hand, if the page number of the page to be written (page #j) is equal to or greater than the page number of the start page (page # i + 1), an additional writing operation described in detail below is selected (step S39). ).
[0132]
Thus, the additional writing determination (step S10) is completed. Thus, in the additional write determination (step S10), either the additional write operation (step S39) or the partial transfer operation (step S9) is selected.
[0133]
Next, the additional writing operation will be described.
[0134]
FIG. 14 is a flowchart showing the additional write operation, and FIGS. 15A to 15C are schematic diagrams showing data storage states of the transfer source block and the transfer destination block in the additional write operation.
[0135]
The additional writing operation (step S39) is performed depending on whether the page to be written (page #j) matches the start page (page # i + 1) (j = i + 1) or not (j> i + 1). Different. Therefore, as shown in FIG. 14, in the additional writing operation, it is first determined whether or not the page to be written (page #j) matches the start page (page # i + 1) (step S41). .
[0136]
As a result, when the page to be written (page #j) and the start page (page # i + 1) match (j = i + 1), for the page to be written (page #j) in the transfer destination block. Data is written (step S43). As a result, as shown in FIG. 15A, pages # 0 to #j (= i + 1) of the transfer destination block are valid pages, and pages # j + 1 to # 31 are empty pages. It becomes. When step S43 is completed, the contents of the start page storage area 33 of the internal variable 30 are then updated to the page number (page # j + 1) of the page next to the page to be written (page #j) (step S44). ).
[0137]
On the other hand, if the page to be written (page #j) and the start page (page # i + 1) do not match (j> i + 1), the page to be written (page # i + 1) from the start page (page # i + 1) in the transfer source block. The data stored in the pages up to the previous page (page # j-1) of page #j) is transferred to the same page in the transfer destination block (step S42). That is, intermediate transfer is performed. As a result, as shown in FIG. 15B, pages # 0 to # j-1 of the transfer destination block become valid pages, and pages #j to # 31 become empty pages. When step S42 is completed, data is written to page #j in step S43 described above, and as a result, as shown in FIG. 15C, pages # 0 to #j (= i + 1) of the transfer destination block. Are valid pages, and pages # j + 1 to # 31 are empty pages. Thereafter, step S44 described above is executed, and the content of the start page storage area 33 is updated to page # j + 1.
[0138]
When the data writing is completed in this way, it is next determined whether or not the page to be written (page #j) is the last page (page # 31) (step S45). As a result, if the page to be written (page #j) is the last page (page # 31), the transfer source block is erased as a free block (step S46), and the corresponding flag 34 is reset to “0”. (Step S47). On the other hand, if the page to be written (page #j) is other than the last page (page # 31), the series of processes is terminated without executing steps S46 and S47.
[0139]
Thus, the additional writing operation (step S39) is completed.
[0140]
The above is the data write operation by the flash memory system 1 according to the present embodiment.
[0141]
In the flash memory system 1 according to this embodiment, a state in which two physical blocks are allocated to one logical block address occurs by performing the partial transfer operation (step S9). For this reason, when the host computer 5 gives an instruction to read data from the block, the internal variable 30 is referred to and the physical block in which correct data is written can be read.
[0142]
However, in this case, since it is necessary to refer to the internal variable 30 every time data reading is instructed from the host computer 5, a data write instruction to the same logical block address is performed after the partial transfer operation is performed. When an instruction other than the above is issued from the host computer 5, the inter-block transfer may be completed by executing the above-described steps S33 to S35 before executing the instruction. In this case, even if the host computer 5 instructs to read data for any logical block address, this can be performed by the same read processing as the normal flash memory system 1.
[0143]
Next, when partial transfer operation (step S9) is performed, power is shut off in a state where two physical blocks are assigned to one logical block address, and then power is turned on again. Will be described.
[0144]
When power is shut down in a state where two physical blocks are assigned to one logical block address, two physical blocks are used as physical blocks corresponding to a certain logical block address in the creation of the address conversion table 27 performed at startup. A block should be found. That is, two physical blocks having the same corresponding logical block address should be found. When such a logical block address is found, a complete operation described in detail below is executed under the control of the microprocessor 6.
[0145]
FIG. 16 is a flowchart showing the completion operation, and FIG. 17 is a schematic diagram showing the data storage state of the transfer source block and the transfer destination block in the completion operation.
[0146]
As shown in FIG. 16, in the completion operation, first, the last pages (page # 31) of two physical blocks having the same corresponding logical block address are respectively read to determine which is an empty page. Here, the determination of which is an empty page is made based on the corresponding logical block address included in the redundant area 26 of these pages, and the one where the corresponding logical block address is all 1 (1111111111111B) is an empty page. It is determined that there is. As a result of the determination, a block in which the last page (page # 31) is an empty page is a transfer destination block in the partial transfer operation, and a block in which the last page (page # 31) is a valid page is in the partial transfer operation. It can be determined that the block is a transfer source block (step S51).
[0147]
When the determination of the transfer destination block / transfer source block for the two physical blocks is completed in this way, the physical block address of the transfer destination block is stored in the corresponding physical block address storage area in the address conversion table 27. At the same time, the corresponding flag is set to “1” (step S52).
[0148]
Next, the pages constituting the transfer destination block are sequentially read back in order from page # 30, thereby detecting the range of empty pages (step S53). For example, if a valid corresponding logical block address is read in page # 20, it is detected that pages # 21 to # 31 are empty blocks.
[0149]
When the range of the empty block is detected, next, the data of the page corresponding to the transfer source block is transferred to each empty page of the transfer destination block (step S54). That is, the operation of the latter half of inter-block transfer is performed. As a result, as shown in FIG. 17, all pages # 0 to # 31 of the transfer destination block become valid pages. FIG. 17 shows the operation when it is detected in step S53 that pages # 21 to # 31 of the transfer destination block are empty blocks. Then, the transfer source block is erased to be an empty block (step S55), and the series of processing ends.
[0150]
Thus, the completion operation is completed.
[0151]
As described above, in the flash memory system 1 according to the present embodiment, for the logical block address to which data has already been assigned, that is, the logical block address for which the corresponding flag in the address conversion table 27 is “1”. Even if the host computer 5 instructs to write data, the inter-block transfer is not immediately performed as in the prior art, but the partial write operation in which the operation of the latter half of the inter-block transfer is omitted is performed. Therefore, the next write operation can be performed when the host computer 5 next instructs the same block to write data. In the additional write operation, as described above, since the number of pages to be transferred is zero or a small number, a series of transfers is performed as compared with a case where the transfer between blocks is performed every time data writing is instructed from the host computer 5. The time required for this process is greatly reduced. In particular, under the situation where the host computer 5 sequentially instructs writing data one page at a time for a plurality of consecutive pages, the effect of speeding up by the flash memory system 1 according to the present embodiment is significant.
[0152]
Next, another preferred embodiment of the present invention will be described.
[0153]
The configuration of the flash memory system 39 according to another preferred embodiment of the present invention is basically the same as that of the flash memory system 1 according to the above embodiment as shown in FIG. 1 and is stored in the SRAM work area 8. The difference is that the internal variable 30 is replaced with the internal variable 40.
[0154]
FIG. 18 is a schematic diagram showing the data structure of the internal variable 40 stored in the SRAM work area 8.
[0155]
As shown in FIG. 18, the internal variable 40 is composed of variables # 0 to # 3, which are a first block address storage area 41, a second block address storage area 42, and a third block address storage area 43, respectively. , A first start page storage area 44, a second start page storage area 45, a first flag 46 and a second flag 47. In the first to third block address storage areas 41 to 43, physical block addresses are stored as 13-bit data, respectively, and in the first and second start page storage areas 44 and 45, page numbers are respectively stored. Is stored as 5-bit data. Each of the first and second flags 46 and 47 is 1-bit data. Therefore, the internal variable 40 occupies 28 bytes of the storage capacity of the SRAM work area 8.
[0156]
If the first flag 46 is “1”, it indicates that the content of the variable is valid, and if it is “0”, the content of the variable is invalid. That is, the first flag 46 is a flag corresponding to the flag 34 in the above embodiment. The second flag 47 is valid only when the first flag 46 is “1”. If this flag is “1”, the first to third block address storage areas 41 to 43 are used. Indicates that the contents of the first and second start page storage areas 44 and 45 are all valid, and if “0”, the first and second block address storage areas 41 and 42 and the first start page storage area The contents of the page storage area 44 are all valid, and the contents of the third block address storage area 43 and the second start page storage area 45 are invalid.
[0157]
The first block address storage area 41 corresponds to the transfer source block address storage area 32 in the above embodiment, and the second block address storage area 42 corresponds to the transfer destination block address storage area 31 in the above embodiment. To do. In addition, the first start page storage area 44 corresponds to the start page storage area 33 in the above embodiment.
[0158]
Next, a data write operation by the flash memory system 39 according to the present embodiment will be described.
[0159]
The data write operation in the flash memory system 39 according to the present embodiment is classified into five, that is, a new write operation, first and second partial transfer operations, and first and second additional write operations. The method for determining which of these write operations is selected is basically the same as the flowchart shown in FIG. 8, but in step S7, it is based on the chip number (the upper 2 bits of the internal address). The corresponding first flag 46 in the internal variable 40 is read out. As a result, if this is “0”, the first partial transfer operation is selected.
[0160]
The first partial transfer operation is basically the same as the partial transfer operation (step S9) in the above embodiment, but in step S22, one of the variables # 0 to # 3 is first selected based on the chip number. The physical block address read from the erased block queue 28 is stored in the second block address storage area 42 constituting the selected variable, and read from the address conversion table 27 in the first block address storage area 41. The issued physical block address is stored, and the page number (page # i + 1) of the next page of the page to be written (page #i) is stored in the first start page storage area 44. Further, the first flag 46 is set to “1”, and the second flag 47 is reset to “0”.
[0161]
Hereinafter, the block specified by the physical block address stored in the first block address storage area 41 is referred to as “first block”, and is specified by the physical block address stored in the second block address storage area 42. This block is called “second block”. A block specified by the physical block address stored in the third block address storage area 43 is referred to as a “third block”.
[0162]
In step S24, the data stored in the pages from the page # 0 in the first block to the page (page # i-1) immediately preceding the page to be written (page #i) is stored in the second block. In step S25, the data instructed to be written by the host computer 5 is written to the page to be written (page #i) of the second block.
[0163]
Next, additional writing determination in this embodiment will be described.
[0164]
FIG. 19 is a flowchart showing the additional write determination by the flash memory system 39 according to the present embodiment.
[0165]
As shown in FIG. 19, in the additional write determination (step S10) in this embodiment, first, the corresponding second flag 47 in the internal variable 40 is based on the chip number (the upper 2 bits of the internal address). Is read (step S61). When the corresponding second flag 47 in the internal variable 40 is read, it is next determined whether the content is “1” or “0” (step S62). As a result, if the content of the read second flag 47 is “0”, the content of the second block address storage area 42 is read (step S63). The contents of the block address storage area 43 are read (step S64).
[0166]
When the content of the second block address storage area 42 is read because the content of the second flag 47 is “0” (step S 63), the physical block read from the content and the address conversion table 27. The address is compared, and it is determined whether or not they match (step S65).
[0167]
As a result, if the two do not match, the contents of the first block address storage area 41 and the first start page storage area 44 are read (step S66) and specified by the contents of the first block address storage area 41 Among the pages in the first block, the data stored in the pages from the page (page # i + 1) specified by the contents of the first start page storage area 44 to the last page (page # 31) are stored. Then, it is transferred to the same page in the second block specified by the contents of the second block address storage area 42 (step S67). That is, the operation of the latter half of inter-block transfer is performed. Such an operation is the same as the transfer operation shown in FIG.
[0168]
When step S67 is completed, the first block is then erased into a new empty block (step S68), and the corresponding first flag 46 is reset to “0” (step S69). ). As a result, the state in which two physical blocks are assigned to one logical block address is eliminated. Thereafter, the above-described first partial transfer operation (step S9) is performed.
[0169]
On the other hand, if the result of determination in step S65 is that they match, the contents of the first start page storage area 44 are read (step S70), and the lower 5 bits of the internal address, that is, the page to be written (page #J) is compared with the start page (page # i + 1) (step S71).
[0170]
As a result, if the page number of the page to be written (page #j) is smaller than the page number of the start page (page # i + 1), a second partial transfer operation (step S72) described in detail below is performed. If the page number of the page to be written (page #j) is greater than or equal to the page number of the start page (page # i + 1), the first additional write operation is selected (step S39). The first additional write operation is basically the same as the partial transfer operation (step S39) in the above embodiment, but in step S44, the contents of the first start page storage area 44 corresponding to the internal variable 40 are stored. Is updated to the page number (page # j + 1) of the next page of the page to be written (page #j). In step S47, the first flag 46 corresponding to the internal variable 40 is reset to “0”.
[0171]
Here, the second partial transfer operation (step S72) will be described.
[0172]
FIG. 20 is a flowchart showing the second partial transfer operation, and FIGS. 21A and 21B are schematic diagrams showing the data storage states of the first to third blocks in the second partial transfer operation. is there.
[0173]
As shown in FIG. 20, in the second partial transfer operation (step S72), first, a predetermined number of queues # 0 to # 7 constituting the erased block queue 28 are controlled under the control of the microprocessor 6. The queue is selected, and the stored physical block address is read (step S91).
[0174]
When the physical block address of the erased block is read, the internal variable 40 is updated based on this (Step S92). Here, in updating the internal variable 40, first, any one of the variables # 0 to # 3 is selected based on the chip number, and the erased block queue is stored in the third block address storage area 43 constituting the selected variable. 28 is stored, and the page number (page # j + 1) of the next page of the page to be written (page #j) is stored in the second start page storage area 45. Further, the second flag 47 is set to “1”.
[0175]
When the update of the internal variable 40 is completed, the address conversion table 27 is then updated (step S93). In updating the address conversion table 27, the physical block address read from the erased block queue 28 is overwritten in the corresponding physical block address storage area.
[0176]
Next, the data stored in the page from page # 0 in the second block to the page (page # j-1) immediately before the page to be written (page #j) is stored in the third block. It is transferred to the same page (step S94). That is, the operation of the first half of inter-block transfer is performed. When step S94 is completed, as shown in FIG. 21A, pages # 0 to # j-1 of the third block become valid pages, and pages #j to # 31 become empty pages.
[0177]
When step S94 is completed, the data instructed to be written by the host computer 5 is then written to the write target page (page #j) of the transfer destination block (step S95). When step S95 is completed, as shown in FIG. 21B, pages # 0 to #j of the third block become valid pages, and pages # j + 1 to # 31 become empty pages.
[0178]
Thus, the second partial transfer operation (step S72) is completed. As shown in FIG. 21, when the second partial transfer operation is performed, three physical blocks are assigned to a certain logical block address.
[0179]
Returning to FIG. 19, the additional write determination will be described again.
[0180]
In step S62, when the content of the third block address storage area 43 is read because the content of the second flag 47 is “1” (step S64), the content is read from the address conversion table 27. The physical block addresses thus compared are compared to determine whether or not they match (step S73).
[0181]
As a result, if they do not match, the contents of the first block address storage area 41, the second block address storage area 42, the first start page storage area 44, and the second start page storage area 45 are read ( Step S74). next,
Of the pages in the second block, the data stored in the pages from the second start page (page # j + 1) to the page (page #i) immediately before the first start page (page # i + 1) Are transferred to the same page in the third block (step S75). As a result, as shown in FIG. 22A, pages # 0 to #i of the third block become effective pages, and page # i + 1 becomes an empty page.
[0182]
Next, of the pages in the first block, the data stored in the pages from the first start page (page # i + 1) to the last page (page # 31) are stored in the same page in the third block. Transferred (step S76). As a result, as shown in FIG. 22B, all pages # 0 to # 31 of the third block become valid pages.
[0183]
Then, the first block and the second block are erased to become a new empty block (step S77), and the corresponding first flag 46 and second flag 47 are reset to “0”. (Step S69). As a result, the state in which three physical blocks are assigned to one logical block address is canceled. Thereafter, the above-described first partial transfer operation (step S9) is performed.
[0184]
On the other hand, if they match in step S73, the contents of the second start page storage area 45 are read (step S78), and the lower 5 bits of the internal address, that is, the page to be written (page #k) And the second start page (page # j + 1) are compared (step S79).
[0185]
As a result, if the page number of the page to be written (page #k) is smaller than the page number of the second start page (page # j + 1), among the pages in the second block, the second start page ( Data stored in pages from page # j + 1) to the page immediately before the first start page (page # i + 1) (page #i) is transferred to the same page in the third block (step S80). Next, the second block is erased (step S81). As a result, the third block becomes a new second block and the second block becomes an empty block, and the internal variable 40 is updated based on this (step S82). Here, in updating the internal variable 40, the contents of the corresponding third block address storage area 43 are copied to the second block address storage area 42, and the second flag 47 is reset to "0". The When the update of the internal variable 40 is completed, the second partial transfer operation (step S72) described above is executed.
[0186]
On the other hand, if the page number of the page to be written (page #k) is greater than or equal to the page number of the second start page (page # j + 1) in step S73, the second additional write operation described in detail below is performed. Selected (step S83).
[0187]
Thus, the additional writing determination (step S10) is completed. Thus, in the additional write determination (step S10) in the present embodiment, the first partial transfer operation (step S9), the second partial transfer operation (step S72), and the first additional write operation (step S10). In S39), one of the second additional write operations (step S83) is selected.
[0188]
Next, the second additional writing operation (step S83) will be described.
[0189]
FIG. 23 is a flowchart showing the second additional write operation, and FIGS. 24A to 24C and FIGS. 25A to 25C show the first to second write operations in the second additional write operation. It is the schematic which shows the data storage state of 3 blocks.
[0190]
The second additional write operation (step S83) is performed when the page to be written (page #k) matches the second start page (page # j + 1) (k = j + 1) and does not match (k The operation differs depending on> j + 1). Therefore, as shown in FIG. 23, in the second additional write operation, it is first determined whether or not the page to be written (page #k) matches the second start page (page # j + 1). (Step S101).
[0191]
As a result, when the page to be written (page #k) matches the second start page (page # j + 1) (k = j + 1), the page to be written (page #k) in the third block. ) Is written (step S102). As a result, as shown in FIG. 24A, pages # 0 to #k (= j + 1) of the third block are valid pages, and pages # k + 1 to # 31 is an empty page. When step S102 is completed, it is next determined whether or not the page to be written (page #k) matches the previous page (page #i) of the first start page (step S103). As a result, if the page to be written (page #k) does not match the page immediately before the first start page (page #i) (k ≠ i), the second start of the internal variable 40 The contents of the page storage area 45 are updated to the page number (page # k + 1) of the page next to the page to be written (page #k) (step S104).
[0192]
On the other hand, if the page to be written (page #k) matches the page immediately before the first start page (page #i) (k = i), the second block is erased as a block. After making it an empty block (step S105), the internal variable 40 is updated (step S106). Here, in updating the internal variable 40, the contents of the corresponding third block address storage area 43 are copied to the second block address storage area 42, and the second flag 47 is reset to "0". The As a result, the third block becomes a new second block, and the second block becomes an empty block.
[0193]
In step S101, if the page to be written (page #k) does not match the second start page (page # j + 1) (k> j + 1), the page to be written (page #k) 1 start page (page # i + 1) is compared (step S107). As a result, if the page to be written (page #k) is equal to or lower than the first start page (page # i + 1), the page to be written (page # j + 1) from the second start page (page # j + 1) in the second block. Data stored in the pages up to the previous page (page # k-1) of page #k) is transferred to the same page in the third block (step S108). As a result, as shown in FIG. 24B, pages # 0 to # k-1 of the third block become valid pages, and pages #k to # 31 become empty pages. When step S108 is completed, data is written to page #k by step S102 described above, and as a result, as shown in FIG. 24C, pages # 0 to #k (= j + 1) of the third block. ) Are valid pages, and pages # k + 1 to # 31 are empty pages. Thereafter, the data writing in step S102 and the comparison in step S103 are executed, and step S104 or steps S105 and S106 are executed based on the result.
[0194]
If the result of comparison in step S107 is that the page to be written (page #k) is larger than the first start page (page # i + 1), the second start page (page # j + 1) in the second block. To the first page (page # i + 1) before the first start page (page # i + 1), the data stored in the page is transferred to the same page of the third block (step S109). As a result, as shown in FIG. 25A, pages # 0 to #i of the third block are valid pages, and pages # i + 1 to # 31 are empty pages. When step S109 is completed, next, from the first start page (page # i + 1) in the first block to the page (page # k-1) immediately before the page to be written (page #k). The data stored in the page is transferred to the same page in the third block (step S110). As a result, as shown in FIG. 25B, pages # 0 to # k-1 of the third block become valid pages, and pages #k to # 31 become empty pages. When the transfer operation from the second block to the third block (step S109) and the transfer operation from the first block to the third block (step S110) are completed in this way, Data is written to the page to be written (page #k) (step S111). As a result, as shown in FIG. 25C, pages # 0 to #k (= j + 1) of the third block. Are valid pages, and pages # k + 1 to # 31 are empty pages.
[0195]
When the data writing is completed in this way, it is next determined whether or not the page to be written (page #k) is the last page (page # 31) (step S112). As a result, if the page to be written (page #k) is the last page (page # 31), the first and second blocks are erased into empty blocks (step S113), and the corresponding first flag 46 is reset to “0” (step S114). On the other hand, if the page to be written (page #k) is other than the final page (page # 31), the above-described steps S105 and S106 are executed, whereby the third block becomes a second block, The second block becomes an empty block.
[0196]
Thus, the second additional write operation (step S83) is completed.
[0197]
The above is the data write operation by the flash memory system 39 according to the present embodiment.
[0198]
Further, in the state where two or three physical blocks are allocated to one logical block address by performing the first partial transfer operation (step S9) or the second partial transfer operation (step S72). When the power is turned off and then turned on again, inter-block transfer is completed by the same operation as the completion operation in the above embodiment.
[0199]
As described above, the flash memory system 39 according to the present embodiment is configured so that three physical blocks can be allocated to one logical block address in addition to the effects of the flash memory system 1 according to the above-described embodiment. The possibility that the additional writing operation is selected is further increased. As a result, a series of data write operations can be executed at a higher speed than the flash memory system 1 according to the above embodiment.
[0200]
Next, still another preferred embodiment of the present invention will be described.
[0201]
The configuration of a flash memory system 49 according to still another preferred embodiment of the present invention is basically the same as that of the flash memory system 1 according to the above embodiment as shown in FIG. 1, and is stored in the SRAM work area 8. The address conversion table 27 is replaced with the address conversion table 57, the erased block queue 28 is replaced with the erased block queue 58, and the internal variable 30 is replaced with the internal variable 50.
[0202]
The flash memory system 49 according to the present embodiment is a “virtual block system” flash memory system. First, the virtual block method will be described.
[0203]
In the virtual block type flash memory system, four actual use blocks selected one by one from each of the flash memory chips 2-0 to 2-3 are virtually combined to form a “virtual block”. Thereby, 8000 virtual blocks including virtual blocks # 0 to # 7999 are configured.
[0204]
FIG. 26 is a diagram illustrating an example of virtual block mapping.
[0205]
In the example shown in FIG. 26, physical block # 150 included in flash memory chip 2-0, physical block # 6811 included in flash memory chip 2-1, physical block # 8191 included in flash memory chip 2-2, Physical blocks # 3048 included in the flash memory chip 2-3 are virtually combined to form one virtual block. Thus, in this embodiment, it is necessary that the four physical blocks constituting one virtual block are included in different flash memory chips. In this way, a maximum of 8000 virtual blocks are configured.
[0206]
27 is a diagram showing a virtual page structure of the virtual block shown in FIG.
[0207]
As shown in FIG. 27, the virtual block is handled as one block composed of 128 virtual pages including virtual page # 0 to page # 127. Here, among the virtual blocks, 32 pages included in the portion including the physical block # 150 are given 4i (i is a physical page number) as a virtual page number, and are included in the portion including the physical block # 6811. 32 pages are given a virtual page number of 4i + 1, and 32 pages included in the part consisting of physical block # 8191 are given a virtual page number of 4i + 2 and included in a part consisting of physical block # 3048 These 32 pages are given 4i + 3 as the virtual page number. These virtual page numbers correspond to the lower 7 bits of the host address. Therefore, these virtual pages # 0 to # 127 are respectively accessed by successive host addresses. For this reason, when the host computer 5 instructs to write data to consecutive host addresses, parallel operation can be performed in each block, so that a series of write operations can be performed faster than in a normal flash memory system. Can be executed.
[0208]
Next, the relationship between the virtual block and the four physical blocks that constitute it will be described.
[0209]
FIG. 28 is a schematic diagram showing the data structure of the address conversion table 57 showing the relationship between 8000 virtual blocks and the four physical blocks constituting each virtual block.
[0210]
As shown in FIG. 28, the address conversion table 57 includes 8000 virtual blocks including virtual blocks # 0 to # 7999 arranged in this order, and each of these virtual blocks # 0 to # 7999 has a cell #. It consists of four cells and one flag consisting of j-0 to cell # j-3 (j is a virtual block address). For example, virtual block # 0 is composed of cell # 0-0 to cell # 0-3 and a flag, and virtual block # 1 is composed of cell # 1-0 to cell # 1-3 and a flag. Therefore, the address conversion table 57 is composed of 32000 cells and 8000 flags. Here, slot # 0 constituting cell # j-0 corresponds to flash memory chip 2-0, slot # 1 constituting cell # j-1 corresponds to flash memory chip 2-1, and cell #j -2 corresponds to the flash memory chip 2-2, and slot # 3 that configures the cell # j-3 corresponds to the flash memory chip 2-3.
[0211]
In cells # j-0 to # j-3 included in each virtual block, the addresses (physical block addresses) of the physical blocks constituting the virtual block are stored.
[0212]
A flag included in each virtual block indicates whether the virtual block is valid or invalid. Specifically, if the flag indicates “1”, the virtual block is valid, and if the flag indicates “0”, the virtual block is invalid. Therefore, the contents stored in the cells # j-0 to # j-3 included in the virtual block whose flag indicates “0” are ignored.
[0213]
The address conversion table 57 is generated as follows.
[0214]
In the virtual block method, among the physical blocks constituting the flash memory chips 2-0 to 2-3, the redundant area 26 included in each head page (physical page # 0) of the block in which data is stored , A virtual block address indicating to which virtual block the block belongs is included, and the virtual block address stored in each head page of each block is controlled by the microprocessor 6 under the control of the flash memory interface block 10. Is read through.
[0215]
If the virtual block address included in the redundant area 26 of the first page (physical page # 0) of each physical block indicates an address of a valid virtual block instead of all 1, cells constituting the address conversion table 57 Among these, the physical block address of the physical block is stored in the cell specified by the chip number and the read virtual block address. For example, if the read virtual block address from the physical block # 12 belonging to the flash memory chip 2-0 is “123”, “12” is written as the physical block address in the cell # 123-0.
[0216]
Such processing is performed for all physical blocks in which data is stored. Thereby, the generation of the address conversion table 57 is completed.
[0217]
Next, the data structure of the erased block queue 58 stored in the SRAM work area 8 will be described.
[0218]
FIG. 29 is a schematic diagram showing the data structure of the erased block queue 58 stored in the SRAM work area 8.
[0219]
As shown in FIG. 29, the erased block queue 58 is composed of six queue sets including queue sets # 0 to # 5, which are respectively queue # k-0 to queue # k-3 (k is , A queue set number). For example, the queue set # 0 includes queues # 0-0 to # 0-3, and the queue set # 1 includes queues # 1-0 to # 1-3. Therefore, the erased block queue 30 is composed of 24 queues. Here, queue # k-0 corresponds to flash memory chip 2-0, queue # k-1 corresponds to flash memory chip 2-1, and queue # k-2 corresponds to flash memory chip 2-2. Queue # k-3 corresponds to the flash memory chip 2-3.
[0220]
In queues # k-0 to # k-3 constituting each queue set # 0 to # 5, physical block addresses of physical blocks in which all flash memory cells 16 constituting the user area 25 are in the erased state are stored. Stored. Therefore, for example, when the erased physical block # 153 belonging to the flash memory chip 2-0 is registered in the erased block queue 58, the physical block address “00000101001001B” is the queue # 0-0 to # 5-0. Stored in either Similarly, for example, when an erased block # 6552 belonging to the flash memory chip 2-2 is registered in the erased block queue 30, the physical block address “11001100111000B” is stored in the queues # 0-2 to # 5- 2 is stored.
[0221]
In this manner, the physical block addresses of up to six erased blocks are registered in the erased block queue 58 for each of the flash memory chips 2-0 to 2-3, whereby up to six queue sets # 0 to # 5 are registered. Is generated.
[0222]
The generation of the erased block queue 58 is performed when the above-described address conversion table 57 is generated under the control of the microprocessor 6 and is stored in these queues from among the redundant blocks waiting for data writing. A physical block to be registered is selected.
[0223]
Next, the data structure of the internal variable 50 stored in the SRAM work area 8 will be described.
[0224]
The internal variable 50 has the same data structure as the internal variable 30 shown in FIG. Variables # 0 to # 3 constituting the internal variable 50 respectively correspond to slots # 0 to # 3 of the virtual block.
[0225]
Next, a data write operation by the flash memory system 49 according to the present embodiment will be described.
[0226]
First, when the host computer 5 instructs to write data to a virtual page with a used virtual block in which data has already been stored, basically the same operation as the partial transfer operation (step S9) described above. Thus, partial transfer is performed only to the corresponding physical block among the four physical blocks constituting the virtual block.
[0227]
FIG. 30 is a schematic diagram showing the data storage state of the transfer source block and the transfer destination block when the host computer 5 instructs to write data to the virtual page 4i + 1 of the virtual block #n.
[0228]
The virtual page 4i + 1 corresponds to the physical page #i of the physical block belonging to the slot # 1 among the four physical blocks constituting the virtual block #n. Therefore, when the host computer 5 instructs the virtual page 4i + 1 to write data, first, under the control of the microprocessor 6, a predetermined one of the queue sets # 0 to # 7 constituting the erased block queue 58 is determined. Slot # 1 of the queue set is selected, and the stored physical block address is read (step S21).
[0229]
When the physical block address of the erased block is read, the internal variable 50 is updated based on this (Step S22). Here, in updating the internal variable 50, first, the variable # 1 is selected based on the slot number, and the physical read out from the erased block queue 58 in the transfer destination block address storage area 31 constituting the selected variable. The block address is stored, the physical block address read from the address conversion table 57 is stored in the transfer source block address storage area 32, and the next page of the physical page to be written (page #i) is stored in the start page storage area 33. The page number (page # i + 1) is stored. Further, the flag 34 is set to “1”.
[0230]
When the update of the internal variable 50 is completed, the address conversion table 57 is then updated (step S23). In updating the address conversion table 57, the physical block address read from the erased block queue 58 is overwritten in the corresponding cell # n-1.
[0231]
Next, the data stored in the pages from the physical page # 0 in the transfer source block to the previous page (page # i-1) of the physical page to be written (page #i) is stored in the transfer destination block. It is transferred to the same page (step S24). That is, the operation of the first half of inter-block transfer is performed. When step S24 is completed, as shown in FIG. 30A, pages # 0 to # i-1 of the transfer destination block become valid pages, and pages #i to # 31 become empty pages.
[0232]
When step S24 is completed, the data instructed to be written by the host computer 5 is written to the physical page (page #i) to be written in the transfer destination block (step S25). When step S25 is completed, as shown in FIG. 30B, physical pages # 0 to #i of the transfer destination block become valid pages, and physical pages # i + 1 to # 31 become empty pages.
[0233]
Thus, the partial transfer operation (step S9) is completed.
[0234]
After such partial transfer is performed, when the host computer 5 instructs to write data to the virtual page 4j + 1 (j> i) of the virtual block #n, the above-described additional write operation (step S39). As a result, a series of data write operations are executed at high speed.
[0235]
Further, when the partial transfer operation (step S9) is performed, the power is shut off in a state where two physical blocks are allocated to one cell, and then the power is turned on again. The transfer between blocks is completed by the same operation as the completion operation in the aspect.
[0236]
As described above, the present invention can also be applied to the virtual block type flash memory system 49.
[0237]
The present invention is not limited to the above-described embodiments, and various modifications are possible within the scope of the invention described in the claims, and these are also included in the scope of the present invention. Needless to say.
[0238]
For example, in the flash memory systems 1, 39, and 49 according to the above embodiment, the internal variables 30, 40, and 50 are made up of variables # 0 to # 3 corresponding to the flash memory chips 2-0 to 2-3, respectively. Thus, each flash memory chip is configured to record one set of transfer destination blocks and transfer source blocks one by one, but one set of transfer destination blocks and transfer source blocks is combined into one in each flash memory chip. The configuration is not limited, and two or more sets may be recorded.
[0239]
In addition, in the flash memory systems 1, 39, and 49 according to the above-described embodiments, when two physical blocks having the same corresponding logical block address are found at the time of startup, the completion operation including steps S51 to S55 is executed. However, in the present invention, it is not essential to perform the completion operation, and the internal variable 30, using the physical block address of these two blocks and the start page of the transfer destination block, are not necessary. The contents of 40 and 50 may be reproduced in the state immediately before the power is shut off.
[0240]
In the flash memory systems 1 and 49 according to the above embodiment, two physical blocks can be assigned to one logical block address (cell). In the flash memory system 39 according to the above embodiment, Although three physical blocks can be assigned to one logical block address, four or more physical blocks may be assigned to one logical block address.
[0241]
In the flash memory system 49 according to the above-described embodiment, a virtual block is configured by physical blocks selected one by one from the flash memory chips 2-0 to 2-3, but a plurality of independent registers are provided. A flash memory chip called a “bank type” divided into banks may be used, and a virtual block may be configured by a plurality of blocks belonging to different banks. If a “bank type” flash memory chip is used, a virtual block can be configured by one flash memory chip.
[0242]
In the flash memory system 1, 39, 49 according to the above embodiment, each block is composed of 32 pages. However, the number of pages constituting each block is not limited to 32. The number may be 16 or 64, for example. The present invention can obtain a more remarkable effect as the number of pages constituting each block increases.
[0243]
In the flash memory systems 1, 39, and 49 according to the above embodiment, when data is written to an empty block, all pages # 0 to ## of the block are independent of the page to which user data is to be written. The corresponding logical block address is stored in the redundant area 26 of 31. However, it is not essential to store the corresponding logical block address in the redundant area 26 of all pages # 0 to # 31. At least the first page (page It is sufficient to write this into the redundant area 26 of # 0) and the last page (page # 31).
[0244]
Further, in the flash memory system 1, 39, 49 according to the above embodiment, the address conversion tables 27, 57 relating to all physical blocks storing data are expanded on the SRAM work area 8. However, it is not essential to expand the address conversion table relating to all these physical blocks, and only a part of them may be expanded. In this case, the storage capacity required for the SRAM work area 8 can be reduced. However, when only the address translation table related to some physical blocks is expanded in this way, it is necessary to update the address translation table every time access to a physical block not included in the address translation table is requested. .
[0245]
In the above embodiment, the flash memory systems 1, 39, and 49 have a card shape, and the four flash memory chips 2-0 to 2-3 and the controller 3 are integrated in one card. However, the flash memory system according to the present invention is not limited to a card shape, and may have another shape, for example, a stick shape.
[0246]
Further, in the above embodiment, the flash memory systems 1, 39 and 49 are configured by integrating the four flash memory chips 2-0 to 2-3 and the controller 3 in one card. The flash memory chips 2-0 to 2-3 and the controller 3 do not have to be integrated in the same casing, and may be packaged in separate casings. In this case, the housing in which the flash memory chips 2-0 to 2-3 are packaged and the housing in which the controller 3 is packaged have connectors for realizing electrical and mechanical connections with the other. With such a connector, the housing in which the flash memory chips 2-0 to 2-3 are packaged is detachably attached to the housing in which the controller 3 is packaged. Furthermore, the flash memory chips 2-0 to 2-3 do not have to be integrated in the same casing, and may be packaged in separate casings.
[0247]
In the flash memory systems 1, 39, and 49 according to the above embodiments, each flash memory chip 2-0 to 2-3 is a semiconductor chip having a storage capacity of 128 Mbytes (1 Gbit). The storage capacity of the flash memory chips 2-0 to 2-3 is not limited to 128 Mbytes (1 Gbit), but may be a different capacity, for example, 32 Mbytes (256 Mbits).
[0248]
Further, in the flash memory systems 1, 39, and 49 according to the above embodiments, 512 bytes are set as one page, which is the minimum access unit. However, the minimum access unit is not limited to 512 bytes and is different from this. It may be a capacity.
[0249]
In the flash memory systems 1, 39, and 49 according to the above-described embodiments, each flash memory cell 16 configuring the flash memory chips 2-0 to 2-3 holds 1-bit data. By controlling the amount of electrons to be injected into the gate electrode 21 in a plurality of stages, data of 2 bits or more may be held.
[0250]
In the flash memory systems 1 and 39 according to the above embodiment, the erased block queue 30 is configured by assigning two queues to the flash memory chips 2-0 to 2-3, respectively. The number of queues assigned to each flash memory chip 2-0 to 2-3 is not limited to two, but may be other numbers, for example, one or eight.
[0251]
Furthermore, in the flash memory systems 1, 39, and 49 according to the above embodiments, a NAND flash memory chip is used as the flash memory chip 2, but the flash memory that can be controlled by the present invention is limited to the NAND type. It is also possible to control other types, for example, an AND type flash memory.
[0252]
In the present invention, the means does not necessarily mean a physical means, but includes cases where the functions of the means are realized by software. Further, the function of one means may be realized by two or more physical means, or the functions of two or more means may be realized by one physical means.
[0253]
The present invention can be realized as a PC card based on a unified standard published by PCMCIA (Personal Computer Memory Card International Association). Furthermore, in recent years, with the development of high integration technology of semiconductor elements, more compact miniaturized memory cards such as “CompactFlash” proposed by CFA (CompactFlash Association) and “MMC (MultiMediaCard)” proposed by MultiMediaCardAssociation. The present invention can be applied to “Memory Stick” proposed by Sony Corporation and “SD Memory Card” proposed by Matsushita Electric Industrial Co., Ltd.
[0254]
【The invention's effect】
As described above, according to the present invention, when data write is requested from the host computer, even if some data is already stored in the block to which the data is to be written, the given data A memory controller capable of performing a series of processes required for writing data at a higher speed and a flash memory system including such a memory controller are provided.
[0255]
In addition, according to the present invention, when a data write is requested from the host computer, it is necessary to write the given data even if some data is already stored in the block to which the data is to be written. A flash memory control method capable of performing a series of processes at a higher speed is provided.
[Brief description of the drawings]
FIG. 1 is a block diagram schematically showing a flash memory system 1 according to a preferred embodiment of the present invention.
FIG. 2 is a cross-sectional view schematically showing the structure of each flash memory cell 16 constituting the flash memory chips 2-0 to 2-3.
FIG. 3 is a cross-sectional view schematically showing a flash memory cell 16 in a write state.
FIG. 4 is a diagram schematically showing a structure of an address space of a flash memory chip 2-0.
5 is a schematic diagram showing a data structure of an address conversion table 27 stored in the SRAM work area 8. FIG.
6 is a schematic diagram showing a data structure of an erased block queue 28 stored in the SRAM work area 8. FIG.
7 is a schematic diagram showing a data structure of an internal variable 30 stored in the SRAM work area 8. FIG.
FIG. 8 is a flowchart for determining the type of write operation;
FIG. 9 is a flowchart showing a new writing operation.
FIG. 10 is a flowchart showing a partial transfer operation.
FIG. 11 is a schematic diagram showing a data storage state of a transfer source block and a transfer destination block in a partial transfer operation.
FIG. 12 is a flowchart showing additional write determination.
FIG. 13 is a schematic diagram showing a data storage state of a transfer source block and a transfer destination block in step S34.
FIG. 14 is a flowchart showing an additional writing operation.
FIG. 15 is a schematic diagram showing a data storage state of a transfer source block and a transfer destination block in an additional write operation.
FIG. 16 is a flowchart showing a completion operation.
FIG. 17 is a schematic diagram illustrating a data storage state of a transfer source block and a transfer destination block in a completion operation.
18 is a schematic diagram showing a data structure of an internal variable 40 stored in the SRAM work area 8. FIG.
FIG. 19 is a flowchart showing additional write determination.
FIG. 20 is a flowchart showing a second partial transfer operation.
FIG. 21 is a schematic diagram showing a data storage state of first to third blocks in a second partial transfer operation;
FIG. 22 is a schematic diagram showing data storage states of first to third blocks in steps S75 to S77.
FIG. 23 is a flowchart showing a second additional write operation.
FIG. 24 is a schematic diagram showing a data storage state of first to third blocks in a second additional write operation.
FIG. 25 is a schematic diagram showing a data storage state of first to third blocks in a second additional write operation.
FIG. 26 is a diagram illustrating an example of virtual block mapping;
FIG. 27 is a diagram showing a virtual page structure of the virtual block shown in FIG. 26;
28 is a schematic diagram showing a data structure of an address conversion table 57. FIG.
29 is a schematic diagram showing a data structure of an erased block queue 58 stored in the SRAM work area 8. FIG.
30 is a schematic diagram showing a data storage state of a transfer source block and a transfer destination block when data is instructed from the host computer 5 to the virtual page 4i + 1 of the virtual block #n. FIG.
[Explanation of symbols]
1 Flash memory system
2-0 to 2-3 flash memory chip
3 Controller
4 Connector
5 Host computer
6 Microprocessor
7 Host interface block
8 SRAM work area
9 buffers
10 Flash memory interface block
11 ECC block
12 Flash sequencer block
13-15 Bus
16 Flash memory cell
17 P-type semiconductor substrate
18 Source diffusion region
19 Drain diffusion region
20 Tunnel oxide film
21 Floating gate electrode
22 Insulating film
23 Control gate electrode
24 channels
25 User area
26 Redundant area
27 Address conversion table
28 Erased block queue
30 internal variables
31 Destination block address storage area
32 Transfer source block address storage area
33 Start page storage area
34 flags
39 Flash memory system
40 internal variables
41 First block address storage area
42 Second block address storage area
43 Third block address storage area
44 Second start page storage area
45 First start page storage area
46 First flag
47 Second flag
49 Flash memory system
50 Internal variables
57 Address conversion table
58 Erased Block Queue

Claims (13)

複数のブロックからなるメモリにアクセスするメモリコントローラであって、
既にデータが格納されている第1のブロックに対応する論理アドレスに対して、新たに新データの書き込みが指示されたことに応答して、前記第1のブロックに格納されているデータの一部を第2のブロックの同じページに転送する第1の手段と、
前記データを前記第2のブロックに書き込む第2の手段と、
前記第1のブロックと前記第2のブロックの対応関係を保持する第3の手段と
前記論理アドレスに対して、さらに、新たに追記データの書き込みが指示されたことに応答して、前記追記データを前記第2のブロックに追加的に書き込み可能か否かを判断する第4の手段と、
前記第4の手段が追加的に書き込み可能であると判断したことに応答して、前記第1のブロックに格納されているデータの一部を前記第2のブロックの同じページに転送するとともに、前記追記データを前記第2のブロックに書き込む第5の手段と、
前記第4の手段が追加的に書き込み不可能であると判断したことに応答して、前記第2のブロック中の全ての空きページに、前記第1のブロックの同じページに格納されているデータを転送する第6の手段と、
前記第2のブロックの全てのページにデータが書き込まれたことに応答して、前記第1のブロックをブロック消去する第7の手段と
を備えたことを特徴とするメモリコントローラ
A memory controller for accessing a memory composed of a plurality of blocks,
A part of the data stored in the first block in response to an instruction to newly write new data to the logical address corresponding to the first block in which data is already stored First means for transferring to the same page of the second block;
Second means for writing the new data into the second block;
Third means for storing relationships between the second block and the first block,
A fourth means for determining whether or not the additional data can be additionally written to the second block in response to a new instruction to write additional data to the logical address. When,
In response to determining that the fourth means is additionally writable, transferring a portion of the data stored in the first block to the same page of the second block; Fifth means for writing the additional data into the second block;
Data stored in the same page of the first block in all empty pages in the second block in response to the determination that the fourth means cannot additionally write A sixth means for transferring
A seventh means for erasing the first block in response to data being written to all pages of the second block;
A memory controller comprising:
前記第1の手段が、前記第1のブロックの先頭ページから前記新データを格納すべきページに対応するページの一つ前のページに格納されているデータを、前記第2のブロックの同じページに転送するように構成されたことを特徴とする請求項1に記載のメモリコントローラ。The first means uses the same page of the second block as the data stored in the page immediately preceding the page corresponding to the page where the new data is to be stored from the first page of the first block. The memory controller according to claim 1, wherein the memory controller is configured to transfer to the memory controller. 前記第3の手段が、さらに、前記第2のブロックの空きページに関する情報を保持し
前記第4の手段が、前記空きページに関する情報に基づき、前記追記データを前記第2のブロックに追加的に書き込み可能か否かを判断するように構成された
ことを特徴とする請求項1または2に記載のメモリコントローラ。
The third means further holds information about empty pages of the second block ;
The fourth means is configured to determine whether or not the additional data can be additionally written to the second block based on the information about the empty page. The memory controller according to claim 1 or 2.
前記第2のブロックにおける前記空きページが、前記第2の手段により前記新データが書き込まれたページの次のページから最終ページまで連続していることを特徴とする請求項3に記載のメモリコントローラ。 4. The memory controller according to claim 3 , wherein the empty pages in the second block are continuous from the next page to the last page of the page in which the new data is written by the second means. . 前記第2のブロックにおける前記追記データを格納するべきページが前記空きページでない場合に、前記第6の手段が、前記第2のブロック中の空きページに前記第1のブロックの同じページに格納されているデータを転送し、その後に、前記第7の手段が、前記第1のブロックに格納されているすべての前記データを消去するように構成されたことを特徴とする請求項1ないし4のいずれか1項に記載のメモリコントローラ。When the page in which the additional data in the second block is to be stored is not the empty page, the sixth means is stored in the same page of the first block as the empty page in the second block. 5. The method of claim 1 wherein the seventh means is configured to erase all the data stored in the first block after the data being transferred is transferred. The memory controller according to any one of the above. さらに、前記第2のブロックにおける前記追記データを格納するべきページが前記空きページでない場合に、前記第2のブロックに格納されているデータの一部を第3のブロックの同じページに転送する第8の手段と、Further, when the page in which the additional data in the second block is to be stored is not the empty page, a part of the data stored in the second block is transferred to the same page in the third block. 8 means,
前記追記データを前記第3のブロックに書き込む第9の手段とを備え、A ninth means for writing the additional data into the third block;
前記第3の手段が、さらに、前記第2のブロックと前記第3のブロックとの対応関係を保持するように構成されたThe third means is further configured to maintain a correspondence relationship between the second block and the third block.
ことを特徴とする請求項1ないし5のいずれか1項に記載のメモリコントローラ。The memory controller according to claim 1, wherein the memory controller is a memory controller.
前記第3の手段が、さらに、前記第3のブロックの空きページに関する情報を保持していることを特徴とする請求項6に記載のメモリコントローラ。The memory controller according to claim 6, wherein the third means further holds information related to an empty page of the third block. さらに、前記追記データの書き込み先のページが、前記第2のブロックにおける空きページ群の先頭ページか否かを判断する第10の手段を備え
前記第10の手段が前記書き込み先のページが前記先頭ページでないと判断したことに 応答して、前記第5の手段が、前記空きページ群の先頭ページから前記追記データの書き込み先の一つ前のページに対応する各ページに、前記第1のブロックの同じページに格納されているデータを転送するように構成された
ことを特徴とする請求項1ないし7のいずれか1項に記載のメモリコントローラ。
And a tenth means for determining whether the page to which the additional data is written is the first page of the empty page group in the second block ;
In response to the determination that the tenth means determines that the write destination page is not the first page, the fifth means determines that the write-once data write destination is immediately before the first page of the empty page group. The data stored in the same page of the first block is transferred to each page corresponding to the page of
The memory controller according to claim 1, wherein the memory controller is a memory controller.
複数のブロックからなるメモリにアクセスするメモリコントローラであって、
前記各ブロックを複数のグループに分類する手段と、
互いに異なるグループに属する複数のブロックを仮想的に結合することにより仮想ブロックを形成する手段と、
前記仮想ブロックを構成する所定のブロックに対して、新たに新データの書き込みが指示されたことに応答して、前記所定のブロックに格納されているデータの一部を他のブロックに転送する手段と、
新たに書き込みが指示された前記新データを前記他のブロックに書き込む手段と、
前記所定のブロックと前記他のブロックの対応関係を保持する手段と、
前記新データの後に、追記データが与えられて、前記所定のブロックに対応する論理アドレスに対して、前記追記データの書き込みが指示されたことに応答して、前記追記データが前記他のブロックに前記追記データを追加的に書き込み可能か否かを判断する手段と、
前記他のブロックに前記追記データが追加的に書き込み可能であると判断されたことに応答して、前記所定のブロックに格納されているデータの一部を前記他のブロックの同じページに転送するとともに、前記追記データを前記他のブロックに書き込む手段と、
前記他のブロックに前記追記データを追加的に書き込み不可能であると判断されたことに応答して、前記他のブロック中の全ての空きページに、前記所定のブロックの同じページに格納されているデータを転送する手段と、
前記他のブロックの全てのページにデータが書き込まれたことに応答して、前記所定のブロックをブロック消去する手段と
を備えたことを特徴とするメモリコントローラ
A memory controller for accessing a memory composed of a plurality of blocks,
Means for classifying each block into a plurality of groups;
Means for forming a virtual block by virtually combining a plurality of blocks belonging to different groups;
Means for transferring a part of data stored in the predetermined block to another block in response to an instruction to newly write new data to the predetermined block constituting the virtual block When,
Means for writing the new data instructed to be newly written into the other block;
Means for storing relationships between the other blocks and the predetermined block,
In response to the fact that additional data is given after the new data and the writing of the additional data is instructed to the logical address corresponding to the predetermined block, the additional data is transferred to the other block. Means for determining whether or not the additional data can be additionally written;
In response to determining that the additional data can be additionally written to the other block, a part of the data stored in the predetermined block is transferred to the same page of the other block. And means for writing the additional data to the other block;
In response to determining that the additional data cannot be additionally written to the other block, all the empty pages in the other block are stored in the same page of the predetermined block. Means for transferring data,
Means for erasing the predetermined block in response to data being written to all pages of the other block;
A memory controller comprising:
請求項1ないし9のいずれか1項に記載のメモリコントローラと、複数のブロックからなるフラッシュメモリと
を備えたことを特徴とするフラッシュメモリシステム。
A flash memory system comprising: the memory controller according to any one of claims 1 to 9; and a flash memory including a plurality of blocks .
前記フラッシュメモリシステムが、同一の筐体に収容されていることを特徴とする請求項10に記載のフラッシュメモリシステム。 The flash memory system according to claim 10, wherein the flash memory system is housed in the same casing. 前記筐体がカード状をなしていることを特徴とする請求項11に記載のフラッシュメモリシステム。The flash memory system according to claim 11, wherein the housing has a card shape . 所定の論理アドレスに対して、新たに新データの書き込みが指示されたことに応答して、アドレス変換テーブル内の前記所定の論理アドレスに対応するブロックを第1のブロックから第2のブロックに変更するステップと、
前記第1のブロックと前記第2のブロックの対応関係を示す変数を作成するステップと、
前記第1のブロックに格納されているデータの一部を第2のブロックに転送するステップと、
前記データを前記第2のブロックに書き込むステップと、
前記所定の論理アドレスに対して、さらに、新たな追記データの書き込みが指示されたことに応答して、前記追記データを前記第2のブロックに追加的に書き込み可能か否かを判断するステップと、
前記追記データを追加的に書き込み可能であると判断したことに応答して、前記第1のブロックに格納されているデータの一部を前記第2のブロックの同じページに転送するとともに、前記追記データを前記第2のブロックに書き込むステップと、
ステップと、
前記追記データを追加的に書き込み可能でないと判断したことに応答して、前記第2の ブロック中の全ての空きページに、前記第1のブロックの同じページに格納されているデータを転送するステップと、
前記第2のブロックの全てのページにデータが書き込まれたことに応答して、前記第1のブロックをブロック消去するステップと
を備えたことを特徴とするフラッシュメモリの制御方法
In response to an instruction to newly write new data to a predetermined logical address, the block corresponding to the predetermined logical address in the address conversion table is changed from the first block to the second block. And steps to
Creating a variable indicating the correspondence between the first block and the second block;
Transferring a portion of the data stored in the first block to a second block;
Writing the new data to the second block;
Determining whether or not the additional data can be additionally written to the second block in response to an instruction to write new additional data to the predetermined logical address; ,
In response to determining that the additional data can be additionally written, a part of the data stored in the first block is transferred to the same page of the second block, and the additional data is written. Writing data into the second block;
Steps,
In response to determining that the additional data cannot be additionally written, transferring the data stored in the same page of the first block to all the empty pages in the second block. When,
Erasing the first block in response to data being written to all pages of the second block;
A method of controlling a flash memory, comprising:
JP2001129160A 2001-04-26 2001-04-26 MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD Expired - Lifetime JP3621051B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2001129160A JP3621051B2 (en) 2001-04-26 2001-04-26 MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2001129160A JP3621051B2 (en) 2001-04-26 2001-04-26 MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD

Publications (2)

Publication Number Publication Date
JP2002324008A JP2002324008A (en) 2002-11-08
JP3621051B2 true JP3621051B2 (en) 2005-02-16

Family

ID=18977727

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2001129160A Expired - Lifetime JP3621051B2 (en) 2001-04-26 2001-04-26 MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD

Country Status (1)

Country Link
JP (1) JP3621051B2 (en)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100437517C (en) * 2004-04-28 2008-11-26 松下电器产业株式会社 Nonvolatile storage device and data write method
EP1746510A4 (en) * 2004-04-28 2008-08-27 Matsushita Electric Ind Co Ltd Nonvolatile storage device and data write method
JP4710274B2 (en) * 2004-08-02 2011-06-29 ソニー株式会社 MEMORY DEVICE, MEMORY DEVICE CONTROL METHOD, AND DATA PROCESSING SYSTEM
WO2007066720A1 (en) 2005-12-09 2007-06-14 Matsushita Electric Industrial Co., Ltd. Nonvolatile memory device, method of writing data, and method of reading out data
US20090307427A1 (en) * 2006-03-31 2009-12-10 Hitachi Ulsi Systems Co., Ltd. Memory card and method of writing data
JP2008152464A (en) * 2006-12-15 2008-07-03 Toshiba Corp Storage device
US20100318723A1 (en) * 2007-02-23 2010-12-16 Masahiro Nakanishi Memory controller, nonvolatile memory device, and nonvolatile memory system
WO2009140112A1 (en) * 2008-05-13 2009-11-19 Rambus Inc. Fractional program commands for memory devices
US9948809B2 (en) 2013-02-01 2018-04-17 Canon Kabushiki Kaisha Image forming apparatus, memory management method for image forming apparatus, and program, using discretely arranged blocks in prioritizing information
CN114089915B (en) * 2017-03-27 2022-12-20 珠海极海半导体有限公司 File additional writing operation method and device based on FLASH memory

Also Published As

Publication number Publication date
JP2002324008A (en) 2002-11-08

Similar Documents

Publication Publication Date Title
JP3905037B2 (en) Memory controller, flash memory system, and flash memory control method
JP4256600B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP3921174B2 (en) Memory controller, flash memory system, and flash memory control method
JP4165990B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND METHOD FOR WRITEING DATA TO FLASH MEMORY
US5953737A (en) Method and apparatus for performing erase operations transparent to a solid state storage system
KR100441587B1 (en) Semiconductor memory device having block alignment function
KR100977899B1 (en) Method and apparatus for effectively enabling an out of sequence write process within a non-volatile memory system
US6172906B1 (en) Increasing the memory performance of flash memory devices by writing sectors simultaneously to multiple flash memory devices
US20010012222A1 (en) Memory controller for flash memory system and method for accessing flash memory device
JPH10124381A (en) Semiconductor storage device
KR20030011230A (en) Non-volatile storage device and rewrite control method thereof
JP3621051B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
WO2006046425A1 (en) Nonvolatile storage device and nonvolatile storage system
KR20020092261A (en) Management Scheme for Flash Memory with the Multi-Plane Architecture
JP4316824B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP4236485B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP4233213B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP4248772B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP4220690B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP3999959B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP2003122630A (en) Memory controller, flash memory system having memory controller, and method for controlling flash memory
JP4042898B2 (en) Memory controller, memory system including the same, and flash memory control method
JP2005190289A (en) Memory controller, flash memory system therewith, and method for controlling flash memory
JP2003337757A (en) Memory controller, flash memory system, and controlling method for the same
JP2007241619A (en) Memory controller, nonvolatile storage device, nonvolatile storage system and data write method

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20040621

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20040727

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20040927

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: 20041109

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20041116

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

Ref document number: 3621051

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20071126

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20081126

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20091126

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20101126

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20111126

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20121126

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20121126

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20131126

Year of fee payment: 9

EXPY Cancellation because of completion of term