From 8f3dcf90ab3b89a3efb73e03c61446ec935be541 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Fri, 18 Aug 2017 09:42:27 +0200 Subject: [PATCH] soc/software/bios/sdram: add optional memtest debug traces --- litex/soc/software/bios/sdram.c | 37 +++++++++++++++++++++++++++++---- 1 file changed, 33 insertions(+), 4 deletions(-) diff --git a/litex/soc/software/bios/sdram.c b/litex/soc/software/bios/sdram.c index 8771f384..cc497f6b 100644 --- a/litex/soc/software/bios/sdram.c +++ b/litex/soc/software/bios/sdram.c @@ -436,10 +436,13 @@ static unsigned short seed_to_data_16(unsigned short seed, int random) #define MEMTEST_BUS_SIZE (512) #endif +//#define MEMTEST_BUS_DEBUG + static int memtest_bus(void) { volatile unsigned int *array = (unsigned int *)MAIN_RAM_BASE; int i, errors; + unsigned int rdata; errors = 0; @@ -449,8 +452,13 @@ static int memtest_bus(void) flush_cpu_dcache(); flush_l2_cache(); for(i=0;i