Skip to contentSkip to conversation

imx: imx6: Add comment to gpr_init function

PATCH New Michael Trimarchi 2 participants 4 messages Jun 23, 2018 – Jun 24, 2018

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 imx: imx6: Add comment to gpr_init function

This function can be used only for some of the nxp SoC. Make it explicit in the comment. This adjust a bit commit 3aa4b703b483f165dd ("imx: imx6: Move gpr_init() function to soc.c")

---
 arch/arm/mach-imx/mx6/soc.c | 5 +++++
 1 file changed, 5 insertions(+)
arch/arm/mach-imx/mx6/soc.c +5 -0
index e8b6f77..2c87c6e 100644
@@ -649,6 +649,11 @@ void imx_setup_hdmi(void)
 }
 #endif
 
+
+/*
+ * gpr_init() function is common for boards using MX6S, MX6DL, MX6D,
+ * MX6Q and MX6QP processors
+ */
 void gpr_init(void)
 {
 	struct iomuxc *iomux = (struct iomuxc *)IOMUXC_BASE_ADDR;
Signature · 1 line
2.7.4
#1 lore raw

PATCH 2/2 i.MX6: engicam: gpr_init can be called only for some architecture

Fix an invalid usage of the gpr_init function for the imx6ul architecture

---
 board/engicam/common/spl.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
board/engicam/common/spl.c +2 -1
index 470d96a..69d1c11 100644
@@ -410,7 +410,8 @@ void board_init_f(ulong dummy)
 	/* setup AIPS and disable watchdog */
 	arch_cpu_init();
 
-	gpr_init();
+	if (!(is_mx6ul()))
+		gpr_init();
 
 	/* iomux */
 	SETUP_IOMUX_PADS(uart_pads);
Signature · 1 line
2.7.4
#3 lore raw

PATCH 1/2 imx: imx6: Add comment to gpr_init function

In reply to Michael Trimarchi
Quoted 16 lines · Michael Trimarchi

This function can be used only for some of the nxp SoC. Make it explicit in the comment. This adjust a bit commit 3aa4b703b483f165dd ("imx: imx6: Move gpr_init() function to soc.c")

---
 arch/arm/mach-imx/mx6/soc.c | 5 +++++
 1 file changed, 5 insertions(+)
arch/arm/mach-imx/mx6/soc.c +0 -0
index e8b6f77..2c87c6e 100644
@@ -649,6 +649,11 @@ void imx_setup_hdmi(void)
 }
 #endif

arch/arm/mach-imx/mx6/soc.c void imx_setup_hdmi(void)

Quoted 10 lines
arch/arm/mach-imx/mx6/soc.c +5 -1
 
+
+/*
+ * gpr_init() function is common for boards using MX6S, MX6DL, MX6D,
+ * MX6Q and MX6QP processors
+ */
 void gpr_init(void)
 {
        struct iomuxc *iomux = (struct iomuxc *)IOMUXC_BASE_ADDR;
--

May be adding ifdef !imx6ul on the code also make sense.

#2 lore raw

PATCH 2/2 i.MX6: engicam: gpr_init can be called only for some architecture

In reply to Michael Trimarchi
Quoted 13 lines · Michael Trimarchi

Fix an invalid usage of the gpr_init function for the imx6ul architecture

---
 board/engicam/common/spl.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
board/engicam/common/spl.c +0 -0
index 470d96a..69d1c11 100644

board/engicam/common/spl.c void board_init_f(ulong dummy) · line 414

Quoted 6 lines
board/engicam/common/spl.c +2 -1
@@ -410,7 +410,8 @@ void board_init_f(ulong dummy)
        /* setup AIPS and disable watchdog */
        arch_cpu_init();
 
-       gpr_init();
+       if (!(is_mx6ul()))
+               gpr_init();