summaryrefslogtreecommitdiff
path: root/plat/imx
diff options
context:
space:
mode:
authorJacky Bai <ping.bai@nxp.com>2020-08-03 13:31:26 +0800
committerJacky Bai <ping.bai@nxp.com>2023-02-28 14:26:39 +0800
commit25c43233e866326326f9f82bfae03357c396a99f (patch)
tree0afacb0f665219779cf18612b2663bc6c615dabc /plat/imx
parent3330084979e4c1a39a92f0642000664c79a00dda (diff)
downloadarm-trusted-firmware-25c43233e866326326f9f82bfae03357c396a99f.tar.gz
fix(imx8m): fix the current fsp init
The dfimisc reg value should be shift right 8 bit to get the current fsp. Signed-off-by: Jacky Bai <ping.bai@nxp.com> Reviewed-by: Anson Huang <Anson.Huang@nxp.com> Change-Id: I4c8c166bc3ad4cc1376961cbf47631c68b5900cc
Diffstat (limited to 'plat/imx')
-rw-r--r--plat/imx/imx8m/ddr/dram.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/plat/imx/imx8m/ddr/dram.c b/plat/imx/imx8m/ddr/dram.c
index 1fea69db8..6780bed9c 100644
--- a/plat/imx/imx8m/ddr/dram.c
+++ b/plat/imx/imx8m/ddr/dram.c
@@ -152,7 +152,8 @@ void dram_info_init(unsigned long dram_timing_base)
DDRC_ACTIVE_TWO_RANK : DDRC_ACTIVE_ONE_RANK;
/* Get current fsp info */
- current_fsp = mmio_read_32(DDRC_DFIMISC(0)) & 0xf;
+ current_fsp = mmio_read_32(DDRC_DFIMISC(0));
+ current_fsp = (current_fsp >> 8) & 0xf;
dram_info.boot_fsp = current_fsp;
dram_info.current_fsp = current_fsp;