diff --git a/litex/soc/software/bios/sdram.c b/litex/soc/software/bios/sdram.c index ad63bf84d..eb8dda036 100644 --- a/litex/soc/software/bios/sdram.c +++ b/litex/soc/software/bios/sdram.c @@ -762,7 +762,7 @@ int memtest(void) #ifdef CSR_DDRPHY_BASE int sdrlevel(void) { - int i, j; + int module; int bitslip; int score; int best_score; @@ -784,14 +784,14 @@ int sdrlevel(void) #endif printf("Read leveling:\n"); - for(i=0; i best_score) { best_bitslip = bitslip; @@ -801,17 +801,17 @@ int sdrlevel(void) if (bitslip == ERR_DDRPHY_BITSLIP-1) break; /* increment bitslip */ - read_bitslip_inc(i); + read_bitslip_inc(module); } /* select best read window */ - printf("best: m%d, b%d ", i, best_bitslip); - read_bitslip_rst(i); - for (j=0; j