arm: mvebu: turris_omnia: Fix RESET button message
PATCH 1/5 arm: mvebu: turris_omnia: Fix RESET button message
--- board/CZ.NIC/turris_omnia/turris_omnia.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
board/CZ.NIC/turris_omnia/turris_omnia.c +1 -1
@@ -488,7 +488,7 @@ static void handle_reset_button(void)/* Ensure bootcmd_rescue is used by distroboot */ env_set ("boot_targets" ,"rescue" ); -printf ("RESET button was pressed, overwriting bootcmd!\n" ); +printf ("RESET button was pressed, overwriting boot_targets!\n" ); }else {/* * In case the user somehow managed to save environment with
Signature · 1 line
2.20.1
PATCH 2/5 arm: mvebu: turris_omnia: Define CONFIG_ETHPRIME instead of ethact= ENV
CONFIG_ETHPRIME defines primary ethernet device and env variable $ethact stores currently active ethernet device.
So there is no point to set ethact= in default environment. Instead set CONFIG_ETHPRIME properly.
--- include/configs/turris_omnia.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
include/configs/turris_omnia.h +2 -1
@@ -26,6 +26,8 @@"fdt_high=0x10000000\0" \ "initrd_high=0x10000000\0" +#define CONFIG_ETHPRIME "ethernet@34000" +/* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10)#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000))
@@ -119,7 +121,6 @@LOAD_ADDRESS_ENV_SETTINGS \"fdtfile=" CONFIG_DEFAULT_DEVICE_TREE ".dtb\0" \"console=ttyS0,115200\0" \ -"ethact=ethernet@34000\0" \"bootcmd_rescue=" TURRIS_OMNIA_BOOTCMD_RESCUE "\0" \BOOTENV
Signature · 1 line
2.20.1
Re: [PATCH 2/5] arm: mvebu: turris_omnia: Define CONFIG_ETHPRIME instead of ethact= ENV
Quoted 7 lines · On Wed, 6 Apr 2022 11:39:33 +0200 Pali Rohár <[email protected]> wrote:
CONFIG_ETHPRIMEdefines primary ethernet device and env variable $ethact stores currently active ethernet device.So there is no point to set ethact= in default environment. Instead set
CONFIG_ETHPRIMEproperly.Signed-off-by Pali Rohár <[email protected]>
Re: [PATCH 2/5] arm: mvebu: turris_omnia: Define CONFIG_ETHPRIME instead of ethact= ENV
In reply to Pali RohárQuoted 16 lines · Pali Rohár
CONFIG_ETHPRIMEdefines primary ethernet device and env variable $ethact stores currently active ethernet device.So there is no point to set ethact= in default environment. Instead set
CONFIG_ETHPRIMEproperly.Signed-off-by Pali Rohár <[email protected]>--- include/configs/turris_omnia.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)include/configs/turris_omnia.h +0
-0
include/configs/turris_omnia.h line 30
Quoted 5 lines
include/configs/turris_omnia.h +2
-0@@ -26,6 +26,8 @@"fdt_high=0x10000000\0" \"initrd_high=0x10000000\0" +#define CONFIG_ETHPRIME "ethernet@34000" +
This was moved to Kconfig in the meantime. I'll make the necessary myself, no need to resend.
Thanks,
Stefan
include/configs/turris_omnia.h line 126
Quoted 11 lines
include/configs/turris_omnia.h +0
-1/* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10)#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000))@@ -119,7 +121,6 @@LOAD_ADDRESS_ENV_SETTINGS \"fdtfile=" CONFIG_DEFAULT_DEVICE_TREE ".dtb\0" \"console=ttyS0,115200\0" \ -"ethact=ethernet@34000\0" \"bootcmd_rescue=" TURRIS_OMNIA_BOOTCMD_RESCUE "\0" \BOOTENV
Viele Grüße,
Stefan Roese
Signature · 3 lines
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: [email protected]
Re: [PATCH 2/5] arm: mvebu: turris_omnia: Define CONFIG_ETHPRIME instead of ethact= ENV
In reply to Pali RohárQuoted 25 lines · Pali Rohár
CONFIG_ETHPRIMEdefines primary ethernet device and env variable $ethact stores currently active ethernet device.So there is no point to set ethact= in default environment. Instead set
CONFIG_ETHPRIMEproperly.Signed-off-by Pali Rohár <[email protected]>--- include/configs/turris_omnia.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)include/configs/turris_omnia.h +2
-0@@ -26,6 +26,8 @@"fdt_high=0x10000000\0" \ "initrd_high=0x10000000\0" +#define CONFIG_ETHPRIME "ethernet@34000" +/* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10)#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000))
include/configs/turris_omnia.h line 126
Quoted 7 lines
include/configs/turris_omnia.h +0
-1@@ -119,7 +121,6 @@LOAD_ADDRESS_ENV_SETTINGS \"fdtfile=" CONFIG_DEFAULT_DEVICE_TREE ".dtb\0" \"console=ttyS0,115200\0" \ -"ethact=ethernet@34000\0" \"bootcmd_rescue=" TURRIS_OMNIA_BOOTCMD_RESCUE "\0" \BOOTENV
Applied to u-boot-marvell/master
Thanks,
Stefan
PATCH 3/5 arm: mvebu: turris_omnia: Always enable MMC, SCSI and USB boot targets
In reply to Pali RohárU-Boot for Turris Omnia is always compiled with MMC, SCSI and USB support, so always enable macros for booting from these devices.
--- include/configs/turris_omnia.h | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-)
include/configs/turris_omnia.h +3 -21
@@ -54,28 +54,10 @@/* Include the common distro boot environment */ #ifndef CONFIG_SPL_BUILD -#ifdef CONFIG_MMC -#define BOOT_TARGET_DEVICES_MMC (func) func(MMC, mmc, 0) -#else -#define BOOT_TARGET_DEVICES_MMC (func) -#endif - -#ifdef CONFIG_USB_STORAGE -#define BOOT_TARGET_DEVICES_USB (func) func(USB, usb, 0) -#else -#define BOOT_TARGET_DEVICES_USB (func) -#endif - -#ifdef CONFIG_SCSI -#define BOOT_TARGET_DEVICES_SCSI (func) func(SCSI, scsi, 0) -#else -#define BOOT_TARGET_DEVICES_SCSI (func) -#endif -#define BOOT_TARGET_DEVICES (func) \ - BOOT_TARGET_DEVICES_MMC(func) \ - BOOT_TARGET_DEVICES_SCSI(func) \ - BOOT_TARGET_DEVICES_USB(func) \ + func(MMC, mmc, 0) \ + func(SCSI, scsi, 0) \ + func(USB, usb, 0) \ func(PXE, pxe, na) \ func(DHCP, dhcp, na)
Signature · 1 line
2.20.1
Re: [PATCH 3/5] arm: mvebu: turris_omnia: Always enable MMC, SCSI and USB boot targets
Quoted 2 lines · On Wed, 6 Apr 2022 11:39:34 +0200 Pali Rohár <[email protected]> wrote:
U-Boot for Turris Omnia is always compiled with MMC, SCSI and USB support, so always enable macros for booting from these devices.
This is not true. Attaching config where scsi is disabled.
If we want to enforce MMC, SCSI and USB, we should add
select MMC
and others to Kconfig under TURRIS_OMNIA. But do we want to enfore these?
Marek
Re: [PATCH 3/5] arm: mvebu: turris_omnia: Always enable MMC, SCSI and USB boot targets
Quoted 6 lines · On Wednesday 06 April 2022 21:31:18 Marek Behún wrote:
Quoted 2 lines · On Wed, 6 Apr 2022 11:39:34 +0200 Pali Rohár <[email protected]> wrote:
U-Boot for Turris Omnia is always compiled with MMC, SCSI and USB support, so always enable macros for booting from these devices.
Quoted 8 lines
This is not true. Attaching config where scsi is disabled.
If we want to enforce MMC, SCSI and USB, we should add
select MMC
and others toKconfigunderTURRIS_OMNIA. But do we want to enfore these?Marek
IIRC macro BOOT_TARGET_DEVICES just defines default values for ENV. So in default ENV would be macros for booting from SCSI, MMC and USB targets. Which means that if you call saveenv on U-Boot compiled with all these options and then replace U-Boot with the one without e.g. MMC support, it does not replace env variables for MMC booting.
Anyway, does not defining e.g. SCSI booting env variables on U-Boot without SCSI support result in the same state as defining SCSI booting env variables on U-Boot with SCSI support with disconnected SCSI controllers or disks? In both cases there would be no SCSI suitable boot device.
Re: [PATCH 3/5] arm: mvebu: turris_omnia: Always enable MMC, SCSI and USB boot targets
Quoted 22 lines · On Friday 08 April 2022 11:00:24 Pali Rohár wrote:
Quoted 6 lines · On Wednesday 06 April 2022 21:31:18 Marek Behún wrote:
Quoted 2 lines · On Wed, 6 Apr 2022 11:39:34 +0200 Pali Rohár <[email protected]> wrote:
U-Boot for Turris Omnia is always compiled with MMC, SCSI and USB support, so always enable macros for booting from these devices.
Quoted 8 lines
This is not true. Attaching config where scsi is disabled.
If we want to enforce MMC, SCSI and USB, we should add
select MMC
and others toKconfigunderTURRIS_OMNIA. But do we want to enfore these?Marek
IIRC macro
BOOT_TARGET_DEVICESjust defines default values for ENV. So in default ENV would be macros for booting from SCSI, MMC and USB targets. Which means that if you call saveenv on U-Boot compiled with all these options and then replace U-Boot with the one without e.g. MMC support, it does not replace env variables for MMC booting.
Quoted 5 lines
Anyway, does not defining e.g. SCSI booting env variables on U-Boot without SCSI support result in the same state as defining SCSI booting env variables on U-Boot with SCSI support with disconnected SCSI controllers or disks? In both cases there would be no SCSI suitable boot device.
So, any issues with it?
Re: [PATCH 3/5] arm: mvebu: turris_omnia: Always enable MMC, SCSI and USB boot targets
Quoted 23 lines · On Sun, 1 May 2022 16:52:31 +0200 Pali Rohár <[email protected]> wrote:
Quoted 22 lines · On Friday 08 April 2022 11:00:24 Pali Rohár wrote:
Quoted 6 lines · On Wednesday 06 April 2022 21:31:18 Marek Behún wrote:
Quoted 2 lines · On Wed, 6 Apr 2022 11:39:34 +0200 Pali Rohár <[email protected]> wrote:
U-Boot for Turris Omnia is always compiled with MMC, SCSI and USB support, so always enable macros for booting from these devices.
Quoted 8 lines
This is not true. Attaching config where scsi is disabled.
If we want to enforce MMC, SCSI and USB, we should add
select MMC
and others toKconfigunderTURRIS_OMNIA. But do we want to enfore these?Marek
IIRC macro
BOOT_TARGET_DEVICESjust defines default values for ENV. So in default ENV would be macros for booting from SCSI, MMC and USB targets. Which means that if you call saveenv on U-Boot compiled with all these options and then replace U-Boot with the one without e.g. MMC support, it does not replace env variables for MMC booting.
Quoted 7 lines
Quoted 5 lines
Anyway, does not defining e.g. SCSI booting env variables on U-Boot without SCSI support result in the same state as defining SCSI booting env variables on U-Boot with SCSI support with disconnected SCSI controllers or disks? In both cases there would be no SCSI suitable boot device.
So, any issues with it?
No. If this cannot cause compilation failures, then I am okay with it.
Re: [PATCH 3/5] arm: mvebu: turris_omnia: Always enable MMC, SCSI and USB boot targets
In reply to Pali RohárQuoted 34 lines · Pali Rohár
U-Boot for Turris Omnia is always compiled with MMC, SCSI and USB support, so always enable macros for booting from these devices.
Signed-off-by Pali Rohár <[email protected]>--- include/configs/turris_omnia.h | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-)include/configs/turris_omnia.h +0
-18@@ -54,28 +54,10 @@/* Include the common distro boot environment */ #ifndef CONFIG_SPL_BUILD -#ifdef CONFIG_MMC -#define BOOT_TARGET_DEVICES_MMC (func) func(MMC, mmc, 0) -#else -#define BOOT_TARGET_DEVICES_MMC (func) -#endif - -#ifdef CONFIG_USB_STORAGE -#define BOOT_TARGET_DEVICES_USB (func) func(USB, usb, 0) -#else -#define BOOT_TARGET_DEVICES_USB (func) -#endif - -#ifdef CONFIG_SCSI -#define BOOT_TARGET_DEVICES_SCSI (func) func(SCSI, scsi, 0) -#else -#define BOOT_TARGET_DEVICES_SCSI (func) -#endif -
include/configs/turris_omnia.h line 63
Quoted 10 lines
include/configs/turris_omnia.h +3
-3#define BOOT_TARGET_DEVICES (func) \ - BOOT_TARGET_DEVICES_MMC(func) \ - BOOT_TARGET_DEVICES_SCSI(func) \ - BOOT_TARGET_DEVICES_USB(func) \ + func(MMC, mmc, 0) \ + func(SCSI, scsi, 0) \ + func(USB, usb, 0) \ func(PXE, pxe, na) \ func(DHCP, dhcp, na)
Applied to u-boot-marvell/master
Thanks,
Stefan
PATCH 4/5 arm: mvebu: turris_omnia: Add NVMe to boot targets
In reply to Pali RohárU-Boot for Turris Omnia has already enabled NVMe support. So add NVMe to boot targets.
--- include/configs/turris_omnia.h | 1 + 1 file changed, 1 insertion(+)
include/configs/turris_omnia.h +1 -0
@@ -56,6 +56,7 @@#define BOOT_TARGET_DEVICES (func) \ func(MMC, mmc, 0) \ + func(NVME, nvme, 0) \ func(SCSI, scsi, 0) \ func(USB, usb, 0) \ func(PXE, pxe, na) \
Signature · 1 line
2.20.1
Re: [PATCH 4/5] arm: mvebu: turris_omnia: Add NVMe to boot targets
Quoted 2 lines · On Wed, 6 Apr 2022 11:39:35 +0200 Pali Rohár <[email protected]> wrote:
U-Boot for Turris Omnia has already enabled NVMe support. So add NVMe to boot targets.
As in my previous message, an user may want to compile U-Boot without NVMe support. They can do this now with menuconfig. If NVME support is to be mandatory, it should be enforced in Kconfig.
But I don't think it should be mandatory.
Marek
Re: [PATCH 4/5] arm: mvebu: turris_omnia: Add NVMe to boot targets
In reply to Pali RohárQuoted 13 lines · Pali Rohár
U-Boot for Turris Omnia has already enabled NVMe support. So add NVMe to boot targets.
Signed-off-by Pali Rohár <[email protected]>--- include/configs/turris_omnia.h | 1 + 1 file changed, 1 insertion(+)include/configs/turris_omnia.h +0
-0
include/configs/turris_omnia.h line 62
Quoted 7 lines
include/configs/turris_omnia.h +1
-0@@ -56,6 +56,7 @@#define BOOT_TARGET_DEVICES (func) \ func(MMC, mmc, 0) \ + func(NVME, nvme, 0) \ func(SCSI, scsi, 0) \ func(USB, usb, 0) \ func(PXE, pxe, na) \
Applied to u-boot-marvell/master
Thanks,
Stefan
PATCH 5/5 arm: mvebu: turris_mox: Add NVMe and SCSI to boot targets
In reply to Pali RohárU-Boot for Turris Mox has already enabled NVMe and SCSI support. So add NVMe and SCSI to boot targets.
--- include/configs/turris_mox.h | 2 ++ 1 file changed, 2 insertions(+)
include/configs/turris_mox.h +2 -0
@@ -28,6 +28,8 @@#define BOOT_TARGET_DEVICES (func) \ func(MMC, mmc, 0) \ + func(NVME, nvme, 0) \ + func(SCSI, scsi, 0) \ func(USB, usb, 0) \ func(PXE, pxe, na) \ func(DHCP, dhcp, na)
Signature · 1 line
2.20.1
Re: [PATCH 5/5] arm: mvebu: turris_mox: Add NVMe and SCSI to boot targets
Quoted 4 lines · On Wed, 6 Apr 2022 11:39:36 +0200 Pali Rohár <[email protected]> wrote:
U-Boot for Turris Mox has already enabled NVMe and SCSI support. So add NVMe and SCSI to boot targets.
Signed-off-by Pali Rohár <[email protected]>
And for MOX I am not sure whether NVME and SCSI can be disabled in menuconfig. Either we need to update the BOOT_TARET macro or enforce all of these (MMC, NVME, SCSI, USB, NET) in Kconfig.
Marek
Re: [PATCH 5/5] arm: mvebu: turris_mox: Add NVMe and SCSI to boot targets
In reply to Pali RohárQuoted 13 lines · Pali Rohár
U-Boot for Turris Mox has already enabled NVMe and SCSI support. So add NVMe and SCSI to boot targets.
Signed-off-by Pali Rohár <[email protected]>--- include/configs/turris_mox.h | 2 ++ 1 file changed, 2 insertions(+)include/configs/turris_mox.h +0
-0
include/configs/turris_mox.h line 35
Quoted 8 lines
include/configs/turris_mox.h +2
-0@@ -28,6 +28,8 @@#define BOOT_TARGET_DEVICES (func) \ func(MMC, mmc, 0) \ + func(NVME, nvme, 0) \ + func(SCSI, scsi, 0) \ func(USB, usb, 0) \ func(PXE, pxe, na) \ func(DHCP, dhcp, na)
Applied to u-boot-marvell/master
Thanks,
Stefan
Quoted 1 line · On Wed, 6 Apr 2022 11:39:32 +0200 Pali Rohár <[email protected]> wrote:
Signed-off-by Pali Rohár <[email protected]>
nitpick: if you don't have anything to say in commit message, don't leave it empty. At least copy the commit title.
Quoted 10 lines · Pali Rohár
Signed-off-by Pali Rohár <[email protected]>--- board/CZ.NIC/turris_omnia/turris_omnia.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)board/CZ.NIC/turris_omnia/turris_omnia.c +0
-0
board/CZ.NIC/turris_omnia/turris_omnia.c static void handle_reset_button(void) · line 494
Quoted 8 lines
board/CZ.NIC/turris_omnia/turris_omnia.c +1
-1@@ -488,7 +488,7 @@ static void handle_reset_button(void)/* Ensure bootcmd_rescue is used by distroboot */ env_set ("boot_targets" ,"rescue" ); -printf ("RESET button was pressed, overwriting bootcmd!\n" ); +printf ("RESET button was pressed, overwriting boot_targets!\n" ); }else {/* * In case the user somehow managed to save environment with
Applied to u-boot-marvell/master
Thanks,
Stefan