Cache programming with backup blocks
By using backup blocks and mapping table mechanisms in NAND flash devices, the problem of data loss in cache programming operations of SSD controllers that lack DRAM is solved, achieving high reliability and performance improvements in data.
Patent Information
- Application Number
- CN202111216689.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2020-12-04
- Filing Date
- 2021-10-19
- Publication Date
- 2024-11-08
- Estimated Expiration
- 2041-10-19
AI Technical Summary
In programming operations of NAND flash devices, SSD controllers lacking DRAM may result in data loss during cache programming operations due to limited internal SRAM storage capabilities, resulting in performance degradation or the need to increase chip size and silicon cost to solve this problem.
The backup block and mapping table mechanism are used to copy data to the target rule block and its mapped backup block during cache programming operations. If a programming error occurs, data can be restored from the backup block to avoid data loss.
Effectively eliminates the risk of data loss due to programming errors, improves the reliability and performance of NAND flash memory devices, and avoids the defects of performance degradation or increased costs.
Smart Images

Figure CN113838511B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the management and implementation of NAND flash memory devices, and in particular to the programming operation of NAND flash memory devices. Background Art
[0002] The development of modern computing systems has been driven in part by the advent of solid-state drives (SSDs), which offer higher speed and latency performance than traditional hard disks. Unlike hard disks, which rely on magnetism to store data, solid-state drives use NAND flash memory devices to achieve data storage. NAND flash memory devices are a family of integrated circuits manufactured through advanced process and assembly technologies that enable multiple layers of memory cells to be stacked vertically into smaller particles and packages, thereby achieving high storage capacity.
[0003] The increase in storage capacity brought about by new NAND flash process technology breakthroughs also leads to a decrease in the reliability of NAND memory cells. For NAND flash devices, the programming operation refers to the operation of writing data to the NAND flash device. And NAND flash devices usually contain bad blocks, including factory bad blocks that are originally defective during the manufacturing process and grown bad blocks that become defective after multiple program and erase (P / E) cycles. As a well-known behavior, NAND memory cells begin to wear out with the increase in the number of P / E cycles, resulting in an increase in error counts and an increase in grown bad blocks.
[0004] NAND flash memory devices generally provide two types of programming operations: regular programming operations and cache programming operations. Both programming operations include receiving data into a cache buffer and moving the data into a data buffer and the NAND memory cell array. The cache programming operation will respond to the SSD controller when the data transfer from the cache buffer to the data buffer is completed. In contrast, the regular programming operation will not respond to the SSD controller until the data transfer to the NAND memory cell array is completed, which requires a long programming time (e.g., tPROG) on the order of several milliseconds.
[0005] Most modern SSD controllers utilize cached programming operations to maximize the performance of writing to NAND Flash devices. With this feature enabled, the SSD controller acknowledges the completion of the write command to the host as soon as it hears from the NAND device that the data has been moved from the cache buffer into the data buffer. However, this approach carries the potential risk of programming errors, where the final operation of writing data to a NAND memory cell may still fail when a particular NAND block is defective and the SSD controller is unaware of it. This is particularly challenging for NAND Flash devices, which grow an increasing number of bad blocks over time.
[0006] To address the aforementioned problem of potential write failures to the NAND memory array in the event of a premature reply to the host, an SSD controller with on-board DRAM can be configured to retain a copy of the data in DRAM until later confirmation that it was successfully written to the NAND memory array. If the NAND reports a programming error, the SSD controller can then simply perform another programming operation on the NAND device with the data from DRAM.
[0007] However, this is a greater challenge for an SSD controller without DRAM because the controller can only retain a small, limited amount of data in its internal SRAM. Write commands from the host may quickly exceed the storage capacity of the internal SRAM while the controller is still waiting for the NAND memory device to slowly acknowledge the limited amount of data stored in the SRAM, causing the SRAM to overflow. As a result, during cache programming operations, the SSD controller without DRAM may not be able to save all temporary data to its internal SRAM, which may lead to catastrophic failures where the data that failed to be saved to the NAND memory is also not restored from the SRAM. Existing solutions that attempt to improve this situation may have to limit the number of cache programming operations using the SSD controller without DRAM, which results in performance degradation. Alternatively, existing solutions may also increase the amount of internal SRAM at the expense of larger chip size and higher silicon cost. Summary of the invention
[0008] The present disclosure provides a non-volatile storage device cache programming operation, which uses backup blocks to eliminate the risk of data loss due to programming errors. A backup block mapping table can be used to store links between regular blocks and backup blocks. During the cache programming operation, data pages are copied to the target regular block and its mapped backup blocks. In the event of a programming error in the target regular block, data is restored from the backup copy at the backup block. In some embodiments, the backup block can use some of the extra physical blocks provided by the over-allocation.
[0009] In an exemplary embodiment, a method is provided, which may include: issuing a first cache programming operation from a storage controller to a non-volatile storage device to write data to a first regular block, writing the data to the first regular block at the non-volatile storage device according to the first cache programming operation, writing a copy of the data to a backup block at the non-volatile storage device, determining that a programming error has occurred when writing the data to the first regular block, declaring a programming error to the storage controller, obtaining a mapping between the first regular block and the backup block from a mapping table by the storage controller, issuing a read operation from the storage controller to the non-volatile storage device to read a copy of the data from the backup block, reading the copy of the data from the backup block, and sending the copy of the data to the storage controller, and issuing a second cache programming operation from the storage controller to the non-volatile storage device to write the data to a second regular block, and marking the first regular block as defective.
[0010] In another exemplary embodiment, a nonvolatile storage system is provided. The nonvolatile storage system may include a nonvolatile storage device and a storage controller coupled to the nonvolatile storage device. The storage controller may be configured to: issue a first cache programming operation to the nonvolatile storage device to write data to a first regular block, receive a programming error from the nonvolatile storage device, obtain a mapping between the first regular block and a backup block from a mapping table, issue a read operation to the nonvolatile storage device to read a copy of the data from the backup block, and issue a second cache programming operation to the nonvolatile storage device to write the data to a second regular block and mark the first regular block as defective. The nonvolatile storage device may be configured to: write the data to the first regular block according to the cache programming operation; write a copy of the data to the backup block; determine that the programming error has occurred when writing the data to the first regular block; declare the programming error to the storage controller; read a copy of the data from the backup block according to the read operation, and send the copy of the data to the storage controller.
[0011] In another exemplary embodiment, a non-transitory machine-readable medium is provided. The non-transitory machine-readable medium may have computer instructions that, when executed by a hardware processor of a storage controller, cause the hardware processor to: issue a first cache programming operation to a non-volatile storage device to write data to a first regular block, receive a programming error from the non-volatile storage device, obtain a mapping between the first regular block and a backup block from a mapping table, issue a read operation to the non-volatile storage device to read a copy of the data from the backup block, and issue a second cache programming operation to the non-volatile storage device to write data to a second regular block and mark the first regular block as defective. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] Figure 1 A nonvolatile storage system according to an embodiment of the present disclosure is schematically shown.
[0013] Figure 2 Data movement in a cache programming operation according to one embodiment of the present disclosure is schematically illustrated.
[0014] Figure 3 is a flow chart of a process for performing a cache program operation in a non-volatile storage system according to one embodiment of the present disclosure. DETAILED DESCRIPTION
[0015] Now, specific embodiments according to the present application will be described in detail with reference to the accompanying drawings. For consistency, the same elements in various figures are represented by the same reference numerals.
[0016] The present disclosure provides systems and methods for cache programming, which use backup blocks to store copies of data of regular blocks being written to non-volatile storage devices. As used herein, a non-volatile storage device can be a computer storage device that can maintain stored information after power failure, and can retrieve the stored information after power failure (closing and reopening). Non-volatile storage devices may include NAND flash memory, NOR flash memory, magnetoresistive random access memory (MRAM), resistive random access memory (RRAM), phase change random access memory (PCRAM), Nano-RAM, etc. NAND flash memory can be used as an example to demonstrate how to implement cache programming operations. However, other types of non-volatile storage devices can be used to implement the technology according to various embodiments of the present disclosure.
[0017] Figure 1A nonvolatile storage system 100 according to one embodiment of the present disclosure is schematically shown. The nonvolatile storage system 100 may include a storage controller 102 and a nonvolatile storage device 104. When the nonvolatile storage system 100 is coupled to a host, the nonvolatile storage system 100 may provide data storage and / or access to stored data for the host. The nonvolatile storage device 104 may be a nonvolatile memory (NVM)-based storage device, such as a NAND device. It should be noted that the nonvolatile storage system 100 may include a plurality of nonvolatile storage devices, and the nonvolatile storage device 104 may be shown as a representative of a plurality of nonvolatile storage devices. The storage controller 102 may include a processor 106 and a memory 108. The processor 106 may be a computer processor, such as, but not limited to, a microprocessor or a microcontroller. The memory 108 may be a non-transitory computer-readable storage medium, such as a DRAM or SRAM, to store computer-executable instructions to be executed by the processor 106.
[0018] In various embodiments, the non-volatile storage device 104 may include more physical blocks than the published capacity (volume). This may be referred to as overprovision (or over-provision). The extra physical blocks may be used for bad block management, garbage collection, and refresh. In some embodiments, the physical blocks in the non-volatile storage device 104 may be classified into regular blocks and backup blocks. Regular blocks may be ordinary physical blocks for storing data, for example, physical blocks in the published capacity. Backup blocks may be used to temporarily store backup data for cache programming operations. For example, a large number of spare blocks provided by overprovision may be redundant blocks and may be used as backup blocks. In one embodiment, when data is written to a regular block for a cache programming operation, a copy of the data may be written to a backup block. In the event that an error occurs when data is written to a regular block, a copy of the data may be obtained and written to another regular block. Therefore, a cache programming operation according to an embodiment of the present disclosure may recover from a programming error without losing data.
[0019] The non-volatile memory device 104 may include one or more chips, and each chip may include one or more planes, each plane having a plurality of physical blocks. In some embodiments, the number of required backup blocks may be much smaller than the number of corresponding regular blocks. A regular block of a plane may have a set of backup blocks to provide data backup. The backup blocks may be kept in a list, and are assigned to the regular blocks in a cyclic manner for the regular blocks of the plane. For example, assuming that there may be M backup blocks (e.g., blocks 0, 1, ..., M-1), the regular blocks of the plane may be assigned to the backup blocks from block 0 to block M-1, and then repeated in a cyclic manner from block 0 again, until all regular blocks may be assigned a backup block. Therefore, the regular blocks may be mapped to the backup blocks in a many-to-one relationship, wherein a plurality of regular blocks are mapped to one backup block.
[0020] The storage controller 102 may implement many techniques to manage backup blocks. For example, in one embodiment, a regular block of the non-volatile storage device 104 may be a multi-bit cell (e.g., a multi-level cell (MLC) or a triple-level cell (TLC), while a backup block may be a single-bit cell (e.g., a single-level cell (SLC)). Due to the many-to-one mapping relationship, a backup block may experience more program / erase (P / E) operations than a regular block, and an SLC cell may provide maximum reliability and durability for P / E operations. In addition, the storage controller 102 may monitor the wear of the backup block by tracking P / E cycles and error counts. In some embodiments, for example, a threshold value of the error count may be set so that further increased errors are no longer correctable. When the error count of a backup block increases to reach a threshold value, the backup block may be deemed to have reached the end of its life, and the storage controller 102 may be configured to retire the backup block (e.g., remove it from a list of backup blocks and a mapping table) and select another block (e.g., an SLC block) to replace the retired backup block.
[0021] Figure 2 Schematically illustrates data movement in a cache programming operation according to one embodiment of the present disclosure. The storage controller 102 may write a data page 202 to the non-volatile storage device 104 in a cache programming operation. The cache programming operation may have a field including a physical address that may identify a target location for storing the data. The target location may be a page 208 within a regular block 206. The data page may be received in a buffer 204 of the non-volatile storage device 104, and the non-volatile storage device 104 may write the data to the page 208 of the regular block 206. The regular block 206 may have a designated backup block 210, and a copy of the data may be written to a page 212 within the backup block 210.
[0022] The buffer 204 may include a cache buffer and a regular buffer. A cache programming operation may respond to the storage controller 102 when data transfer from the cache buffer to the data buffer is completed. In contrast, a regular programming operation may not respond to the storage controller 102 until data transfer to the storage array (e.g., regular block 206) of the non-volatile storage device 104 is completed, which requires a long time tPROG on the order of several milliseconds. By using the backup block 210 to store a copy of the data page 202, even if there is a programming error when writing the data to the regular block 206, a cache programming operation for writing the data page to the page 208 of the regular block 206 can respond to the storage controller 102 when the data transfer from the cache buffer to the data buffer is completed without data loss.
[0023] In some embodiments, for each data page written from the storage controller 102 to the non-volatile storage device 104 through a cache programming operation, the non-volatile storage device 104 may make a copy of the data and write the copy of the data to a backup block m (where m is 0, 1, ..., M-1) in addition to writing the data to a regular block specified in the address of the cache programming operation. The copy of the data may also be referred to as a backup copy of the data.
[0024] In an example implementation, the number of backup blocks in the backup block list may be set to 4 per plane. This is because at a given time when data is written to the storage array of the non-volatile storage device 104, there may be at most 2 additional transfers per plane, one from the storage controller 102 to the cache buffer of the non-volatile storage device 104, and another from the cache buffer of the non-volatile storage device 104 to the data buffer of the non-volatile storage device 104. By having 4 backup blocks per plane, it is ensured that the data in the backup blocks will not be overwritten before a programming error is declared.
[0025] A mapping table can be retained to link backup blocks with regular blocks. The mapping table can record which backup block each regular block is mapped to. In one embodiment, the mapping table can be managed by the storage controller 102 and dynamically updated. In another embodiment, the mapping table can also be managed by the non-volatile storage device 104 and made visible to the storage controller 102. It should be noted that if the non-volatile storage device 104 has multiple planes, then in one embodiment, there can be multiple mapping tables so that each plane can have its own mapping table. In another embodiment, the non-volatile storage device 104 can have a mapping table for all regular blocks. Table 1 shows an exemplary mapping between regular blocks and backup blocks in one embodiment. It should be noted that the left column can include many different blocks, while the right column can include M blocks repeated in a cyclic manner.
[0026]
[0027] Mapping Table 1
[0028] Figure 3 3 is a flow chart of a process 300 for performing a cache programming operation in a non-volatile storage system according to one embodiment of the present disclosure. In box 302, a first cache programming operation may be issued from a storage controller to a non-volatile storage device to write data to a first regular block. In one embodiment, for example, the storage controller 102 may issue a cache programming operation to a non-volatile storage device 104 to write data to a regular block A in the non-volatile storage device 104. In box 304, according to the cache programming operation, data may be written to a first regular block at the non-volatile storage device, and in box 306, a copy of the data may be written to a backup block at the non-volatile storage device. In one embodiment, a copy of the data may be written to backup block 0 mapped to regular block A by mapping from regular block A to backup block 0 as shown in example mapping table one.
[0029] In block 308, it may be determined that a programming error has occurred while writing data to the first regular block, and in block 310, a programming error may be declared to the storage controller. In one embodiment, if no programming errors are reported to regular block A while programming, the cache programming operation may be considered to have completed successfully. However, if any programming errors are reported while writing data to regular block A, the non-volatile storage device 104 may declare the programming error to the storage controller 102.
[0030] In block 312, the storage controller may obtain a mapping between the first regular block and the backup block from a mapping table. In one embodiment, upon receiving a programming error, the storage controller 102 may obtain a mapping between regular block A and backup block 0 from mapping table 1.
[0031] In block 314, a read operation may be issued from the storage controller to the nonvolatile storage device to read a copy of the data from the backup block. In one embodiment, using the mapping information, the storage controller 102 may determine that a copy of the data is stored in backup block 0 and issue a read operation to the nonvolatile storage device 104 to read a copy of the data from backup block 0. In block 316, a copy of the data may be read from the backup block and sent to the storage controller. For example, the nonvolatile storage device 104 may read a copy of the data from backup block 0 and send the copy of the data to the storage controller 104. In block 318, the storage controller may issue a second cache programming operation to the nonvolatile storage device to write the data to the second regular block and mark the first regular block as defective. In one embodiment, using the copy of the data obtained from backup block 0, the storage controller 102 may issue another cache programming operation to write the data to another regular block (e.g., regular block B, which may be mapped to backup block 1 according to mapping table one). At the same time, the storage controller 102 may mark block A as a bad block and remove it from storage use.
[0032] At least a portion of process 300 may be implemented using software (e.g., executable by a computer processor (CPU, GPU, or both)), hardware (e.g., a field programmable gate array (FPGA) or an application specific IC (ASIC)), firmware, or any suitable combination of the three. In one embodiment, for example, the portion of process 300 to be performed by storage controller 102 may be programmed in computer processor executable instructions, stored in a non-transitory machine-readable medium (e.g., memory 108, non-volatile storage device 104, hard drive, CD, DVD, etc.), and executed by processor 102 (e.g., a microprocessor or microcontroller) executing the executable instructions.
[0033] In an exemplary embodiment, a method is provided, which may include: issuing a first cache programming operation from a storage controller to a non-volatile storage device to write data to a first regular block; writing the data to the first regular block at the non-volatile storage device according to the first cache programming operation; writing a copy of the data to a backup block at the non-volatile storage device; determining that a programming error has occurred when writing the data to the first regular block; declaring the programming error to the storage controller; obtaining, by the storage controller, a mapping between the first regular block and the backup block from a mapping table; issuing a read operation from the storage controller to the non-volatile storage device to read a copy of the data from the backup block; reading a copy of the data from the backup block and sending the copy of the data to the storage controller; and issuing a second cache programming operation from the storage controller to the non-volatile storage device to write the data to a second regular block and marking the first regular block as defective.
[0034] In one embodiment, the backup block may include storage cells of single-bit units, and the first regular block and the second regular block may include storage cells of multi-bit units.
[0035] In one embodiment, the method may further include obtaining an error count of the backup block, and, when the error count reaches a threshold, determining that the backup block has reached the end of its life span, and replacing the backup block with a new backup block.
[0036] In one embodiment, replacing the backup block with the new backup block may include updating the backup block in the mapping table to the new backup block.
[0037] In one embodiment, the mapping table may contain four backup blocks that are repeatedly mapped to regular blocks in the plane in a round-robin manner.
[0038] In one embodiment, the mapping table may be managed by a storage controller.
[0039] In one embodiment, the mapping table may be managed by the non-volatile storage device and provided to the storage controller so that the storage controller can obtain the mapping between the first regular block and the backup block.
[0040] In one embodiment, the backup block may be a spare block provided by over-provisioning.
[0041] In another exemplary embodiment, a nonvolatile storage system is provided. The nonvolatile storage system may include a nonvolatile storage device and a storage controller coupled to the nonvolatile storage device. The storage controller may be configured to: issue a first cache programming operation to the nonvolatile storage device to write data to a first regular block, receive a programming error from the nonvolatile storage device, obtain a mapping between the first regular block and a backup block from a mapping table, issue a read operation to the nonvolatile storage device to read a copy of the data from the backup block, and issue a second cache programming operation to the nonvolatile storage device to write the data to a second regular block and mark the first regular block as defective. The nonvolatile storage device may be configured to: write the data to the first regular block according to the cache programming operation; write a copy of the data to the backup block; determine that the programming error has occurred when writing the data to the first regular block; declare the programming error to the storage controller; read a copy of the data from the backup block according to the read operation, and send the copy of the data to the storage controller.
[0042] In one embodiment, the backup block may include storage cells of single-bit units, and the first regular block and the second regular block may include storage cells of multi-bit units.
[0043] In one embodiment, the storage controller may be further configured to obtain an error count of the backup block, determine that the backup block has reached its life span when the error count reaches a threshold, and replace the backup block with a new backup block.
[0044] In one embodiment, replacing the backup block with the new backup block may include updating the backup block in the mapping table to the new backup block.
[0045] In one embodiment, the mapping table may contain four backup blocks that are repeatedly mapped to regular blocks in the plane in a round-robin manner.
[0046] In one embodiment, the mapping table may be managed by a storage controller.
[0047] In one embodiment, the mapping table may be managed by the non-volatile storage device and provided to the storage controller so that the storage controller can obtain the mapping between the first regular block and the backup block.
[0048] In one embodiment, the backup block may be a spare block provided by over-provisioning.
[0049] In another exemplary embodiment, a non-transitory machine-readable medium is provided. The non-transitory machine-readable medium may have computer instructions that, when executed by a hardware processor of a storage controller, cause the hardware processor to: issue a first cache programming operation to a non-volatile storage device to write data to a first regular block, receive a programming error from the non-volatile storage device, obtain a mapping between the first regular block and a backup block from a mapping table, issue a read operation to the non-volatile storage device to read a copy of the data from the backup block, and issue a second cache programming operation to the non-volatile storage device to write data to a second regular block and mark the first regular block as defective.
[0050] In one embodiment, the backup block may include storage cells of single-bit units and is one of the spare blocks provided by over-provisioning, and the first regular block and the second regular block include storage cells of multi-bit units.
[0051] In one embodiment, when executed by a hardware processor of the storage controller, the computer instructions may further cause the hardware processor to: obtain an error count of a backup block, determine that the backup block has reached its lifespan when the error count reaches a threshold, and replace the backup block with a new backup block.
[0052] In one embodiment, the mapping table may be managed by a storage controller, or managed by the non-volatile storage device, and provided to the storage controller for the storage controller to obtain a mapping between the first regular block and the backup block.
[0053] Any disclosed methods and operations may be implemented as computer-executable instructions (e.g., software code of the operations described herein) stored on one or more computer-readable storage media (e.g., non-transitory computer-readable media, such as one or more optical disk media, volatile storage components (e.g., DRAM or SRAM), or non-volatile storage components (e.g., hard disk drives) and executed on a device controller (e.g., firmware executed by an ASIC). Any computer-executable instructions for implementing the disclosed techniques and any data created and used during implementation of the disclosed embodiments may be stored on one or more computer-readable media (e.g., non-transitory computer-readable media).
[0054] Although various aspects and embodiments have been disclosed herein, other aspects and embodiments will be apparent to those skilled in the art. The various aspects and embodiments disclosed herein are for purposes of illustration and are not intended to be limiting, with the true scope and spirit being indicated by the appended claims.
Claims
1. A method, characterized in that include: issuing a first cache programming operation from a storage controller to a non-volatile storage device to write data to a first regular block of the non-volatile storage device; receiving the data from the storage controller to a cache buffer of the non-volatile storage device; transferring the data from the cache buffer to a data buffer of the non-volatile storage device; responding to the storage controller when the transfer of the data from the cache buffer to the data buffer is completed; writing the data from the data buffer into the first regular block, wherein the storage cells in the first regular block are multi-bit cells; Writing the data from the data storage device to a backup block of the non-volatile storage device as a copy of the data, wherein the storage unit in the backup block is a single-bit unit; determining that a programming error has occurred while writing the data to the first regular block; declaring the programming error to the storage controller; The storage controller obtains a mapping between the first regular block and the backup block from a mapping table; issuing a read operation from the storage controller to the non-volatile storage device to read a copy of the data from the backup block; reading a copy of the data from the backup block and sending the copy of the data to the storage controller; and A second cache programming operation is issued from the memory controller to the non-volatile memory device to write the data into a second regular block of the non-volatile memory device and mark the first regular block as defective, wherein the memory cells in the second regular block are multi-bit cells.
2. The method according to claim 1, characterized in that Also includes: An error count of the backup block is obtained, and when the error count reaches a threshold, it is determined that the backup block has reached the end of its life span, and the backup block is replaced with a new backup block.
3. The method according to claim 2, characterized in that Replacing the backup block with the new backup block includes updating the backup block in the mapping table to the new backup block.
4. The method according to claim 1, characterized in that: The mapping table contains four backup blocks that are repeatedly mapped to regular blocks in the plane in a round-robin manner.
5. The method according to claim 1, characterized in that The mapping table is managed by the storage controller.
6. The method according to claim 1, characterized in that The mapping table is managed by the non-volatile storage device and provided to the storage controller, so that the storage controller can obtain the mapping between the first regular block and the backup block.
7. The method according to claim 1, characterized in that The backup block is a spare block provided by over-provisioning.
8. A non-volatile storage system, characterized in that: include: Non-volatile storage devices; and a storage controller coupled to the non-volatile storage device, wherein the storage controller is configured to: issuing a first cache programming operation to the non-volatile memory device to write data to a first regular block of the non-volatile memory device, wherein the memory cells in the first regular block are multi-bit cells; receiving a programming error from the non-volatile storage device; Acquire a mapping between the first regular block and a backup block of the non-volatile storage device from a mapping table, wherein a storage unit in the backup block is a single-bit unit; issuing a read operation to the non-volatile storage device to read a copy of the data from the backup block; and issuing a second cache programming operation to the non-volatile memory device to write the data into a second regular block of the non-volatile memory device and marking the first regular block as defective, wherein the memory cells in the second regular block are multi-bit cells; and Wherein, the non-volatile storage device is configured as: receiving the data from the storage controller to a cache buffer of the non-volatile storage device; transferring the data from the cache buffer to a data buffer of the non-volatile storage device; responding to the storage controller when the transfer of the data from the cache buffer to the data buffer is completed; writing the data from the data buffer into the first regular block; Writing the data from the data storage into the backup block as a copy of the data; determining that the programming error has occurred while writing the data to a first regular block; declaring the programming error to the memory controller; and A copy of the data is read from the backup block and sent to the storage controller.
9. The non-volatile storage system according to claim 8, characterized in that: The storage controller is further configured to obtain an error count of the backup block, and, when the error count reaches a threshold, determine that the backup block has reached the end of its life span, and replace the backup block with a new backup block.
10. The non-volatile storage system according to claim 9, characterized in that: Replacing the backup block with the new backup block includes updating the backup block in the mapping table to the new backup block.
11. The non-volatile storage system according to claim 8, characterized in that: The mapping table contains four backup blocks that are repeatedly mapped to regular blocks in the plane in a round-robin manner.
12. The non-volatile storage system according to claim 8, characterized in that: The mapping table is managed by the storage controller.
13. The non-volatile storage system according to claim 8, characterized in that: The mapping table is managed by the non-volatile storage device and provided to the storage controller, so that the storage controller can obtain the mapping between the first regular block and the backup block.
14. The non-volatile storage system according to claim 8, characterized in that: The backup block is a spare block provided by over-provisioning.
15. A non-transitory machine-readable medium having computer instructions, characterized in that: When executed by a hardware processor of a storage controller, the computer instructions cause the hardware processor to: issuing a first cache programming operation to a non-volatile memory device to write data to a first regular block of the non-volatile memory device, wherein the memory cells in the first regular block are multi-bit cells; wherein the non-volatile memory device is configured to: receive the data from the memory controller to a cache buffer of the non-volatile memory device; transferring the data from the cache buffer to a data buffer of the non-volatile storage device; responding to the storage controller when the transfer of the data from the cache buffer to the data buffer is completed; writing the data from the data buffer into the first regular block; Writing the data from the data storage into a backup block as a copy of the data, wherein the storage unit in the backup block is a single-bit unit; receiving a programming error from the non-volatile storage device; Acquire the mapping between the first regular block and the backup block from the mapping table; issuing a read operation to the non-volatile storage device to read a copy of the data from the backup block; and A second cache programming operation is issued to the non-volatile memory device to write the data into a second regular block of the non-volatile memory device and mark the first regular block as defective, wherein the memory cells in the second regular block are multi-bit cells.
16. The non-transitory machine-readable medium of claim 15, wherein: When executed by a hardware processor of the storage controller, the computer instructions further cause the hardware processor to: obtain an error count of the backup block, and, when the error count reaches a threshold, determine that the backup block has reached its end of life, and replace the backup block with a new backup block.
17. The non-transitory machine-readable medium of claim 15, wherein: The mapping table is managed by the storage controller or the non-volatile storage device and provided to the storage controller for the storage controller to obtain the mapping between the first regular block and the backup block.
