diff mbox

ARM: uniphier: skip MEMCONF ch2 parsing if CH2_DISABLE bit is set

Message ID 1487560205-19522-1-git-send-email-yamada.masahiro@socionext.com
State Accepted
Commit bed1624d0df66c50e74a68cbdbcb8d3ed7f8411b
Headers show

Commit Message

Masahiro Yamada Feb. 20, 2017, 3:10 a.m. UTC
If SG_MEMCONF_CH2_DISABLE bit is set, the DRAM channel 2 is unused.
The register settings for the ch2 should be ignored.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>

---

 arch/arm/mach-uniphier/dram_init.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

-- 
2.7.4

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Comments

Masahiro Yamada Feb. 22, 2017, 11:34 p.m. UTC | #1
2017-02-20 12:10 GMT+09:00 Masahiro Yamada <yamada.masahiro@socionext.com>:
> If SG_MEMCONF_CH2_DISABLE bit is set, the DRAM channel 2 is unused.

> The register settings for the ch2 should be ignored.

>

> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>



Applied to u-boot-uniphier.


-- 
Best Regards
Masahiro Yamada
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot
diff mbox

Patch

diff --git a/arch/arm/mach-uniphier/dram_init.c b/arch/arm/mach-uniphier/dram_init.c
index 1cd354e..d98187d 100644
--- a/arch/arm/mach-uniphier/dram_init.c
+++ b/arch/arm/mach-uniphier/dram_init.c
@@ -166,7 +166,7 @@  static int uniphier_memconf_decode(struct uniphier_dram_map *dram_map)
 
 	dram_map[1].size = size;
 
-	if (!data->have_ch2)
+	if (!data->have_ch2 || val & SG_MEMCONF_CH2_DISABLE)
 		return 0;
 
 	/* set up ch2 */