From 4679b86314b2a5014bde1aacffb5a33144fda8dc Mon Sep 17 00:00:00 2001 From: Greg Davill Date: Sun, 5 Dec 2021 15:34:24 +1030 Subject: [PATCH] soc.intergration.dram: Use nranks in capacity calc This ensures that dual ranked memory appears with the correct capacity --- litex/soc/integration/soc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litex/soc/integration/soc.py b/litex/soc/integration/soc.py index 7d3a7a02d..5a18e449b 100644 --- a/litex/soc/integration/soc.py +++ b/litex/soc/integration/soc.py @@ -1301,7 +1301,7 @@ class LiteXSoC(SoC): # Compute/Check SDRAM size. sdram_size = 2**(module.geom_settings.bankbits + module.geom_settings.rowbits + - module.geom_settings.colbits)*phy.settings.databits//8 + module.geom_settings.colbits)*phy.settings.nranks*phy.settings.databits//8 if size is not None: sdram_size = min(sdram_size, size)