ECC check single-bit error correction system of DDR controller

Through the ECC verification single-bit error correction system of the DDR controller, the hardware implements ECC verification, which solves the problems of slow processing speed and high resource utilization in DDR particle DRAM, and realizes rapid correction of single-bit errors and reduces resource overhead.

CN120429160APending Publication Date: 2025-08-05XINSIYUAN MICROELECTRONICS CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510411720.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-02
Publication Date
2025-08-05

AI Technical Summary

Technical Problem

In the prior art, the ECC verification processing speed of DDR particle DRAM is slower, has a high delay and occupies more CPU resources.

Method used

The ECC verification single-bit error correction system using DDR controller is used to realize ECC verification through hardware, including DDR controller, DDR physical layer and DDR particle bars, and uses modules such as ECC single-bit error correction and data selector for data processing and correction.

Benefits of technology

It realizes the rapid processing of single-bit errors in data in DDR particle DRAM, reducing the delay in reading and writing data paths and reducing resource overhead.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120429160A_ABST
    Figure CN120429160A_ABST
Patent Text Reader

Abstract

The invention relates to memory error correction, in particular to an ECC (error correction code) check single-bit error correction system of a DDR (double data rate) controller, which comprises the following steps of: generating a command Cmd1, an address Addr1 and write data Wrdata1, and receiving read data Rddataout, a read address Rdaddrout and a single-bit error enable signal 1bit; the ECC single-bit error corrector is used for receiving a single-bit error signal 1bit, read data Rddataout and a read address Rdaddrout, and generating a command Cmd2, an address Addr2, write data Wrdata2 and a single-bit error enable signal 1bit which are required by ECC single-bit error correction, and the command Cmd2, the address Addr2, the write data Wrdata2 and the single-bit error enable signal 1bit are used for correcting the ECC single-bit error; according to the technical scheme provided by the invention, the defects of relatively low processing speed, relatively high delay and relatively large CPU (Central Processing Unit) resource occupation can be effectively overcome.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to memory error correction, and in particular to an ECC check single-bit error correction system of a DDR controller. Background Art

[0002] For the data in DDR particle DRAM, due to the influence of some environmental factors, such as temperature changes, voltage fluctuations, electromagnetic interference, etc., some data bits may be flipped, thereby destroying the accuracy and integrity of the data and causing data errors.

[0003] For the data bit flip problem in DDR DRAM, ECC is currently a relatively effective detection method. Hamming code is a type of ECC check code. Because of its ability to correct single-bit errors and detect double-bit errors, it is widely used to ensure data accuracy and integrity.

[0004] In existing technology, ECC checking of data in DDR DRAM is primarily implemented through software. This involves using software to generate an ECC check code for write data, writing both the write data and the corresponding ECC check code into the DDR DRAM, and then performing ECC decoding and bit error handling on the read data. While this approach achieves ECC checking of data in DDR DRAM, it suffers from slow processing speeds, high latency, and high CPU resource consumption. Summary of the Invention

[0005] (1) Technical problems solved

[0006] In view of the above shortcomings of the prior art, the present invention provides an ECC single-bit error correction system for a DDR controller, which can effectively overcome the shortcomings of the prior art such as slow processing speed, high latency, and high CPU resource usage.

[0007] (2) Technical solution

[0008] To achieve the above objectives, the present invention is implemented through the following technical solutions:

[0009] A DDR controller ECC single-bit error correction system includes a DDR controller DDRC, a DDR physical layer DDRPHY and a DDR particle strip DIMM. The DDR controller DDRC includes:

[0010] The controller generates a command Cmd_1, an address Addr_1, and write data Wr_data_1, and receives read data Rd_data_out, a read address Rd_addr_out, and a single-bit error enable signal 1bit_err_en;

[0011] An ECC single-bit error corrector receives a single-bit error signal 1bit_err, read data Rd_data_out, and a read address Rd_addr_out, and generates a command Cmd_2, an address Addr_2, write data Wr_data_2, and a single-bit error enable signal 1bit_err_en required for ECC single-bit error correction;

[0012] The data selector Mux1, under the control of the single-bit error enable signal 1bit_err_en, selects the command and address generated by the controller, or the command and address generated by the ECC single-bit error corrector, and sends it to the DDR physical layer DDRPHY;

[0013] The data selector Mux2 selects the write data generated by the controller or the write data generated by the ECC single-bit error corrector under the control of the single-bit error enable signal 1bit_err_en, and sends it to the write data processing module;

[0014] The write data processing module generates and processes the ECC check code for the output of the data selector Mux2, and sends the write data Wr_data and the corresponding write data ECC check code ECC_wr_data to the DDR physical layer DDRPHY;

[0015] Read data register, stores the read data Dfi_rddata returned by the DDR physical layer DDR PHY, and sends it to the read data processing module;

[0016] Read data valid register, stores the read data valid value Dfi_rddata_valid returned by the DDR physical layer DDRPHY, and sends the last read data valid value Rddata_last_en of the burst transmission to the controller and read address FIFO;

[0017] Read address FIFO, stores the read address Rd_addr when the read command Rd_cmd is 1, and sends the read address Rd_addr_out to the ECC single-bit error corrector when the read data valid value Rddata_last_en is 1;

[0018] The read data processing module performs ECC decoding on the read data Dfi_rddata and sends the single-bit error signal 1bit_err and the corrected read data Rd_data_out to the ECC single-bit error corrector.

[0019] Preferably, when the single-bit error enable signal 1bit_err_en is 1, the controller stops generating valid commands;

[0020] The controller has a set of registers for storing status information when an ECC check error occurs, including a correctable error flag corr_err register, an uncorrectable error flag uncorr_err register, a read data Rd_data_out register and a read address Rd_addr_out register, to query the ECC check status.

[0021] Preferably, the ECC single-bit error corrector comprises:

[0022] The cmd generator receives the single-bit error signal 1bit_err, the read data Rd_data_out, and the error address addr sent by the single-bit error address FIFO, and generates the command Cmd_2, the address Addr_2, the write data Wr_data_2, the single-bit error enable signal 1bit_err_en, and the Pop_2 signal and the Push_en signal. This module will enter the ECC single-bit error correction only when the single-bit error signal 1bit_err is 1, thereby generating a valid ECC single-bit error correction command;

[0023] AND gate AND1 receives the Push_en signal and the single-bit error signal 1bit_err and generates the Push_2 signal to control the data writing of the single-bit error address FIFO;

[0024] The single-bit error address FIFO stores the read address Rd_addr_out when the Push_2 signal is 1, and sends the read address Rd_addr_out as the error address addr to the cmd generator.

[0025] Preferably, the write data processing module includes:

[0026] The data selector Mux3 selects the write data Wr_data_sel output by the data selector Mux2 or the invalid data invalid as the write data Wr_data under the control of the write command Wr cmd output by the data selector Mux1;

[0027] The ECC generator generates the corresponding ECC check code according to the write data Wr_data_sel output by the data selector Mux2 through the Hamming code;

[0028] Inverter NOT1 inverts the ECC check code to help check whether the DDR DRAM is disconnected. When the write data Wr_data written to the DDR DRAM is all 0, the corresponding ECC check code should be all 0. After inversion, it is all 1. When reading the data in the DDR DRAM, if the read data Rd_data and the corresponding read data ECC check code ECC_rd_data are all 0, it is considered that the DDR DRAM is disconnected. At this time, the ECC decoder in the read data processing module will have an ECC check error.

[0029] The data selector Mux4, under the control of the write command Wr cmd output by the data selector Mux1, selects the inverted ECC check code output by the inverter NOT1, or the invalid data invalid as the write data ECC check code ECC_wr_data.

[0030] Preferably, the read data processing module includes:

[0031] Inverter NOT2 inverts the read data ECC check code ECC_rd_data in the read data register;

[0032] The ECC decoder decodes the inverted read data ECC check code ECC_rd_data and the read data Rd_data in the read data register through Hamming code, and sets the correctable error flag corr_err to 1 when a single-bit error occurs, and sends the corrected data corr_data to the data selector Mux5; and sets the uncorrectable error flag uncorr_err to 1 when a multi-bit error occurs;

[0033] AND gate AND2 receives the correctable error flag corr_err, the inverted value of the uncorrectable error flag uncorr_err and the read data valid value Rddata_last_en, and generates a single-bit error signal 1bit_err;

[0034] The data selector Mux5 selects the corrected data corr_data output by the ECC decoder or the read data Rd_data in the read data register as the corrected read data Rd_data_out under the control of the single-bit error signal 1bit_err.

[0035] Preferably, the DDR particle strip DIMM includes a plurality of DDR particle DRAMs, wherein one of the DDR particle DRAMs is used as an ECC DRAM for storing ECC data ECC DATA;

[0036] The DDR controller DDRC communicates with the DDR physical layer DDRPHY via the DFI bus, and the DDR physical layer DDRPHY communicates with the DDR particle DRAM via the command address CA bus and the data DATA bus;

[0037] The data transmitted by the data bus DATA includes normal data DATA and ECC data ECC DATA.

[0038] (3) Beneficial effects

[0039] Compared with the existing technology, the ECC check single-bit error correction system of the DDR controller provided by the present invention realizes the ECC check single-bit error correction function of the DDR controller, can quickly handle single-bit errors of data in DDR particle DRAM, and has small delay in the read and write data paths when performing single-bit error processing, which can effectively improve the processing speed; at the same time, since ECC check is implemented through hardware, there is no need to occupy additional CPU and other resources, which significantly reduces resource overhead. BRIEF DESCRIPTION OF THE DRAWINGS

[0040] To more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. Those skilled in the art can also derive other drawings based on these drawings without inventive effort.

[0041] Figure 1 A schematic diagram of the system of the present invention;

[0042] Figure 2 For the present invention Figure 1 Schematic diagram of the hardware structure of the DDR controller DDRC;

[0043] Figure 3 For the present invention Figure 2 Schematic diagram of the hardware structure of the ECC single-bit error corrector;

[0044] Figure 4 This is a first timing diagram for performing ECC single-bit error correction in the present invention;

[0045] Figure 5 This is a second timing diagram for performing ECC single-bit error correction in the present invention;

[0046] Figure 6 This is the third timing diagram of ECC single-bit error correction in the present invention. DETAILED DESCRIPTION

[0047] To make the purpose, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making any creative efforts shall fall within the scope of protection of the present invention.

[0048] A DDR controller ECC single-bit error correction system, such as Figure 1 and Figure 2 As shown, it includes a DDR controller DDRC, a DDR physical layer DDRPHY, and a DDR particle strip DIMM. The DDR controller DDRC includes:

[0049] The controller generates a command Cmd_1, an address Addr_1, and write data Wr_data_1, and receives read data Rd_data_out, a read address Rd_addr_out, and a single-bit error enable signal 1bit_err_en;

[0050] An ECC single-bit error corrector receives a single-bit error signal 1bit_err, read data Rd_data_out, and a read address Rd_addr_out, and generates a command Cmd_2, an address Addr_2, write data Wr_data_2, and a single-bit error enable signal 1bit_err_en required for ECC single-bit error correction;

[0051] The data selector Mux1, under the control of the single-bit error enable signal 1bit_err_en, selects the command and address generated by the controller, or the command and address generated by the ECC single-bit error corrector, and sends it to the DDR physical layer DDRPHY;

[0052] The data selector Mux2 selects the write data generated by the controller or the write data generated by the ECC single-bit error corrector under the control of the single-bit error enable signal 1bit_err_en, and sends it to the write data processing module;

[0053] The write data processing module generates and processes the ECC check code for the output of the data selector Mux2, and sends the write data Wr_data and the corresponding write data ECC check code ECC_wr_data to the DDR physical layer DDRPHY;

[0054] Read data register, stores the read data Dfi_rddata returned by the DDR physical layer DDR PHY, and sends it to the read data processing module;

[0055] Read data valid register, stores the read data valid value Dfi_rddata_valid returned by the DDR physical layer DDRPHY, and sends the last read data valid value Rddata_last_en of the burst transmission to the controller and read address FIFO;

[0056] Read address FIFO, stores the read address Rd_addr when the read command Rd_cmd is 1, and sends the read address Rd_addr_out to the ECC single-bit error corrector when the read data valid value Rddata_last_en is 1;

[0057] The read data processing module performs ECC decoding on the read data Dfi_rddata and sends the single-bit error signal 1bit_err and the corrected read data Rd_data_out to the ECC single-bit error corrector.

[0058] In the technical solution of the present application, the DDR particle strip DIMM includes multiple DDR particle DRAMs, one of which is used as an ECC DRAM for storing ECC data ECC DATA;

[0059] The DDR controller DDRC communicates with the DDR physical layer DDRPHY through the DFI bus, and the DDR physical layer DDR PHY communicates with the DDR DRAM through the command address CA bus and the data DATA bus.

[0060] The data transmitted by the data bus DATA includes normal data DATA and ECC data ECC DATA.

[0061] ① When the single-bit error enable signal 1bit_err_en is 1, the controller stops generating valid commands;

[0062] The controller has a set of registers for storing status information when an ECC check error occurs, including the correctable error flag corr_err register, the uncorrectable error flag uncorr_err register, the read data Rd_data_out register, and the read address Rd_addr_out register to query the ECC check status.

[0063] ② If Figure 3 As shown, the ECC single-bit error corrector includes:

[0064] The cmd generator receives the single-bit error signal 1bit_err, the read data Rd_data_out, and the error address addr sent by the single-bit error address FIFO, and generates the command Cmd_2, the address Addr_2, the write data Wr_data_2, the single-bit error enable signal 1bit_err_en, and the Pop_2 signal and the Push_en signal. This module will enter the ECC single-bit error correction only when the single-bit error signal 1bit_err is 1, thereby generating a valid ECC single-bit error correction command;

[0065] AND gate AND1 receives the Push_en signal and the single-bit error signal 1bit_err and generates the Push_2 signal to control the data writing of the single-bit error address FIFO;

[0066] The single-bit error address FIFO stores the read address Rd_addr_out when the Push_2 signal is 1, and sends the read address Rd_addr_out as the error address addr to the cmd generator.

[0067] ③Write data processing module includes:

[0068] The data selector Mux3 selects the write data Wr_data_sel output by the data selector Mux2 or the invalid data invalid as the write data Wr_data under the control of the write command Wr cmd output by the data selector Mux1;

[0069] The ECC generator generates the corresponding ECC check code according to the write data Wr_data_sel output by the data selector Mux2 through the Hamming code;

[0070] Inverter NOT1 inverts the ECC check code to help check whether the DDR DRAM is disconnected. When the write data Wr_data written to the DDR DRAM is all 0, the corresponding ECC check code should be all 0. After inversion, it is all 1. When reading the data in the DDR DRAM, if the read data Rd_data and the corresponding read data ECC check code ECC_rd_data are all 0, it is considered that the DDR DRAM is disconnected. At this time, the ECC decoder in the read data processing module will have an ECC check error.

[0071] The data selector Mux4, under the control of the write command Wr cmd output by the data selector Mux1, selects the inverted ECC check code output by the inverter NOT1, or the invalid data invalid as the write data ECC check code ECC_wr_data.

[0072] ④The read data processing module includes:

[0073] Inverter NOT2 inverts the read data ECC check code ECC_rd_data in the read data register;

[0074] The ECC decoder decodes the inverted read data ECC check code ECC_rd_data and the read data Rd_data in the read data register through Hamming code, and sets the correctable error flag corr_err to 1 when a single-bit error occurs, and sends the corrected data corr_data to the data selector Mux5; and sets the uncorrectable error flag uncorr_err to 1 when a multi-bit error occurs;

[0075] AND gate AND2 receives the correctable error flag corr_err, the inverted value of the uncorrectable error flag uncorr_err and the read data valid value Rddata_last_en, and generates a single-bit error signal 1bit_err;

[0076] The data selector Mux5 selects the corrected data corr_data output by the ECC decoder or the read data Rd_data in the read data register as the corrected read data Rd_data_out under the control of the single-bit error signal 1bit_err.

[0077] In the technical solution of this application, the timing diagram for performing ECC check single-bit error correction is as follows: Figures 4 to 6 As shown, at time t1, the controller sends a read command RDm with address m. After time T3, at time t2, the DDRC internal signal 1bit_err is pulled high for one cycle, indicating that there is a single-bit error in the read data. Then, the DDRC enters the ECC single-bit error correction phase. The ECC single-bit error corrector pulls 1bit_err_en high, stores the address m of the read command in the single-bit error address FIFO, and generates the command required for ECC single-bit error correction. At this time, the controller stops generating valid commands, and the data selector Mux1 outputs the command and address generated by the ECC single-bit error corrector to the DFI CA bus.

[0078] Between time t2 and time t3, there is a command buffer period of duration T4, during which the ECC single-bit error corrector sends invalid commands to wait for the completion of transmission of valid commands within duration T3.

[0079] At time t3, the cmd generator in the ECC single-bit error corrector generates a read command RDn with address n. The address n is the value stored in the single-bit error address FIFO during the T3 duration. There may be multiple values, such as Figure 6As shown in the figure, the read commands corresponding to address m and address k both have single-bit errors in the read data. Address m and address k are both stored in the single-bit error address FIFO and popped out in sequence according to Pop_2. The read command RDn at time t3 must be issued because when address n is the same as address m, it can prevent Figure 5 The situation shown in the figure occurs, that is, at time t2, the previous command is a write command WRm with address m. At this time, the new data overwrites the single-bit error data at address m in the DRAM. Therefore, it is necessary to read the new data at address m in the DRAM through the read command RDn at time t3 and use it for the subsequent write command WRn at time t4. At time t3, the cmd generator pulls Push_en low. When the read data corresponding to the read command RDn of address n has a single-bit error, Push_en can prevent address n from being stored in the single-bit error address FIFO.

[0080] Between time t3 and time t4, there is a period of time tRW, which is used to wait for the read data datan corresponding to the read command RDn to be transmitted;

[0081] At time t4, the cmd generator generates a write command WRn with address n. The corresponding write data uses the ECC correction value of the read data datan corresponding to the read command RDn. The write command WRn can correct the single-bit error data at address n in the DRAM.

[0082] Between time t4 and time t5, there is a period of time T5, which is used to wait for the write data transmission corresponding to the write command WRn to be completed. During the period of time T5, after the cmd generator generates the write command WRn, it needs to pull Pop_2 high for one cycle to pop the next address in the single-bit error address FIFO;

[0083] At time t5, the cmd generator decides whether the DDRC exits the ECC single-bit error correction phase based on whether the single-bit error address FIFO is empty. At time t5, when the single-bit error address FIFO is not empty, it indicates that there is still uncorrected single-bit error data in the DRAM. At this time, the cmd generator still pulls 1bit_err_en high and push_en low, and executes the process between time t3 and time t5 again. At this time, the address corresponding to the read and write commands is the new address provided by the single-bit error address FIFO, thereby correcting the single-bit error data corresponding to the new address in the DRAM. At time t5, when the single-bit error address FIFO is empty, the cmd generator pulls 1bit_err_en low and push_en high, thereby exiting the ECC single-bit error correction phase, and the next command is issued by the controller.

[0084] Figures 4 to 6There are some time parameters in it, among which T1 is the delay time of cmd signal from DFI to DRAM; RL is the time from DRAM receiving read command to sending read data; T2 is the delay time of read data signal from DRAM to DFI; BL is the time of one burst of read and write data; WL is the time from DRAM receiving write command to sending write data; T3 is the time from DFI sending read command to DDRC generating single-bit error signal 1bit_err, that is, T3 = T1 + RL + T2 + BL; T4 is the buffer time after DDRC enters the ECC single-bit error correction phase, which is determined by the completion time of the command before time t2 and takes the maximum value: when the command before time t2 is a write command, such as Figure 5 As shown, T4>=T1+WL+BL; when the command before time t2 is a read command, as shown Figure 6 As shown, T4>=T1+RL+T2+BL, so T4 takes the maximum value of the two, that is, T4=MAX(T1+WL+BL,T1+RL+T2+BL); tRW is the time from the read command RDn to the write command WRn in the ECC single-bit error correction phase, that is, tRW=T1+RL+T2+BL; T5 is the time for the write data transmission corresponding to the write command WRn to be completed, that is, T5=T1+WL+BL.

[0085] The technical solution of the present application can quickly process single-bit errors in DRAM data. It only takes T4+tRW+T5 from error detection to error correction. When single-bit errors are processed, the corresponding read and write commands are issued by the ECC single-bit error corrector in the DDRC, and the corresponding read data is also received and processed by the ECC single-bit error corrector. Compared with issuing read and write commands from software, the technical solution of the present application has a very small read and write data path delay when single-bit errors are processed. In addition, the ECC single-bit error correction function in the present application is completely implemented by the hardware in the DDRC, without the need to occupy additional CPU and other resources, which significantly reduces resource overhead.

[0086] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements will not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims

1. An ECC single-bit error correction system for a DDR controller, characterized by: It includes a DDR controller DDRC, a DDR physical layer DDRPHY and a DDR particle strip DIMM. The DDR controller DDRC includes: The controller generates a command Cmd_1, an address Addr_1, and write data Wr_data_1, and receives read data Rd_data_out, a read address Rd_addr_out, and a single-bit error enable signal 1bit_err_en; An ECC single-bit error corrector receives a single-bit error signal 1bit_err, read data Rd_data_out, and a read address Rd_addr_out, and generates a command Cmd_2, an address Addr_2, write data Wr_data_2, and a single-bit error enable signal 1bit_err_en required for ECC single-bit error correction; The data selector Mux1, under the control of the single-bit error enable signal 1bit_err_en, selects the command and address generated by the controller, or the command and address generated by the ECC single-bit error corrector, and sends it to the DDR physical layer DDRPHY; The data selector Mux2 selects the write data generated by the controller or the write data generated by the ECC single-bit error corrector under the control of the single-bit error enable signal 1bit_err_en, and sends it to the write data processing module; The write data processing module generates and processes the ECC check code for the output of the data selector Mux2, and sends the write data Wr_data and the corresponding write data ECC check code ECC_wr_data to the DDR physical layer DDRPHY; Read data register, stores the read data Dfi_rddata returned by the DDR physical layer DDR PHY, and sends it to the read data processing module; Read data valid register, stores the read data valid value Dfi_rddata_valid returned by the DDR physical layer DDRPHY, and sends the last read data valid value Rddata_last_en of the burst transmission to the controller and read address FIFO; Read address FIFO, stores the read address Rd_addr when the read command Rd_cmd is 1, and sends the read address Rd_addr_out to the ECC single-bit error corrector when the read data valid value Rddata_last_en is 1; The read data processing module performs ECC decoding on the read data Dfi_rddata and sends the single-bit error signal 1bit_err and the corrected read data Rd_data_out to the ECC single-bit error corrector.

2. The ECC single-bit error correction system for a DDR controller according to claim 1, wherein: When the single-bit error enable signal 1bit_err_en is 1, the controller stops generating valid commands; The controller has a set of registers for storing status information when an ECC check error occurs, including a correctable error flag corr_err register, an uncorrectable error flag uncorr_err register, a read data Rd_data_out register and a read address Rd_addr_out register, to query the ECC check status.

3. The ECC single-bit error correction system for a DDR controller according to claim 1, wherein: The ECC single-bit error corrector comprises: The cmd generator receives the single-bit error signal 1bit_err, the read data Rd_data_out, and the error address addr sent by the single-bit error address FIFO, and generates the command Cmd_2, the address Addr_2, the write data Wr_data_2, the single-bit error enable signal 1bit_err_en, and the Pop_2 signal and the Push_en signal. This module will enter the ECC single-bit error correction only when the single-bit error signal 1bit_err is 1, thereby generating a valid ECC single-bit error correction command; AND gate AND1 receives the Push_en signal and the single-bit error signal 1bit_err and generates the Push_2 signal to control the data writing of the single-bit error address FIFO; The single-bit error address FIFO stores the read address Rd_addr_out when the Push_2 signal is 1, and sends the read address Rd_addr_out as the error address addr to the cmd generator.

4. The ECC single-bit error correction system for a DDR controller according to claim 1, wherein: The write data processing module includes: The data selector Mux3 selects the write data Wr_data_sel output by the data selector Mux2 or the invalid data invalid as the write data Wr_data under the control of the write command Wr cmd output by the data selector Mux1; The ECC generator generates the corresponding ECC check code according to the write data Wr_data_sel output by the data selector Mux2 through the Hamming code; Inverter NOT1 inverts the ECC check code to help check whether the DDR DRAM is disconnected. When the write data Wr_data written to the DDR DRAM is all 0, the corresponding ECC check code should be all 0. After inversion, it is all 1. When reading the data in the DDR DRAM, if the read data Rd_data and the corresponding read data ECC check code ECC_rd_data are all 0, it is considered that the DDR DRAM is disconnected. At this time, the ECC decoder in the read data processing module will have an ECC check error. The data selector Mux4, under the control of the write command Wr cmd output by the data selector Mux1, selects the inverted ECC check code output by the inverter NOT1, or the invalid data invalid as the write data ECC check code ECC_wr_data.

5. The ECC single-bit error correction system for a DDR controller according to claim 1, wherein: The read data processing module includes: Inverter NOT2 inverts the read data ECC check code ECC_rd_data in the read data register; The ECC decoder decodes the inverted read data ECC check code ECC_rd_data and the read data Rd_data in the read data register through Hamming code, and sets the correctable error flag corr_err to 1 when a single-bit error occurs, and sends the corrected data corr_data to the data selector Mux5; and sets the uncorrectable error flag uncorr_err to 1 when a multi-bit error occurs; AND gate AND2 receives the correctable error flag corr_err, the inverted value of the uncorrectable error flag uncorr_err and the read data valid value Rddata_last_en, and generates a single-bit error signal 1bit_err; The data selector Mux5 selects the corrected data corr_data output by the ECC decoder or the read data Rd_data in the read data register as the corrected read data Rd_data_out under the control of the single-bit error signal 1bit_err.

6. The ECC single-bit error correction system for a DDR controller according to any one of claims 1 to 5, characterized in that: The DDR particle strip DIMM includes a plurality of DDR particle DRAMs, wherein one DDR particle DRAM is used as an ECC DRAM for storing ECC data ECC DATA; The DDR controller DDRC communicates with the DDR physical layer DDR PHY via the DFI bus, and the DDR physical layer DDRPHY communicates with the DDR particle DRAM via the command address CA bus and the data DATA bus; The data transmitted by the data bus DATA includes normal data DATA and ECC data ECC DATA.

Citation Information

Cited By

  • Method and system for automatically repairing data of storage unit

    CN121415848A