Re: [RFC] binman: add support for creating dummy files for external blobs

2021-11-24 Thread Heiko Thiery
Hi Simon, Am Di., 23. Nov. 2021 um 17:15 Uhr schrieb Simon Glass : > > Hi Heiko, > > On Tue, 16 Nov 2021 at 03:47, Heiko Thiery wrote: > > > > While converting to binman for an imx8mq board, it has been found that > > building in the u-boot CI fails. This is because an imx8mq requires an > > exte

[RESEND RFC PATCH 10/10] FWU: cmd: Add a command to read metadata

2021-11-24 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 --- cmd/Kconfig| 6 + cmd/Makefile | 1 + cmd/fwu_metadata.c | 65 ++ 3 files changed, 72 ins

[RESEND RFC PATCH 09/10] FWU: Add support for FWU Multi Bank Update feature

2021-11-24 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

[RESEND RFC PATCH 08/10] FWU: Add boot time checks as highlighted by the FWU specification

2021-11-24 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 Updat

[RESEND RFC PATCH 07/10] EFI: FMP: Add provision to update image's ImageTypeId in image descriptor

2021-11-24 Thread Sughosh Ganu
The FWU Multi Banks Update feature allows updating different types of updatable firmware images on the platform. These image types are identified using the ImageTypeId GUID value. Add support in the GetImageInfo function of the FMP protocol to get the GUID values for the individual images and popul

[RESEND RFC PATCH 06/10] FWU: STM32MP1: Add support to read boot index from backup register

2021-11-24 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 value

[RESEND RFC PATCH 05/10] FWU: stm32mp1: Add helper functions for accessing metadata

2021-11-24 Thread Sughosh Ganu
Add helper functions needed for accessing the metadata which contains information on the updatable images. These functions have been added for the STM32MP157C-DK2 board which has the updatable images on the uSD card, formatted as GPT partitions. Signed-off-by: Sughosh Ganu --- board/st/stm32mp1/

[RESEND RFC PATCH 04/10] FWU: Add metadata access functions for GPT partitioned block devices

2021-11-24 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 functions 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

[RESEND RFC PATCH 03/10] FWU: Add metadata structure and functions for accessing metadata

2021-11-24 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 functions to access the metadata. These are generic API's, and implementations can be added based on paramete

[RESEND RFC PATCH 02/10] stm32mp: dfu: Move the ram partitions to the end of the dfu_alt_info variable

2021-11-24 Thread Sughosh Ganu
With the FWU multi bank update feature enabled, the dfu alt no that is used to identify the partition to be updated is derived at runtime and should match the partition number on the storage media. Achieve this by moving the ram partitions to the end of the dfu_alt_info variable. Signed-off-by: Su

[RESEND RFC PATCH 01/10] GPT: Add function to get gpt header and partition entries

2021-11-24 Thread Sughosh Ganu
Add function to get the gpt header and partition entries filled. These would be used subsequently for multi bank firmware update support on devices where the images reside on GPT partitions. Signed-off-by: Sughosh Ganu --- disk/part_efi.c | 10 ++ include/part.h | 14 ++ 2 f

[RESEND RFC PATCH 00/10] FWU: Add support for FWU Multi Bank Update feature

2021-11-24 Thread Sughosh Ganu
(resending to including the first paragraph which got deleted for some reason). 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 multi

a question about falcon mode

2021-11-24 Thread Chan Kim
Hello all, I'm trying to implement falcon mode for our board. Then should I first implement the normal mode(spl + proper)? It looks like so while I'm reading doc/README.falcon. (It says, after loading kernel, DT etc. I should give 'spl export' command). Please someone confirm this. Thank you.

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

2021-11-24 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 --- cmd/Kconfig| 6 + cmd/Makefile | 1 + cmd/fwu_metadata.c | 65 ++ 3 files changed, 72 ins

[RFC PATCH 09/10] FWU: Add support for FWU Multi Bank Update feature

2021-11-24 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

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

2021-11-24 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 Updat

[RFC PATCH 07/10] EFI: FMP: Add provision to update image's ImageTypeId in image descriptor

2021-11-24 Thread Sughosh Ganu
The FWU Multi Banks Update feature allows updating different types of updatable firmware images on the platform. These image types are identified using the ImageTypeId GUID value. Add support in the GetImageInfo function of the FMP protocol to get the GUID values for the individual images and popul

[RFC PATCH 06/10] FWU: STM32MP1: Add support to read boot index from backup register

2021-11-24 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 value

[RFC PATCH 05/10] FWU: stm32mp1: Add helper functions for accessing metadata

2021-11-24 Thread Sughosh Ganu
Add helper functions needed for accessing the metadata which contains information on the updatable images. These functions have been added for the STM32MP157C-DK2 board which has the updatable images on the uSD card, formatted as GPT partitions. Signed-off-by: Sughosh Ganu --- board/st/stm32mp1/

[RFC PATCH 04/10] FWU: Add metadata access functions for GPT partitioned block devices

2021-11-24 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 functions 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

[RFC PATCH 03/10] FWU: Add metadata structure and functions for accessing metadata

2021-11-24 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 functions to access the metadata. These are generic API's, and implementations can be added based on paramete

[RFC PATCH 02/10] stm32mp: dfu: Move the ram partitions to the end of the dfu_alt_info variable

2021-11-24 Thread Sughosh Ganu
With the FWU multi bank update feature enabled, the dfu alt no that is used to identify the partition to be updated is derived at runtime and should match the partition number on the storage media. Achieve this by moving the ram partitions to the end of the dfu_alt_info variable. Signed-off-by: Su

[RFC PATCH 01/10] GPT: Add function to get gpt header and partition entries

2021-11-24 Thread Sughosh Ganu
Add function to get the gpt header and partition entries filled. These would be used subsequently for multi bank firmware update support on devices where the images reside on GPT partitions. Signed-off-by: Sughosh Ganu --- disk/part_efi.c | 10 ++ include/part.h | 14 ++ 2 f

[RFC PATCH 00/10] FWU: Add support for FWU Multi Bank Update feature

2021-11-24 Thread Sughosh Ganu
The FWU multi bank update feature is used for supporting multiple sets(also called banks) of firmware images, allowing the platform to boot from a different bank, in case it fails to boot from the active bank. This functionality is supported by keeping the relevant information in a structure called

Re: [PATCH v2 4/6] drivers: tpm: atmel_twi: do not use an offset byte

2021-11-24 Thread Ilias Apalodimas
Hi Simon, On Thu, 25 Nov 2021 at 02:12, Simon Glass wrote: > > On Wed, 10 Nov 2021 at 21:06, Mathew McBride wrote: > > > > This driver was broken due to an empty offset byte being prepended > > at the start of every transmission. > > > > The hardware does not mimic an EEPROM device with register

[PATCH] efi_loader: check tcg2 protocol installation outside the TCG protocol

2021-11-24 Thread Masahisa Kojima
There are functions that calls tcg2_agile_log_append() outside of the TCG protocol invocation (e.g tcg2_measure_pe_image). These functions must to check that tcg2 protocol is installed. If not, measurement shall be skipped. Together with above change, this commit also removes the unnecessary tcg2_

Re: [PATCH v7 00/12] efi_loader: capsule: improve capsule authentication support

2021-11-24 Thread AKASHI Takahiro
Hi Heinrich On Tue, Nov 16, 2021 at 01:32:26PM +0900, AKASHI Takahiro wrote: > As I proposed and discussed in [1] and [2], I have made a couple of > improvements on the current implementation of capsule update in this > patch set. For this version(v7), I have seen your review comments only on pat

Re: [BUG] efi_loader: incorrect creation of device paths

2021-11-24 Thread AKASHI Takahiro
Heinrich, On Wed, Nov 24, 2021 at 12:10:32PM +0900, AKASHI Takahiro wrote: > On Sat, Nov 20, 2021 at 01:54:30PM +0100, Heinrich Schuchardt wrote: > > Hello Takahiro, > > > > in a prior mail we have discussed the creation of device paths for USB > > mass storage devices. > > > > On the sand boxyo

[PATCH v2] image-board: fix wrong implementation ram disk address setup from cmdline

2021-11-24 Thread Artem Lapkin
Problem Wrong implementation logic: ramdisk cmdline image address always ignored! Next block { rd_addr = hextoul(select, NULL) } unusable for raw initrd. We have unbootable raw initrd images because, select_ramdisk for raw initrd images ignore submited select addr and setup rd_datap value to 0 S

Re: [PATCH 00/16] tools: Add support for signing devicetree blobs

2021-11-24 Thread Tom Rini
On Wed, Nov 24, 2021 at 05:12:12PM -0700, Simon Glass wrote: > Hi François, > > On Sat, 13 Nov 2021 at 11:53, François Ozog wrote: > > > > Hi Simon > > > > Le sam. 13 nov. 2021 à 14:57, Simon Glass a écrit : > >> > >> Hi Heinrich, > >> > >> On Sat, 13 Nov 2021 at 04:57, Heinrich Schuchardt > >

Re: [RFC PATCH] RFC: Sketch of dm event notification

2021-11-24 Thread AKASHI Takahiro
Hi Simon, On Wed, Nov 24, 2021 at 05:12:45PM -0700, Simon Glass wrote: > Hi Takahiro, > > On Tue, 16 Nov 2021 at 20:03, AKASHI Takahiro > wrote: > > > > On Tue, Nov 16, 2021 at 07:48:59PM -0700, Simon Glass wrote: > > > Hi Takahiro, > > > > > > On Tue, 16 Nov 2021 at 19:31, AKASHI Takahiro > > >

Re: [PATCH v7 12/12] (RFC) efi_loader, dts: add public keys for capsules to device tree

2021-11-24 Thread AKASHI Takahiro
Hi Simon, On Wed, Nov 24, 2021 at 05:11:49PM -0700, Simon Glass wrote: > Hi Takahiro, > > On Mon, 15 Nov 2021 at 21:33, AKASHI Takahiro > wrote: > > > > By specifying CONFIG_EFI_CAPSULE_KEY_PATH, the build process will > > automatically insert the given key into the device tree. > > Otherwise, u

RE: [PATCH 3/3] arm: socfpga: arria10: Enable double peripheral RBF configuration

2021-11-24 Thread Chee, Tien Fong
> -Original Message- > From: Kho, Sin Hui > Sent: Sunday, 7 November, 2021 11:09 PM > To: u-boot@lists.denx.de > Cc: Simon Goldschmidt ; Marek Vasut > ; Chee, Tien Fong ; Hea, Kok > Kiang ; Westergreen, Dalon > ; Cozart, Sue ; Kho, > Sin Hui > Subject: [PATCH 3/3] arm: socfpga: arria10

RE: [PATCH 2/3] arm: socfpga: arria10: Reset MPFE NoC after program periph / combined RBF

2021-11-24 Thread Chee, Tien Fong
> -Original Message- > From: Kho, Sin Hui > Sent: Sunday, 7 November, 2021 11:09 PM > To: u-boot@lists.denx.de > Cc: Simon Goldschmidt ; Marek Vasut > ; Chee, Tien Fong ; Hea, Kok > Kiang ; Westergreen, Dalon > ; Cozart, Sue ; Kho, > Sin Hui > Subject: [PATCH 2/3] arm: socfpga: arria10

RE: [PATCH 1/3] arm: socfpga: arria10: Setting image magic value to romcode initswstate reg

2021-11-24 Thread Chee, Tien Fong
> -Original Message- > From: Kho, Sin Hui > Sent: Sunday, 7 November, 2021 11:09 PM > To: u-boot@lists.denx.de > Cc: Simon Goldschmidt ; Marek Vasut > ; Chee, Tien Fong ; Hea, Kok > Kiang ; Westergreen, Dalon > ; Cozart, Sue ; Kho, Sin > Hui > Subject: [PATCH 1/3] arm: socfpga: arria10

variable __rel_dyn_start and __rel_dyn_end missing for u-boot proper?

2021-11-24 Thread Chan Kim
Hello experts, I can't find the definition of variable __rel_dyn_start and __rel_dyn_end for u-boot proper build. Those variables are used in arch/arm/cpu/armv8/start.S (though they are enclosed in #ifdef CONFIG_POSISION_INDEPDNED and #endif) pie_fixup: adr x0, _start /* x0 <-

Re: [PATCH 00/16] tools: Add support for signing devicetree blobs

2021-11-24 Thread Simon Glass
Hi François, On Sat, 13 Nov 2021 at 11:53, François Ozog wrote: > > Hi Simon > > Le sam. 13 nov. 2021 à 14:57, Simon Glass a écrit : >> >> Hi Heinrich, >> >> On Sat, 13 Nov 2021 at 04:57, Heinrich Schuchardt wrote: >> > >> > >> > >> > On 11/13/21 04:30, Simon Glass wrote: >> > > Hi Heinrich, >>

Re: rk3399-gru-kevin: issues on bringup

2021-11-24 Thread Simon Glass
Hi Alper, On Sun, 7 Nov 2021 at 10:26, Alper Nebi Yasak wrote: > > On 06/11/2021 06:16, Simon Glass wrote: > > On Tue, 2 Nov 2021 at 17:05, Simon Glass wrote: > >> On Mon, 1 Nov 2021 at 17:25, Alper Nebi Yasak > >> wrote: > >>> Most of the patches are small config and dts changes that I've gro

Re: [PATCH 1/5] test: fix pylint errors in multiplexed_log.py

2021-11-24 Thread Simon Glass
On Mon, 22 Nov 2021 at 16:02, Heinrich Schuchardt wrote: > > * don't inherit from object > * remove superfluous comprehension > * add module docstring > > Signed-off-by: Heinrich Schuchardt > --- > test/py/multiplexed_log.py | 14 -- > 1 file changed, 8 insertions(+), 6 deletions(-)

Re: [PATCH 1/1] sandbox: replace putchar(ch) by fputc(ch, stdout)

2021-11-24 Thread Simon Glass
On Sat, 20 Nov 2021 at 05:28, Heinrich Schuchardt wrote: > > When compiled with -Og for better debugability u-boot ends up in a stack > overflow using > > gcc (Ubuntu 11.2.0-7ubuntu2) 11.2.0 > GNU Binutils for Ubuntu 2.37 > > putchar(ch) is defined as a macro which ends up calling U-Boot's

Re: [PATCH 3/3] arm: apple: Use watchdog timer for system reset

2021-11-24 Thread Simon Glass
On Sun, 14 Nov 2021 at 04:19, Mark Kettenis wrote: > > Rely on the new watchdog timer driver and the sysreset uclass to > reset the system. This gets rid of hard-coded addresses and > should work on systems based on the new M1 Pro and M1 Max SoCs > as well. > > Signed-off-by: Mark Kettenis > ---

Re: [RFC PATCH v3 6/8] common: spl: fit_ram: allow to use image pre load

2021-11-24 Thread Simon Glass
On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit add the support of image pre load in spl or tpl > when loading an image from ram. Add support for image pre-load ... > > Signed-off-by: Philippe Reynes > --- > common/spl/spl_ram.c | 21 - > 1 file changed

Re: [RFC PATCH v3 0/8] image: add a stage pre-load

2021-11-24 Thread Simon Glass
Hi Philippe, On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This serie adds a stage pre-load before launching an image. > This stage is used to read a header before the image and > this header contains the signature of the full image. > So u-boot may check the full image before using an

Re: [PATCH v3] env: Avoid using GNU features in awk

2021-11-24 Thread Simon Glass
Hi Tom, On Sat, 20 Nov 2021 at 08:55, Tom Rini wrote: > > On Sat, Nov 20, 2021 at 08:45:34AM -0700, Simon Glass wrote: > > > GNU has a very useful third argument to match() but this is not supported > > in the POSIX awk. > > > > Update the code to cope, so that the script is POSIX-compliant. > >

Re: [PATCH 5/5] test: fix pylint error in u_boot_console_exec_attach.py

2021-11-24 Thread Simon Glass
On Mon, 22 Nov 2021 at 16:02, Heinrich Schuchardt wrote: > > * provide module docstring > > Signed-off-by: Heinrich Schuchardt > --- > test/py/u_boot_console_exec_attach.py | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) Reviewed-by: Simon Glass

Re: [PATCH 4/5] test: fix pylint error in u_boot_console_sandbox.py

2021-11-24 Thread Simon Glass
On Mon, 22 Nov 2021 at 16:02, Heinrich Schuchardt wrote: > > * provide module docstring > > Signed-off-by: Heinrich Schuchardt > --- > test/py/u_boot_console_sandbox.py | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) Reviewed-by: Simon Glass

Re: [PATCH 3/5] test: fix pylint errors in u_boot_utils.py

2021-11-24 Thread Simon Glass
On Mon, 22 Nov 2021 at 16:02, Heinrich Schuchardt wrote: > > * there is no os.path.unlink() method > * don't inherit from object > * add module docstring > * move imports to the top > * avoid unused variable > > Signed-off-by: Heinrich Schuchardt > --- > test/py/u_boot_utils.py | 25

Re: [PATCH 2/5] test: fix pylint errors in u_boot_spawn.py

2021-11-24 Thread Simon Glass
On Mon, 22 Nov 2021 at 16:02, Heinrich Schuchardt wrote: > > * don't inherit from object > * imports should be on the top level > * avoid unused variable names > * avoid unnecessary else after raise > > Signed-off-by: Heinrich Schuchardt > --- > test/py/u_boot_spawn.py | 26 +

Re: [PATCH] arm: apple: Remove CONFIG_SYS_SDRAM_BASE

2021-11-24 Thread Simon Glass
On Sun, 14 Nov 2021 at 05:10, Mark Kettenis wrote: > > The memory layout is taken from the device tree passed to us by > m1n1, so there is no need to define this. > > Signed-off-by: Mark Kettenis > --- > include/configs/apple.h | 2 -- > 1 file changed, 2 deletions(-) > Reviewed-by: Simon Glass

Re: [PATCH v7 12/12] (RFC) efi_loader, dts: add public keys for capsules to device tree

2021-11-24 Thread Simon Glass
Hi Takahiro, On Mon, 15 Nov 2021 at 21:33, AKASHI Takahiro wrote: > > By specifying CONFIG_EFI_CAPSULE_KEY_PATH, the build process will > automatically insert the given key into the device tree. > Otherwise, users are required to do so manually, possibly, with > the utility script, fdtsig.sh. > >

Re: [PATCH v2 1/2] env: setenv add resolve value option

2021-11-24 Thread Simon Glass
On Thu, 18 Nov 2021 at 21:37, Artem Lapkin wrote: > > Add possibility setup env variable with additional resolving vars inside > value. > > Usage examples: > > => setenv a hello; setenv b world; setenv c '${a} ${b}' > => setenv -r d '${c}! ${a}...' > => printenv d > d=hello world! hello... > > /*

Re: [RFC PATCH v3 2/8] lib: crypto: allow to build crypyo in SPL

2021-11-24 Thread Simon Glass
On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit adds the options: > - SPL_ASYMMETRIC_KEY_TYPE > - SPL_ASYMMETRIC_PUBLIC_KEY_SUBTYPE > - SPL_RSA_PUBLIC_KEY_PARSER > > Signed-off-by: Philippe Reynes > --- > lib/Makefile| 2 +- > lib/crypto/Kconfig | 15 ++

Re: [PATCH 5/6] Makefile: Add a pylint checker to the build

2021-11-24 Thread Simon Glass
Hi Heinrich, On Mon, 22 Nov 2021 at 01:05, Heinrich Schuchardt wrote: > > On 11/22/21 04:48, Simon Glass wrote: > > At present the Python code in U-Boot is somewhat inconsistent, with some > > files passing pylint quite cleanly and others not. > > > > Add a way to track progress on this clean-up,

Re: [PATCH v3 1/3] mmc: rockchip_sdhci: add phy and clock config for rk3399

2021-11-24 Thread Simon Glass
Hi Jack, On Fri, 29 Oct 2021 at 09:45, Jack Mitchell wrote: > > Hi, > > > snip > > > + > > +static int rk3399_emmc_get_phy(struct udevice *dev) > > +{ > > + struct rockchip_sdhc *priv = dev_get_priv(dev); > > + ofnode phy_node; > > + void *grf_base; > > + u32 grf_phy_offset, phand

Re: [PATCH 6/6] Azure/GitLab CI: Add the pylint checker

2021-11-24 Thread Simon Glass
Hi Heinrich, On Mon, 22 Nov 2021 at 00:40, Heinrich Schuchardt wrote: > > On 11/22/21 04:48, Simon Glass wrote: > > Add a check that new Python code does not regress the pylint score for > > any module. > > How will ./scripts/pylint.base be updated? For the moment people will have to add it to t

Re: [PATCH] sandbox: poweroff in efi_system_reset()

2021-11-24 Thread Simon Glass
On Sat, 20 Nov 2021 at 06:58, Heinrich Schuchardt wrote: > > efi_system_reset() should exit if called with EFI_RESET_SHUTDOWN. > > Signed-off-by: Heinrich Schuchardt > --- > arch/sandbox/cpu/start.c | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) Reviewed-by: Simon Glass

Re: [PATCH v2 2/2] test: env: deep resolve value testing

2021-11-24 Thread Simon Glass
On Thu, 18 Nov 2021 at 21:37, Artem Lapkin wrote: > > Add new tests for `setenv -r` options (setup env variable with additional > resolving vars inside value). > > test.py -k test_env > > Signed-off-by: Artem Lapkin > --- > test/py/tests/test_env.py | 24 > 1 file change

Re: [RFC PATCH v3 8/8] tools: gen_pre_load_header.sh: initial import

2021-11-24 Thread Simon Glass
Hi, On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit adds a script gen_pre_load_header.sh > that generate the header used by the image pre-load > stage. > > Signed-off-by: Philippe Reynes > --- > tools/gen_pre_load_header.sh | 174 +++ > 1 fil

Re: [RFC PATCH v3 7/8] mkimage: add public key for image pre-load stage

2021-11-24 Thread Simon Glass
Hi Philippe, On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit enhances mkimage to update the node > /image/pre-load/sig with the public key. > > Signed-off-by: Philippe Reynes > --- > include/image.h| 15 ++ > tools/fit_image.c | 3 ++ > tools/image-host.c | 116

Re: [PATCH v2 3/6] drivers: tpm: atmel_twi: drop non-DM_I2C compatibility

2021-11-24 Thread Simon Glass
On Wed, 10 Nov 2021 at 21:06, Mathew McBride wrote: > > There are no users of this driver without DM_I2C > > Signed-off-by: Mathew McBride > Reviewed-by: Ilias Apalodimas > --- > drivers/tpm/tpm_atmel_twi.c | 14 +- > 1 file changed, 1 insertion(+), 13 deletions(-) Reviewed-by: Sim

Re: [RFC PATCH v3 5/8] cmd: bootm: add a stage pre-load

2021-11-24 Thread Simon Glass
Hi Philippe, On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit adds a stage pre-load to the command Add a stage... > bootm. Right now, this stage may be used to read > a header and check the signature of the full > image. > > Signed-off-by: Philippe Reynes > --- > boot/boot

Re: [RFC PATCH v3 4/8] boot: image: add a stage pre-load

2021-11-24 Thread Simon Glass
Hi Philippe, On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit adds a stage pre-load that could > check or modify an image. > > For the moment, only a header with a signature is > supported. This header has this format: > - magic : 4 bytes > - image size : 4 bytes > - signature

Re: [RFC PATCH v3 3/8] lib: rsa: allow rsa verify with pkey in SPL

2021-11-24 Thread Simon Glass
On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit adds the option SPL_RSA_VERIFY_WITH_PKEY. > > Signed-off-by: Philippe Reynes > --- > lib/rsa/Kconfig | 8 > 1 file changed, 8 insertions(+) > > diff --git a/lib/rsa/Kconfig b/lib/rsa/Kconfig > index 469596abe7..608d51c

Re: [RFC PATCH v3 1/8] lib: allow to build asn1 decoder and oid registry in SPL

2021-11-24 Thread Simon Glass
Hi Philippe, On Wed, 17 Nov 2021 at 10:52, Philippe Reynes wrote: > > This commit adds the options: > - SPL_ASN1_DECODER > - SPL_OID_REGISTRY > > Signed-off-by: Philippe Reynes > --- > lib/Kconfig | 6 ++ > lib/Makefile | 7 +-- > 2 files changed, 11 insertions(+), 2 deletions(-) > > d

Re: [PATCH 1/3] dtoc: Rename is_wider_than() to reduce confusion

2021-11-24 Thread Simon Glass
Hi Walter, On Mon, 2 Aug 2021 at 13:29, Walter Lozano wrote: > > Hi Simon, > > On 8/1/21 11:50 PM, Simon Glass wrote: > > Hi Walter, > > > > On Sun, 1 Aug 2021 at 20:45, Walter Lozano wrote: > >> Hi Simon, > >> > >> Thanks for checking this bug, I'm glad that you were able to come with > >> fix

Re: [RFC PATCH] RFC: Sketch of dm event notification

2021-11-24 Thread Simon Glass
Hi Takahiro, On Tue, 16 Nov 2021 at 20:03, AKASHI Takahiro wrote: > > On Tue, Nov 16, 2021 at 07:48:59PM -0700, Simon Glass wrote: > > Hi Takahiro, > > > > On Tue, 16 Nov 2021 at 19:31, AKASHI Takahiro > > wrote: > > > > > > Simon, > > > > > > On Mon, Nov 01, 2021 at 03:41:50PM +0900, AKASHI Tak

Re: [PATCH 2/5] doc: add include/lmb.h to the HTML documentation

2021-11-24 Thread Simon Glass
On Sun, 14 Nov 2021 at 02:03, Heinrich Schuchardt wrote: > > Correct Sphinx style comments in include/lmb.h > > Add the logical memory block API to the HTML documentation. > > Signed-off-by: Heinrich Schuchardt > --- > doc/api/index.rst | 1 + > doc/api/lmb.rst | 7 +++ > include/lmb.h

Re: [PATCH v2 4/6] drivers: tpm: atmel_twi: do not use an offset byte

2021-11-24 Thread Simon Glass
On Wed, 10 Nov 2021 at 21:06, Mathew McBride wrote: > > This driver was broken due to an empty offset byte being prepended > at the start of every transmission. > > The hardware does not mimic an EEPROM device with registers so > an offset byte is not required. > > Signed-off-by: Mathew McBride >

Re: [PATCH 2/3] arm: dts: apple: Add watchdog timer node

2021-11-24 Thread Simon Glass
On Sun, 14 Nov 2021 at 04:19, Mark Kettenis wrote: > > Add a node for the watchdog timer based on the proposed Linux > device tree bindings. > > Signed-off-by: Sven Peter > Signed-off-by: Mark Kettenis > --- > arch/arm/dts/t8103.dtsi | 13 - > 1 file changed, 8 insertions(+), 5 dele

Re: [PATCH 1/3] watchdog: Add a driver for the Apple watchdog

2021-11-24 Thread Simon Glass
On Sun, 14 Nov 2021 at 04:19, Mark Kettenis wrote: > > This driver supports the watchdog timer found on Apple's M1 SoC. > On systems that use these SoC, the watchdog timer is the primary > way to reboot the system. > > Signed-off-by: Mark Kettenis > --- > MAINTAINERS | 1 + >

Re: [PATCH v4 5/5] sf: Provide a command to access memory-mapped SPI

2021-11-24 Thread Simon Glass
Hi Heinrich, On Sat, 13 Nov 2021 at 04:47, Heinrich Schuchardt wrote: > > > > On 9/19/21 23:49, Simon Glass wrote: > > Add a new 'sf mmap' function to show the address of a SPI offset, if the > > I would expect a 'spi info' command to provide this information. Why is that? It depends on the size

Re: [PATCH 7/7] RFC: Move Odroid-C2 to use binman to produce the image

2021-11-24 Thread Simon Glass
Hi Neil, On Wed, 24 Nov 2021 at 07:26, Neil Armstrong wrote: > > Hi Simon, > > On 24/11/2021 05:09, Simon Glass wrote: > > This shows how binman can be used to replace the long and complicated > > instructions with an automated build. It is still complicated to read > > but users don't have to wo

Re: [EXT] Re: [PATCH v4 01/16] crypto/fsl: Add support for CAAM Job ring driver model

2021-11-24 Thread Simon Glass
Hi Gaurav, On Mon, 8 Nov 2021 at 02:30, Gaurav Jain wrote: > > Hello Simon > > > -Original Message- > > From: Simon Glass > > Sent: Tuesday, November 2, 2021 8:26 PM > > To: Gaurav Jain > > Cc: U-Boot Mailing List ; Stefano Babic > > ; Fabio Estevam ; Peng Fan > > ; Priyanka Jain ; Ye L

Re: [PATCH v2 04/11] Convert CONFIG_PHYSMEM to Kconfig

2021-11-24 Thread Simon Glass
Hi Andy, On Wed, 24 Nov 2021 at 09:33, Andy Shevchenko wrote: > > On Wed, Nov 24, 2021 at 6:28 PM Simon Glass wrote: > > > > This converts the following to Kconfig: > >CONFIG_PHYSMEM > > Why? Because we want to avoid ad-hoc CONFIG options. > > And why my message [1] left unanswered? > > [1

Re: [PATCH v2] cmd: pxe_utils: sysboot: add label override support

2021-11-24 Thread Simon Glass
Hi Amjad, On Sat, 13 Nov 2021 at 06:09, Amjad Ouled-Ameur wrote: > > This will allow consumers to choose a pxe label at runtime instead of > having to prompt the user. One good use-case for this, is choosing > whether or not to apply a dtbo depending on the hardware configuration. > e.g: for TI's

Re: [RFC PATCH v4 6/6] fpga: zynqmp: support loading authenticated images

2021-11-24 Thread Simon Glass
Hi Oleksandr, On Thu, 11 Nov 2021 at 02:59, Oleksandr Suvorov wrote: > > Add supporting new compatible string "u-boot,zynqmp-fpga-ddrauth" to > handle loading authenticated images (DDR). > > Based on solution by Jorge Ramirez-Ortiz > Signed-off-by: Oleksandr Suvorov > Co-developed-by: Ricardo S

Re: [PATCH v2 5/6] drivers: tpm: atmel_twi: implement get_desc operation

2021-11-24 Thread Simon Glass
On Wed, 10 Nov 2021 at 21:06, Mathew McBride wrote: > > Without get_desc, the tpm command will not provide a > description of the device in 'tpm device' or 'tpm info'. > > Due to the characteristics of the Atmel TPM it isn't > possible to determine certain attributes (e.g open/close > status) with

Re: [PATCH v2 6/6] drivers: tpm: atmel_twi: fix printf specifier compile warning

2021-11-24 Thread Simon Glass
On Wed, 10 Nov 2021 at 21:07, Mathew McBride wrote: > > %d was being used as the specifier for size_t, leading to a > compiler warning > > Signed-off-by: Mathew McBride > Reviewed-by: Ilias Apalodimas > --- > drivers/tpm/tpm_atmel_twi.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >

Re: [PATCH v2] boot: don't enable the non-secure boot commands by default if secure boot enabled

2021-11-24 Thread Simon Glass
On Tue, 9 Nov 2021 at 00:23, Rover Mo wrote: > > To prevent booting unsigned images, don't enable the non-secure boot > commands(booti, bootz .etc) by default if secure boot enabled. > > Signed-off-by: Rover Mo > Cc: Heinrich Schuchardt > Cc: Simon Glass > > --- > > Changes for v2: > - Don'

Re: [PATCH v2 2/6] cmd: tpm-v1: fix load_key_by_sha1 compile errors

2021-11-24 Thread Simon Glass
On Wed, 10 Nov 2021 at 21:06, Mathew McBride wrote: > > This command is not compiled by default and has not been updated alongside > changes to the tpmv1 API, such as passing the TPM udevice to the relevant > functions. > > Signed-off-by: Mathew McBride > Reviewed-by: Ilias Apalodimas > --- > c

Re: [PATCH v2 1/6] cmd: tpm-v1: fix compile error in TPMv1 list resources command

2021-11-24 Thread Simon Glass
On Wed, 10 Nov 2021 at 21:06, Mathew McBride wrote: > > This command is not compiled by default and was not > updated to pass the udevice to tpm_get_capability. > > Signed-off-by: Mathew McBride > Reviewed-by: Ilias Apalodimas > --- > cmd/tpm-v1.c | 7 ++- > 1 file changed, 6 insertions(+),

Re: [PATCH 2/2] scripts: remove CONFIG_IS_ENABLED and CONFIG_VAL in config_whitelist.txt

2021-11-24 Thread Simon Glass
On Mon, 8 Nov 2021 at 02:21, Patrick Delaunay wrote: > > The helper macro CONFIG_IS_ENABLED and CONFIG_VAL are not real > configurations and they are no more present in u-boot.cfg so they can > be removed in config_whitelist.txt. > > Signed-off-by: Patrick Delaunay > --- > > scripts/config_white

Re: an off-by-one error in dm_test_rtc_set_get()?

2021-11-24 Thread Simon Glass
Hi, I filed https://source.denx.de/u-boot/u-boot/-/issues/4 Regards, Simon On Thu, 28 Oct 2021 at 05:58, Tom Rini wrote: > > On Thu, Oct 28, 2021 at 09:22:30AM +0200, Rasmus Villemoes wrote: > > On 27/10/2021 15.22, Tom Rini wrote: > > > On Wed, Oct 27, 2021 at 12:43:38PM +0800, Bin Meng wrot

Re: [PATCH 1/2] scripts: remove CONFIG_IS_ENABLED and CONFIG_VAL in generated u_boot.cfg

2021-11-24 Thread Simon Glass
On Mon, 8 Nov 2021 at 02:21, Patrick Delaunay wrote: > > The two helpers macros CONFIG_IS_ENABLED and CONFIG_VAL are defined in > include/linux/kconfig.h but they are not real configurations; they can > be safely removed in the generated configuration file "u-boot.cfg". > > This patch simplifies t

Re: [PATCH v7 11/12] (RFC) tools: add fdtsig.sh

2021-11-24 Thread Simon Glass
Hi Takahiro, On Mon, 15 Nov 2021 at 21:33, AKASHI Takahiro wrote: > > With this script, a public key is added to a device tree blob > as the default efi_get_public_key_data() expects. > > Signed-off-by: AKASHI Takahiro > --- > MAINTAINERS | 1 + > tools/fdtsig.sh | 40 +

[PATCH v3 1/2] riscv: Support booting SiFive Unmatched from SPI.

2021-11-24 Thread Thomas Skibo
Configure SPI flash devices into SPL. Add SPI boot option to spl.c. Document how to format flash for booting. Signed-off-by: Thomas Skibo --- .../dts/hifive-unmatched-a00-u-boot.dtsi | 11 +++ board/sifive/unmatched/spl.c | 3 ++ configs/sifive_unmatched_defconfig

[PATCH v3 0/2] riscv: Support booting SiFive Unmatched from SPI flash.

2021-11-24 Thread Thomas Skibo
This patch set adds support for booting the SiFive Unmatched board from SPI flash memory and saving the environment to flash. Thomas Skibo (2): riscv: Support booting SiFive Unmatched from SPI. riscv: Enable SPI flash env for SiFive Unmatched. arch/riscv/cpu/fu740/Kconfig |

[PATCH v3 2/2] riscv: Enable SPI flash env for SiFive Unmatched.

2021-11-24 Thread Thomas Skibo
Enable saving environment to SPI flash memory on SiFive Unmatched. Signed-off-by: Thomas Skibo --- arch/riscv/cpu/fu740/Kconfig | 13 + board/sifive/unmatched/Kconfig | 1 + 2 files changed, 14 insertions(+) diff --git a/arch/riscv/cpu/fu740/Kconfig b/arch/riscv/cpu/fu740/Kconfig

Re: [PATCH v2 05/41] sandbox: mmc: Support a backing file

2021-11-24 Thread Simon Glass
Provide a way for sandbox MMC to present data from a backing file. This allows a filesystem to be created on the host and easily served via an emulated mmc device. Signed-off-by: Simon Glass --- Changes in v2: - Free the memory buffer, to avoid running out of memory - Unmap the file - Reorder st

Re: [PATCH v2 17/41] test/py: Relax the naming rules for unit tests

2021-11-24 Thread Simon Glass
At present the collection function used by pytest is quite strict on the naming of the functions it detects. In particular it requires the name of the test to be repeated in the function name. This is not enforced anywhere else, but instead the tests are silently omitted from the pytest run. This

Re: [PATCH v2 13/41] dm: core: Add a way to obtain a string list

2021-11-24 Thread Simon Glass
Hi Ilias, On Tue, 26 Oct 2021 at 13:21, Ilias Apalodimas wrote: > > On Sun, 24 Oct 2021 at 02:26, Simon Glass wrote: > > > > At present we support reading a string list a string at a time. Apart > > from being inefficient, this makes it impossible to separate reading of > > the devicetree into t

Re: [PATCH v2 03/41] test/py: Allow passing input to a program

2021-11-24 Thread Simon Glass
When running a program on the host, allow input to be passed in as stdin. This is needed for running sfdisk, for example. Signed-off-by: Simon Glass --- (no changes since v1) test/py/multiplexed_log.py | 8 +--- test/py/u_boot_utils.py| 5 +++-- 2 files changed, 8 insertions(+), 5 dele

Re: [PATCH v2 04/41] sandbox: Support unmapping a file

2021-11-24 Thread Simon Glass
Add the opposite of mapping, so that we can unmap and avoid running out of address space. Signed-off-by: Simon Glass --- (no changes since v1) arch/sandbox/cpu/os.c | 10 ++ include/os.h | 9 + 2 files changed, 19 insertions(+) Applied to u-boot-dm/next, thanks!

Re: [PATCH v2 06/41] mmc: Allow for children other than the block device

2021-11-24 Thread Simon Glass
At present the MMC uclass assumes that the only child it can have is a block device. Update this so we can add a bootmethod too. Signed-off-by: Simon Glass --- (no changes since v1) drivers/mmc/mmc-uclass.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Applied to u-boot-dm/next, t

Re: [PATCH v2 07/41] mbr: Correct verification check

2021-11-24 Thread Simon Glass
Hi Simon, On Sat, Oct 23, 2021 at 05:26:01PM -0600, Simon Glass wrote: > At present this command considers the partitions to be identical if the > start and size are smaller than expected. It should check that they are > the same. Fix this and tidy up the code style a little. > > Signed-off-by: Si

Re: [PATCH v2 09/41] common: Allow a smaller console-recording pre-reloc

2021-11-24 Thread Simon Glass
Before relocation there is generally not as much available memory and not that much console output. At present the console-output buffer is the same side before and after relocation. Add a separate Kconfig option to remove this limitation. Signed-off-by: Simon Glass --- (no changes since v1) c

Re: [PATCH v2 08/41] disk: part_dos: Fix a NULL pointer error

2021-11-24 Thread Simon Glass
When ext is NULL we cannot dereference it. Update the code flow to avoid this, so that layout_mbr_partitions() can be used with partition tables that do not include an extended partition. Signed-off-by: Simon Glass --- (no changes since v1) disk/part_dos.c | 10 ++ 1 file changed, 6 in

Re: [PATCH v2 10/41] dm: core: Add tests for stringlist functions

2021-11-24 Thread Simon Glass
These functions currently lack tests so add some. The error handling differs betwee livetree and flattree at present, so only check the error codes with livetree. Signed-off-by: Simon Glass --- (no changes since v1) arch/sandbox/dts/test.dts | 1 + test/dm/ofnode.c | 76 +

Re: [PATCH v2 11/41] dm: core: Fix handling of uclass pre_unbind method

2021-11-24 Thread Simon Glass
This method is currently called after the platform data has been freed. But the pre_unbind() method may wish to access this, e.g. to free some data structures stored there. Split the unbinding of devices into two pieces, as is done with removal. This corrects the problem. Also tidy a code-style i

Re: [PATCH v2 12/41] dm: core: Fix up string-function documentation

2021-11-24 Thread Simon Glass
The details for of_property_read_string_helper() and ofnode_read_string_index() are a little inaccurate. Fix up the comments to avoid confusion. Signed-off-by: Simon Glass --- (no changes since v1) drivers/core/of_access.c | 3 ++- include/dm/ofnode.h | 4 ++-- 2 files changed, 4 insertio

  1   2   >