public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [PATCH] imx: imx8mn_beacon: Fix USB booting
@ 2022-01-26 18:25 Adam Ford
  2022-01-29 18:59 ` Fabio Estevam
  2022-02-05 16:39 ` sbabic
  0 siblings, 2 replies; 3+ messages in thread
From: Adam Ford @ 2022-01-26 18:25 UTC (permalink / raw)
  To: u-boot; +Cc: sbabic, tharvey, trini, Adam Ford, Michael Nazzareno Trimarchi

The i.MX8M Nano can boot over USB using the boot ROM instead of
adding extra code to SPL to support USB drivers, etc.  However,
when booting from USB, the environment doesnt' know where to load
and causes a hang.  Fix this hang by supporting CONFIG_ENV_IS_NOWHERE=y.
It only falls back to this condition when booting from USB, so it
does not impact MMC booting.

Suggested-by: Michael Nazzareno Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/configs/imx8mn_beacon_2g_defconfig b/configs/imx8mn_beacon_2g_defconfig
index 8b98d687ec..1766a43cce 100644
--- a/configs/imx8mn_beacon_2g_defconfig
+++ b/configs/imx8mn_beacon_2g_defconfig
@@ -66,6 +66,7 @@ CONFIG_OF_CONTROL=y
 CONFIG_SPL_OF_CONTROL=y
 CONFIG_OF_SPL_REMOVE_PROPS="interrupt-parent interrupts"
 CONFIG_ENV_OVERWRITE=y
+CONFIG_ENV_IS_NOWHERE=y
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_SYS_MMC_ENV_DEV=2
diff --git a/configs/imx8mn_beacon_defconfig b/configs/imx8mn_beacon_defconfig
index a707ee664e..8ac36121aa 100644
--- a/configs/imx8mn_beacon_defconfig
+++ b/configs/imx8mn_beacon_defconfig
@@ -66,6 +66,7 @@ CONFIG_CMD_FAT=y
 CONFIG_OF_CONTROL=y
 CONFIG_SPL_OF_CONTROL=y
 CONFIG_ENV_OVERWRITE=y
+CONFIG_ENV_IS_NOWHERE=y
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_SYS_MMC_ENV_DEV=2
-- 
2.32.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] imx: imx8mn_beacon: Fix USB booting
  2022-01-26 18:25 [PATCH] imx: imx8mn_beacon: Fix USB booting Adam Ford
@ 2022-01-29 18:59 ` Fabio Estevam
  2022-02-05 16:39 ` sbabic
  1 sibling, 0 replies; 3+ messages in thread
From: Fabio Estevam @ 2022-01-29 18:59 UTC (permalink / raw)
  To: Adam Ford
  Cc: U-Boot-Denx, Stefano Babic, Tim Harvey, Tom Rini,
	Michael Nazzareno Trimarchi

On Wed, Jan 26, 2022 at 3:25 PM Adam Ford <aford173@gmail.com> wrote:
>
> The i.MX8M Nano can boot over USB using the boot ROM instead of
> adding extra code to SPL to support USB drivers, etc.  However,
> when booting from USB, the environment doesnt' know where to load
> and causes a hang.  Fix this hang by supporting CONFIG_ENV_IS_NOWHERE=y.
> It only falls back to this condition when booting from USB, so it
> does not impact MMC booting.
>
> Suggested-by: Michael Nazzareno Trimarchi <michael@amarulasolutions.com>
> Signed-off-by: Adam Ford <aford173@gmail.com>

Reviewed-by: Fabio Estevam <festevam@gmail.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH] imx: imx8mn_beacon: Fix USB booting
  2022-01-26 18:25 [PATCH] imx: imx8mn_beacon: Fix USB booting Adam Ford
  2022-01-29 18:59 ` Fabio Estevam
@ 2022-02-05 16:39 ` sbabic
  1 sibling, 0 replies; 3+ messages in thread
From: sbabic @ 2022-02-05 16:39 UTC (permalink / raw)
  To: Adam Ford, u-boot

> The i.MX8M Nano can boot over USB using the boot ROM instead of
> adding extra code to SPL to support USB drivers, etc.  However,
> when booting from USB, the environment doesnt' know where to load
> and causes a hang.  Fix this hang by supporting CONFIG_ENV_IS_NOWHERE=y.
> It only falls back to this condition when booting from USB, so it
> does not impact MMC booting.
> Suggested-by: Michael Nazzareno Trimarchi <michael@amarulasolutions.com>
> Signed-off-by: Adam Ford <aford173@gmail.com>
> Reviewed-by: Fabio Estevam <festevam@gmail.com>
> diff --git a/configs/imx8mn_beacon_2g_defconfig b/configs/imx8mn_beacon_2g_defconfig
> index 8b98d687ec..1766a43cce 100644
> --- a/configs/imx8mn_beacon_2g_defconfig
> +++ b/configs/imx8mn_beacon_2g_defconfig
> @@ -66,6 +66,7 @@ CONFIG_OF_CONTROL=y
>  CONFIG_SPL_OF_CONTROL=y
>  CONFIG_OF_SPL_REMOVE_PROPS="interrupt-parent interrupts"
>  CONFIG_ENV_OVERWRITE=y
> +CONFIG_ENV_IS_NOWHERE=y
>  CONFIG_ENV_IS_IN_MMC=y
>  CONFIG_SYS_RELOC_GD_ENV_ADDR=y
>  CONFIG_SYS_MMC_ENV_DEV=2
> diff --git a/configs/imx8mn_beacon_defconfig b/configs/imx8mn_beacon_defconfig
> index a707ee664e..8ac36121aa 100644
> --- a/configs/imx8mn_beacon_defconfig
> +++ b/configs/imx8mn_beacon_defconfig
> @@ -66,6 +66,7 @@ CONFIG_CMD_FAT=y
>  CONFIG_OF_CONTROL=y
>  CONFIG_SPL_OF_CONTROL=y
>  CONFIG_ENV_OVERWRITE=y
> +CONFIG_ENV_IS_NOWHERE=y
>  CONFIG_ENV_IS_IN_MMC=y
>  CONFIG_SYS_RELOC_GD_ENV_ADDR=y
>  CONFIG_SYS_MMC_ENV_DEV=2
Applied to u-boot-imx, master, thanks !

Best regards,
Stefano Babic

-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic@denx.de
=====================================================================

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-02-05 16:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-01-26 18:25 [PATCH] imx: imx8mn_beacon: Fix USB booting Adam Ford
2022-01-29 18:59 ` Fabio Estevam
2022-02-05 16:39 ` sbabic

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox