CN107544919B - 数据储存装置的数据储存方法 - Google Patents

数据储存装置的数据储存方法 Download PDF

Info

Publication number
CN107544919B
CN107544919B CN201710035376.XA CN201710035376A CN107544919B CN 107544919 B CN107544919 B CN 107544919B CN 201710035376 A CN201710035376 A CN 201710035376A CN 107544919 B CN107544919 B CN 107544919B
Authority
CN
China
Prior art keywords
data
data storage
storage device
host
storage method
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.)
Active
Application number
CN201710035376.XA
Other languages
English (en)
Other versions
CN107544919A (zh
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.)
Silicon Motion Inc
Original Assignee
Silicon Motion Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Silicon Motion Inc filed Critical Silicon Motion Inc
Publication of CN107544919A publication Critical patent/CN107544919A/zh
Application granted granted Critical
Publication of CN107544919B publication Critical patent/CN107544919B/zh
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0629Configuration or reconfiguration of storage systems
    • G06F3/0634Configuration or reconfiguration of storage systems by changing the state or mode of one or more devices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/28Supervision thereof, e.g. detecting power-supply failure by out of limits supervision
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • G06F12/0238Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • G06F12/0253Garbage collection, i.e. reclamation of unreferenced memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0616Improving the reliability of storage systems in relation to life time, e.g. increasing Mean Time Between Failures [MTBF]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0617Improving the reliability of storage systems in relation to availability
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0619Improving the reliability of storage systems in relation to data integrity, e.g. data losses, bit errors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/0652Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0655Vertical data movement, i.e. input-output transfer; data movement between one or more hosts and one or more storage devices
    • G06F3/0656Data buffering arrangements
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0679Non-volatile semiconductor memory device, e.g. flash memory, one time programmable memory [OTP]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0683Plurality of storage devices
    • G06F3/0685Hybrid storage combining heterogeneous device types, e.g. hierarchical storage, hybrid arrays
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1032Reliability improvement, data loss prevention, degraded operation etc
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/60Details of cache memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/72Details relating to flash memory management
    • G06F2212/7204Capacity control, e.g. partitioning, end-of-life degradation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0653Monitoring storage devices or systems

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Computer Security & Cryptography (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

本发明涉及一种可用于数据储存装置的数据储存方法。在所述的数据储存方法中,当发生电源中断事件时,数据储存装置便依据电荷储存装置的电压准位的记录来判断电荷储存装置是否正常运作,当判断为否时便进入安全操作模式。

Description

数据储存装置的数据储存方法
技术领域
本发明涉及一种数据储存的技术,且特别是关于一种数据储存装置的数据储存方法。
背景技术
一般的数据储存装置主要由控制单元、降压模块、易失性存储器(volatilememory)与非易失性存储器(non-volatile memory)所构成,且控制单元可电性耦接主机(host),例如是电性耦接至计算机或手持式行动装置,并负责与主机进行沟通与数据的传递。在习知的数据储存装置的操作中,控制单元会接收并处理来自于主机的指令,将目标数据写入非易失性存储器中或自非易失性存储器读取目标数据。若主机所传来的是数据量很小的数据,例如是不足一个数据页(page)大小的数据时,那么控制单元就会将此数据先储存在易失性存储器或数据缓冲器中,待数据的大小等于或大于一个数据页大小的时候,再将易失性存储器与数据缓冲器中的数据写入非易失性存储器中以进行储存。除了来自于或提供给主机的数据外,控制单元运作所需的系统数据,例如:地址对应表,亦会储存在易失性存储器中。
一般而言,数据储存装置乃是将主机所提供的外部电源经其降压模块转换成不同电压大小的降压电源,然后再将这些降压电源当作控制单元、易失性存储器与非易失性存储器的操作电源。然而,数据储存装置在运作上可能会遇到电源中断事件,为了避免发生电源中断事件而造成数据储存装置的不当运作,有些制造商在数据储存装置中加入电荷储存装置(或电容),以作为小型的备用电源。当发生电源中断事件时,电荷储存装置能提供短暂的电源使数据储存装置得以顺利地完成指定的任务。
然而,一般而言,电荷储存装置有使用寿命的问题,当使用寿命(lifetime)到期或产品故障时,除非用户更换电荷储存装置或进行故障排除的处置,否则,电荷储存装置将无法发挥预期的功能。然而,目前并无适当的处理机制来处理电荷储存装置使用寿命到期或产生了故障的事件。
此外,数据储存装置亦需要保护机制以保护发生电源中断事件时仍储存于易失性存储器,例如是动态随机存取存储器(dynamic random access memory,DRAM),中的数据或储存于数据缓冲器中的数据。
发明内容
本发明的一目的在提供一种可用于数据储存装置的数据储存方法,其可使数据储存装置在电荷储存装置已无法正常运作时,仍能确保欲写入的数据不会发生遗失。
本发明的另一目的在提供一种可用于数据储存装置的数据储存方法,其可确保数据储存装置处于忙碌状态时,供电给数据储存装置的主机不会强制关机。
本发明的再一目的在提供一种可用于数据储存装置的数据储存方法,其可确保供电给数据储存装置的主机在关机时,数据储存装置可以马上启动数据倾倒程序。
本发明提出一种可用于数据储存装置的数据储存方法,此数据储存方法包括下列步骤:判断是否发生电源中断事件;当发生电源中断事件时,记录电荷储存装置的电压准位,其中此电荷储存装置于电源中断事件时可提供电源至数据储存装置;依据电荷储存装置的电压准位的记录来判断电荷储存装置是否正常运作;以及当判断结果为否时,使数据储存装置进入安全操作模式。
本发明另提出一种可用于数据储存装置的数据储存方法,此数据储存方法包括下列步骤:判断是否自主机接收到中断信息,所述中断信息为主机在其电源开关被切换为断路时所传送;当收到中断信息时,判断数据储存装置是否正处于忙碌状态;以及当判断为真时,使数据储存装置透过GPIO脚位传送上述忙碌状态至主机。
本发明再提出一种可用于数据储存装置的数据储存方法,此数据储存方法包括下列步骤:指派数据暂存区块;判断是否自主机接收到中断信息,此中断信息为主机在其电源开关被切换为断路时所传送;以及当判断为真时,启动数据倾倒程序。
本发明的数据储存装置由于采用上述操作,因此其可在发生电源中断事件时,仍能确保欲写入数据储存装置的数据不会发生遗失,保证了欲写入数据的完整性与正确性。
上述说明仅是本发明技术方案的概述,为了能够更清楚了解本发明的技术手段,而可依照说明书的内容予以实施,并且为了让本发明的上述和其他目的、特征和优点能够更明显易懂,以下特举优选实施例,并配合附图,详细说明如下。
附图说明
图1为绘有依照本发明一实施例的数据储存装置的示意图。
图2为依照本发明一实施例的数据储存方法的流程图。
图3为依照本发明另一实施例的数据储存方法的流程图。
图4绘有PLP电容放电曲线。
图5为依照本发明再一实施例的数据储存方法的流程图。
具体实施方式
图1绘有依照本发明一实施例的数据储存装置的示意图。如图1所示,数据储存装置100系电性耦接主机200。此数据储存装置100包括升压模块110(非必要)、电荷储存装置120、降压模块130、控制单元140、易失性存储器150与非易失性存储器160。其中,升压模块110用于接收主机200所提供的外部电源EP,例如5伏特,并用于提高外部电源EP的电压准位而据以产生升压电源HV,例如12伏特。电荷储存装置120系电性耦接于升压电源HV与参考电位REF之间。此外,降压模块130用于接收升压电源HV,并用于降低其所接收的电源的电压准位而据以产生至少一降压电源。在此例中,降压模块130具有降压电路132、134、136与138,而这些降压电路用于分别产生降压电源V1(例如5伏特)、V2(例如3.3伏特)、V3(例如1.5伏特)与V4(例如1.2伏特)。控制单元140系接收降压电源V1、V2、V3与V4,以将所接收的降压电源当作其内部各构件的操作电源。
用户可使控制单元140将所接收到的降压电源的至少其中之一转传至易失性存储器150与非易失性存储器160,例如将降压电源V3转传至易失性存储器150,并将降压电源V4转传至非易失性存储器160,以将这二个降压电源分别当作易失性存储器150与非易失性存储器160的操作电源。或者,部份降压电源V1、V2、V3与V4可直接提供给易失性存储器150与非易失性存储器160。例如:降压电源V2及V3可直接提供给非易失性存储器160,降压电源V3可直接提供给易失性存储器150,此实施例可降低控制单元140的负担并降低其内部电路大小,其缺点为控制单元140缺乏对易失性存储器150与非易失性存储器160的电源管理的能力。
上述的易失性存储器150例如可采用动态随机存取存储器或静态随机存取存储器(static random-access memory,SRAM)来实现。在另一实施例中,亦可以用数据缓冲器替代易失性存储器150,数据缓冲器系置于控制单元140内部,其缺点为数据储存能力小,其优点为速度快、成本低。上述的非易失性存储器160则例如可采用闪存(flash memory)、磁阻式随机存取存储器(magnetoresistive RAM)、相变内存(phase-change memory)或铁电随机存取存储器(ferroelectric RAM)等具有长时间数据保存的内存装置来实现。
非易失性存储器160包括数据暂存区162、数据储存区164与备用区块(spare datablock)池168。数据储存区164较佳具有多个第一类数据区块(数据区块即所谓的datablock),每一第一类数据区块中的每一储存单元(储存单元即所谓的memory cell)可储存M个位的数据。数据暂存区162具有多个第二类数据区块且每一第二类数据区块中的每一储存单元可储存N个位的数据,其中N与M皆为正整数,且N小于M。数据暂存区162的功能乃是作为数据缓冲区,其具有较快速的数据存取能力,用于暂存来自于主机200的数据。备用区块池168具有多个第一类数据区块,可以用于替换数据储存区164的第一类数据区块。在另一实施例中,备用区块池168更具有多个第二类数据区块,可以用于替换数据暂存区162的第二类数据区块。当发生电源中断事件时,控制单元140会将储存于易失性存储器150的数据倾倒至数据暂存区162的第二类数据区块,或将控制单元140内部的数据缓冲器中所储存的数据倾倒至数据暂存区162的第二类数据区块。
在另一实施例中,非易失性存储器160也可包括数据暂存区162、数据储存区164、数据倾倒(flush)区块166与备用区块池168。此实施例的数据暂存区162、数据储存区164与备用区块池168的功能与上一实施例相同。数据倾倒区块166具有一个第二类数据区块。在正常操作下数据倾倒区块166不提供数据暂存的功能,来自于主机200的数据皆会先储存至数据暂存区162。控制单元140仅有在紧急状态下才会对数据倾倒区块166进行数据的存取,例如:当发生电源中断事件时,控制单元140会将储存于易失性存储器150的数据倾倒至数据倾倒区块166,或将控制单元140内部的数据缓冲器中所储存的数据倾倒至数据倾倒区块166。
第一类数据区块较佳可采用三阶储存单元(triple-level cell,TLC)型态的闪存来实现,并利用软件方式来将部份的第一类数据区块的记忆单元规划成多阶储存单元(multi-level cell,MLC)或单阶储存单元(single level cell,SLC),或切换至MLC或SLC的模式,并成为第二类数据区块。而在另一实施例中,非易失性存储器160可采用多阶储存单元型态的闪存来实现,并利用软件方式来将部份的第一类数据区块的记忆单元规划成单阶储存单元,或切换至SLC的模式,并成为第二类数据区块。在另一实施例中,第一类数据区块为TLC型态的闪存,第二类数据区块为SLC型态的闪存。在另一实施例中,第一类数据区块为MLC型态的闪存,第二类数据区块为SLC型态的闪存。
控制单元140系透过通讯接口170电性耦接主机200,并透过通讯接口170来与主机200进行沟通与传递数据。此通讯接口170例如可采序列式ATA(serial advancedtechnology attachment,SATA)、序列式小型计算机系统接口(serial attached SCSI ,SAS)、高速外围组件互连(peripheral component interconnect express,PCI-E)、通用串行总线(universal serial bus,USB)、M.2(原称为next generation form factor,NGFF)界面、U.2(原称为SFF-8639,small form factor)接口、mSATA(即mini SATA)接口等连接接口来实现。
控制单元140除了可以透过通讯接口170与主机200进行通信之外,控制单元140更可以透过通用输入/输出(general purpose input/output,GPIO)脚位142与主机200进行通信,使控制单元140可以透过GPIO脚位142而传送或接收来自于主机200的数据。其中,GPIO脚位142较佳为通讯接口170的功能保留脚位的其中一,如此一来,通讯接口170无需进行物理上的变更;当然,GPIO脚位142亦可为一个独立于通讯接口170的脚位。GPIO脚位142所传送或接收的数据较佳为中断信息或忙录讯号。一般而言,主机200具有基本输入输出系统(basic input/output system,BIOS)、芯片组(Chipset)202、中央处理器以及外围电子组件。芯片组202可包括北桥和南桥芯片,或是整合北桥和南桥的单芯片。主机200可藉由GPIO脚位142而传送中断信息至控制单元140,例如,当主机200的电源开关被切换为断路(open)或重置开关被按下以重置主机200时,BIOS输出一个中断讯号至芯片组202。当芯片组202侦测到来自于BIOS的中断讯号时,主机200的芯片组202可藉由GPIO脚位142而传送中断信息至控制单元140。此外,主机200于默认时间后,例如2秒后,才执行关机或系统重置程序。
另一方面,数据储存装置100完成系统初始化后则执行本发明的数据储存方法,如图2所示,步骤S202:指派数据暂存区块,例如事先指派数据倾倒区块166或数据暂存区162的第二类数据区块来当作数据暂存区块。步骤S204:控制单元140判断是否从外部,例如主机200,收到中断信息,若判断为真则执行步骤S206。当控制单元140收到此中断信息(即步骤S204的判断结果为是),控制单元140立即启动数据倾倒程序(如步骤S206所示),即将易失性存储器150或控制单元140的内部数据缓冲器所储存的数据复制或搬移至数据倾倒区块166(较佳)或数据暂存区162的第二类数据区块。另外,数据倾倒程序可为一连串的数据写入指令或倾倒指令,使DRAM、SRAM或数据缓冲器所储存的数据写入数据倾倒区块166或数据暂存区162的第二类数据区块。数据倾倒程序较佳具有最高或较高的优先执行权,使得数据可以最快的速度或默认时间内写入数据倾倒区块166或数据暂存区162的第二类数据区块中,完成本发明的数据储存的目的。
图3为本发明的数据储存方法的另一实施例。于步骤S204时,控制单元140在接收到芯片组202传来的中断信息后,会先执行步骤S208:判断控制单元140本身是否正处于忙碌状态(busy state)。当步骤S208的判断结果为是时,例如控制单元140判断其本身正在执行耗损平均(wear leveling)程序或是垃圾收集(garbage collection)程序而呈现忙碌状态时,则执行步骤S210:控制单元140透过GPIO脚位142传送忙录讯号给芯片组202,表示控制单元140正处于忙碌状态而必须暂缓关机或系统重置程序。另外,芯片组202在接收到这样的信息后,亦可进一步透过主机200的屏幕(未绘示)或是喇叭(未绘示)来显示或发出警告信息或警告声给使用者。当控制单元140完成耗损平均或垃圾收集程序之后,即离开忙碌状态之后,立即执行步骤S206来启动数据倾倒程序以完成本发明的数据储存的目的。
由于硬件或软件设计上的差异,当主机200的电源开关被切换为断路(open)或重置开关被按下以重置主机200时,有可能主机200会立即执行关机或系统重置程序,而不是等待一段预设时间再执行关机或系统重置程序。在此例中,控制单元140更包括电压侦测单元144。如图4所示,一般而言,当电荷储存装置120正常运作时,其电压准位的变化与时间将如PLP(power loss protection)电容放电曲线所示。电压侦测单元144可侦测并记录电荷储存装置120的电压准位,使控制单元140可以依据此记录而判断电荷储存装置120是否正常运作。
如图5所示,本发明的数据储存方法的另一实施例包括下列步骤,当外部电源EP中断或消失时(此时步骤S402的判断结果为是),电荷储存装置120仍可短暂地提供控制单元140、易失性存储器150以及非易失性存储器160运作所需的电源。假设电荷储存装置120并无损坏,则其电压准位的变化(此需透过执行步骤S404来进行记录),从电压准位Va(即图4所示的开始进行压降侦测的默认电压准位)降低到电压准位Vb(即图4所示的电压临界值),所需的时间为100ms(即T1与T0的时间差),误差值为10ms;假设电荷储存装置120已损坏或无法正常运作,则其电压准位的变化,从电压准位Va降低到电压准位Vb,所需的时间可能小于误差下限值90ms,例如,仅50ms。因此,当控制单元140依据此记录而判断电荷储存装置120已无法正常运作(此时步骤S406的判断结果为否),此时,控制单元140藉由GPIO脚位142或通讯接口170中所定义的功能保留脚位而传送一备用电源损坏信息至主机200,而控制单元140亦从正常操作模式进入安全操作模式(如步骤S408所示)。
安全操作模式可为无写入快取(write caching)模式。在无写入快取模式下,控制单元140一律将来自于主机200的数据写入数据暂存区162的第二类数据区块中,而不利用易失性存储器150来暂存数据。虽然在无写入快取模式下,数据储存装置100的系统效能比较低落,但是能确保来自于主机200的数据皆已写入至数据暂存区162。
在另一实施例中,安全操作模式可为混合写入快取(hybrid write caching)模式。在混合写入快取模式下,控制单元140限缩易失性存储器150的数据储存量,例如,数据储存量仅为原本的一半,或数据储存量仅为一个数据页的大小。当发生电源中断事件时,控制单元140可在有限的时间及资源下,仍然能够将易失性存储器150的数据复制或搬移至数据倾倒区块166(较佳)或数据暂存区162的数据暂存区块。
在另一实施例中,安全操作模式可为直接写入(write through)模式。在直接写入模式下,控制单元140将来自于主机200的数据同时写入数据暂存区162的第二类数据区块以及易失性存储器150。如此一来,数据储存装置100可提供高速的数据读取速度,又能确保自于主机200的数据皆已写入至数据暂存区块。
图5所示的数据储存方法的另一实施例更包括步骤(未示出):提供侦错日志(debug log)。控制单元140可主动或被动地依据主机200的要求,透过通讯接口170提供侦错日志给主机200。侦错日志较佳为S.M.A.R.T.(self-monitoring analysis andreporting technology,自我监测、分析及报告技术)信息,亦可为任何记录有控制单元140的软件、硬件、发生事件的信息,并记录电荷储存装置120的相关信息,使主机200可以据侦错日志而判断出备用电源损坏或接近损坏。主机200透过其屏幕将判断的结果显示给用户,让用户可以在备用电源损坏或接近损坏时及时进行更换。
综上所述,本发明的数据储存装置可在发生电源中断事件时,仍能确保欲写入数据储存装置的数据不会发生遗失,保证了欲写入数据的完整性与正确性。

Claims (11)

1.一种可用于数据储存装置的数据储存方法,其特征在于,所述数据储存方法包括:
判断是否发生电源中断事件;
当发生所述电源中断事件时,记录电荷储存装置的电压准位,其中所述电荷储存装置于所述电源中断事件时可提供电源至所述数据储存装置;
依据所述电荷储存装置的电压准位的记录来判断所述电荷储存装置是否正常运作;以及
当判断结果为否时,使所述数据储存装置进入安全操作模式,其中所述安全操作模式包括直接写入模式;
其中在所述直接写入模式下,来自于主机的数据同时写入所述数据储存装置的数据暂存区以及易失性存储器。
2.如权利要求1所述的数据储存方法,其特征在于,当所述电荷储存装置的电压准位自默认电压准位降低至电压临界值所需的时间小于误差下限值时,便判断所述电荷储存装置为非正常运作。
3.如权利要求1所述的数据储存方法,其特征在于,所述数据储存方法所述数据储存方法更包括:
当判断结果为否时,透过GPIO脚位传送备用电源损坏信息至主机。
4.如权利要求3所述的数据储存方法,其特征在于,所述GPIO脚位包括通讯接口的功能保留脚位。
5.一种可用于数据储存装置的数据储存方法,其特征在于,所述数据储存方法包括:
判断是否自主机接收到中断信息,所述中断信息为所述主机在其电源开关被切换为断路时所传送;
当收到所述中断信息时,判断所述数据储存装置是否正处于忙碌状态;以及
当判断为真时,使所述数据储存装置透过GPIO脚位传送所述忙碌状态至所述主机;
当所述数据储存装置离开所述忙碌状态后,启动数据倾倒程序,其中所述数据倾倒程序是复制或搬移易失性存储器所储存的数据至所述数据储存装置的数据暂存区块。
6.如权利要求5所述的数据储存方法,其特征在于,当所述数据储存装置正执行耗损平均程序或垃圾收集程序时,便判断所述数据储存装置处于所述忙碌状态。
7.如权利要求5所述的数据储存方法,其特征在于,所述GPIO脚位包括通讯接口的保留脚位。
8.如权利要求5所述的数据储存方法,其特征在于,所述数据储存方法更包括:
指派所述数据暂存区块。
9.如权利要求5所述的数据储存方法,其特征在于,所述数据倾倒程序包括复数数据写入指令或倾倒指令。
10.一种可用于数据储存装置的数据储存方法,其特征在于,所述数据储存方法包括:
指派数据暂存区块;
判断是否自主机接收到中断信息,所述中断信息为所述主机在其电源开关被切换为断路时所传送;以及
当判断为真时,启动数据倾倒程序,其中所述数据倾倒程序是复制或搬移易失性存储器所储存的数据至所述数据储存装置的所述数据暂存区块。
11.如权利要求10所述的数据储存方法,其特征在于,所述数据倾倒程序包括复数数据写入指令或倾倒指令。
CN201710035376.XA 2016-06-23 2017-01-17 数据储存装置的数据储存方法 Active CN107544919B (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US201662353570P 2016-06-23 2016-06-23
USUS62/353,570 2016-06-23

Publications (2)

Publication Number Publication Date
CN107544919A CN107544919A (zh) 2018-01-05
CN107544919B true CN107544919B (zh) 2021-02-05

Family

ID=60676833

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710035376.XA Active CN107544919B (zh) 2016-06-23 2017-01-17 数据储存装置的数据储存方法

Country Status (3)

Country Link
US (2) US10324645B2 (zh)
CN (1) CN107544919B (zh)
TW (1) TWI602115B (zh)

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10705129B2 (en) * 2017-09-13 2020-07-07 Toshiba Memory Corporation Techniques for testing PLP capacitors
DE102018101028B3 (de) * 2018-01-18 2019-05-29 Infineon Technologies Austria Ag Mikrocontrollersystem mit schaltungsinternem Debugger
US10839862B2 (en) 2018-04-25 2020-11-17 Micron Technology, Inc. Cross point array memory in a non-volatile dual in-line memory module
TWI670601B (zh) * 2018-07-30 2019-09-01 慧榮科技股份有限公司 斷電保護方法及系統
TWI688864B (zh) * 2018-08-31 2020-03-21 威剛科技股份有限公司 儲存設備及儲存方法
LU100947B1 (en) * 2018-09-27 2020-03-27 Nanopower As Device connection system and method of operation
KR20210080967A (ko) * 2019-12-23 2021-07-01 에스케이하이닉스 주식회사 컨트롤러 및 컨트롤러의 동작방법
CN111968694A (zh) * 2020-09-07 2020-11-20 湖南国科微电子股份有限公司 一种数据保护装置、存储设备及存储系统
TWI800777B (zh) * 2020-12-15 2023-05-01 宏碁股份有限公司 溫度控制方法與資料儲存系統
US20230072161A1 (en) * 2021-09-07 2023-03-09 Novatek Microelectronics Corp. Method of display control and related display driver circuit and application processor
GB2620445A (en) * 2022-07-08 2024-01-10 Kirintec Ltd Data erasure system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5608684A (en) * 1994-10-13 1997-03-04 Hewlett-Packard Company System and method for RAM power and data backup utilizing a capacitor and ROM
CN101853143A (zh) * 2009-03-31 2010-10-06 S·艾勒特 连接海量存储器设备的分级存储结构
CN102539961A (zh) * 2010-12-20 2012-07-04 矢崎总业株式会社 用于检测绝缘状态检测单元的快速电容器的故障的装置
US9141505B1 (en) * 2012-09-27 2015-09-22 Emc Corporation Adaptive failure survivability in a storage system using save time and data transfer after power loss

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW466394B (en) * 2000-01-04 2001-12-01 Via Tech Inc Terminated circuit module and computer system using the same
US7353305B2 (en) * 2002-06-28 2008-04-01 Brocade Communications Systems, Inc. Apparatus and method for data virtualization in a storage processing device
JP2004110367A (ja) * 2002-09-18 2004-04-08 Hitachi Ltd 記憶装置システムの制御方法、記憶制御装置、および記憶装置システム
US8032787B2 (en) * 2004-09-02 2011-10-04 Intel Corporation Volatile storage based power loss recovery mechanism
US8032688B2 (en) * 2005-06-30 2011-10-04 Intel Corporation Micro-tile memory interfaces
US7692996B2 (en) * 2007-07-30 2010-04-06 Micron Technology, Inc. Method, system, and apparatus for voltage sensing and reporting
US20150378415A1 (en) * 2014-02-05 2015-12-31 Christopher George Back-up power supply systems and methods for use with solid state storage devices
KR102174030B1 (ko) * 2014-05-13 2020-11-05 삼성전자주식회사 불휘발성 메모리 장치를 포함하는 저장 장치 및 그것의 읽기 방법
US8902652B1 (en) * 2014-05-13 2014-12-02 Sandisk Technologies Inc. Systems and methods for lower page writes
US9632562B2 (en) * 2014-11-20 2017-04-25 Qualcomm Incorporated Systems and methods for reducing volatile memory standby power in a portable computing device
TWI569144B (zh) * 2015-02-02 2017-02-01 慧榮科技股份有限公司 資料儲存裝置及其斷電事件判斷方法
US9846468B2 (en) * 2015-06-24 2017-12-19 Xitore, Inc. Apparatus, system, and method of storage and retrieval of local volatile memory content of non-volatile storage memory
US20170091042A1 (en) * 2015-09-25 2017-03-30 Quanta Computer Inc. System and method for power loss protection of storage device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5608684A (en) * 1994-10-13 1997-03-04 Hewlett-Packard Company System and method for RAM power and data backup utilizing a capacitor and ROM
CN101853143A (zh) * 2009-03-31 2010-10-06 S·艾勒特 连接海量存储器设备的分级存储结构
CN102539961A (zh) * 2010-12-20 2012-07-04 矢崎总业株式会社 用于检测绝缘状态检测单元的快速电容器的故障的装置
US9141505B1 (en) * 2012-09-27 2015-09-22 Emc Corporation Adaptive failure survivability in a storage system using save time and data transfer after power loss

Also Published As

Publication number Publication date
TWI602115B (zh) 2017-10-11
TW201800930A (zh) 2018-01-01
US10592143B2 (en) 2020-03-17
US10324645B2 (en) 2019-06-18
US20190258418A1 (en) 2019-08-22
CN107544919A (zh) 2018-01-05
US20170371577A1 (en) 2017-12-28

Similar Documents

Publication Publication Date Title
CN107544919B (zh) 数据储存装置的数据储存方法
US10438669B2 (en) Flash storage device with data integrity protection
US8230161B2 (en) Data backup method for a flash memory and controller and storage system using the same
TWI524183B (zh) 資料寫入方法、記憶體控制電路單元與記憶體儲存裝置
KR102602990B1 (ko) 전원 공급 장치 및 이를 포함하는 전자 장치
US10860247B2 (en) Data writing method and storage controller
US9443591B2 (en) Storage device out-of-space handling
US10853241B2 (en) Data storing method and data storing apparatus for reducing power consumption in sudden power-off
CN110781029A (zh) 断电保护方法及系统
CN112201284B (zh) 存储器系统及其操作方法
KR20160007988A (ko) 런 타임 배드 셀을 관리하는 스토리지 시스템
CN107357520B (zh) 整理指令处理方法、存储器控制电路单元及其存储装置
US11803307B2 (en) Memory system and operating method thereof
CN113138720B (zh) 数据存储方法、存储器控制电路单元以及存储器存储装置
KR20230134288A (ko) 메모리 시스템 및 그것의 동작 방법
TWI738235B (zh) 用來進行恢復管理的方法以及記憶裝置及其控制器以及電子裝置
CN110442300B (zh) 整理指令记录方法、存储器控制电路单元与存储装置
TWI512623B (zh) 休眠模式啓動方法、記憶體控制電路單元及儲存裝置
CN107451073B (zh) 数据储存方法及发生电源中断事件后的系统初始化的方法
US20240126473A1 (en) Data storage device and method for managing a write buffer
US20240143226A1 (en) Data storage device and method for managing a write buffer
US20220171706A1 (en) Memory system and operating method thereof
KR20150072485A (ko) 데이터 저장 장치 및 그것의 동작 방법

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant