diff --git a/litex/soc/software/liblitedram/sdram.c b/litex/soc/software/liblitedram/sdram.c index c8cfbb869..093bb7dc5 100644 --- a/litex/soc/software/liblitedram/sdram.c +++ b/litex/soc/software/liblitedram/sdram.c @@ -283,15 +283,15 @@ void sdram_write_leveling_rst_cmd_delay(int show) { } void sdram_write_leveling_force_cmd_delay(int taps, int show) { + int i; _sdram_write_leveling_cmd_scan = 0; _sdram_write_leveling_cmd_delay = taps; if (show) printf("Forcing Cmd delay to %d taps\n", taps); ddrphy_cdly_rst_write(1); - while (taps > 0) { + for (i=0; i