ram: ast2700: Add DRAM controller initialization
Add driver for AST2700 to initialize DRAM in SPL.
This patch also refactors the Kconfig dependency of
Aspeed DRAM drivers as some of them are shared among
the file structures of RV and ARM ISAs.
Signed-off-by: Chia-Wei Wang <chiawei_wang@aspeedtech.com>
Acked-by: Leo Yu-Chi Liang <ycliang@andestech.com>
diff --git a/drivers/ram/aspeed/Kconfig b/drivers/ram/aspeed/Kconfig
index 0deab86..e491846 100644
--- a/drivers/ram/aspeed/Kconfig
+++ b/drivers/ram/aspeed/Kconfig
@@ -1,6 +1,7 @@
menuconfig ASPEED_RAM
bool "ASPEED SDRAM configuration"
- depends on RAM && ARCH_ASPEED
+ depends on RAM
+ depends on ARCH_ASPEED || TARGET_ASPEED_AST2700_IBEX
default ARCH_ASPEED
help
Configuration options for DDR SDRAM on ASPEED systems.
@@ -8,8 +9,6 @@
RAM initialisation is always built in for the platform. This menu
allows customisation of the configuration used.
-if ASPEED_RAM
-
config ASPEED_DDR4_DUALX8
bool "Enable Dual X8 DDR4 die"
depends on ASPEED_RAM
@@ -74,4 +73,24 @@
select DDR4 target data rate at 1600M
endchoice
+choice
+ prompt "AST2700 DDR target date rate"
+ default ASPEED_DDR_3200
+ depends on ASPEED_RAM
+ depends on TARGET_ASPEED_AST2700_IBEX
+
+config ASPEED_DDR_1600
+ bool "1600 Mbps"
+ help
+ select DDR target data rate at 1600M
+
+config ASPEED_DDR_2400
+ bool "2400 Mbps"
+ help
+ select DDR target data rate at 2400M
+
-endif # End of ASPEED_RAM
+config ASPEED_DDR_3200
+ bool "3200 Mbps"
+ help
+ select DDR target data rate at 3200M
+endchoice