![Intel IXP45X Developer'S Manual Download Page 625](http://html1.mh-extra.com/html/intel/ixp45x/ixp45x_developers-manual_2073092625.webp)
Intel
®
IXP45X and Intel
®
IXP46X Product Line of Network Processors
August 2006
Developer’s Manual
Order Number: 306262-004US
625
Memory Controller—Intel
®
IXP45X and Intel
®
IXP46X Product Line of Network Processors
11.2.3.4.1
ECC Example Using the H-Matrix
Assume the Intel XScale processor writes 1234 5678 9ABC DEF0H to the DDRI SDRAM
memory space. The Intel XScale processor Address Decoder decodes the address and
determines the write should be sent to the Core Memory Transaction Queue. The CMTQ
latches the transaction with data 1234 5678 9ABC DEF0H on DATA[63:0].
During the next CMTQ tenure, this transaction is processed and the DDRI SDRAM
Control Block receives the data and then must calculate the ECC code.
, the DDRI SDRAM Control Block creates each check
bit by XORing the appropriate bits in the row. Using 1234 5678 9ABC DEF0H, the ECC
code generated is D2H. This code is written with the data to the SDRAM devices on
DDRI_CB[7:0].
Assume that bit 17 was corrupted in the array. Therefore, the bit has been inverted
from 0 to 1.
At some later point in time, the core wishes to read from the same address. The Intel
XScale processor issues a read transaction which is latched by the CMTQ after the Core
Address Decoder decodes the address and determines the read targets the DDRI
SDRAM address space. Upon the receipt of 1234 5678 9ABE DEF0H on
DDRI_DQ[31:0], the DDRI SDRAM Control Block calculates the syndrome with the G-
Matrix in
. The DDRI SDRAM Control Block calculates a syndrome of 52H.
Note:
During a memory write, ECC code is created by XORing the appropriate data bits
indicated by the G-Matrix. The syndrome is created during a memory read by XORing
the 8-bit value generated by XORing appropriate data bits on DDRI_DQ[31:0] indicated
by the G-Matrix with the check bits DDRI_CB[7:0].
Referring to
, if the syndrome is non-zero and matches a value in the H-
Matrix, there is a single-bit error that can be fixed. A syndrome of 52H matches a value
in the H-Matrix (see
) which indicates that bit 17 has an error. The DDRI
SDRAM Control Block inverts bit 17 prior to returning the corrected data on
DATA[63:0]. The MCU returns 1234 5678 9ABC DEF0H on DATA[63:0].
Assuming this was the first error, the MCU records the address where the error
occurred in ECAR0 and error type in ELOG0. If error reporting is enabled in the ECCR,
the MCU writes a 1 to MCISR[0] which generates an interrupt to the core. A software
interrupt handler scrubs the array and fixes the error in bit 17. Unless more errors
occur, future reads from this location do not result in an error.
11.2.3.5
ECC Disabled
If software disables ECC, the MCU does not check the ECC byte during a read access.
However, the MCU does generate the ECC byte during a write access. If ECC is enabled
but the access is less than 32 bits, the MCU does not check, modify, nor write to the
ECC byte.
11.2.3.6
ECC Testing
explains how the software is responsible for correcting
an error in the memory array once it has been detected by the ECC logic. The MCU
implements the ECTST register providing the programmer the ability to test error
handling software. For write transactions, the ECTST register value is XORed with the
generated ECC. This inverts the bits where the mask is set prior to writing the ECC to
memory. When the MCU reads the address later, the ECC mismatches and the error
condition occurs (see
“Interrupts/Error Conditions” on page 627
).