Storage device and data processing method

By introducing a controller into the storage device, the problem of data loss in NAND products is solved and data reliability and integrity are improved by classifying and performing corresponding operations based on the data instruction error correction values ​​of the storage blocks.

WO2025251306A1PCT designated stage Publication Date: 2025-12-11SHANGHAI LONGSYS DIGITAL TECH CO LTD
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/098234
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Filing Date
2024-06-07
Publication Date
2025-12-11

AI Technical Summary

Technical Problem

When writing data to NAND products, due to process reasons, some blocks may fail to program or read data, resulting in the loss of host data.

Method used

By introducing a controller into the storage device, storage blocks are classified into different types based on their data instruction error correction values. The first type of storage block is used for write data operations, and the second type is used for data refresh and garbage collection operations. This identifies and processes potentially risky blocks, reducing the risk of data loss.

Benefits of technology

By classifying operation sets, the data reliability of NAND products is improved, the risk of data loss is reduced, and data integrity is ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024098234_11122025_PF_FP_ABST
    Figure CN2024098234_11122025_PF_FP_ABST
Patent Text Reader

Abstract

Disclosed in the present application is a storage device. The storage device is connected to a host device and comprises: at least one storage block, and a controller connected to each of the at least one storage block and connected to the host device. The controller is used for: in response to a read instruction received from the host device, performing a data read operation on any one of the at least one storage block; in response to an instruction error correction value of data in the storage block meeting a preset condition when the data read operation is performed on the storage block, determining the storage block to be a first-type storage block, wherein the first-type storage block is used for a first operation set; and in response to the instruction error correction value of the data in the storage block not meeting the preset condition, determining the storage block to be a second-type storage block, wherein the second-type storage block is used for a second operation set. Further disclosed in the present application is a data processing method. The present application reduces the risk of data loss in NAND products and improves data reliability.
Need to check novelty before this filing date? Find Prior Art

Description

Storage device and data processing method TECHNICAL FIELD

[0001] The disclosed embodiments of the present application relate to the technical field of flash memory, and more particularly, to a storage device and a data processing method. BACKGROUND

[0002] When writing data, a NAND product issues data from a host to a NAND device, and the NAND device caches the data from the host into a master buffer register (SRAM buffer). When the data reaches a certain amount, the NAND device issues the relevant data to the NAND for writing, and clears the data in the master buffer register. Due to process reasons, some blocks (Block) in the NAND may have program status fail (PSF) or uncorrectable error correction code (UECC). However, many consumer-level masters (DRAM-Less) immediately clear the data from the host after issuing the data to the NAND. At this time, due to the occurrence of PSF or UECC, the data is not completely written into the NAND, resulting in loss of the data from the host.

[0003] SUMMARY

[0004] According to embodiments of the present application, a storage device and a data processing method are provided to solve the above problems.

[0005] A first aspect of the present application discloses a storage device connected with a host device, comprising: at least one storage block; and a controller connected with each of the at least one storage block and connected with the host device; wherein the controller is configured to: perform a read data operation from any one of the at least one storage block in response to a read instruction received from the host device; determine the storage block as a first type storage block in response to a condition that an instruction error correction value of the data in the storage block during the read data operation from the storage block satisfies a preset condition, wherein the first type storage block is used for a first operation set; and determine the storage block as a second type storage block in response to a condition that the instruction error correction value of the data in the storage block does not satisfy the preset condition, wherein the second type storage block is used for a second operation set.

[0006] In some embodiments, the first operation set includes a write data operation with the host device.

[0007] In some embodiments, the second operation set includes a data refresh operation and / or a data garbage collection operation.

[0008] In some embodiments, the controller is further configured to perform, in response to the storage block being determined as the first type of storage block, a write data operation on the storage block with the host device, and perform, in response to the storage block being determined as the second type of storage block, the data refresh operation and / or the data garbage collection operation on the storage block.

[0009] In some embodiments, the controller is further configured to perform, after completion of the data refresh operation and / or the data garbage collection operation, a data verification operation on the storage block, and release the storage block in response to passing of the data verification.

[0010] In some embodiments, the controller is further configured to perform, in response to correct data writing of the storage block when performing the write data operation on the storage block, other operations in the first set of operations on the storage block, and mark the storage block as unusable storage block in response to incorrect data writing of the storage block when performing the write data operation on the storage block.

[0011] In some embodiments, the write data operation with the host device comprises receiving a write instruction from the host device, and performing the write data operation on the storage block in response to the write instruction.

[0012] The second aspect of the present application discloses a data processing method, comprising: being applied to the storage device as described in the first aspect, the storage device being connected with a host device, and the method comprising: performing a read data operation on any one of the at least one storage block in response to a read instruction received from the host device; determining the storage block as a first type of storage block in response to an instruction error correction value of data in the storage block satisfying a preset condition when performing the read data operation on the storage block, wherein the first type of storage block is used for a first set of operations; and determining the storage block as a second type of storage block in response to the instruction error correction value of data in the storage block not satisfying the preset condition, wherein the second type of storage block is used for a second set of operations.

[0013] The third aspect of the present application discloses a data processing method, being applied to a host device, the host device being connected with a storage device as described in the first aspect, and the method comprising: the host device issuing a read instruction to the storage device, so that the storage device performs the data processing method as described in the second aspect.

[0014] In some embodiments, the host device issues a write instruction to the storage device, so that the storage device performs a write data operation on a first type of storage block in the storage device in response to the write instruction, and marks the storage block as unusable storage block in response to incorrect data writing of the first type of storage block when performing the write data operation on the first type of storage block.

[0015] The application has the beneficial effect that a storage device is connected with a host device, the storage device comprises at least one storage block and a controller, wherein the controller is connected with each of the at least one storage block and connected with the host device, the controller is configured to determine a first type storage block in response to that a preset condition is met by an instruction error correction value of data in the storage block when a read data operation is performed on the storage block, and determine a second type storage block in response to that the preset condition is not met by the instruction error correction value of the data in the storage block, wherein the first type storage block is used for a first operation set, and the second type storage block is used for a second operation set, that is, by classifying the storage blocks, different types of storage blocks correspond to different operation sets, so that the risk of data loss of the NAND product is reduced, and the data reliability of the product is improved. BRIEF DESCRIPTION OF DRAWINGS

[0016] The application will be further described below in conjunction with the drawings and embodiments, wherein:

[0017] Fig. 1 is a structural schematic diagram of a storage device according to an embodiment of the application;

[0018] Fig. 2 is a flow schematic diagram of a data processing method according to an embodiment of the application;

[0019] Fig. 3 is a flow schematic diagram of a data processing method according to another embodiment of the application;

[0020] Fig. 4 is a flow schematic diagram of reading data according to an embodiment of the application;

[0021] Fig. 5 is a flow schematic diagram of writing data according to an embodiment of the application. DETAILED DESCRIPTION

[0022] Reference in the specification to "an embodiment" or "the embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment of the application. The appearances of the phrase "in an embodiment" or "in the embodiment" in various places in the specification are not necessarily all referring to the same embodiment, nor are they necessarily mutually exclusive of one another.

[0023] The term "and / or", in this application, merely describes an associated relationship with the associated objects, which means that there can be three relationships, for example, A and / or B can represent the following three cases: A exists alone, A and B exist together, and B exists alone. In addition, the character " / " in this application generally represents an "or" relationship between the front and rear associated objects. In addition, "multiple" in this application means two or more than two. In addition, the term "at least one" in this application means any one of multiple or any combination of at least two of multiple, for example, including at least one of A, B and C can mean including any one or more elements selected from the set consisting of A, B and C. In addition, the terms "first", "second", "third" in this application are only for description purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features.

[0024] In order for those skilled in the art to better understand the technical solutions of the present application, the technical solutions of the present application will be further described in detail below in combination with the drawings and specific embodiments.

[0025] Please refer to FIG. 1, which is a structural schematic diagram of a storage device according to an embodiment of the present application. The storage device 10 is connected with a host device 20. Specifically, the storage device 10 comprises at least one storage block 110 and a controller 120, wherein the controller 120 is connected with each of the at least one storage block 110 and is connected with the host device 20.

[0026] The controller 120 is configured to perform a read data operation from any one of the at least one storage block 110 in response to a read instruction received from the host device 20. In response to receiving a read instruction sent from the host device 20, the controller 120 performs a read data operation from any one of the at least one storage block 110.

[0027] The controller 120 is configured to determine the storage block as a first type storage block in response to the instruction error correction value of the data in the storage block satisfying a preset condition when performing the read data operation from the storage block, wherein the first type storage block is used for a first operation set. For example, the preset condition is that the instruction error correction value of the data in the storage block is less than a preset instruction error correction value X, and the instruction error correction value of the data in the storage block satisfies the preset condition when performing the read data operation from the storage block, i.e. the instruction error correction value of the data in the storage block is less than X when performing the read data operation from the storage block, then the storage block is determined as a first type storage block, for example, as a class A Block. The first type storage block can be understood as a normal operation block, which is used for the first operation set. The first operation set includes data processing operations interacting with the host device 20, etc.

[0028] The controller 120 is configured to determine the storage block as a second type storage block in response to the instruction error correction value of the data in the storage block not satisfying a preset condition, wherein the second type storage block is used for a second operation set, for example, the preset condition is that the instruction error correction value of the data in the storage block is less than a preset instruction error correction value X, and the instruction error correction value of the data in the storage block does not satisfy the preset condition when a read data operation is performed on the storage block, that is, the instruction error correction value of the data in the storage block is greater than or equal to X when the read data operation is performed on the storage block, and the storage block is determined as the second type storage block, for example, a B type Block. The second type storage block can be understood as a potential risk bad block, and is only used for the second operation set. Understandably, if the existence of the potential risk bad block cannot be determined, PSF or UECC may occur, causing data not to be completely written into the NAND, which may result in Host data loss.

[0029] In the embodiment, the storage device 10 is connected with the host device 20. Specifically, the storage device 10 includes at least one storage block 110 and a controller 120, wherein the controller 120 is connected with each of the at least one storage block 110 and is connected with the host device 20. The controller 120 is configured to determine the storage block as a first type storage block in response to the instruction error correction value of the data in the storage block satisfying a preset condition when a read data operation is performed on the storage block, and determine the storage block as a second type storage block in response to the instruction error correction value of the data in the storage block not satisfying the preset condition, wherein the first type storage block is used for a first operation set, and the second type storage block is used for a second operation set, that is, different types of storage blocks correspond to different operation sets. That is, by effectively identifying the potential risk block in the NAND, the risk of product data loss is reduced, and the data reliability of the NAND product is improved.

[0030] In some embodiments, the first operation set includes a write data operation with the host device 20.

[0031] The controller 120 is configured to determine the storage block as a first type storage block in response to the instruction error correction value of the data in the storage block satisfying a preset condition when a read data operation is performed on the storage block, and determine the storage block as a second type storage block in response to the instruction error correction value of the data in the storage block not satisfying the preset condition, wherein the first type storage block is used for a first operation set, and the second type storage block is used for a second operation set, wherein the first operation set includes a write data operation with the host device 20, for example, the first operation set includes a data processing operation related to the host device 20, such as a write data operation, an operation corresponding to a related firmware algorithm, and the like, that is, the first type storage block participates in performing a write data operation, a related operation corresponding to a firmware algorithm, and the like.

[0032] In some embodiments, the second operation set includes a data refresh operation and / or a data garbage collection operation.

[0033] The controller 120 is further configured to determine the storage block as a second type storage block in response to the instruction error correction value of the data in the storage block not satisfying a preset condition when performing a read data operation from the storage block, for example, the preset condition is that the instruction error correction value of the data in the storage block is less than a preset instruction error correction value, the preset instruction error correction value is X, if the instruction error correction value of the data in the storage block B2 is greater than or equal to X when performing a read data operation from the storage block B1, the storage block B1 is determined as a second type storage block, the second type storage block is only used for a second operation set, wherein the second operation set includes a data refresh operation (refresh) and / or a data garbage collection operation (Garbage Collection, GC), that is, the second type storage block participates in performing the data refresh operation and / or the data garbage collection operation, for example, the storage block B1 only participates in performing the data refresh operation and / or the data garbage collection operation.

[0034] It can be understood that the second operation set and the first operation set can be completely different or partially different. Specifically, the second operation set and the first operation set can be completely different, that is, the first operation set includes a write data operation, for example, a write data operation, an operation corresponding to a related firmware algorithm, etc. with the host device 20, but does not include a data refresh operation and / or a data garbage collection operation, and the second operation set only includes the data refresh operation and / or the data garbage collection operation, that is, the second operation set does not include the write data operation, for example, the second operation set does not include a data processing operation related to the interaction with the host device 20, that is, the second type storage block does not participate in performing the write data operation, the operation corresponding to the related firmware algorithm, etc., so that the second operation set is completely different from the first operation set; or the second operation set and the first operation set can be partially different, that is, the first operation set includes a write data operation, for example, a write data operation, an operation corresponding to a related firmware algorithm, etc. with the host device 20, and also includes a data refresh operation and / or a data garbage collection operation, and the second operation set only includes the data refresh operation and / or the data garbage collection operation, that is, the second operation set does not include the write data operation, for example, the second operation set does not include a data processing operation related to the interaction with the host device 20, that is, the second type storage block does not participate in performing the write data operation, the operation corresponding to the related firmware algorithm, etc., so that the second operation set is partially different from the first operation set, that is, the first operation set can include the second operation set.

[0035] For example, in response to the instruction error correction value of the data in the storage block A1 satisfying the preset condition when a read data operation is performed from the storage block A1, the storage block A1 is determined as a first type storage block, and then the storage block A1 is used for a first operation set, and the first operation set includes a write data operation of the host device 20; in response to the instruction error correction value of the data in the storage block B1 not satisfying the preset condition, the storage block B1 is determined as a second type storage block, and then the storage block B1 is used for a second operation set, and the second operation set does not include the write data operation of the host device 20, that is, the second type storage block does not participate in the execution of the write data operation, the operation corresponding to the related firmware algorithm, and the like, thereby reducing the risk of data loss caused by programming failure when the Host data is written.

[0036] In some embodiments, the controller 120 is further configured to perform, in response to the storage block being determined as the first type storage block, a write data operation of the host device 20 on the storage block, and perform, in response to the storage block being determined as the second type storage block, a data refresh operation and / or a data garbage collection operation on the storage block.

[0037] In response to the instruction error correction value of the data in the storage block satisfying the preset condition when a read data operation is performed from the storage block, the storage block is determined as a first type storage block, and in response to the storage block being determined as the first type storage block, a write data operation of the host device 20 is performed on the storage block, for example, in response to the instruction error correction value of the data in the storage block A1 being less than a preset instruction error correction value X when a read data operation is performed from the storage block A1, the storage block A1 is determined as a first type storage block, and then a write data operation of the host device 20 can be performed on the storage block A1; in response to the instruction error correction value of the data in the storage block not satisfying the preset condition when a read data operation is performed from the storage block, the storage block is determined as a second type storage block, and in response to the storage block being determined as the second type storage block, a data refresh operation and / or a data garbage collection operation is performed on the storage block, for example, in response to the instruction error correction value of the data in the storage block B1 being greater than or equal to the preset instruction error correction value X when a read data operation is performed from the storage block B1, the storage block B1 is determined as a second type storage block, and then a data refresh operation and / or a data garbage collection operation can be performed on the storage block B1.

[0038] In some embodiments, the controller 120 is further configured to perform, in response to the storage block being determined as the first type storage block, a write data operation of the host device 20 on the storage block, and perform, in response to the storage block being determined as the second type storage block, a data refresh operation and / or a data garbage collection operation on the storage block.

[0039] For example, when the instruction correction value of the data in the storage block B1 is greater than or equal to the preset instruction correction value X during the read data operation from the storage block B1, the storage block B1 is determined as the second type of storage block, the data refresh operation and / or the data garbage collection operation can be performed on the storage block B1, after the data refresh operation and / or the data garbage collection operation is completed, the data verification operation is performed on the storage block, and in response to the data verification passing, the storage block is released, for example, after the data refresh operation and / or the data garbage collection operation is performed on the storage block B1, the data verification operation is performed on the storage block B1, and in response to the data verification passing, the storage block B1 is released, that is, the space of the data source storage block B1 is released after the data is written correctly.

[0040] In some embodiments, the controller 120 is further configured to, in response to the data being written correctly in the storage block during the write data operation on the storage block, performing other operations in the first operation set on the storage block, and in response to the data being written incorrectly in the storage block during the write data operation on the storage block, marking the storage block as an unusable storage block.

[0041] For example, when the instruction correction value of the data in the storage block A1 is less than the preset instruction correction value X during the read data operation from the storage block A1, the storage block A1 is determined as the first type of storage block, the write data operation with the host device 20 is performed on the storage block A1, in response to the data being written correctly in the storage block during the write data operation on the storage block, performing other operations in the first operation set on the storage block, that is, in response to the data being written correctly in the storage block A1 during the write data operation on the storage block A1, performing other operations in the first operation set on the storage block A1, such as related operations corresponding to the firmware algorithm, etc.; in response to the data being written incorrectly in the storage block during the write data operation on the storage block, marking the storage block as an unusable storage block, that is, in response to the data being written incorrectly in the storage block A1 during the write data operation on the storage block A1, marking the storage block A1 as an unusable storage block, and the storage block A1 no longer participates in the execution of the data processing operation related to the interaction with the host device 20.

[0042] In some embodiments, the write data operation with the host device 20 includes: receiving a write instruction from the host device 20, and in response to the write instruction, performing the write data operation on the storage block.

[0043] The controller 120 is configured to determine the storage block as a first type storage block in response to the instruction error correction value of the data in the storage block satisfying a preset condition when performing the read data operation on the storage block, and determine the storage block as a second type storage block in response to the instruction error correction value of the data in the storage block not satisfying the preset condition, the first type storage block is used for a first operation set, and the second type storage block is used for a second operation set, wherein the first operation set includes a write data operation of the host device 20, for example, the first operation set includes a data processing operation related to the host device 20, and the second operation set does not include the write data operation of the host device 20, wherein the write data operation of the host device 20 includes receiving a write instruction from the host device 20, and performing the write data operation on the storage block in response to the write instruction, for example, when performing the read data operation on the storage block A1, the instruction error correction value of the data in the storage block A1 is less than a preset instruction error correction value X, and the storage block A1 is determined as the first type storage block, and the write data operation is performed on the storage block A1 in response to receiving the write instruction from the host device 20.

[0044] Referring to FIG. 2, FIG. 2 is a flowchart of a data processing method according to an embodiment of the present application. The execution subject of the method can be the storage device 10 described above, and the storage device 10 is connected with the host device 20. Specifically, the storage device 10 includes at least one storage block 110 and a controller 120, wherein the controller 120 is connected with each of the at least one storage block 110, and is connected with the host device 20. It should be noted that the method of the present application is not limited to the order of the flowchart shown in FIG. 2 if there is substantially the same result.

[0045] In some possible implementation manners, the method can be implemented by a processor invoking computer readable instructions stored in a memory. As shown in FIG. 2, the method can include the following steps:

[0046] S21: performing a read data operation on any one of the at least one storage block in response to a read instruction received from the host device.

[0047] In response to the read instruction received from the host device 20, a read data operation is performed on any one of the at least one storage block 110, and in response to receiving the read instruction sent from the host device 20, the controller 120 performs a read data operation on any one of the at least one storage block 110.

[0048] S22: determining the storage block as a first type storage block in response to the instruction error correction value of the data in the storage block satisfying a preset condition when performing the read data operation on the storage block, wherein the first type storage block is used for a first operation set.

[0049] In response to the instruction error correction value of the data in the storage block satisfying a preset condition when a read data operation is performed on the storage block, the storage block is determined as a first type storage block, wherein the first type storage block is used for a first operation set, for example, the preset condition is that the instruction error correction value of the data in the storage block is less than a preset instruction error correction value X, and when the read data operation is performed on the storage block, the instruction error correction value of the data in the storage block satisfies the preset condition, i.e., the instruction error correction value of the data in the storage block is less than X, the storage block is determined as the first type storage block, for example, as a class A Block, and the first type storage block can be understood as a normal operation block, which is used for the first operation set, and the first operation set includes a data processing operation interacting with the host device 20.

[0050] S23: In response to the instruction error correction value of the data in the storage block not satisfying a preset condition, the storage block is determined as a second type storage block, wherein the second type storage block is used for a second operation set.

[0051] In response to the instruction error correction value of the data in the storage block not satisfying a preset condition, the storage block is determined as a second type storage block, wherein the second type storage block is used for a second operation set, wherein the second operation set is different from the first operation set, for example, the preset condition is that the instruction error correction value of the data in the storage block is less than a preset instruction error correction value X, and when the read data operation is performed on the storage block, the instruction error correction value of the data in the storage block does not satisfy the preset condition, i.e., the instruction error correction value of the data in the storage block is greater than or equal to X, the storage block is determined as the second type storage block, for example, as a class B Block, and the second type storage block can be understood as a potential risk bad block, which is used for the second operation set, and the data operation corresponding to the second operation set is different from the data operation corresponding to the first operation set.

[0052] Referring to FIG. 3, FIG. 3 is a flowchart of a data processing method according to another embodiment of the present application, which can be applied to the host device 20 described above, and the host device 20 is connected with the storage device 10. It should be noted that the method of the present application is not limited to the order of the flowchart shown in FIG. 3 if there is substantially the same result.

[0053] In some possible implementations, the method can be implemented by a processor invoking computer readable instructions stored in a memory, as shown in FIG. 3, the method can include the following steps:

[0054] S31: The host device issues a read instruction to the storage device, so that the storage device performs the above-mentioned data processing method.

[0055] The host device 20 issues a read instruction to the storage device 10, so that the storage device 10 performs the above-mentioned data processing method. Specifically, the storage device 10 performs a read data operation from any one of the at least one storage block 110 in response to the read instruction received from the host device 20; determines the storage block as a first type storage block in response to the instruction error correction value of the data in the storage block satisfying a preset condition when the read data operation is performed from the storage block, wherein the first type storage block is used for a first operation set; and determines the storage block as a second type storage block in response to the instruction error correction value of the data in the storage block not satisfying the preset condition, wherein the second type storage block is used for a second operation set, and the second operation set is partially different from the first operation set.

[0056] Further, in some embodiments, the host device 20 issues a write instruction to the storage device 10, so that the storage device 10 performs a write data operation on the first type storage block in the storage device 10 in response to the write instruction, and marks the storage block as an unusable storage block in response to the data write being incorrect in the first type storage block when the write data operation is performed on the first type storage block.

[0057] The storage device 10 performs a write data operation on the first type storage block in the storage device 10 in response to the write instruction, and the instruction error correction value of the data in the storage block A1 is less than the preset instruction error correction value X when the read data operation is performed from the storage block A1, so that the storage block A1 is determined as the first type storage block. The write data operation is performed on the storage block A1 with the host device 20, and other operations in the first operation set are performed on the storage block in response to the data write being correct in the storage block when the write data operation is performed on the storage block, i.e., the data write is correct in the storage block A1 when the write data operation is performed on the storage block A1, and other operations in the first operation set are performed on the storage block A1, such as related operations corresponding to the firmware algorithm, etc. The storage block is marked as an unusable storage block in response to the data write being incorrect in the first type storage block when the write data operation is performed on the first type storage block, i.e., the data write is incorrect in the storage block A1 when the write data operation is performed on the storage block A1, and the storage block A1 is marked as an unusable storage block. The storage block A1 no longer participates in the execution of the data processing operation related to the interaction with the host device 20.

[0058] For ease of understanding, the read data is exemplified in the present application. As shown in FIG. 4, FIG. 4 is a flow diagram of the read data of the embodiment of the present application. When the host device 20 initiates a data read command, the controller 120 performs a read data operation from any one of the at least one storage block 110 in response to the read instruction received from the host device 20. The specific steps are as follows:

[0059] S41: Determine whether the instruction error correction value of the data in the storage block meets a preset condition, for example, the preset condition is that the instruction error correction value of the data in the storage block is less than a preset instruction error correction value X.

[0060] One of the determination results of step S41 is that the instruction error correction value of the data in the storage block meets the preset condition, and then step S42 is performed, for example, the instruction error correction value of the data in the storage block is less than the preset instruction error correction value X.

[0061] The other of the determination results of step S41 is that the instruction error correction value of the data in the storage block does not meet the preset condition, and then step S43 is performed, for example, the instruction error correction value of the data in the storage block is greater than or equal to the preset instruction error correction value X.

[0062] S42: Determine that the storage block is a first type storage block. The first type storage block is used for a first operation set.

[0063] S43: Determine that the storage block is a second type storage block. The second type storage block is used for a second operation set.

[0064] For the convenience of understanding, the data writing of the present application is exemplified, as shown in FIG. 5, which is a flow diagram of the data writing of an embodiment of the present application. When the host device 20 initiates a data writing command, the storage device 10 responds to the write instruction and performs a data writing operation on the storage block in the storage device 10, and the specific steps are as follows:

[0065] S51: Determine whether the storage block is a first type storage block.

[0066] One of the determination results of step S51 is that the storage block is a first type storage block, and step S52 is performed.

[0067] The other of the determination results of step S51 is that the storage block is not a first type storage block, and step S53 is performed.

[0068] S52: Perform the data writing operation. In response to the storage block being determined as a first type storage block, perform the data writing operation with the host device 20 on the storage block.

[0069] S53: Do not participate in performing the data writing operation.

[0070] S54: Determine whether the data writing is correct.

[0071] One of the determination results of step S54 is that the data writing is correct, and step S55 is performed.

[0072] The other of the determination results of step S54 is that the data writing is incorrect, and step S56 is performed.

[0073] S55: Perform other operations in the first operation set.

[0074] S56: mark the storage block as unusable storage block. That is, in response to the data write of the first type storage block being incorrect when performing the write data operation on the first type storage block, mark the storage block as unusable storage block.

[0075] Those skilled in the art can understand that, in the above method of the specific embodiment, the writing order of each step does not mean a strict execution order and does not constitute any limitation on the implementation process. The specific execution order of each step should be determined according to its function and possible inherent logic.

[0076] The above description of each embodiment tends to emphasize the differences between each embodiment, and the same or similar parts can be referred to each other, and for the sake of brevity, will not be repeated here.

[0077] In several embodiments provided in the present application, it should be understood that the disclosed method and related equipment can be implemented in other ways. For example, the above-described related equipment implementation is only schematic, for example, the division of the module or unit is only a logical function division, and actual implementation can have another division manner, for example, a unit or component can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication between the shown or discussed mutual units can be indirect coupling or communication through some interface, device or unit, and can be electrical, mechanical or other forms.

[0078] In addition, each functional unit in each embodiment of the present application can be integrated in one processing unit, or each unit can exist physically, or two or more units can be integrated in one unit. The above integrated unit can be realized in the form of hardware, or in the form of software functional unit.

[0079] The integrated unit, if implemented in the form of a software function unit and sold or used as an independent product, can be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application essentially or in other words the part that contributes to the prior art or the whole or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes a plurality of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) or a processor to execute all or part of the steps of the methods of the various embodiments of the present application. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM, Read-Only Memory), a random access memory (RAM, Random Access Memory), a magnetic disk or an optical disk, and various media that can store program codes.

[0080] It is easy for those skilled in the art to make many modifications and variations to the device and method while maintaining the teachings of the present application. Therefore, the above disclosure should be regarded as limited only by the scope of the appended claims.

Claims

1. A storage device, comprising: connected with a host device, comprising: at least one memory block; and a controller connected with each of the at least one memory block and connected with the host device; wherein the controller is configured to: perform a read data operation from any of the at least one memory block in response to a read instruction received from the host device; determine the memory block as a first type memory block in response to an instruction error correction value of data in the memory block satisfying a preset condition when the read data operation is performed from the memory block, wherein the first type memory block is configured for a first operation set; determine the memory block as a second type memory block in response to the instruction error correction value of data in the memory block not satisfying the preset condition, wherein the second type memory block is configured for a second operation set.

2. The storage device of claim 1, wherein, the first operation set comprises a write data operation with the host device.

3. The storage device of claim 2, wherein, the second operation set comprises a data refresh operation and / or a data garbage collection operation.

4. The storage device of claim 3, wherein, the controller is further configured to perform the write data operation with the memory block in response to the memory block being determined as the first type memory block, and perform the data refresh operation and / or the data garbage collection operation on the memory block in response to the memory block being determined as the second type memory block.

5. The storage device of claim 4, wherein, the controller is further configured to perform a data verification operation on the memory block after the data refresh operation and / or the data garbage collection operation is completed, and release the memory block in response to the data verification passing.

6. The storage device of claim 4, wherein, the controller is further configured to perform other operations in the first operation set on the memory block in response to data writing to the memory block being correct when the write data operation is performed on the memory block, and mark the memory block as unusable in response to data writing to the memory block being incorrect when the write data operation is performed on the memory block.

7. The storage device of any of claims 2-6, wherein, a write data operation with the host device, comprising: receiving a write instruction from the host device, and performing the write data operation on the memory block in response to the write instruction.

8. A data processing method, characterized by, applicable to a storage device as claimed in any one of claims 1-7 connected with a host device, the method comprising: performing a read data operation from any of the at least one memory block in response to a read instruction received from the host device; determining the memory block as a first type memory block in response to an instruction error correction value of data in the memory block satisfying a preset condition when the read data operation is performed from the memory block, wherein the first type memory block is configured for a first operation set; determining the memory block as a second type memory block in response to the instruction error correction value of data in the memory block not satisfying the preset condition, wherein the second type memory block is configured for a second operation set.

9. A data processing method, characterized by, applicable to a host device connected with a storage device as claimed in any one of claims 1-7, the method comprising: issuing a read instruction by the host device to the storage device, so as to cause the storage device to perform the data processing method as claimed in claim 8.

10. The method of claim 9, wherein, the method further comprising: The host device issues a write instruction to the storage device, so that the storage device performs a write data operation on a first type storage block in the storage device in response to the write instruction, and marks the storage block as an unusable storage block in response to data writing of the first type storage block being incorrect when the write data operation is performed on the first type storage block.

Citation Information

Patent Citations

  • Flash memory equipment, and method and system for managing storage blocks in same

    CN102073563A

  • Flash memory equipment detection method and apparatus thereof

    CN104091617A

  • Electronic equipment having data retention protection and operating method thereof

    CN111223514A

  • Hard disk management method and device, hard disk equipment and storage medium

    CN113703681A

  • Method for judging data reliability of NAND flash memory, storage medium and storage equipment

    CN114281271A