summaryrefslogtreecommitdiff
path: root/drivers/fpga/fpga.c
diff options
context:
space:
mode:
authorGeorgi Vlaev <g-vlaev@ti.com>2025-01-06 14:37:01 +0530
committerTom Rini <trini@konsulko.com>2025-01-14 15:47:07 -0600
commitfed3b1eb9bf81928d54136aceeb671bdd22c66a9 (patch)
tree1a75c250d8aebcdec62d039ab3f842c5ed588816 /drivers/fpga/fpga.c
parent8ff96fb6d01640cb8a468dba8200463bd4950c0a (diff)
ram: k3-ddrss: Use the DDR controller BIST engine for ECC priming
The 1-bit inline ECC support in TI's DDRSS bridge requires the configured memory regions to be preloaded with a pattern before use. This is done by the k3-ddrss driver from the R5 SPL in a 'for' loop. It takes around 10 seconds to fill 2GB of memory, for example. Memset can cut the time in half and using DMA currently yields a similar result. The BIST engine of DDR controller provides support for initializing any memory region with a pattern. This bypasses the DDRSS bridge, so the required inline ECC data is not computed and populated in the memory. For some values like zero, the computed ECC syndrome is also zero and we can use these values to preload the memory from the DDR controller, without the assistance of the bridge. The registers involved in the process are described in the 'DDR controller registers' topic in [1] AM62 and [2] J721E reference manuals. The patch replaces the 'for' loop memory fill function with the BIST memory initialization procedure. This cuts the time to preload the 2GB memory from 10 seconds down to 1 second. The bist preload function uses the lpddr4 APIs in the k3-ddrss, so this is compatible with devices with both 16-bit LPDDR4 and 32-bit LPDDR4 interfaces (e.g J721E). [1] AM62x: https://www.ti.com/lit/pdf/spruiv7 [2] DRA829/TDA4VM: https://www.ti.com/lit/zip/spruil1 Signed-off-by: Georgi Vlaev <g-vlaev@ti.com> Signed-off-by: Santhosh Kumar K <s-k6@ti.com>
Diffstat (limited to 'drivers/fpga/fpga.c')
0 files changed, 0 insertions, 0 deletions