From 7b61b68f68aea8f67c1f43693be631d0850e058a Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Wed, 5 Sep 2018 23:39:41 +0200 Subject: [PATCH] sdram_init: min value for wr is 5 --- litedram/sdram_init.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litedram/sdram_init.py b/litedram/sdram_init.py index 5cc6d50..48c983d 100644 --- a/litedram/sdram_init.py +++ b/litedram/sdram_init.py @@ -171,7 +171,7 @@ def get_sdram_phy_init_sequence(phy_settings, timing_settings): if hasattr(phy_settings, "ron"): ron = phy_settings.ron - wr = timing_settings.tWTR*phy_settings.nphases # >= ceiling(tWR/tCK) + wr = max(timing_settings.tWTR*phy_settings.nphases, 5) # >= ceiling(tWR/tCK) mr0 = format_mr0(bl, cl, wr, 1) mr1 = format_mr1( z_to_ron[ron],