[PATCH] nvmem: u-boot-env: fix crc32 casting type

2022-08-17 Thread Rafał Miłecki
From: Rafał Miłecki This fixes: drivers/nvmem/u-boot-env.c:141:17: sparse: sparse: cast to restricted __le32 Reported-by: kernel test robot Fixes: f955dc1445069 ("nvmem: add driver handling U-Boot environment variables") Signed-off-by: Rafał Miłecki --- drivers/nvmem/u-boot-env.c | 2 +- 1

Re: [PATCH v8 10/13] FWU: cmd: Add a command to read FWU metadata

2022-08-17 Thread Simon Glass
Hi Sugosh, On Wed, 17 Aug 2022 at 06:44, Sughosh Ganu wrote: > > Add a command to read the metadata as specified in the FWU > specification and print the fields of the metadata. > > Signed-off-by: Sughosh Ganu > Reviewed-by: Ilias Apalodimas > --- > Changes since V7: None > > cmd/Kconfig

Re: [PATCH v8 13/13] FWU: doc: Add documentation for the FWU feature

2022-08-17 Thread Simon Glass
On Wed, 17 Aug 2022 at 06:44, Sughosh Ganu wrote: > > Add documentattion for the FWU Multi Bank Update feature. The document spelling > describes the steps needed for setting up the platform for the > feature, as well as steps for enabling the feature on the platform. > > Signed-off-by: Sughosh

Re: [PATCH v8 03/13] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-08-17 Thread Simon Glass
Hi Sughosh, On Wed, 17 Aug 2022 at 06:44, Sughosh Ganu wrote: > > In the FWU Multi Bank Update feature, the information about the > updatable images is stored as part of the metadata, on a separate > partition. Add a driver for reading from and writing to the metadata > when the updatable images

Re: [PATCH v8 08/13] FWU: Add boot time checks as highlighted by the FWU specification

2022-08-17 Thread Simon Glass
Hi Sughosh, On Wed, 17 Aug 2022 at 06:44, Sughosh Ganu wrote: > > The FWU Multi Bank Update specification requires the Update Agent to > carry out certain checks at the time of platform boot. The Update > Agent is the component which is responsible for updating the firmware > components and

[PATCH v3] cmd: Add pause command

2022-08-17 Thread Samuel Dionne-Riel
This command is being introduced with the goal of allowing user-friendly "generic use case" U-Boot builds to pause until user input under some situations. The main use case would be when a boot failure happens, to pause until the user has had time to acknowledge the current state. Tested using:

[PATCH v2] cmd: Add pause command

2022-08-17 Thread Samuel Dionne-Riel
This command is being introduced with the goal of allowing user-friendly "generic use case" U-Boot builds to pause until user input under some situations. The main use case would be when a boot failure happens, to pause until the user has had time to acknowledge the current state. Tested with

Re: [PATCH v8 02/13] FWU: Add FWU metadata structure and driver for accessing metadata

2022-08-17 Thread Simon Glass
Hi Sughosh, On Wed, 17 Aug 2022 at 06:44, Sughosh Ganu wrote: > > In the FWU Multi Bank Update feature, the information about the > updatable images is stored as part of the metadata, which is stored on > a dedicated partition. Add the metadata structure, and a driver model > uclass which

Re: [PATCH] Makefile: Unify condition for mpc85xx reset vector

2022-08-17 Thread Simon Glass
On Wed, 3 Aug 2022 at 15:57, Pali Rohár wrote: > > Use 'CONFIG_MPC85XX_HAVE_RESET_VECTOR && CONFIG_OF_SEPARATE' pattern > instead of 'CONFIG_MPC85XX_HAVE_RESET_VECTOR && !CONFIG_OF_EMBED' also in > OBJCOPYFLAGS_u-boot-nodtb.bin as this pattern is used in rest of Makefile. > > Signed-off-by: Pali

Re: [GIT PULL] please pull fsl-qoriq-2022-8-17

2022-08-17 Thread Peng Fan
On 8/18/2022 6:40 AM, Tom Rini wrote: On Wed, Aug 17, 2022 at 02:26:32AM +, Peng Fan (OSS) wrote: Hi Tom, Please pull fsl-qoriq-2022-8-17 CI: https://source.denx.de/u-boot/custodians/u-boot-fsl-qoriq/-/pipelines/13155 First, applied to u-boot/master, thanks! Second, do you have any

[PATCH 3/3] arm: bcmbca: make bcm6753 driver depending on CONFIG_BCM6855

2022-08-17 Thread William Zhang
As CONFIG_ARCH_BCM6753 is replaced with CONFIG_BCM6855, update the driver Kconfig to use the new config symbol. Signed-off-by: William Zhang --- drivers/gpio/Kconfig | 2 +- drivers/led/Kconfig | 2 +- drivers/mtd/nand/raw/Kconfig | 2 +- drivers/watchdog/Kconfig | 2 +-

[PATCH 2/3] arm: bcmbca: remove bcm6753 support under CONFIG_ARCH_BCM6753

2022-08-17 Thread William Zhang
BCM6753 is essentially same as the main chip BCM6855 but with different SKU number. Now that BCM6855 is supported under CONFIG_ARCH_BCMBCA and CONFIG_BCM6855, remove the original ARCH_BCM6753 support and migrate its configuration and dts settings. This includes: - Remove the bcm96753ref board

[PATCH 1/3] arm: bcmbca: add bcm6855 SoC support under CONFIG_ARCH_BCMBCA

2022-08-17 Thread William Zhang
BCM6855 is a Broadcom ARM A7 based PON Gateway SoC. It is part of the BCA (Broadband Carrier Access origin) chipset family. Like other broadband SoC, this patch adds it under CONFIG_BCM6855 chip config and CONFIG_ARCH_BCMBCA platform config. This initial support includes a bare-bone

[PATCH 0/3] arm: bcmbca: move bcm6753 support under CONFIG_ARCH_BCMBCA

2022-08-17 Thread William Zhang
BCM6753 is essentially same as the main chip BCM6855 with different SKU number. It is part of the Broadcom BCA (Broadband Carrier Access origin) chipset family. BCM6753 was originally added by Philippe before Broadcom started to upstream the support for BCMBCA SoCs. The ARM based broadband SoC

[PATCH 3/3] arm: bcmbca: make bcm6858 driver depending on CONFIG_BCM6858

2022-08-17 Thread William Zhang
As CONFIG_ARCH_BCM6858 is replaced with CONFIG_BCM6858, update the driver Kconfig to use the new config symbol. Signed-off-by: William Zhang --- drivers/gpio/Kconfig | 3 +-- drivers/led/Kconfig | 2 +- drivers/mtd/nand/raw/Kconfig | 2 +- drivers/spi/Kconfig | 3 +--

[PATCH 2/3] arm: bcmbca: remove bcm6858 support under CONFIG_ARCH_BCM6858

2022-08-17 Thread William Zhang
Now that BCM6858 is supported under CONFIG_ARCH_BCMBCA and CONFIG_BCM6858, remove the original ARCH_BCM6858 support and migrate its configuration and dts settings. This includes: - Remove the bcm968580xref board folder. It is replaced by the generic bcmbca board folder. - Update bcm968580xref

[PATCH 1/3] arm: bcmbca: add bcm6858 SoC support under CONFIG_ARCH_BCMBCA

2022-08-17 Thread William Zhang
BCM6858 is a Broadcom B53 based PON Gateway SoC. It is part of the BCA (Broadband Carrier Access origin) chipset family. Like other broadband SoC, this patch adds it under CONFIG_BCM6858 chip config and CONFIG_ARCH_BCMBCA platform config. This initial support includes a bare-bone implementation

[PATCH 0/3] arm: bcmbca: move bcm6858 support under CONFIG_ARCH_BCMBCA BCM6858 is

2022-08-17 Thread William Zhang
part of the Broadcom BCA (Broadband Carrier Access origin) chipset family. BCM6858 was originally added by Philippe before Broadcom started to upstream the support for BCMBCA SoCs. The ARM based Broadband SoC family is now supported under the unified ARCH_BCMBCA config. This patch series migrate

[PATCH v3 3/3] arm: bcmbca: make bcm68360 driver depending on CONFIG_BCM6856

2022-08-17 Thread William Zhang
As CONFIG_ARCH_BCM68360 is replaced with CONFIG_BCM6856, update the driver Kconfig to use the new config symbol Signed-off-by: William Zhang --- (no changes since v1) drivers/gpio/Kconfig | 2 +- drivers/led/Kconfig | 2 +- drivers/mtd/nand/raw/Kconfig | 2 +-

[PATCH v3 2/3] arm: bcmbca: remove bcm68360 support under CONFIG_ARCH_BCM68360

2022-08-17 Thread William Zhang
BCM68360 is a variant within the BCM6856 chip family. Now that BCM6856 is supported under CONFIG_ARCH_BCMBCA and CONFIG_BCM6856, remove the original ARCH_BCM68360 support and migrate its configuration and dts settings. This includes: - Remove the bcm968360bg board folder. It is replaced by the

[PATCH v3 1/3] arm: bcmbca: add bcm6856 SoC support under CONFIG_ARCH_BCMBCA

2022-08-17 Thread William Zhang
BCM6856 is a Broadcom B53 based PON Gateway SoC. It is part of the BCA (Broadband Carrier Access origin) chipset family. Like other Broadband SoC, this patch adds it under CONFIG_BCM6856 chip config and CONFIG_ARCH_BCMBCA platform config. This initial support includes a bare-bone implementation

[PATCH v3 0/3] arm: bcmbca: move bcm68360 support under CONFIG_ARCH_BCMBCA

2022-08-17 Thread William Zhang
BCM68360 is a variant for the main PON chip BCM6856 which is part of the Broadcom BCA (Broadband Carrier Access origin) chipset family. BCM68360 was originally added by Philippe before Broadcom started to upstream the support for BCMBCA SoCs. The ARM based Broadband SoC family is now supported

[PATCH v2 5/5] arm: bcmbca: make reset_cpu function weak

2022-08-17 Thread William Zhang
BCM63158 carries the CONFIG_SYSRESET from the original configuration. It provide reset_cpu function already so need to define weak version of the dummy reset_cpu for other BCMBCA SoCs to avoid linking error. Signed-off-by: William Zhang --- (no changes since v1) board/broadcom/bcmbca/board.c

[PATCH v2 4/5] MAINTAINERS: Add BCM63158 maintainer to BCMBCA entry

2022-08-17 Thread William Zhang
Since ARCH_BCM63158 SoC support is merged into ARCH_BCMBCA, add BCM63158 maintainer Philippe to bcmbca maintainer list. Signed-off-by: William Zhang --- (no changes since v1) MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index

[PATCH v2 2/5] arm: bcmbca: remove bcm63158 support under CONFIG_ARCH_BCM63158

2022-08-17 Thread William Zhang
Now that BCM63158 is supported under CONFIG_ARCH_BCMBCA and CONFIG_BCM63158, remove the original ARCH_BCM63158 support and migrate configuration settings. Signed-off-by: William Zhang --- Changes in v2: - Remove bcm963158_ram_defconfig per discussion with Philippe as a basic config version of

[PATCH v2 3/5] arm: bcmbca: make bcm63158 driver depending on CONFIG_BCM63158

2022-08-17 Thread William Zhang
As CONFIG_ARCH_BCM63158 is replaced with CONFIG_BCM63158, update the driver Kconfig to use the new config symbol Signed-off-by: William Zhang --- (no changes since v1) drivers/gpio/Kconfig | 2 +- drivers/led/Kconfig | 2 +- drivers/mtd/nand/raw/Kconfig | 2 +-

[PATCH v2 1/5] arm: bcmbca: add bcm63158 SoC support under CONFIG_ARCH_BCMBCA

2022-08-17 Thread William Zhang
BCM63158 is a Broadcom B53 based DSL Gateway SoC. It is part of the BCA (Broadband Carrier Access origin) chipset family. Like other Broadband SoC, this patch adds it under CONFIG_BCM63158 chip config and CONFIG_ARCH_BCMBCA platform config. This initial support includes a bare-bone implementation

[PATCH v2 0/5] arm: bcmbca: move bcm63158 support under CONFIG_ARCH_BCMBCA

2022-08-17 Thread William Zhang
BCM63158 is one of the Broadcom Broadband origin DSL Gateway router SoC. It was originally added by Philippe before Broadcom started to upstream the support for broadband SoCs. The ARM based Broadcom Broadband SoC family is now supported under the same ARCH_BCMBCA config. This patch series migrate

Re: [PATCH 2/2] Makefile: Build final mpc85xx non-SPL image in standard file u-boot.bin

2022-08-17 Thread Simon Glass
Hi, On Wed, 17 Aug 2022 at 15:07, Pali Rohár wrote: > > On Wednesday 03 August 2022 13:28:01 Pali Rohár wrote: > > On Monday 01 August 2022 19:15:46 Tom Rini wrote: > > > On Mon, Aug 01, 2022 at 09:39:00PM +0200, Pali Rohár wrote: > > > > On Monday 01 August 2022 13:13:22 Simon Glass wrote: > >

Re: Fwd: [PATCH] [RFC] cmd: i2c: fix default address len for DM_I2C

2022-08-17 Thread Simon Glass
Hi Nicolas, On Wed, 17 Aug 2022 at 13:50, Nicolas IOOSS wrote: > > Hello all, > > On Tue, Aug 16, 2022 at 1:47 PM Simon Glass wrote: > > > > Hi Tim, > > > > On Tue, 16 Aug 2022 at 13:50, Tim Harvey wrote: > > > > > > On Mon, Aug 15, 2022 at 3:16 PM Simon Glass wrote: > > > > > > > > Hi Tim, >

Re: [GIT PULL] please pull fsl-qoriq-2022-8-17

2022-08-17 Thread Tom Rini
On Wed, Aug 17, 2022 at 02:26:32AM +, Peng Fan (OSS) wrote: > Hi Tom, > > Please pull fsl-qoriq-2022-8-17 > > CI: > https://source.denx.de/u-boot/custodians/u-boot-fsl-qoriq/-/pipelines/13155 First, applied to u-boot/master, thanks! Second, do you have any comment on the various

[PATCH] arm: kirkwood: Add CONFIG_SUPPORT_PASSING_ATAGS

2022-08-17 Thread Tony Dinh
Add CONFIG_SUPPORT_PASSING_ATAGS and friends to support legacy image method of booting. Debian and OpenWrt installer use uImage with appended DTB for these Kirkwood boards. Signed-off-by: Tony Dinh --- configs/dockstar_defconfig | 3 +++ configs/dreamplug_defconfig | 3 +++

Re: [PATCH] pci: Add checks to prevent config space overflow

2022-08-17 Thread Pali Rohár
On Monday 04 July 2022 08:00:23 Stefan Roese wrote: > On 03.07.22 12:48, Pali Rohár wrote: > > PCIe config space has address range 0-4095. So do not allow reading from > > addresses outside of this range. Lot of U-Boot drivers do not expect that > > passed value is not in this range. PCI DM read

Re: [PATCH] Makefile: Unify condition for mpc85xx reset vector

2022-08-17 Thread Pali Rohár
PING? On Wednesday 03 August 2022 23:56:55 Pali Rohár wrote: > Use 'CONFIG_MPC85XX_HAVE_RESET_VECTOR && CONFIG_OF_SEPARATE' pattern > instead of 'CONFIG_MPC85XX_HAVE_RESET_VECTOR && !CONFIG_OF_EMBED' also in > OBJCOPYFLAGS_u-boot-nodtb.bin as this pattern is used in rest of Makefile. > >

Re: [PATCH 2/2] Makefile: Build final mpc85xx non-SPL image in standard file u-boot.bin

2022-08-17 Thread Pali Rohár
On Wednesday 03 August 2022 13:28:01 Pali Rohár wrote: > On Monday 01 August 2022 19:15:46 Tom Rini wrote: > > On Mon, Aug 01, 2022 at 09:39:00PM +0200, Pali Rohár wrote: > > > On Monday 01 August 2022 13:13:22 Simon Glass wrote: > > > > Hi Pali, > > > > > > > > On Mon, 1 Aug 2022 at 09:43, Pali

Re: [PATCH] board: freescale: p1_p2_rdb_pc: Delete watchdog max6370 node in load_default mode

2022-08-17 Thread Pali Rohár
PING? (This change applies also for Turris 1.x boards; which use same CPLD firmware code) On Monday 01 August 2022 15:35:43 Pali Rohár wrote: > CPLD in load_default mode ignores watchdog reset signal. It does not reset > board when watchdog triggers reset signal. > > Detect load_default mode by

Re: [PATCH v2 1/4] board: freescale: p1_p2_rdb_pc: Add workaround for board reset reboot loop

2022-08-17 Thread Pali Rohár
PING? On Monday 01 August 2022 15:31:43 Pali Rohár wrote: > CPLD's system reset register on P1/P2 RDB boards is not autocleared after > flipping it. If this register is set to one in 100ms after reset starts > then CPLD triggers another CPU reset. > > This means that trying to reset board via

Re: [PATCH v2] board: freescale: p1_p2_rdb_pc: Calculate offsets for eSDHC boot sector

2022-08-17 Thread Pali Rohár
On Monday 01 August 2022 14:50:12 Pali Rohár wrote: > Correctly calculate offsets between SPL and proper U-Boot when new config > option CONFIG_FSL_PREPBL_ESDHC_BOOT_SECTOR for generating eSDHC boot sector > is enabled. Otherwise SPL would not be able to boot proper U-Boot. > > Signed-off-by:

Re: [PATCH RFC] Makefile: Rename u-boot-spl.kwb to u-boot-with-spl.kwb

2022-08-17 Thread Pali Rohár
On Wednesday 17 August 2022 12:05:20 Stefan Roese wrote: > On 17.08.22 11:59, Pali Rohár wrote: > > File name with pattern u-boot-spl* is used on all places except in kwb > > image for binary with SPL-only code. Combined binary with both SPL and > > proper U-Boot in other places has file name

[PATCH v2] powerpc: Add support for CZ.NIC Turris 1.x routers

2022-08-17 Thread Pali Rohár
CZ.NIC Turris 1.0 and 1.1 are open source routers, they have dual-core PowerPC Freescale P2020 CPU and are based on Freescale P2020RDB-PC-A board. Hardware design is fully open source, all firmware and hardware design files are available at Turris project website:

Re: [PATCH 04/22] timer: add orion-timer support

2022-08-17 Thread Pali Rohár
On Wednesday 17 August 2022 21:37:51 Michael Walle wrote: > Add timer support for Kirkwood and MVEBU devices. > > Cc: Pali Rohár > Signed-off-by: Michael Walle Acked-by: Pali Rohár > --- > drivers/timer/Kconfig | 6 > drivers/timer/Makefile | 1 + >

Re: [PATCH 03/22] arm: kirkwood: make it CONFIG_TIMER aware

2022-08-17 Thread Pali Rohár
On Wednesday 17 August 2022 21:37:50 Michael Walle wrote: > If we switch to CONFIG_TIMER, we don't need the legacy timer macros and > functions anymore. Add the proper guards to exclude them from compiling. > > Cc: Pali Rohár > Signed-off-by: Michael Walle Reviewed-by: Pali Rohár > --- >

Re: [PATCH 01/22] time: move the CONFIG_SYS_TIMER_RATE handling to the compiler

2022-08-17 Thread Pali Rohár
On Wednesday 17 August 2022 21:37:48 Michael Walle wrote: > CONFIG_SYS_TIMER_RATE might be a dynamic value, i.e. a function call > instead of a static value, thus it has to be evaluated at runtime. If it > is a static value, the compiler should be able to optimize the unused > branches out. > >

[PATCH 14/22] board: lsxl: use proper *_r variables

2022-08-17 Thread Michael Walle
Use the common kernel_addr_r, ramdisk_addr_r and fdt_addr_r variable names. Signed-off-by: Michael Walle --- include/configs/lsxl.h | 42 +- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/include/configs/lsxl.h b/include/configs/lsxl.h

[PATCH 18/22] board: lsxl: convert to DM_ETH

2022-08-17 Thread Michael Walle
Just enabling the Kconfig option for DM_ETH and DM_MDIO is enough. Additionally, we can remove the old hardcoded config. Signed-off-by: Michael Walle --- configs/lschlv2_defconfig | 2 ++ configs/lsxhl_defconfig | 2 ++ include/configs/lsxl.h| 8 3 files changed, 4 insertions(+),

[PATCH 17/22] board: lsxl: convert to DM_GPIO

2022-08-17 Thread Michael Walle
Use the new mvebu GPIO driver and convert all the function calls to the former kirkwood GPIO driver. This means that we are now using the LED uclass and the regulator uclass. Unfortunately, the GPIO LED doesn't offer a blinking method. Thus we are now stuck with solid on and off states, which

[PATCH 16/22] board: lsxl: make last resort recovery more reliable

2022-08-17 Thread Michael Walle
If something is wrong with the environment, we cannot rely on a proper u-boot operation anymore. In fact, it is possible, that we never reach misc_init_r() with a broken environment. Also don't enable the netconsole by environment settings. This way the user don't have to reconfigure the

[PATCH 15/22] board: lsxl: enable ATAGS support

2022-08-17 Thread Michael Walle
We still need to be able to boot legacy images. Esp. the debian installer will have a kernel with an appended DTB. Signed-off-by: Michael Walle --- configs/lschlv2_defconfig | 3 +++ configs/lsxhl_defconfig | 3 +++ 2 files changed, 6 insertions(+) diff --git a/configs/lschlv2_defconfig

[PATCH 22/22] board: lsxl: update the README

2022-08-17 Thread Michael Walle
Update the board's README to reflect all the recent changes. Signed-off-by: Michael Walle --- board/buffalo/lsxl/README | 32 +--- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/board/buffalo/lsxl/README b/board/buffalo/lsxl/README index

[PATCH 21/22] board: lsxl: disable eth0

2022-08-17 Thread Michael Walle
The board has only one network interface. The linux kernel will gracefully skip a the ethernet interface if no connected PHY could be probed. u-boot on the other hand will throw an error message. The kernel device tree is about to be fixed. For now, just disable the ethernet interface in our

[PATCH 20/22] board: lsxl: convert to CONFIG_TIMER

2022-08-17 Thread Michael Walle
Enable the orion timer driver and we are good. Signed-off-by: Michael Walle --- configs/lschlv2_defconfig | 2 ++ configs/lsxhl_defconfig | 2 ++ 2 files changed, 4 insertions(+) diff --git a/configs/lschlv2_defconfig b/configs/lschlv2_defconfig index 57e54130d2..e9cc632696 100644 ---

[PATCH 19/22] board: lsxl: convert to DM_SERIAL

2022-08-17 Thread Michael Walle
DM_SERIAL needs early malloc. The on-chip RAM is pretty tight, it's only 2kiB, with DM_SERIAL enabled, this doesn't work anymore. Fortunately for us, we don't need the on-chip RAM because the DRAM is already initialized before u-boot starts. Just put the early malloc area there and use the default

[PATCH 13/22] board: lsxl: reorder image loading and remove ramdisk_len

2022-08-17 Thread Michael Walle
We can load the ramdisk as the last step. This way we don't have to set the intermediate variable 'ramdisk_len' and can remove it. Signed-off-by: Michael Walle --- include/configs/lsxl.h | 15 ++- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/include/configs/lsxl.h

[PATCH 12/22] board: lsxl: use CONFIG_DEFAULT_FDT_FILE

2022-08-17 Thread Michael Walle
Drop our own CONFIG_FDTFILE handling in favor of the generic CONFIG_DEFAULT_FDT_FILE one. Signed-off-by: Michael Walle --- configs/lschlv2_defconfig | 1 + configs/lsxhl_defconfig | 1 + include/configs/lsxl.h| 14 +++--- 3 files changed, 5 insertions(+), 11 deletions(-) diff

[PATCH 11/22] board: lsxl: automatically select CONFIG_MISC_INIT_R

2022-08-17 Thread Michael Walle
The board code needs this to be set. Otherwise, the recovery mechanism doesn't work. Therefore, select this option automatically with the board. Signed-off-by: Michael Walle --- arch/arm/mach-kirkwood/Kconfig | 1 + board/buffalo/lsxl/lsxl.c | 2 -- configs/lschlv2_defconfig | 1 -

[PATCH 10/22] board: lsxl: remove unused header files

2022-08-17 Thread Michael Walle
Cleanup the included header files in the board code. These are all leftovers from earlier days. Signed-off-by: Michael Walle --- board/buffalo/lsxl/lsxl.c | 5 - 1 file changed, 5 deletions(-) diff --git a/board/buffalo/lsxl/lsxl.c b/board/buffalo/lsxl/lsxl.c index 106d46d436..42221eef3a

[PATCH 09/22] board: lsxl: remove CONFIG_ENV_OVERWRITE

2022-08-17 Thread Michael Walle
This is not needed. The user can force setting the variables with "setenv -f". Signed-off-by: Michael Walle --- board/buffalo/lsxl/lsxl.c | 4 configs/lschlv2_defconfig | 1 - configs/lsxhl_defconfig | 1 - 3 files changed, 6 deletions(-) diff --git a/board/buffalo/lsxl/lsxl.c

[PATCH 07/22] board: lsxl: remove unused features

2022-08-17 Thread Michael Walle
Make the binary smaller by removing unused features. Signed-off-by: Michael Walle --- configs/lschlv2_defconfig | 3 +-- configs/lsxhl_defconfig | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/configs/lschlv2_defconfig b/configs/lschlv2_defconfig index

[PATCH 08/22] board: lsxl: remove eraseenv script

2022-08-17 Thread Michael Walle
This is not needed. The user can do a "env default -f -a". Signed-off-by: Michael Walle --- include/configs/lsxl.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/include/configs/lsxl.h b/include/configs/lsxl.h index e1108619f2..db5f7a93f9 100644 --- a/include/configs/lsxl.h +++

[PATCH 06/22] board: lsxl: limit size to 384kiB

2022-08-17 Thread Michael Walle
The board only has a 4Mbit flash and two sectors are reserved for the u-boot environment and the device tree. Signed-off-by: Michael Walle --- configs/lschlv2_defconfig | 2 ++ configs/lsxhl_defconfig | 2 ++ 2 files changed, 4 insertions(+) diff --git a/configs/lschlv2_defconfig

[PATCH 05/22] button: gpio: add DM_GPIO dependency

2022-08-17 Thread Michael Walle
The gpio-button driver depends on DM_GPIO, add it to Kconfig to avoid build errors. Signed-off-by: Michael Walle --- drivers/button/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/button/Kconfig b/drivers/button/Kconfig index 6db3c5e93a..8ce2de37d6 100644 ---

[PATCH 04/22] timer: add orion-timer support

2022-08-17 Thread Michael Walle
Add timer support for Kirkwood and MVEBU devices. Cc: Pali Rohár Signed-off-by: Michael Walle --- drivers/timer/Kconfig | 6 drivers/timer/Makefile | 1 + drivers/timer/orion-timer.c | 63 + 3 files changed, 70 insertions(+) create mode

[PATCH 02/22] arm: kirkwood: 88f6281: Detect CONFIG_SYS_TCLK from SAR register

2022-08-17 Thread Michael Walle
From: Pali Rohár Bit 21 in SAR register specifies if TCLK is running at 166 MHz or 200 MHz. This information is undocumented in public Marvell Kirkwood Functional Specifications [2], but is available in Linux v3.15 kirkwood code [1]. Commit 8ac303d49f89 ("arm: kirkwood: Do not overwrite

[PATCH 01/22] time: move the CONFIG_SYS_TIMER_RATE handling to the compiler

2022-08-17 Thread Michael Walle
CONFIG_SYS_TIMER_RATE might be a dynamic value, i.e. a function call instead of a static value, thus it has to be evaluated at runtime. If it is a static value, the compiler should be able to optimize the unused branches out. This will be needed for kirkwoods dynamic CONFIG_SYS_TCLK setting. Cc:

[PATCH 03/22] arm: kirkwood: make it CONFIG_TIMER aware

2022-08-17 Thread Michael Walle
If we switch to CONFIG_TIMER, we don't need the legacy timer macros and functions anymore. Add the proper guards to exclude them from compiling. Cc: Pali Rohár Signed-off-by: Michael Walle --- arch/arm/mach-kirkwood/include/mach/config.h | 2 ++ arch/arm/mach-mvebu/Makefile | 3

[PATCH 00/22] board: lsxl: major update and DM conversion

2022-08-17 Thread Michael Walle
Convert the Buffalo Linkstation LS-CHLv2 and XHL boards to DM_GPIO, DM_ETH, DM_SERIAL and CONFIG_TIMER. Patches 01-02 fix TCLK handling on the kirkwood SoC if the clock is 166MHz. Patches 03-04 add CONFIG_TIMER support for kirkwood/mvebu. Patches 05-21 will then update the lsxl board Michael

Re: [PATCH v7] board: purism: add the Purism Librem5 phone

2022-08-17 Thread Angus Ainslie
On 2022-08-13 07:53, Fabio Estevam wrote: Hi Angus, On Sun, Aug 7, 2022 at 1:02 PM Angus Ainslie wrote: Initial commit of Librem5 u-boot and SPL All of the pre-requisite patches for this board are now upstream. Changes since v6: Move migrated symbols Rebase onto latest u-boot-imx Changes

Re: [PATCH v2 6/7] tpm: Implement state command for Cr50

2022-08-17 Thread Simon Glass
Hi Ilias, On Tue, 16 Aug 2022 at 06:43, Ilias Apalodimas wrote: > > Hi Simon, > > I know little of this device and the whole patch seems fine apart from > the definitions and declarations of the state functions. > > > On Sat, 13 Aug 2022 at 22:56, Simon Glass wrote: > > > > > > >

Re: [PATCH v2 2/7] tpm: Correct the permissions command in TPMv1

2022-08-17 Thread Simon Glass
Hi Ilias, On Tue, 16 Aug 2022 at 07:59, Ilias Apalodimas wrote: > > Hi Simon > > On Sat, 13 Aug 2022 at 22:56, Simon Glass wrote: > > > > The offset here is incorrect. Fix it. > > Since we got it wrong the first time, any chance you can give me a > link to the spec describing these offsets

Re: [PATCH 2/4] regulator: bd718x7: Only bind children when PMIC_CHILDREN is enabled

2022-08-17 Thread Simon Glass
On Wed, 17 Aug 2022 at 05:24, Adam Ford wrote: > > If the bd718x7 is required, but PMIC_CHILDREN is disabled, this > driver throws a compile error. Fix this by putting the function > to bind children into an if-statement checking for PMIC_CHILDREN. > > Allowing PMIC_CHILDREN to be disabled in

Re: [PATCH v4 07/13] binman: Add BintoolPacker class to bintool

2022-08-17 Thread Simon Glass
On Tue, 16 Aug 2022 at 02:42, Stefan Herbrechtsmeier wrote: > > From: Stefan Herbrechtsmeier > > Add a bintools base class for packers which compression / decompression > entry contents. > > Signed-off-by: Stefan Herbrechtsmeier > > --- > > (no changes since v3) > > Changes in v3: > - Document

Re: [PATCH] cmd: tpm-v2: add get_random

2022-08-17 Thread Simon Glass
Hi Ilias, On Wed, 17 Aug 2022 at 06:13, Ilias Apalodimas wrote: > > Hi Oleksandr > > On Wed, Aug 17, 2022 at 01:27:16PM +0300, Oleksandr Suvorov wrote: > > From: Jorge Ramirez-Ortiz > > > > Enable getting randomness from the tpm command line. > > Does it have to be the tpm command lime? > As of

[PATCH 2/2] patman: Tidy up unnecessary blank lines and numbers

2022-08-17 Thread Simon Glass
Quite a few blank lines are not needed here. Drop these and use the # mechanism to number paragraphs. Signed-off-by: Simon Glass --- tools/patman/patman.rst | 45 ++--- 1 file changed, 15 insertions(+), 30 deletions(-) diff --git a/tools/patman/patman.rst

[PATCH 1/2] patman: Fix version table

2022-08-17 Thread Simon Glass
One of the changes to the version table was made by mistake. Fix it. Signed-off-by: Simon Glass --- tools/patman/patman.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/patman/patman.rst b/tools/patman/patman.rst index 9226b66f840..f2e6d7636fd 100644 ---

Re: [PATCH v8 06/13] FWU: Add helper functions for accessing FWU metadata

2022-08-17 Thread Sughosh Ganu
On Wed, 17 Aug 2022 at 22:30, Jassi Brar wrote: > > On Wed, 17 Aug 2022 at 07:44, Sughosh Ganu wrote: > . > > diff --git a/lib/fwu_updates/fwu.c b/lib/fwu_updates/fwu.c > > new file mode 100644 > > index 00..9808036eec > > --- /dev/null > > +++ b/lib/fwu_updates/fwu.c > > @@ -0,0

Re: [PATCH v8 06/13] FWU: Add helper functions for accessing FWU metadata

2022-08-17 Thread Jassi Brar
On Wed, 17 Aug 2022 at 07:44, Sughosh Ganu wrote: . > diff --git a/lib/fwu_updates/fwu.c b/lib/fwu_updates/fwu.c > new file mode 100644 > index 00..9808036eec > --- /dev/null > +++ b/lib/fwu_updates/fwu.c > @@ -0,0 +1,22 @@ > +// SPDX-License-Identifier: GPL-2.0-or-later > +/* > + *

[PATCH v6 3/3] ARM: imx6: dh-imx6: Enable d-cache early in SPL

2022-08-17 Thread Philip Oberfichtner
From: Marek Vasut Enable d-cache early in SPL right after DRAM is started up. This reduces U-Boot proper load time by 650ms when loaded from SPI NOR. Signed-off-by: Marek Vasut Signed-off-by: Philip Oberfichtner --- Changes in v6: - Once more improve the dcache_disable() comment

[PATCH v6 2/3] ARM: cache: Allow SPL to build cache-pl310.c

2022-08-17 Thread Philip Oberfichtner
Introduce the new Kconfig symbol CONFIG_SPL_SYS_L2_PL310 to allow the SPL to build cache-pl310.c. Before this commit, the SPL could enable the PL310 L2 cache [1], but the cache maintenance functions from cache-pl310.c were only useable for non-SPL builds. After enabling the cache one must be

[PATCH v6 1/3] Convert CONFIG_SYS_L2_PL310 to Kconfig

2022-08-17 Thread Philip Oberfichtner
This converts CONFIG_SYS_L2_PL310 to Kconfig. For omap2 and mvebu the 'select SYS_L2_PL310' locations were determined using ./tools/moveconfig -i CONFIG_SYS_L2_PL310. For mx6 I manually chose ARCH_MX6 as 'select' location. The correctness has been verified using $ ./tools/moveconfig.py

[PATCH v8 13/13] FWU: doc: Add documentation for the FWU feature

2022-08-17 Thread Sughosh Ganu
Add documentattion for the FWU Multi Bank Update feature. The document describes the steps needed for setting up the platform for the feature, as well as steps for enabling the feature on the platform. Signed-off-by: Sughosh Ganu --- Changes since V7: * Handle the various review comments from

[PATCH v8 12/13] mkeficapsule: Add support for setting OEM flags in capsule header

2022-08-17 Thread Sughosh Ganu
Add support for setting OEM flags in the capsule header. As per the UEFI specification, bits 0-15 of the flags member of the capsule header can be defined per capsule GUID. The oemflags will be used for the FWU Multi Bank update feature, as specified by the Dependable Boot specification[1]. Bit

[PATCH v8 11/13] mkeficapsule: Add support for generating empty capsules

2022-08-17 Thread Sughosh Ganu
The Dependable Boot specification[1] describes the structure of the firmware accept and revert capsules. These are empty capsules which are used for signalling the acceptance or rejection of the updated firmware by the OS. Add support for generating these empty capsules. [1] -

[PATCH v8 10/13] FWU: cmd: Add a command to read FWU metadata

2022-08-17 Thread Sughosh Ganu
Add a command to read the metadata as specified in the FWU specification and print the fields of the metadata. Signed-off-by: Sughosh Ganu Reviewed-by: Ilias Apalodimas --- Changes since V7: None cmd/Kconfig | 7 + cmd/Makefile| 1 + cmd/fwu_mdata.c | 80

[PATCH v8 09/13] FWU: Add support for the FWU Multi Bank Update feature

2022-08-17 Thread Sughosh Ganu
The FWU Multi Bank Update feature supports updation of firmware images to one of multiple sets(also called banks) of images. The firmware images are clubbed together in banks, with the system booting images from the active bank. Information on the images such as which bank they belong to is stored

[PATCH v8 08/13] FWU: Add boot time checks as highlighted by the FWU specification

2022-08-17 Thread Sughosh Ganu
The FWU Multi Bank Update specification requires the Update Agent to carry out certain checks at the time of platform boot. The Update Agent is the component which is responsible for updating the firmware components and maintaining and keeping the metadata in sync. The spec requires that the

[PATCH v8 07/13] FWU: STM32MP1: Add support to read boot index from backup register

2022-08-17 Thread Sughosh Ganu
The FWU Multi Bank Update feature allows the platform to boot the firmware images from one of the partitions(banks). The first stage bootloader(fsbl) passes the value of the boot index, i.e. the bank from which the firmware images were booted from to U-Boot. On the STM32MP157C-DK2 board, this

[PATCH v8 06/13] FWU: Add helper functions for accessing FWU metadata

2022-08-17 Thread Sughosh Ganu
Add weak functions for getting the update index value and dfu alternate number needed for FWU Multi Bank update functionality. The current implementation for getting the update index value is for platforms with 2 banks. If a platform supports more than 2 banks, it can implement it's own function.

[PATCH v8 05/13] stm32mp1: dk2: Add image information for capsule updates

2022-08-17 Thread Sughosh Ganu
Enabling capsule update functionality on the platform requires populating information on the images that are to be updated using the functionality. Do so for the DK2 board. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Ilias Apalodimas --- Changes since V7: None

[PATCH v8 04/13] stm32mp1: dk2: Add a node for the FWU metadata device

2022-08-17 Thread Sughosh Ganu
The FWU metadata structure is accessed through the driver model interface. On the stm32mp157c-dk2 board, the FWU metadata is stored on the uSD card. Add the fwu-mdata node on the u-boot specifc dtsi file for accessing the metadata structure. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick

[PATCH v8 03/13] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-08-17 Thread Sughosh Ganu
In the FWU Multi Bank Update feature, the information about the updatable images is stored as part of the metadata, on a separate partition. Add a driver for reading from and writing to the metadata when the updatable images and the metadata are stored on a block device which is formated with GPT

[PATCH v8 02/13] FWU: Add FWU metadata structure and driver for accessing metadata

2022-08-17 Thread Sughosh Ganu
In the FWU Multi Bank Update feature, the information about the updatable images is stored as part of the metadata, which is stored on a dedicated partition. Add the metadata structure, and a driver model uclass which provides functions to access the metadata. These are generic API's, and

[PATCH v8 01/13] dt/bindings: Add bindings for GPT based FWU Metadata storage device

2022-08-17 Thread Sughosh Ganu
Add bindings needed for accessing the FWU metadata partitions. These include the compatible string which point to the access method and the actual device which stores the FWU metadata. The current patch adds basic bindings needed for accessing the metadata structure on GPT partitioned block

[PATCH v8 00/13] FWU: Add FWU Multi Bank Update feature support

2022-08-17 Thread Sughosh Ganu
The patchset adds support for the FWU Multi Bank Update[1] feature. Certain aspects of the Dependable Boot[2] specification have also been implemented. The FWU multi bank update feature is used for supporting multiple sets(also called banks) of firmware image(s), allowing the platform to boot

Re: [PATCH] cmd: tpm-v2: add get_random

2022-08-17 Thread Ilias Apalodimas
Hi Oleksandr On Wed, Aug 17, 2022 at 01:27:16PM +0300, Oleksandr Suvorov wrote: > From: Jorge Ramirez-Ortiz > > Enable getting randomness from the tpm command line. Does it have to be the tpm command lime? As of 87ab234c1cf ("cmd: rng: Add support for selecting RNG device") you can explicitly

[PATCH v5 0/3] ARM: imx6: dh-imx6: Enable d-cache early in SPL

2022-08-17 Thread Philip Oberfichtner
This patch series enables d-cache in SPL for i.MX6 based boards from DH in order to improve boot time. This can only be achieved after migrating the corresponding symbols to Kconfig, which is done in patch 1/3 and 2/3. Changes in v5: - Clarify dcache_disable() comment Changes in v4:

[PATCH v4 0/3] ARM: imx6: dh-imx6: Enable d-cache early in SPL

2022-08-17 Thread Philip Oberfichtner
This patch series enables d-cache in SPL for i.MX6 based boards from DH in order to improve boot time. This can only be achieved after migrating the corresponding symbols to Kconfig, which is done in patch 1/3 and 2/3. Changes in v4: - Reduce diffstat by using 'select' statements for

[PATCH 4/4] imx: imx8mn-beacon: Configure PMIC before DDR initialization

2022-08-17 Thread Adam Ford
The DDR is configured for LPDDR4 running at 1.6GHz which requires the voltage on the PMIC to rise a bit or it will be running out of spec. Signed-off-by: Adam Ford diff --git a/board/beacon/imx8mn/spl.c b/board/beacon/imx8mn/spl.c index 029f71bc99..9acd916180 100644 ---

[PATCH 2/4] regulator: bd718x7: Only bind children when PMIC_CHILDREN is enabled

2022-08-17 Thread Adam Ford
If the bd718x7 is required, but PMIC_CHILDREN is disabled, this driver throws a compile error. Fix this by putting the function to bind children into an if-statement checking for PMIC_CHILDREN. Allowing PMIC_CHILDREN to be disabled in SPL saves some space and still permits some read/write

[PATCH 3/4] configs: imx8mn_beacon: Enable SPL_DM_PMIC_BD71837

2022-08-17 Thread Adam Ford
To properly operate the Nano with LPDDR4 at 1.6GHz, the voltage needs to be adjusted before DDR is initialized. Enable the PMIC in SPL to do this. Signed-off-by: Adam Ford diff --git a/configs/imx8mn_beacon_2g_defconfig b/configs/imx8mn_beacon_2g_defconfig index 98a75d4950..fda545a9ad 100644

[PATCH 1/4] configs: imx8mn_beacon: Re-align memory to standard imx8mn settings

2022-08-17 Thread Adam Ford
The imx8mn_beacon board does not use the same memory map as the reference design from NXP or other imx8mn boards. As such, memory is more limited in SPL. Moving SPL_BSS_START_ADDR and SPL_STACK to default locations increases the amount of available meory for the SPL stack. Doing this allows the

  1   2   >