* [PATCH v2 0/2] board: ti: am6x: Switch to standard boot
@ 2023-10-05 13:06 Roger Quadros
2023-10-05 13:06 ` [PATCH v2 1/2] board: ti: am62x: am62x.env: Fix boot_targets Roger Quadros
2023-10-05 13:06 ` [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow Roger Quadros
0 siblings, 2 replies; 12+ messages in thread
From: Roger Quadros @ 2023-10-05 13:06 UTC (permalink / raw)
To: trini, nm
Cc: vigneshr, m-chawdhry, sjg, jonas, srk, afd, bb, praneeth, u-boot,
Roger Quadros
Hi,
This series switches am64x to standard boot flow.
Also minor fix to am62x boot targets.
NOTE:
Tested on AM64x GP EVM but I had to hand edit the grub.cfg
file provided with the TI release [1]
from,
menuentry 'boot'{
linux /Image root=PARTUUID=3a4a99a8-02 rootwait rootfstype=ext4
}
to,
menuentry 'boot'{
linux /Image console=ttyS2,115200n8 root=PARTUUID=3a4a99a8-02 rootwait rootfstype=ext4
}
else there is no console output.
[1] https://dr-download.ti.com/software-development/software-development-kit-sdk/MD-yXgchBCk98/09.00.00.03/tisdk-default-image-am64xx-evm.wic.xz
cheers,
-roger
Changelog:
v2:
- Added Nishanth's Reviewed-by for patch 1
- Dropped unnecessary headers and macro from patch 2
Roger Quadros (2):
board: ti: am62x: am62x.env: Fix boot_targets
board: ti: am64x: Switch to standard boot flow
board/ti/am62x/am62x.env | 2 +-
board/ti/am64x/am64x.env | 1 +
configs/am64x_evm_a53_defconfig | 5 +++--
include/configs/am64x_evm.h | 9 ---------
4 files changed, 5 insertions(+), 12 deletions(-)
base-commit: e29b932aa07fa0226d325b35d96cd4eea0370129
prerequisite-patch-id: afb49f33f198747451687f83936f039049365924
prerequisite-patch-id: 1d8297eb0a3b44d8578cae785cc22f0fb6077239
prerequisite-patch-id: 4ae9fdc0b3737e55289a78a59d546a08c03d62e5
prerequisite-patch-id: 2be0e0caf153bec2c453b2f21342ba207c1ee13d
prerequisite-patch-id: 7710703ce9a41b72ff3fb89abf0823625a5b5454
prerequisite-patch-id: 60d61440bf0ab8c0bea8b971ef18aa6d0d26e113
prerequisite-patch-id: c974e6d80489cbb0ee8cc1f3e19bcc9cf47f25b6
--
2.34.1
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH v2 1/2] board: ti: am62x: am62x.env: Fix boot_targets
2023-10-05 13:06 [PATCH v2 0/2] board: ti: am6x: Switch to standard boot Roger Quadros
@ 2023-10-05 13:06 ` Roger Quadros
2023-10-12 21:03 ` Tom Rini
2023-10-05 13:06 ` [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow Roger Quadros
1 sibling, 1 reply; 12+ messages in thread
From: Roger Quadros @ 2023-10-05 13:06 UTC (permalink / raw)
To: trini, nm
Cc: vigneshr, m-chawdhry, sjg, jonas, srk, afd, bb, praneeth, u-boot,
Roger Quadros
ti_mmc is not a valid boot_target for standard boot flow so
remove it. Prefer mmc1 (sd-card) over mmc0 (emmc).
Signed-off-by: Roger Quadros <rogerq@kernel.org>
Reviewed-by: Nishanth Menon <nm@ti.com>
---
board/ti/am62x/am62x.env | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/board/ti/am62x/am62x.env b/board/ti/am62x/am62x.env
index 22a6c2c91b..e53a55c38f 100644
--- a/board/ti/am62x/am62x.env
+++ b/board/ti/am62x/am62x.env
@@ -8,7 +8,7 @@ args_all=setenv optargs ${optargs} earlycon=ns16550a,mmio32,0x02800000
${mtdparts}
run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
-boot_targets=ti_mmc mmc0 mmc1 usb pxe dhcp
+boot_targets=mmc1 mmc0 usb pxe dhcp
boot=mmc
mmcdev=1
bootpart=1:2
--
2.34.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 13:06 [PATCH v2 0/2] board: ti: am6x: Switch to standard boot Roger Quadros
2023-10-05 13:06 ` [PATCH v2 1/2] board: ti: am62x: am62x.env: Fix boot_targets Roger Quadros
@ 2023-10-05 13:06 ` Roger Quadros
2023-10-05 13:30 ` Nishanth Menon
` (2 more replies)
1 sibling, 3 replies; 12+ messages in thread
From: Roger Quadros @ 2023-10-05 13:06 UTC (permalink / raw)
To: trini, nm
Cc: vigneshr, m-chawdhry, sjg, jonas, srk, afd, bb, praneeth, u-boot,
Roger Quadros
Switch to using bootstd. Note with this change, we will stop using
distro_bootcmd and instead depend entirely on bootflow method of
starting the system up.
Drop header files that are no longer needed in am64x_evm.h.
k3_dfu.h is available via k3_dfu.env in am64x.env.
Drop unused macro CFG_SYS_SDRAM_BASE1.
Signed-off-by: Roger Quadros <rogerq@kernel.org>
---
board/ti/am64x/am64x.env | 1 +
configs/am64x_evm_a53_defconfig | 5 +++--
include/configs/am64x_evm.h | 9 ---------
3 files changed, 4 insertions(+), 11 deletions(-)
diff --git a/board/ti/am64x/am64x.env b/board/ti/am64x/am64x.env
index 68e42222b7..efd736b99b 100644
--- a/board/ti/am64x/am64x.env
+++ b/board/ti/am64x/am64x.env
@@ -15,6 +15,7 @@ console=ttyS2,115200n8
args_all=setenv optargs earlycon=ns16550a,mmio32,0x02800000 ${mtdparts}
run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
+boot_targets=mmc1 mmc0 usb pxe dhcp
boot=mmc
mmcdev=1
bootpart=1:2
diff --git a/configs/am64x_evm_a53_defconfig b/configs/am64x_evm_a53_defconfig
index 718ad176cb..43bfcf957a 100644
--- a/configs/am64x_evm_a53_defconfig
+++ b/configs/am64x_evm_a53_defconfig
@@ -31,8 +31,9 @@ CONFIG_SPL_SPI=y
# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
CONFIG_SPL_LOAD_FIT=y
CONFIG_SPL_LOAD_FIT_ADDRESS=0x81000000
-CONFIG_DISTRO_DEFAULTS=y
-CONFIG_BOOTCOMMAND="run envboot; run distro_bootcmd;"
+CONFIG_BOOTSTD_FULL=y
+CONFIG_BOOTSTD_DEFAULTS=y
+CONFIG_BOOTCOMMAND="run envboot; bootflow scan -lb"
CONFIG_BOARD_LATE_INIT=y
CONFIG_SPL_MAX_SIZE=0x180000
CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
diff --git a/include/configs/am64x_evm.h b/include/configs/am64x_evm.h
index 062102a610..f9f8c7bc2f 100644
--- a/include/configs/am64x_evm.h
+++ b/include/configs/am64x_evm.h
@@ -9,15 +9,6 @@
#ifndef __CONFIG_AM642_EVM_H
#define __CONFIG_AM642_EVM_H
-#include <linux/sizes.h>
-#include <config_distro_bootcmd.h>
-#include <env/ti/mmc.h>
-#include <asm/arch/am64_hardware.h>
-#include <env/ti/k3_dfu.h>
-
-/* DDR Configuration */
-#define CFG_SYS_SDRAM_BASE1 0x880000000
-
/* Now for the remaining common defines */
#include <configs/ti_armv7_common.h>
--
2.34.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 13:06 ` [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow Roger Quadros
@ 2023-10-05 13:30 ` Nishanth Menon
2023-10-05 15:01 ` Simon Glass
2023-10-12 21:03 ` Tom Rini
2 siblings, 0 replies; 12+ messages in thread
From: Nishanth Menon @ 2023-10-05 13:30 UTC (permalink / raw)
To: Roger Quadros
Cc: trini, vigneshr, m-chawdhry, sjg, jonas, srk, afd, bb, praneeth,
u-boot
On 16:06-20231005, Roger Quadros wrote:
> Switch to using bootstd. Note with this change, we will stop using
> distro_bootcmd and instead depend entirely on bootflow method of
> starting the system up.
>
> Drop header files that are no longer needed in am64x_evm.h.
> k3_dfu.h is available via k3_dfu.env in am64x.env.
>
> Drop unused macro CFG_SYS_SDRAM_BASE1.
>
> Signed-off-by: Roger Quadros <rogerq@kernel.org>
> ---
> board/ti/am64x/am64x.env | 1 +
> configs/am64x_evm_a53_defconfig | 5 +++--
> include/configs/am64x_evm.h | 9 ---------
> 3 files changed, 4 insertions(+), 11 deletions(-)
>
> diff --git a/board/ti/am64x/am64x.env b/board/ti/am64x/am64x.env
> index 68e42222b7..efd736b99b 100644
> --- a/board/ti/am64x/am64x.env
> +++ b/board/ti/am64x/am64x.env
> @@ -15,6 +15,7 @@ console=ttyS2,115200n8
> args_all=setenv optargs earlycon=ns16550a,mmio32,0x02800000 ${mtdparts}
> run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
>
> +boot_targets=mmc1 mmc0 usb pxe dhcp
> boot=mmc
> mmcdev=1
> bootpart=1:2
> diff --git a/configs/am64x_evm_a53_defconfig b/configs/am64x_evm_a53_defconfig
> index 718ad176cb..43bfcf957a 100644
> --- a/configs/am64x_evm_a53_defconfig
> +++ b/configs/am64x_evm_a53_defconfig
> @@ -31,8 +31,9 @@ CONFIG_SPL_SPI=y
> # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
> CONFIG_SPL_LOAD_FIT=y
> CONFIG_SPL_LOAD_FIT_ADDRESS=0x81000000
> -CONFIG_DISTRO_DEFAULTS=y
> -CONFIG_BOOTCOMMAND="run envboot; run distro_bootcmd;"
> +CONFIG_BOOTSTD_FULL=y
> +CONFIG_BOOTSTD_DEFAULTS=y
> +CONFIG_BOOTCOMMAND="run envboot; bootflow scan -lb"
> CONFIG_BOARD_LATE_INIT=y
> CONFIG_SPL_MAX_SIZE=0x180000
> CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
> diff --git a/include/configs/am64x_evm.h b/include/configs/am64x_evm.h
> index 062102a610..f9f8c7bc2f 100644
> --- a/include/configs/am64x_evm.h
> +++ b/include/configs/am64x_evm.h
> @@ -9,15 +9,6 @@
> #ifndef __CONFIG_AM642_EVM_H
> #define __CONFIG_AM642_EVM_H
>
> -#include <linux/sizes.h>
> -#include <config_distro_bootcmd.h>
> -#include <env/ti/mmc.h>
> -#include <asm/arch/am64_hardware.h>
> -#include <env/ti/k3_dfu.h>
> -
> -/* DDR Configuration */
> -#define CFG_SYS_SDRAM_BASE1 0x880000000
> -
> /* Now for the remaining common defines */
> #include <configs/ti_armv7_common.h>
>
> --
> 2.34.1
>
Reviewed-by: Nishanth Menon <nm@ti.com>
--
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 849D 1736 249D
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 13:06 ` [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow Roger Quadros
2023-10-05 13:30 ` Nishanth Menon
@ 2023-10-05 15:01 ` Simon Glass
2023-10-05 16:31 ` Tom Rini
2023-10-12 21:03 ` Tom Rini
2 siblings, 1 reply; 12+ messages in thread
From: Simon Glass @ 2023-10-05 15:01 UTC (permalink / raw)
To: Roger Quadros
Cc: trini, nm, vigneshr, m-chawdhry, jonas, srk, afd, bb, praneeth,
u-boot
Hi Roger,
On Thu, 5 Oct 2023 at 07:07, Roger Quadros <rogerq@kernel.org> wrote:
>
> Switch to using bootstd. Note with this change, we will stop using
> distro_bootcmd and instead depend entirely on bootflow method of
> starting the system up.
>
> Drop header files that are no longer needed in am64x_evm.h.
> k3_dfu.h is available via k3_dfu.env in am64x.env.
>
> Drop unused macro CFG_SYS_SDRAM_BASE1.
>
> Signed-off-by: Roger Quadros <rogerq@kernel.org>
> ---
> board/ti/am64x/am64x.env | 1 +
> configs/am64x_evm_a53_defconfig | 5 +++--
> include/configs/am64x_evm.h | 9 ---------
> 3 files changed, 4 insertions(+), 11 deletions(-)
>
> diff --git a/board/ti/am64x/am64x.env b/board/ti/am64x/am64x.env
> index 68e42222b7..efd736b99b 100644
> --- a/board/ti/am64x/am64x.env
> +++ b/board/ti/am64x/am64x.env
> @@ -15,6 +15,7 @@ console=ttyS2,115200n8
> args_all=setenv optargs earlycon=ns16550a,mmio32,0x02800000 ${mtdparts}
> run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
>
> +boot_targets=mmc1 mmc0 usb pxe dhcp
> boot=mmc
> mmcdev=1
> bootpart=1:2
> diff --git a/configs/am64x_evm_a53_defconfig b/configs/am64x_evm_a53_defconfig
> index 718ad176cb..43bfcf957a 100644
> --- a/configs/am64x_evm_a53_defconfig
> +++ b/configs/am64x_evm_a53_defconfig
> @@ -31,8 +31,9 @@ CONFIG_SPL_SPI=y
> # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
> CONFIG_SPL_LOAD_FIT=y
> CONFIG_SPL_LOAD_FIT_ADDRESS=0x81000000
> -CONFIG_DISTRO_DEFAULTS=y
> -CONFIG_BOOTCOMMAND="run envboot; run distro_bootcmd;"
> +CONFIG_BOOTSTD_FULL=y
> +CONFIG_BOOTSTD_DEFAULTS=y
> +CONFIG_BOOTCOMMAND="run envboot; bootflow scan -lb"
> CONFIG_BOARD_LATE_INIT=y
> CONFIG_SPL_MAX_SIZE=0x180000
> CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
> diff --git a/include/configs/am64x_evm.h b/include/configs/am64x_evm.h
> index 062102a610..f9f8c7bc2f 100644
> --- a/include/configs/am64x_evm.h
> +++ b/include/configs/am64x_evm.h
> @@ -9,15 +9,6 @@
> #ifndef __CONFIG_AM642_EVM_H
> #define __CONFIG_AM642_EVM_H
>
> -#include <linux/sizes.h>
> -#include <config_distro_bootcmd.h>
> -#include <env/ti/mmc.h>
> -#include <asm/arch/am64_hardware.h>
> -#include <env/ti/k3_dfu.h>
> -
> -/* DDR Configuration */
> -#define CFG_SYS_SDRAM_BASE1 0x880000000
> -
> /* Now for the remaining common defines */
> #include <configs/ti_armv7_common.h>
It looks like this file still includes distro_bootcmd and defines all
the BOOT_TARGET things. Can they be dropped? Perhaps for now they
could be put behind an #ifdef if other boards need them?
I suspect that with your patch as is, the environment is still full of scripts?
>
> --
> 2.34.1
>
Regards,
Simon
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 15:01 ` Simon Glass
@ 2023-10-05 16:31 ` Tom Rini
2023-10-05 17:14 ` Nishanth Menon
2023-10-05 17:22 ` Simon Glass
0 siblings, 2 replies; 12+ messages in thread
From: Tom Rini @ 2023-10-05 16:31 UTC (permalink / raw)
To: Simon Glass
Cc: Roger Quadros, nm, vigneshr, m-chawdhry, jonas, srk, afd, bb,
praneeth, u-boot
[-- Attachment #1: Type: text/plain, Size: 3223 bytes --]
On Thu, Oct 05, 2023 at 09:01:42AM -0600, Simon Glass wrote:
> Hi Roger,
>
> On Thu, 5 Oct 2023 at 07:07, Roger Quadros <rogerq@kernel.org> wrote:
> >
> > Switch to using bootstd. Note with this change, we will stop using
> > distro_bootcmd and instead depend entirely on bootflow method of
> > starting the system up.
> >
> > Drop header files that are no longer needed in am64x_evm.h.
> > k3_dfu.h is available via k3_dfu.env in am64x.env.
> >
> > Drop unused macro CFG_SYS_SDRAM_BASE1.
> >
> > Signed-off-by: Roger Quadros <rogerq@kernel.org>
> > ---
> > board/ti/am64x/am64x.env | 1 +
> > configs/am64x_evm_a53_defconfig | 5 +++--
> > include/configs/am64x_evm.h | 9 ---------
> > 3 files changed, 4 insertions(+), 11 deletions(-)
> >
> > diff --git a/board/ti/am64x/am64x.env b/board/ti/am64x/am64x.env
> > index 68e42222b7..efd736b99b 100644
> > --- a/board/ti/am64x/am64x.env
> > +++ b/board/ti/am64x/am64x.env
> > @@ -15,6 +15,7 @@ console=ttyS2,115200n8
> > args_all=setenv optargs earlycon=ns16550a,mmio32,0x02800000 ${mtdparts}
> > run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
> >
> > +boot_targets=mmc1 mmc0 usb pxe dhcp
> > boot=mmc
> > mmcdev=1
> > bootpart=1:2
> > diff --git a/configs/am64x_evm_a53_defconfig b/configs/am64x_evm_a53_defconfig
> > index 718ad176cb..43bfcf957a 100644
> > --- a/configs/am64x_evm_a53_defconfig
> > +++ b/configs/am64x_evm_a53_defconfig
> > @@ -31,8 +31,9 @@ CONFIG_SPL_SPI=y
> > # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
> > CONFIG_SPL_LOAD_FIT=y
> > CONFIG_SPL_LOAD_FIT_ADDRESS=0x81000000
> > -CONFIG_DISTRO_DEFAULTS=y
> > -CONFIG_BOOTCOMMAND="run envboot; run distro_bootcmd;"
> > +CONFIG_BOOTSTD_FULL=y
> > +CONFIG_BOOTSTD_DEFAULTS=y
> > +CONFIG_BOOTCOMMAND="run envboot; bootflow scan -lb"
> > CONFIG_BOARD_LATE_INIT=y
> > CONFIG_SPL_MAX_SIZE=0x180000
> > CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
> > diff --git a/include/configs/am64x_evm.h b/include/configs/am64x_evm.h
> > index 062102a610..f9f8c7bc2f 100644
> > --- a/include/configs/am64x_evm.h
> > +++ b/include/configs/am64x_evm.h
> > @@ -9,15 +9,6 @@
> > #ifndef __CONFIG_AM642_EVM_H
> > #define __CONFIG_AM642_EVM_H
> >
> > -#include <linux/sizes.h>
> > -#include <config_distro_bootcmd.h>
> > -#include <env/ti/mmc.h>
> > -#include <asm/arch/am64_hardware.h>
> > -#include <env/ti/k3_dfu.h>
> > -
> > -/* DDR Configuration */
> > -#define CFG_SYS_SDRAM_BASE1 0x880000000
> > -
> > /* Now for the remaining common defines */
> > #include <configs/ti_armv7_common.h>
>
> It looks like this file still includes distro_bootcmd and defines all
> the BOOT_TARGET things. Can they be dropped? Perhaps for now they
> could be put behind an #ifdef if other boards need them?
>
> I suspect that with your patch as is, the environment is still full of scripts?
There's a lot of TI platforms, so I'm not sure what "#if" you're
thinking of might make it cleaner? We could / should move some of the
still relevant content and comments from that file to
include/env/ti/ti_armv7_common.env as I do think some of the K3
platforms could just drop <configs/ti_armv7_common.h> at this point.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 16:31 ` Tom Rini
@ 2023-10-05 17:14 ` Nishanth Menon
2023-10-05 17:19 ` Tom Rini
2023-10-05 17:22 ` Simon Glass
1 sibling, 1 reply; 12+ messages in thread
From: Nishanth Menon @ 2023-10-05 17:14 UTC (permalink / raw)
To: Tom Rini
Cc: Simon Glass, Roger Quadros, vigneshr, m-chawdhry, jonas, srk, afd,
bb, praneeth, u-boot
On 12:31-20231005, Tom Rini wrote:
[...]
> > > /* Now for the remaining common defines */
> > > #include <configs/ti_armv7_common.h>
> >
> > It looks like this file still includes distro_bootcmd and defines all
> > the BOOT_TARGET things. Can they be dropped? Perhaps for now they
> > could be put behind an #ifdef if other boards need them?
> >
> > I suspect that with your patch as is, the environment is still full of scripts?
>
> There's a lot of TI platforms, so I'm not sure what "#if" you're
> thinking of might make it cleaner? We could / should move some of the
> still relevant content and comments from that file to
> include/env/ti/ti_armv7_common.env as I do think some of the K3
> platforms could just drop <configs/ti_armv7_common.h> at this point.
Is'nt the header distro_bootcmd.h and related stuff under #ifdef
CONFIG_DISTRO_DEFAULTS already?
So, all we are picking up in effect is really CFG_SYS_SDRAM_BASE - which
is consistent across platforms.
--
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 849D 1736 249D
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 17:14 ` Nishanth Menon
@ 2023-10-05 17:19 ` Tom Rini
0 siblings, 0 replies; 12+ messages in thread
From: Tom Rini @ 2023-10-05 17:19 UTC (permalink / raw)
To: Nishanth Menon
Cc: Simon Glass, Roger Quadros, vigneshr, m-chawdhry, jonas, srk, afd,
bb, praneeth, u-boot
[-- Attachment #1: Type: text/plain, Size: 1166 bytes --]
On Thu, Oct 05, 2023 at 12:14:07PM -0500, Nishanth Menon wrote:
> On 12:31-20231005, Tom Rini wrote:
> [...]
>
> > > > /* Now for the remaining common defines */
> > > > #include <configs/ti_armv7_common.h>
> > >
> > > It looks like this file still includes distro_bootcmd and defines all
> > > the BOOT_TARGET things. Can they be dropped? Perhaps for now they
> > > could be put behind an #ifdef if other boards need them?
> > >
> > > I suspect that with your patch as is, the environment is still full of scripts?
> >
> > There's a lot of TI platforms, so I'm not sure what "#if" you're
> > thinking of might make it cleaner? We could / should move some of the
> > still relevant content and comments from that file to
> > include/env/ti/ti_armv7_common.env as I do think some of the K3
> > platforms could just drop <configs/ti_armv7_common.h> at this point.
>
> Is'nt the header distro_bootcmd.h and related stuff under #ifdef
> CONFIG_DISTRO_DEFAULTS already?
That's true too. The file (and probably all of the other *common.h
ones) likely need some cleaning out of dead comments, etc, from the
Kconfig migration.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 16:31 ` Tom Rini
2023-10-05 17:14 ` Nishanth Menon
@ 2023-10-05 17:22 ` Simon Glass
2023-10-06 9:53 ` Roger Quadros
1 sibling, 1 reply; 12+ messages in thread
From: Simon Glass @ 2023-10-05 17:22 UTC (permalink / raw)
To: Tom Rini
Cc: Roger Quadros, nm, vigneshr, m-chawdhry, jonas, srk, afd, bb,
praneeth, u-boot
Hi Tom,
On Thu, 5 Oct 2023 at 10:31, Tom Rini <trini@konsulko.com> wrote:
>
> On Thu, Oct 05, 2023 at 09:01:42AM -0600, Simon Glass wrote:
> > Hi Roger,
> >
> > On Thu, 5 Oct 2023 at 07:07, Roger Quadros <rogerq@kernel.org> wrote:
> > >
> > > Switch to using bootstd. Note with this change, we will stop using
> > > distro_bootcmd and instead depend entirely on bootflow method of
> > > starting the system up.
> > >
> > > Drop header files that are no longer needed in am64x_evm.h.
> > > k3_dfu.h is available via k3_dfu.env in am64x.env.
> > >
> > > Drop unused macro CFG_SYS_SDRAM_BASE1.
> > >
> > > Signed-off-by: Roger Quadros <rogerq@kernel.org>
> > > ---
> > > board/ti/am64x/am64x.env | 1 +
> > > configs/am64x_evm_a53_defconfig | 5 +++--
> > > include/configs/am64x_evm.h | 9 ---------
> > > 3 files changed, 4 insertions(+), 11 deletions(-)
> > >
> > > diff --git a/board/ti/am64x/am64x.env b/board/ti/am64x/am64x.env
> > > index 68e42222b7..efd736b99b 100644
> > > --- a/board/ti/am64x/am64x.env
> > > +++ b/board/ti/am64x/am64x.env
> > > @@ -15,6 +15,7 @@ console=ttyS2,115200n8
> > > args_all=setenv optargs earlycon=ns16550a,mmio32,0x02800000 ${mtdparts}
> > > run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
> > >
> > > +boot_targets=mmc1 mmc0 usb pxe dhcp
> > > boot=mmc
> > > mmcdev=1
> > > bootpart=1:2
> > > diff --git a/configs/am64x_evm_a53_defconfig b/configs/am64x_evm_a53_defconfig
> > > index 718ad176cb..43bfcf957a 100644
> > > --- a/configs/am64x_evm_a53_defconfig
> > > +++ b/configs/am64x_evm_a53_defconfig
> > > @@ -31,8 +31,9 @@ CONFIG_SPL_SPI=y
> > > # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
> > > CONFIG_SPL_LOAD_FIT=y
> > > CONFIG_SPL_LOAD_FIT_ADDRESS=0x81000000
> > > -CONFIG_DISTRO_DEFAULTS=y
> > > -CONFIG_BOOTCOMMAND="run envboot; run distro_bootcmd;"
> > > +CONFIG_BOOTSTD_FULL=y
> > > +CONFIG_BOOTSTD_DEFAULTS=y
> > > +CONFIG_BOOTCOMMAND="run envboot; bootflow scan -lb"
> > > CONFIG_BOARD_LATE_INIT=y
> > > CONFIG_SPL_MAX_SIZE=0x180000
> > > CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
> > > diff --git a/include/configs/am64x_evm.h b/include/configs/am64x_evm.h
> > > index 062102a610..f9f8c7bc2f 100644
> > > --- a/include/configs/am64x_evm.h
> > > +++ b/include/configs/am64x_evm.h
> > > @@ -9,15 +9,6 @@
> > > #ifndef __CONFIG_AM642_EVM_H
> > > #define __CONFIG_AM642_EVM_H
> > >
> > > -#include <linux/sizes.h>
> > > -#include <config_distro_bootcmd.h>
> > > -#include <env/ti/mmc.h>
> > > -#include <asm/arch/am64_hardware.h>
> > > -#include <env/ti/k3_dfu.h>
> > > -
> > > -/* DDR Configuration */
> > > -#define CFG_SYS_SDRAM_BASE1 0x880000000
> > > -
> > > /* Now for the remaining common defines */
> > > #include <configs/ti_armv7_common.h>
> >
> > It looks like this file still includes distro_bootcmd and defines all
> > the BOOT_TARGET things. Can they be dropped? Perhaps for now they
> > could be put behind an #ifdef if other boards need them?
> >
> > I suspect that with your patch as is, the environment is still full of scripts?
>
> There's a lot of TI platforms, so I'm not sure what "#if" you're
> thinking of might make it cleaner? We could / should move some of the
> still relevant content and comments from that file to
> include/env/ti/ti_armv7_common.env as I do think some of the K3
> platforms could just drop <configs/ti_armv7_common.h> at this point.
OK so if they are using text env then the header-file stuff doesn't
matter since I believe it is ignored? I was thinking of something
like:
#ifdef CONFIG_DISTRO_DEFAULTS
do all the distro #defines
#endif
Regards,
Simon
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 17:22 ` Simon Glass
@ 2023-10-06 9:53 ` Roger Quadros
0 siblings, 0 replies; 12+ messages in thread
From: Roger Quadros @ 2023-10-06 9:53 UTC (permalink / raw)
To: Simon Glass, Tom Rini
Cc: nm, vigneshr, m-chawdhry, jonas, srk, afd, bb, praneeth, u-boot
Hi Simon,
On 05/10/2023 20:22, Simon Glass wrote:
> Hi Tom,
>
> On Thu, 5 Oct 2023 at 10:31, Tom Rini <trini@konsulko.com> wrote:
>>
>> On Thu, Oct 05, 2023 at 09:01:42AM -0600, Simon Glass wrote:
>>> Hi Roger,
>>>
>>> On Thu, 5 Oct 2023 at 07:07, Roger Quadros <rogerq@kernel.org> wrote:
>>>>
>>>> Switch to using bootstd. Note with this change, we will stop using
>>>> distro_bootcmd and instead depend entirely on bootflow method of
>>>> starting the system up.
>>>>
>>>> Drop header files that are no longer needed in am64x_evm.h.
>>>> k3_dfu.h is available via k3_dfu.env in am64x.env.
>>>>
>>>> Drop unused macro CFG_SYS_SDRAM_BASE1.
>>>>
>>>> Signed-off-by: Roger Quadros <rogerq@kernel.org>
>>>> ---
>>>> board/ti/am64x/am64x.env | 1 +
>>>> configs/am64x_evm_a53_defconfig | 5 +++--
>>>> include/configs/am64x_evm.h | 9 ---------
>>>> 3 files changed, 4 insertions(+), 11 deletions(-)
>>>>
>>>> diff --git a/board/ti/am64x/am64x.env b/board/ti/am64x/am64x.env
>>>> index 68e42222b7..efd736b99b 100644
>>>> --- a/board/ti/am64x/am64x.env
>>>> +++ b/board/ti/am64x/am64x.env
>>>> @@ -15,6 +15,7 @@ console=ttyS2,115200n8
>>>> args_all=setenv optargs earlycon=ns16550a,mmio32,0x02800000 ${mtdparts}
>>>> run_kern=booti ${loadaddr} ${rd_spec} ${fdtaddr}
>>>>
>>>> +boot_targets=mmc1 mmc0 usb pxe dhcp
>>>> boot=mmc
>>>> mmcdev=1
>>>> bootpart=1:2
>>>> diff --git a/configs/am64x_evm_a53_defconfig b/configs/am64x_evm_a53_defconfig
>>>> index 718ad176cb..43bfcf957a 100644
>>>> --- a/configs/am64x_evm_a53_defconfig
>>>> +++ b/configs/am64x_evm_a53_defconfig
>>>> @@ -31,8 +31,9 @@ CONFIG_SPL_SPI=y
>>>> # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
>>>> CONFIG_SPL_LOAD_FIT=y
>>>> CONFIG_SPL_LOAD_FIT_ADDRESS=0x81000000
>>>> -CONFIG_DISTRO_DEFAULTS=y
>>>> -CONFIG_BOOTCOMMAND="run envboot; run distro_bootcmd;"
>>>> +CONFIG_BOOTSTD_FULL=y
>>>> +CONFIG_BOOTSTD_DEFAULTS=y
>>>> +CONFIG_BOOTCOMMAND="run envboot; bootflow scan -lb"
>>>> CONFIG_BOARD_LATE_INIT=y
>>>> CONFIG_SPL_MAX_SIZE=0x180000
>>>> CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
>>>> diff --git a/include/configs/am64x_evm.h b/include/configs/am64x_evm.h
>>>> index 062102a610..f9f8c7bc2f 100644
>>>> --- a/include/configs/am64x_evm.h
>>>> +++ b/include/configs/am64x_evm.h
>>>> @@ -9,15 +9,6 @@
>>>> #ifndef __CONFIG_AM642_EVM_H
>>>> #define __CONFIG_AM642_EVM_H
>>>>
>>>> -#include <linux/sizes.h>
>>>> -#include <config_distro_bootcmd.h>
>>>> -#include <env/ti/mmc.h>
>>>> -#include <asm/arch/am64_hardware.h>
>>>> -#include <env/ti/k3_dfu.h>
>>>> -
>>>> -/* DDR Configuration */
>>>> -#define CFG_SYS_SDRAM_BASE1 0x880000000
>>>> -
>>>> /* Now for the remaining common defines */
>>>> #include <configs/ti_armv7_common.h>
>>>
>>> It looks like this file still includes distro_bootcmd and defines all
>>> the BOOT_TARGET things. Can they be dropped? Perhaps for now they
>>> could be put behind an #ifdef if other boards need them?
>>>
>>> I suspect that with your patch as is, the environment is still full of scripts?
>>
>> There's a lot of TI platforms, so I'm not sure what "#if" you're
>> thinking of might make it cleaner? We could / should move some of the
>> still relevant content and comments from that file to
>> include/env/ti/ti_armv7_common.env as I do think some of the K3
>> platforms could just drop <configs/ti_armv7_common.h> at this point.
>
> OK so if they are using text env then the header-file stuff doesn't
> matter since I believe it is ignored? I was thinking of something
> like:
>
> #ifdef CONFIG_DISTRO_DEFAULTS
>
> do all the distro #defines
>
> #endif
This is already done, although within #ifdef CONFIG_ARM64 ...
All we are picking up is really CFG_SYS_SDRAM_BASE.
Cleaning up ti_armv7_common.h should be a separate series and
involve testing on all affected platforms (entire TI range) :P.
--
cheers,
-roger
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 1/2] board: ti: am62x: am62x.env: Fix boot_targets
2023-10-05 13:06 ` [PATCH v2 1/2] board: ti: am62x: am62x.env: Fix boot_targets Roger Quadros
@ 2023-10-12 21:03 ` Tom Rini
0 siblings, 0 replies; 12+ messages in thread
From: Tom Rini @ 2023-10-12 21:03 UTC (permalink / raw)
To: Roger Quadros
Cc: nm, vigneshr, m-chawdhry, sjg, jonas, srk, afd, bb, praneeth,
u-boot
[-- Attachment #1: Type: text/plain, Size: 331 bytes --]
On Thu, Oct 05, 2023 at 04:06:41PM +0300, Roger Quadros wrote:
> ti_mmc is not a valid boot_target for standard boot flow so
> remove it. Prefer mmc1 (sd-card) over mmc0 (emmc).
>
> Signed-off-by: Roger Quadros <rogerq@kernel.org>
> Reviewed-by: Nishanth Menon <nm@ti.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow
2023-10-05 13:06 ` [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow Roger Quadros
2023-10-05 13:30 ` Nishanth Menon
2023-10-05 15:01 ` Simon Glass
@ 2023-10-12 21:03 ` Tom Rini
2 siblings, 0 replies; 12+ messages in thread
From: Tom Rini @ 2023-10-12 21:03 UTC (permalink / raw)
To: Roger Quadros
Cc: nm, vigneshr, m-chawdhry, sjg, jonas, srk, afd, bb, praneeth,
u-boot
[-- Attachment #1: Type: text/plain, Size: 546 bytes --]
On Thu, Oct 05, 2023 at 04:06:42PM +0300, Roger Quadros wrote:
> Switch to using bootstd. Note with this change, we will stop using
> distro_bootcmd and instead depend entirely on bootflow method of
> starting the system up.
>
> Drop header files that are no longer needed in am64x_evm.h.
> k3_dfu.h is available via k3_dfu.env in am64x.env.
>
> Drop unused macro CFG_SYS_SDRAM_BASE1.
>
> Signed-off-by: Roger Quadros <rogerq@kernel.org>
> Reviewed-by: Nishanth Menon <nm@ti.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2023-10-12 21:53 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-05 13:06 [PATCH v2 0/2] board: ti: am6x: Switch to standard boot Roger Quadros
2023-10-05 13:06 ` [PATCH v2 1/2] board: ti: am62x: am62x.env: Fix boot_targets Roger Quadros
2023-10-12 21:03 ` Tom Rini
2023-10-05 13:06 ` [PATCH v2 2/2] board: ti: am64x: Switch to standard boot flow Roger Quadros
2023-10-05 13:30 ` Nishanth Menon
2023-10-05 15:01 ` Simon Glass
2023-10-05 16:31 ` Tom Rini
2023-10-05 17:14 ` Nishanth Menon
2023-10-05 17:19 ` Tom Rini
2023-10-05 17:22 ` Simon Glass
2023-10-06 9:53 ` Roger Quadros
2023-10-12 21:03 ` Tom Rini
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox