* [PATCH] mx6cuboxi: Do not print devicetree model
@ 2024-03-27 17:03 Fabio Estevam
2024-03-28 7:17 ` Christian Gmeiner
0 siblings, 1 reply; 3+ messages in thread
From: Fabio Estevam @ 2024-03-27 17:03 UTC (permalink / raw)
To: festevam; +Cc: baruch, trini, josua, u-boot, cgmeiner
The mx6cuboxi_defconfig target supports several board
variants. All of these variants use the hummingboard devicetree in U-Boot.
Currently, the devicetree model as well as the board variant name
are shown:
U-Boot 2024.04-rc5-00003-g774ec4fda8 (Mar 27 2024 - 16:48:35 +0100)
...
Model: SolidRun HummingBoard2 Dual/Quad (1.5som+emmc)
Board: MX6 Cubox-i
...
Printing the devicetree model that is used internally by U-Boot
may confuse users.
Unselect the CONFIG_DISPLAY_BOARDINFO option so that only the
board name is printed instead.
Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
configs/mx6cuboxi_defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/configs/mx6cuboxi_defconfig b/configs/mx6cuboxi_defconfig
index 27ceb22599a6..e3aba715aa58 100644
--- a/configs/mx6cuboxi_defconfig
+++ b/configs/mx6cuboxi_defconfig
@@ -28,6 +28,7 @@ CONFIG_BOOTCOMMAND="run findfdt; run finduuid; run distro_bootcmd"
CONFIG_USE_PREBOOT=y
CONFIG_PREBOOT="if hdmidet; then usb start; setenv stdin serial,usbkbd; setenv stdout serial,vidconsole; setenv stderr serial,vidconsole; else setenv stdin serial; setenv stdout serial; setenv stderr serial; fi;"
CONFIG_SYS_PBSIZE=532
+# CONFIG_DISPLAY_BOARDINFO is not set
CONFIG_BOARD_EARLY_INIT_F=y
CONFIG_SPL_SYS_MALLOC=y
CONFIG_SPL_FS_EXT4=y
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] mx6cuboxi: Do not print devicetree model
2024-03-27 17:03 [PATCH] mx6cuboxi: Do not print devicetree model Fabio Estevam
@ 2024-03-28 7:17 ` Christian Gmeiner
2024-03-28 13:45 ` Fabio Estevam
0 siblings, 1 reply; 3+ messages in thread
From: Christian Gmeiner @ 2024-03-28 7:17 UTC (permalink / raw)
To: Fabio Estevam; +Cc: baruch, trini, josua, u-boot
Hi Fabio
> The mx6cuboxi_defconfig target supports several board
> variants. All of these variants use the hummingboard devicetree in U-Boot.
>
> Currently, the devicetree model as well as the board variant name
> are shown:
>
> U-Boot 2024.04-rc5-00003-g774ec4fda8 (Mar 27 2024 - 16:48:35 +0100)
>
> ...
> Model: SolidRun HummingBoard2 Dual/Quad (1.5som+emmc)
> Board: MX6 Cubox-i
> ...
>
> Printing the devicetree model that is used internally by U-Boot
> may confuse users.
>
> Unselect the CONFIG_DISPLAY_BOARDINFO option so that only the
> board name is printed instead.
>
This is not what this patch is doing. show_board_info() is the only
caller of checkboard()
so we end with the following output:
U-Boot 2024.04-rc5-00005-g50decee264-dirty (Mar 28 2024 - 08:09:58
+0100)
CPU: Freescale i.MX6Q rev1.3 996 MHz (running at 792 MHz)
CPU: Extended Commercial temperature grade (-20C to 105C) at 34C
Reset cause: POR
DRAM: 2 GiB
Core: 84 devices, 19 uclasses, devicetree: fit
WDT: Started watchdog@20bc000 with servicing every 1000ms (128s
timeout)
MMC: FSL_SDHC: 1, FSL_SDHC: 2
Loading Environment from MMC... *** Warning - bad CRC, using default
environment
Thanks & Regards,
Christian
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] mx6cuboxi: Do not print devicetree model
2024-03-28 7:17 ` Christian Gmeiner
@ 2024-03-28 13:45 ` Fabio Estevam
0 siblings, 0 replies; 3+ messages in thread
From: Fabio Estevam @ 2024-03-28 13:45 UTC (permalink / raw)
To: Christian Gmeiner; +Cc: baruch, trini, josua, u-boot
[-- Attachment #1: Type: text/plain, Size: 298 bytes --]
Hi Christian,
On Thu, Mar 28, 2024 at 4:18 AM Christian Gmeiner <cgmeiner@igalia.com> wrote:
> This is not what this patch is doing. show_board_info() is the only
> caller of checkboard()
> so we end with the following output:
You're right. The attached patch should do what we want.
[-- Attachment #2: 0001-mx6cuboxiboardrevv2.patch --]
[-- Type: text/x-patch, Size: 3279 bytes --]
From b74a410127cabc100a8993840a3b00d403a316ad Mon Sep 17 00:00:00 2001
From: Fabio Estevam <festevam@gmail.com>
Date: Thu, 28 Mar 2024 10:39:29 -0300
Subject: [PATCH v2] mx6cuboxi: Do not print devicetree model
The mx6cuboxi_defconfig target supports several board
variants. All of these variants use the hummingboard devicetree in U-Boot.
Currently, the devicetree model as well as the board variant name
are shown:
...
Model: SolidRun HummingBoard2 Dual/Quad (1.5som+emmc)
Board: MX6 Cubox-i
...
Printing the devicetree model that is used internally by U-Boot
may confuse users.
Unselect the CONFIG_DISPLAY_BOARDINFO option so that only the
board name is printed in board_late_init() instead.
Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
Changes since v1:
- Remove checkboard and print the board name in board_late_init().
board/solidrun/mx6cuboxi/mx6cuboxi.c | 40 ++++++----------------------
configs/mx6cuboxi_defconfig | 1 +
2 files changed, 9 insertions(+), 32 deletions(-)
diff --git a/board/solidrun/mx6cuboxi/mx6cuboxi.c b/board/solidrun/mx6cuboxi/mx6cuboxi.c
index 8edabf4404c2..31d30cfbbd7b 100644
--- a/board/solidrun/mx6cuboxi/mx6cuboxi.c
+++ b/board/solidrun/mx6cuboxi/mx6cuboxi.c
@@ -381,37 +381,6 @@ static bool has_emmc(void)
return (mmc_get_op_cond(mmc, true) < 0) ? 0 : 1;
}
-/* Override the default implementation, DT model is not accurate */
-int checkboard(void)
-{
- request_detect_gpios();
-
- switch (board_type()) {
- case CUBOXI:
- puts("Board: MX6 Cubox-i");
- break;
- case HUMMINGBOARD:
- puts("Board: MX6 HummingBoard");
- break;
- case HUMMINGBOARD2:
- puts("Board: MX6 HummingBoard2");
- break;
- case UNKNOWN:
- default:
- puts("Board: Unknown\n");
- goto out;
- }
-
- if (is_rev_15_som())
- puts(" (som rev 1.5)\n");
- else
- puts("\n");
-
- free_detect_gpios();
-out:
- return 0;
-}
-
static int find_ethernet_phy(void)
{
struct mii_dev *bus = NULL;
@@ -505,12 +474,15 @@ int board_late_init(void)
switch (board_type()) {
case CUBOXI:
env_set("board_name", "CUBOXI");
+ puts("Board: MX6 Cubox-i");
break;
case HUMMINGBOARD:
env_set("board_name", "HUMMINGBOARD");
+ puts("Board: MX6 HummingBoard");
break;
case HUMMINGBOARD2:
env_set("board_name", "HUMMINGBOARD2");
+ puts("Board: MX6 HummingBoard2");
break;
case UNKNOWN:
default:
@@ -522,8 +494,12 @@ int board_late_init(void)
else
env_set("board_rev", "MX6DL");
- if (is_rev_15_som())
+ if (is_rev_15_som()) {
env_set("som_rev", "V15");
+ puts(" (som rev 1.5)\n");
+ } else {
+ puts("\n");
+ }
if (has_emmc())
env_set("has_emmc", "yes");
diff --git a/configs/mx6cuboxi_defconfig b/configs/mx6cuboxi_defconfig
index 27ceb22599a6..e3aba715aa58 100644
--- a/configs/mx6cuboxi_defconfig
+++ b/configs/mx6cuboxi_defconfig
@@ -28,6 +28,7 @@ CONFIG_BOOTCOMMAND="run findfdt; run finduuid; run distro_bootcmd"
CONFIG_USE_PREBOOT=y
CONFIG_PREBOOT="if hdmidet; then usb start; setenv stdin serial,usbkbd; setenv stdout serial,vidconsole; setenv stderr serial,vidconsole; else setenv stdin serial; setenv stdout serial; setenv stderr serial; fi;"
CONFIG_SYS_PBSIZE=532
+# CONFIG_DISPLAY_BOARDINFO is not set
CONFIG_BOARD_EARLY_INIT_F=y
CONFIG_SPL_SYS_MALLOC=y
CONFIG_SPL_FS_EXT4=y
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-03-28 13:45 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-27 17:03 [PATCH] mx6cuboxi: Do not print devicetree model Fabio Estevam
2024-03-28 7:17 ` Christian Gmeiner
2024-03-28 13:45 ` Fabio Estevam
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.