Data storage device and screening method for damaged data blocks thereof

By writing and reading data blocks in the data storage device, calculating the number of error bits and setting threshold values, corrupt data blocks are filtered out, thus solving the problem of statistical characteristic parameter offset caused by corrupt data blocks and ensuring the accuracy of statistical characteristic parameters of the data storage device.

CN116069236BActive Publication Date: 2026-03-24SILICON MOTION INC
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-14
Publication Date
2026-03-24

AI Technical Summary

Technical Problem

In the prior art, when data storage devices sample data blocks, damaged data blocks can cause deviations in statistical characteristic parameters, which is especially significant for substandard products. Therefore, an effective screening method is needed to remove damaged data blocks.

Method used

By writing data to the sample block in the data storage device, reading and comparing the number of error bits in the data column, calculating the number of error bits in the large block and the number of corrupted data columns, setting a threshold value to identify and record corrupted data blocks, and avoiding the impact of corrupted data blocks on statistical characteristic parameters.

Benefits of technology

Effective removal of damaged data blocks avoids deviations in the statistical characteristic parameters of the data storage device, ensuring the representativeness of the statistical characteristic parameters of the data storage device.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116069236B_ABST
    Figure CN116069236B_ABST
Patent Text Reader

Abstract

A data storage device and a screening method for damaged data blocks thereof includes: writing data to a sample block; reading the written data of the sample block as read data; comparing the read data and the written data of each data column of the sample block to calculate the error bit number of each data column, and to calculate the error bit number of each large block accordingly; selecting a large block with the largest error bit number to record the data column with the largest error bit number in the large block as a damaged data column; determining whether the error bit number of the large block is greater than or equal to a first threshold value and whether the number of damaged data columns is greater than or equal to a second threshold value; and when the error bit number of the large block is greater than or equal to the first threshold value and the number of damaged data columns in the large block is greater than or equal to the second threshold value, recording the sample block as a damaged data block.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present invention relates to a data storage device access technology, and more particularly, to a method for screening a bad data block of a data storage device. BACKGROUND

[0002] The grading of a data storage device is based on the quality of sampled data blocks. That is, the quality of the sampled data blocks will affect the statistical characteristic parameters of the data storage device, such as the average error rate of each data column, and cause a shift, especially for the Downgrade Flash. Therefore, a method for screening a bad data block when sampling data blocks of a data storage device is needed. SUMMARY

[0003] The present invention provides a data storage device and a method for screening a bad data block, which can remove the bad data block from a sample block to avoid the shift of the statistical characteristic parameters of the data storage device caused by the bad data block.

[0004] The method for screening a bad data block of the present invention is suitable for a data storage device, wherein the data storage device comprises a control unit and a data storage medium, and the data storage medium comprises a plurality of data blocks, each data block comprises a plurality of data columns, and the data columns are divided into a plurality of large blocks. The control unit performs the method for screening a bad data block, which comprises: writing data to a sample block, wherein the sample block is selected from the plurality of data blocks; reading the written data of the sample block as read data; comparing the read data and the written data of each data column of the sample block to calculate the error bit number of each data column, and calculate the error bit number of each large block accordingly; selecting a large block with the largest error bit number to record a data column with the largest error bit number in the large block as a bad data column; judging whether the error bit number of the large block is greater than or equal to a first threshold value and whether the number of bad data columns in the large block is greater than or equal to a second threshold value; and when the error bit number of the large block is greater than or equal to the first threshold value and the number of bad data columns in the large block is greater than or equal to the second threshold value, recording the sample block as a bad data block; wherein the first threshold value is the number of error bits that can be corrected by the error correction code of the data storage device; and wherein the second threshold value is the total number of bad data columns that can be recorded by the data storage device.

[0005] The data storage device includes a data storage medium and a control unit connected to the data storage medium. The data storage medium includes a plurality of data blocks, each of which includes a plurality of data columns, and the plurality of data columns are divided into a plurality of large blocks. The control unit is configured to perform a screening method for a damaged data block. The screening method includes: writing data to a sample block, wherein the sample block is selected from the plurality of data blocks; reading the written data of the sample block as read data; comparing the read data and the written data of each data column of the sample block to calculate the number of error bits of each data column, and calculating the number of error bits of each large block; selecting a large block with the largest number of error bits to record a data column with the largest number of error bits in the large block as a damaged data column; determining whether the number of error bits of the large block is greater than or equal to a first threshold value and whether the number of damaged data columns is greater than or equal to a second threshold value; and when it is determined that the number of error bits of the large block is greater than or equal to the first threshold value and the number of damaged data columns in the large block is greater than or equal to the second threshold value, recording the sample block as a damaged data block; wherein the first threshold value is the number of error bits that can be corrected by the error correction code of the data storage device; and wherein the second threshold value is the total number of damaged data columns that can be recorded by the data storage device.

[0006] In an embodiment of the present application, each of the large blocks includes a data area and a spare area.

[0007] In an embodiment of the present application, each of the data blocks includes a plurality of data pages, each of which includes a plurality of data columns in the same column.

[0008] In an embodiment of the present application, each of the data pages includes a data area and a spare area, and the large blocks are located in the data area.

[0009] In an embodiment of the present application, the first threshold value and the number of damaged data columns are negatively correlated.

[0010] The data storage device and the screening method for a damaged data block provided by the present application can remove damaged data blocks from sample blocks, thereby avoiding the shift of statistical characteristic parameters of the data storage device caused by damaged data blocks.

[0011] In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the following embodiments are described in detail below, and the accompanying drawings are described as follows. BRIEF DESCRIPTION OF DRAWINGS

[0012] Figure 1 A schematic diagram of a data storage device provided by an embodiment of the present application;

[0013] Figure 2 A schematic diagram of a data storage medium provided by an embodiment of the present application; and

[0014] Figure 3 This is a flowchart illustrating a method for filtering damaged data blocks in a data storage device according to an embodiment of the present invention. Detailed Implementation

[0015] Please refer to Figure 1 This is a schematic diagram of a data storage device provided in an embodiment of the present invention. The data storage device 1 includes a data storage medium 10 and a control unit 20, wherein the control unit 20 is connected to the data storage medium 10 to access data on the data storage medium 10.

[0016] Please refer to Figure 2 This is a schematic diagram of a data storage medium provided in an embodiment of the present invention. This data storage medium 10 includes multiple data blocks (as labeled B0 to BZ-1). Each data block includes multiple data columns 11, and data columns placed in the same column are called data pages (as labeled P0 to PN-1). Furthermore, according to user needs, the data columns 11 can be divided into M chunks (as labeled C0 to CM-1), each chunk C0 to CM-1 containing multiple data columns 11. Z, N, and M in the above are all positive integers. In this embodiment, the data storage medium 10 is implemented using non-volatile memory, such as flash memory, magnetoresistive random access memory, ferroelectric random access memory, or other memory devices with long-term data retention capabilities. Furthermore, in one embodiment, each data page can be divided into a data area and a spare area, and the M chunks are located in the data area. In another embodiment, each block C0 to CM-1 can be divided into a data area and a spare area. The data area is used to store data (or user data), and the spare area is used to store parity check codes, which can be used to correct error bits in the data area.

[0017] Next, the screening method of the damaged data block (hereinafter referred to as the screening method) of the present application can be used to screen the damaged data block in the sample block of the data storage medium 10. In addition, the present embodiment randomly selects one data block B0 to BZ-1 of the data storage medium 10 as the sample block to execute the screening method, without using all the data blocks B0 to BZ-1. It can be noted that the skilled person can select different number of sample blocks according to the capacity of the data storage medium 10 to execute the screening method so that the screened sample blocks can represent the statistical characteristic parameters of the data storage device 1. For example, 16 sample blocks can be selected to execute the screening method to screen the damaged data block until 16 sample blocks are non-damaged data blocks, and thus the present application does not limit the number of sample blocks. In another embodiment, the present application can execute the screening method on all the data blocks B0 to BZ-1.

[0018] Please refer to Figure 3 The flowchart of the screening method of the damaged data block of the data storage device provided by an embodiment of the present application is shown in FIG. 4. The control unit 20 executes the screening method of the damaged data block of the present application includes the following operations. In step S1, the control unit 20 writes data to the sample block, wherein the sample block is selected from the data blocks B0 to BZ-1. In step S3, the control unit 20 reads the written data of the sample block as the read data. In step S5, the control unit 20 compares the read data and the written data of each data column 11 of the sample block to calculate the number of error bits of each data column 11, and calculates the number of error bits of each block C0 to CM-1 according to the number of error bits of each data column 11. In step S7, the control unit 20 selects the block with the largest number of error bits to record the data column 11 with the largest number of error bits in the block as a damaged data column. In step S9, the control unit 20 judges whether the number of error bits of the block is greater than or equal to a first threshold value and whether the number of damaged data columns in the block is greater than or equal to a second threshold value, wherein the first threshold value is the number of error bits that can be corrected by an error correction code of the data storage device 1, and the second threshold value is the total number of damaged data columns that can be recorded by the data storage device 1. In step S11, when the number of error bits of the block is greater than or equal to the first threshold value and the number of damaged data columns in the block is greater than or equal to the second threshold value, the control unit 20 records the sample block as a damaged data block.

[0019] Since the damaged data columns exist in the data storage medium 10, the screening method of the damaged data blocks of the present application can effectively determine and record the positions of the damaged data columns of the data storage medium 10 before the data storage medium 10 is divided into the data area and the spare area. After the positions of the damaged data columns are determined, the division of the data area and the spare area is performed. In addition, the division of the data area and the spare area is a logical division based on data management, and thus the user can first perform the division of the data area and the spare area, then determine and record the positions of the damaged data columns by using the screening method of the damaged data blocks of the present application, and finally adjust the division of the data area and the spare area. The spirits of the above two data division manners are similar, and the execution sequences are slightly different. In order to simplify the description of the present application, only the second implementation manner is described, but the present application is not limited to this.

[0020] In an example, the data storage medium 10 includes 17472 data columns 11, each data column has 2560 bits, and the data columns are divided into 16 blocks, each block includes 1024 data columns 11, and thus the spare area is 17472-(16*1024) = 1088 data columns 11, that is, 68 data columns 11 can be allocated to each block, and thus the error correction code provides 36-bit correction capability for correctable errors of the data columns 11 of the spare area. In the example, the above values change with the capacity of the data storage medium 10, and the present application is not limited to the above values.

[0021] First, the control unit 20 selects a data block (for example, the data block B0) as a sample block and writes data into the sample block, reads the written data of the sample block as read data, compares the read data and the written data of each data column 11 in the sample block to calculate the error bit number of each data column 11, and calculates the error bit number of each block in the sample block based on the error bit number of each data column 11. For example, the data storage medium 10 includes 10 data blocks, and each data column 11 of each data block can be allocated to 2560 / 10 = 256 bits. The control unit 20 compares the 256 bits of the written data and the read data of each data column 11 to calculate the error bit number of the 256 bits of each data column 11, and calculates the total error bit number of 1024 data columns 11 of each block.

[0022] Next, the control unit 20 selects a chunk having the largest number of error bits (e.g., chunk C0 in data block B0 has the largest number of error bits of 1000 error bits) and finds a first data column 11 having the largest number of error bits in the chunk C0 (e.g., a data column has the largest number of error bits of 10 error bits) and records the first data column as a defective data column in a defective data column summary table of the data storage device 1. It is noted that the total number of defective data columns recorded in the defective data column summary table of the data storage device 1 is an upper limit value, i.e., a second threshold value, which is 1088 data columns of the spare area in the present example, while the number of error bits correctable by the error correction code of the data storage device 1, i.e., a first threshold value, is negatively correlated with the number of defective data columns. That is, the more the number of defective data columns recorded in the defective data column summary table, the lower the first threshold value will be, as shown in Table 1.

[0023] Table 1

[0024]

[0025] Next, after recording the first data column as a defective data column in the defective data column summary table, the control unit 20 again finds a second data column 11 having the largest number of error bits in the chunk C0 and records the second data column as a defective data column in the defective data column summary table. This is repeated until the number of 1088 recordable defective data columns of the data storage device 1 is used up.

[0026] Finally, the control unit 20 can determine whether the number of error bits of the chunk C0 is greater than or equal to the first threshold value and whether the number of defective data columns in the chunk C0 is greater than or equal to the second threshold value. When the control unit 20 determines that the number of error bits of the chunk C0 is greater than the first threshold value and that the number of defective data columns in the chunk C0 is equal to the second threshold value, the control unit 20 records the sample block (i.e., data block B0) as a defective data block and again selects another data block as a sample block to perform the screening method. On the other hand, when the control unit 20 determines that the number of error bits of the chunk having the largest number of error bits is less than the first threshold value, i.e., the error tolerance in Table 1 is a positive integer, the sample block can be used as one of the representative parameters of the statistical characteristics of the data storage device 1.

[0027] In summary, the data storage device and the screening method of defective data blocks thereof provided by the present application can remove defective data blocks from sample blocks, thereby avoiding the shift of the statistical characteristics of the data storage device caused by defective data blocks and using sample blocks as representative parameters of the statistical characteristics of the data storage device 1.

[0028] The above merely describes preferred embodiments of the present application, and is not intended to limit the present application in any form. Although the present application has been disclosed with the preferred embodiments as above, it is not intended to limit the present application, and any person skilled in the art can make some changes or modifications to the above disclosed methods and technical contents to make equivalent embodiments with equivalent changes, but as long as the changes or modifications do not deviate from the technical solutions of the present application, and any simple modifications, equivalent changes and modifications made to the above embodiments according to the technical essence of the present application are still within the scope of the technical solutions of the present application.

Claims

1. A method for filtering corrupted data blocks, characterized in that, A data storage device is applicable, the data storage device including a control unit and a data storage medium, the data storage medium including multiple data blocks, each of the data blocks including multiple data columns, and the data columns being divided into multiple large blocks, wherein the control unit performs a method for filtering the corrupted data blocks including: Write data to a sample block, wherein the sample block is selected from the data blocks; Reading the written data of this sample block is equivalent to reading the data. The read data and the write data of each of the data columns of the sample block are compared to calculate the number of error bits for each of the data columns, and the number of error bits for each of the blocks is calculated accordingly. Select a large block with the largest number of such error bits and record the data column with the largest number of such error bits in that large block as a corrupted data column; Determine whether the number of erroneous bits in the large block is greater than or equal to a first threshold value and whether the number of corrupted data columns is greater than or equal to a second threshold value; and When the number of error bits in the block is greater than or equal to the first threshold value and the number of corrupted data columns in the block is greater than or equal to the second threshold value, the sample block is recorded as a corrupted data block. The first threshold value is the number of error bits that an error correction code of the data storage device can correct; The second threshold value is the total number of the damaged data columns that the data storage device can record.

2. The method for filtering damaged data blocks as described in claim 1, characterized in that, Each of these large blocks includes a data area and a spare area.

3. The method for filtering damaged data blocks as described in claim 1, characterized in that, Each of these data blocks comprises multiple data pages, and each of these data pages comprises data columns located in the same column.

4. The method for filtering damaged data blocks as described in claim 3, characterized in that, Each of these data pages includes a data area and a spare area, and the large blocks are located in the data area.

5. The method for filtering damaged data blocks as described in claim 1, characterized in that, The first threshold value is negatively correlated with the number of corrupted data columns.

6. A data storage device, characterized in that, include: A data storage medium comprising multiple data blocks, wherein each of the data blocks comprises multiple data columns, and the data columns are divided into multiple large blocks; as well as A control unit, connected to the data storage medium, is used to perform a method for filtering corrupted data blocks, the method including: Write data to a sample block, wherein the sample block is selected from the data blocks; Reading the written data of this sample block is equivalent to reading the data. The read data and the write data of each of the data columns of the sample block are compared to calculate the number of error bits for each of the data columns, and the number of error bits for each of the blocks is calculated accordingly. Select a large block with the largest number of such error bits and record the data column with the largest number of such error bits in that large block as a corrupted data column; Determine whether the number of erroneous bits in the large block is greater than or equal to a first threshold value and whether the number of corrupted data columns is greater than or equal to a second threshold value; and When the number of error bits in the block is greater than or equal to the first threshold value and the number of corrupted data columns in the block is greater than or equal to the second threshold value, the sample block is recorded as a corrupted data block. The first threshold value is the number of error bits that an error correction code of the data storage device can correct; The second threshold value is the total number of the damaged data columns that the data storage device can record.

7. The data storage device as claimed in claim 6, characterized in that, Each of these large blocks includes a data area and a spare area.

8. The data storage device as claimed in claim 6, characterized in that, Each of these data blocks comprises multiple data pages, and each of these data pages comprises data columns located in the same column.

9. The data storage device as claimed in claim 8, characterized in that, Each of these data pages includes a data area and a spare area, and the large blocks are located in the data area.

10. The data storage device as claimed in claim 6, characterized in that, The first threshold value is negatively correlated with the number of corrupted data columns.

Citation Information

Patent Citations

  • Method for screening bad column and data storage device with bad column summary table

    CN107346212A

  • Unusable column mapping in flash memory devices

    US20180046372A1