Re: help on udoo_neo power up on mainline uboot

Fabio Estevam
2021-12-29T21:06:24Z

[-- Attachment #1: Type: text/plain, Size: 547 bytes --]

Hi Tommaso,

On Wed, Dec 29, 2021 at 5:51 PM Fabio Estevam <festevam@gmail.com> wrote:

> > U-Boot 2022.01-rc4-00030-gb3f84a939f-dirty (Dec 29 2021 - 21:22:30 +0100)
> >
> > CPU: Freescale i.MX6SX rev1.2 996 MHz (running at 792 MHz)
> > CPU: Extended Commercial temperature grade (-20C to 105C) at 30C
> > Reset cause: POR
> > Model: UDOO Neo Basic
> > Board: UDOO Neo UNDEFINED
>
> Could you please help to investigate this output? It should not print
> "UNDEFINED".

Please try this attached patch instead and share the U-Boot logs.

Thanks

[-- Attachment #2: 0001-udooneo_debug.patch --]
[-- Type: text/x-patch, Size: 2002 bytes --]

From 1033bf6c71c55225288a854d56abf7b9ca99e1f7 Mon Sep 17 00:00:00 2001
From: Fabio Estevam <festevam@gmail.com>
Date: Wed, 29 Dec 2021 18:03:47 -0300
Subject: [PATCH] udoo: neo: Fix the board version IOMUX

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
board/udoo/neo/neo.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/board/udoo/neo/neo.c b/board/udoo/neo/neo.c
index 92a1e084b524..8511f65ce60f 100644
--- a/board/udoo/neo/neo.c
+++ b/board/udoo/neo/neo.c
@@ -67,12 +67,6 @@ enum {
#define WDOG_PAD_CTRL (PAD_CTL_PUE | PAD_CTL_PKE | PAD_CTL_SPEED_MED | \
PAD_CTL_DSE_40ohm)

-#define BOARD_DETECT_PAD_CTRL (PAD_CTL_PKE | PAD_CTL_PUE | \
- PAD_CTL_PUS_100K_UP | PAD_CTL_SPEED_MED | \
- PAD_CTL_DSE_34ohm | PAD_CTL_HYS | PAD_CTL_SRE_FAST)
-#define BOARD_DETECT_PAD_CFG (MUX_PAD_CTRL(BOARD_DETECT_PAD_CTRL) | \
- MUX_MODE_SION)
-
int dram_init(void)
{
gd->ram_size = imx_ddr_size();
@@ -222,9 +216,9 @@ static iomux_v3_cfg_t const phy_control_pads[] = {

static iomux_v3_cfg_t const board_recognition_pads[] = {
/*Connected to R184*/
- MX6_PAD_NAND_READY_B__GPIO4_IO_13 | BOARD_DETECT_PAD_CFG,
+ MX6_PAD_NAND_READY_B__GPIO4_IO_13 | MUX_PAD_CTRL(NO_PAD_CTRL),
/*Connected to R185*/
- MX6_PAD_NAND_ALE__GPIO4_IO_0 | BOARD_DETECT_PAD_CFG,
+ MX6_PAD_NAND_ALE__GPIO4_IO_0 | MUX_PAD_CTRL(NO_PAD_CTRL),
};

static iomux_v3_cfg_t const wdog_b_pad = {
@@ -296,12 +290,18 @@ static int get_board_value(void)
imx_iomux_v3_setup_multiple_pads(board_recognition_pads,
ARRAY_SIZE(board_recognition_pads));

+ gpio_request(IMX_GPIO_NR(4, 13), "r184");
+ gpio_request(IMX_GPIO_NR(4, 0), "r185");
+
gpio_direction_input(IMX_GPIO_NR(4, 13));
gpio_direction_input(IMX_GPIO_NR(4, 0));

r184 = gpio_get_value(IMX_GPIO_NR(4, 13));
r185 = gpio_get_value(IMX_GPIO_NR(4, 0));

+ printf("********* r184 is %d\n", r184);
+ printf("********* r185 is %d\n", r185);
+
/*
* Machine selection -
* Machine r184, r185
--
2.25.1