Decoding apparatus and method
A decoding apparatus includes a decoding unit and an updated erasure data generating unit. The decoding unit receives read data and updated erasure data, and generates decoding data including flag information according to the read data and the updated erasure data. The updated erasure data generating unit is coupled to the decoding unit, receives the flag information and original erasure data, and generates the updated erasure data according to the flag information and the original erasure data. The original erasure data is generated by a reading device that reads a storage medium. A decoding method performed by the decoding apparatus is also disclosed.
Latest Realtek Semiconductor Corp. Patents:
- DONGLE DEVICE AND FIRMWARE UPDATING METHOD THEREOF
- CENTRAL PROCESSING UNIT, I3C CONTROLLER, AND PROCESSING METHOD FOR TASK PACKET
- Method and apparatus of image compression with bit rate control
- Multi-link device and method of switching operation mode of multi-link device
- Method for establishing variation model related to circuit characteristics for performing circuit simulation, and associated circuit simulation system
This application claims priority of Taiwanese application no. 096102087, filed on Jan. 19, 2007.
BACKGROUND OF THE INVENTION1. Field of the Invention
The invention relates to a decoding apparatus and method, more particularly to a product code decoding apparatus and method.
2. Description of the Related Art
Referring to
When a conventional decoding apparatus conducts error-correction decoding using the parity of outer code and the parity of inner code, positions which are unable to be correctly decoded are first marked as erasures, and for each row and each column, it is determined whether erasure decoding or pure error decoding is to be conducted according to the number of erasures. Erasure decoding can increase error correction capability (without erasure decoding, each column can have 8 bytes corrected and each row can have 5 bytes corrected; with erasure decoding, each column can have 16 bytes corrected and each row can have 10 bytes corrected) to result in better decoding capacity. Nevertheless, when the number of erasures is larger than the number of errors that can be corrected using erasure decoding, only pure error decoding can be used for error correction, which often arises in erroneous results, and which reduces the decoding capacity significantly. Therefore, to improve decoding capacity, the probability of conducting erasure decoding must be increased accordingly. As such, how to mark erasures correctly and to use erasures for enhancing the ability to perform correct decoding are important to the industry.
In the conventional decoding apparatus, columns and rows are marked entirely as erasures when they are unable to be correctly decoded. When conducting PO error-correction decoding in rows, the number of erasures is the same as that of rows that are unable to be correctly decoded. In the same token, when conducting PI error-correction decoding in columns, the number of erasures is the same as that of columns that are unable to be correctly decoded. In practice, for those rows and columns that are unable to be correctly decoded, the entire data thereof are usually not erroneous. As a result, marking of an entire row or column that is unable to be correctly decoded as an erasure in the conventional method inevitably generates a greater number of erasures. Moreover, when there exists a burst error in a DVD, the numbers of rows and columns that are unable to be correctly decoded are most likely to be higher than the number of errors that can be corrected by erasure decoding, such that erasure decoding cannot be conducted in the conventional method and such that decoding capacity by the conventional decoding apparatus is significantly reduced.
SUMMARY OF THE INVENTIONTherefore, an object of the present invention is to provide a decoding apparatus and method that can enhance decoding capacity and make efficient use of erasures.
According to one aspect of the present invention, there is provided a decoding apparatus that comprises a decoding unit and an updated erasure data generating unit. The decoding unit receives read data and updated erasure data, and generates decoding data including flag information according to the read data and the updated erasure data. The updated erasure data generating unit is coupled to the decoding unit, receives the flag information and original erasure data, and generates the updated erasure data according to the flag information and the original erasure data. The original erasure data is generated by a reading device that reads a storage medium.
According to another aspect of the present invention, there is provided a decoding method adapted for a data block read from a storage medium. The data block includes a plurality of data sectors, a parity of outer code region and a parity of inner code region. The decoding method comprises the steps of:
generating updated erasure data according to flag information and original erasure data, the flag information including a plurality of column flags and a plurality of row flags, each of the column flags and the row flags indicating decoding integrity of a respective one of columns and rows of the data block, the original erasure data being generated when the storage medium is being read and indicating known error positions in the data block; and
conducting error-correction decoding of the data block using the updated erasure data and a parity of outer code and a parity of inner code in the data block, and updating the flag information.
According to yet another aspect of the present invention, there is provided a decoding method comprising the steps of: generating decoding data including flag information according to read data and updated erasure data; and generating the updated erasure data according to the flag information and original erasure data.
Other features and advantages of the present invention will become apparent in the following detailed description of the embodiments with reference to the accompanying drawings, of which:
Before the present invention is described in greater detail with reference to the accompanying embodiments, it should be noted herein that like elements are denoted by the same reference numerals throughout the disclosure.
Referring to
In this embodiment, the storage medium 4 is exemplified as a DVD but should not be limited thereto. The read data includes a data block. The data block includes sixteen data sectors, a parity of outer code region, and a parity of inner code region. Each data sector includes an error detection code. This invention is also adapted for other types of storage media, and the storage medium 4 is not restricted to current DVD data formats so as to suit diverse characteristics of erasure data in different types of storage media. That is, this invention is applicable to any apparatus that utilizes erasure decoding.
In this embodiment, the reading device 3 marks erasures in units of one byte, but can also mark erasures in units of several bytes. In other words, the present invention is not limited in this aspect.
The updated erasure data generating unit 21 receives flag information and the original erasure data generated by the reading device 3, and combines the flag information and the original erasure data to generate updated erasure data on the fly. The flag information includes a plurality of column flags, a plurality of row flags, and a plurality of sector flags. The column and row flags are used to indicate decoding integrity of a respective one of columns and rows of the data block. The sector flags are used to indicate whether a respective one of the data sectors has passed error detection.
The decoding unit 22, which is coupled to the updated erasure data generating unit 21, utilizes the updated erasure data generated by the updated erasure data generating unit 21 and the parity of outer code and parity of inner code in the data block for conducting error-correction decoding on the data block. The decoding unit 22 further updates the column flags and the row flags, utilizes the error detection codes in the data block to detect integrity of the data sectors, and updates the sector flags according to result of detection. Since error-correction decoding using the parity of outer code and the parity of inner code, and determination as to whether erasure decoding or pure error decoding is to be conducted according to the number of erasures for each row and each column are performed by the decoding unit 22 in a conventional manner, further details of the same are omitted herein for the sake of brevity.
In this embodiment, the updated erasure data generating unit 21 generates the updated erasure data by combining the flag information and the original erasure data on the fly. However, in other embodiments of this invention, the updated erasure data generating unit 21 may be configured so as to generate the updated erasure data by combining the flag information and the original erasure data not on the fly, which will be illustrated in the following second and third embodiments of the invention.
Referring to
In this embodiment, the combining unit 213 generates the updated erasure data according to a polynomial function f(x, y), where x stands for the original erasure data, and y stands for the flag information. In one embodiment of the present invention, the combining unit 213 is a logic circuit. With reference to the original erasure data in the erasure table 212 and the flag information in the flag table 211, the combining unit 213 removes corresponding erasures in the original erasure data that were correctly decoded in a respective column or row and that have passed error detection in the respective data sector (which indicates that previous erasure marking is incorrect), and preserves the other erasures in the original erasure data for generating the updated erasure data. This can be represented by the function f(x,y)=x·y, in which the logic circuit used is an AND gate.
It should be noted that generation of the updated erasure data by the combining unit 213 is not limited to the above scheme where incorrect portions of the original erasure data are modified and correct portions of the original erasure data are preserved. In another embodiment, the original erasure data is preserved, and the columns, rows and data sectors that are unable to be correctly decoded are marked as erasures so as to generate the updated erasure data. This can be represented by the function f(x,y)=x+y, in which the logic circuit used is an OR gate. In still another embodiment, one of the original erasure data, and the columns, rows and data sectors that are unable to be correctly decoded is selected for erasure marking so as to generate the updated erasure data. This can be represented by the function f(x,y)=x or the function f(x,y)=y, in which the updated erasure data is generated according to one of the original erasure data and the flag information. In yet another embodiment, an option not to update can be selected based on actual operating conditions. Other schemes that can achieve the same purpose of updating belong to the scope of the present invention.
Moreover, in a further embodiment, the decoding unit 22 can provide feedback (not shown) to the combining unit 213 so as to adjust dynamically generation of the updated erasure data. That is, according to information generated during a process of decoding by the decoding unit 22, the combining unit 213 is able to adjust dynamically generation of the updated erasure data. For instance, when many columns, rows and data sectors are unable to be decoded correctly, the function f(x,y)=x·y is used; and when few columns, rows and data sectors are unable to be decoded correctly, the function f(x,y)=x+y is used.
It is noted that, unlike the prior art where entire columns and rows unable to be correctly decoded are marked as erasures, i.e., f(x, y)=y, when the combining unit 213 generates the updated erasure data using the function f(x, y)=x·y in this embodiment, the positions intersected by the original erasure data x and the flag information y are marked as erasures.
A simple example will now be illustrated with reference to
Referring to
In one implementation of the third embodiment, the updated erasure data generating unit 21 includes a flag table 214 for storing the flag information, an erasure table 215 for storing the updated erasure data, and a combining unit 216 that is coupled to the flag table 214 and the erasure table 215, and that combines the flag information in the flag table 214 and the erasure data in the erasure table 215 to generate new erasure data and that overwrites the erasure table 215. Source data of the updated erasure data is the original erasure data. It is noted that the connections among the components shown in
Since generation of the updated erasure data by the combining unit 216 is the same as that in the second embodiment, further details of the same will be omitted herein.
In sum, since the original erasure data is generated when the storage medium 4 is read and is combined with the flag information to generate the erasure data used by the decoding unit 22, the number of erasures can be reduced compared to the prior art so that this invention has a higher probability to conduct erasure decoding to thereby increase decoding capacity and efficiently use erasures.
It should be noted that the scope of the present invention is not limited to the above-mentioned embodiments. For example, in the first embodiment in
While the present invention has been described in connection with what are considered the most practical and preferred embodiments, it is understood that this invention is not limited to the disclosed embodiments but is intended to cover various arrangements included within the spirit and scope of the broadest interpretation so as to encompass all such modifications and equivalent arrangements.
Claims
1. A decoding apparatus comprising:
- a decoding unit for receiving read data and updated erasure data, and for generating decoding data including flag information according to the read data and the updated erasure data; and
- an updated erasure data generating unit for receiving the flag information and original erasure data, and generating the updated erasure data according to the flag information and the original erasure data, the original erasure data being generated by a reading device that reads a storage medium.
2. The decoding apparatus as claimed in claim 1, wherein said updated erasure data generating unit generates the updated erasure data by combining the flag information and the original erasure data on the fly.
3. The decoding apparatus as claimed in claim 1, wherein said updated erasure data generating unit combines the flag information and first updated erasure data to generate second updated erasure data, and overwrites the first updated erasure data by the second updated erasure data.
4. The decoding apparatus as claimed in claim 1, wherein the read data includes a data block, said decoding unit performing error-correction decoding on the data block according to the updated erasure data to generate the decoding data.
5. The decoding apparatus as claimed in claim 1, wherein the read data includes a plurality of data sectors, a parity of outer code region, and a parity of inner code region,
- each of the data sectors including an error detection code,
- the flag information including a plurality of sector flags, each of the sector flags indicating whether a respective one of the data sectors has passed error detection.
6. The decoding apparatus as claimed in claim 5, wherein said decoding unit utilizes the error detection codes of the data sectors to detect integrity of the data sectors, and updates the sector flags according to result of detection.
7. The decoding apparatus as claimed in claim 1, wherein said updated erasure data generating unit adjusts dynamically generation of the updated erasure data according to information generated during generation of the decoding data by said decoding unit.
8. The decoding apparatus as claimed in claim 1, wherein said updated erasure data generating unit comprises a flag table for storing the flag information, an erasure table for storing the original erasure data, and a combining unit coupled to said flag table and said erasure table, said combining unit combining the flag information in said flag table and the original erasure data in said erasure table to generate the updated erasure data.
9. The decoding apparatus as claimed in claim 8, wherein said combining unit is a logic circuit.
10. The decoding apparatus as claimed in claim 8, wherein said combining unit overwrites the original erasure data stored in said erasure table by the updated erasure data generated thereby, source data of the updated erasure data being the original erasure data.
11. The decoding apparatus as claimed in claim 1, wherein said decoding unit receives the updated erasure data generated by said updated erasure data generating unit from a table.
12. A decoding method adapted for a data block read from a storage medium, the data block including a plurality of data sectors, a parity of outer code region and a parity of inner code region, said decoding method comprising the steps of:
- generating updated erasure data according to flag information and original erasure data, the flag information including a plurality of column flags and a plurality of row flags, each of the column flags and the row flags indicating decoding integrity of a respective one of columns and rows of the data block, the original erasure data being generated when the storage medium is being read and indicating known error positions in the data block; and
- conducting error-correction decoding of the data block using the updated erasure data and a parity of outer code and a parity of inner code in the data block, and updating the flag information.
13. The decoding method as claimed in claim 12, wherein the updated erasure data is generated by combining the flag information and the original erasure data on the fly.
14. The decoding method as claimed in claim 12, wherein the flag information is combined with first updated erasure data to generate second updated erasure data, and the first updated erasure data is overwritten by the second updated erasure data.
15. The decoding method as claimed in claim 12, wherein generation of the updated erasure data is adjusted dynamically according to information generated during a process of decoding.
16. The decoding method as claimed in claim 12, each of the data sectors including an error detection code, wherein the flag information further includes a plurality of sector flags, each of the sector flags indicating whether a respective one of the data sectors has passed error detection,
- the error detection codes of the data sectors being utilized to detect integrity of the data sectors during a process of decoding, and the sector flags being updated according to result of detection.
17. A decoding method comprising the steps of:
- generating decoding data including flag information according to read data and updated erasure data; and
- generating the updated erasure data according to the flag information and original erasure data.
18. The decoding method as claimed in claim 17, wherein the original erasure data is generated when a storage medium is read.
19. The decoding method as claimed in claim 17, wherein the updated erasure data is generated by combining the flag information and the original erasure data on the fly.
20. The decoding method as claimed in claim 17, wherein the flag information is combined with first updated erasure data to generate second updated erasure data, and the first updated erasure data is overwritten by the second updated erasure data.
21. The decoding method as claimed in claim 17, wherein the read data is generated through Reed-Solomon Product Code encoding.
22. The decoding method as claimed in claim 17, wherein the read data includes a data block that has a plurality of data sectors, a parity of outer code region and a parity of inner code region.
23. The decoding method as claimed in claim 22, wherein the decoding data is generated by conducting error-correction decoding on the data block according to the updated erasure data.
24. The decoding method as claimed in claim 23, wherein each of the data sectors includes an error detection code, the flag information including a plurality of sector flags, each of the sector flags indicating whether a respective one of the data sectors has passed error detection,
- the error detection codes of the data sectors being utilized to detect integrity of the data sectors when generating the decoding data, and the sector flags being updated according to result of detection.
25. The decoding method as claimed in claim 17, wherein generation of the updated erasure data is adjusted dynamically according to information generated during generation of the decoding data.
Type: Application
Filed: Jan 17, 2008
Publication Date: Jul 24, 2008
Applicant: Realtek Semiconductor Corp. (Hsinchu)
Inventors: Shieh-Hsing Kuo (Hsinchu), Chien-Chih Chen (Hsinchu)
Application Number: 12/009,413
International Classification: H03M 13/00 (20060101);