Re: [PATCH v12 8/9] doc:eficonfig: add documentation for eficonfig command

2022-08-23 Thread Masahisa Kojima
On Wed, 24 Aug 2022 at 13:27, Masahisa Kojima wrote: > > Add documentation for eficonfig command. > > Signed-off-by: Masahisa Kojima > --- > Changes in v12: > - CONFIG_BOOTMENU_DISABLE_UBOOT_CONSOLE condition is added > to show newly added boot option > > No update since v10 > > Changes in

Re: mvebu - switch to orion-timer

2022-08-23 Thread Stefan Roese
Hi Pali, On 24.08.22 00:33, Pali Rohár wrote: Hello Stefan! Now when U-Boot contains new orion-timer.c driver, which Michael wrote, I think that it mvebu platform should switch to use it. Because build process for armada boards prints deprecation warning that new timer is not being used. Could

Re: [PATCH] board: ti: common: board_detect: Fix EEPROM read quirk

2022-08-23 Thread Nishanth Menon
On 19:05-20220823, Matwey V. Kornilov wrote: > There are three different kinds of EEPROM possibly present on boards. > 1. 1byte address. For those we should avoid 2byte address in order > not to rewrite the data. Second byte of the address can potentially > be interpreted

Re: [PATCH v11 6/9] bootmenu: add removable media entries

2022-08-23 Thread Masahisa Kojima
On Wed, 24 Aug 2022 at 13:29, Masahisa Kojima wrote: > > Hi Akashi-san, > > On Wed, 24 Aug 2022 at 10:57, Takahiro Akashi > wrote: > > > > On Fri, Aug 19, 2022 at 12:05:50PM +0900, Masahisa Kojima wrote: > > > Hi Akashi-san, > > > > > > On Fri, 19 Aug 2022 at 10:31, Takahiro Akashi > > > wrote:

[PATCH v2 2/2] timer: bcmbca: use arm global timer for bcm63138 SoC

2022-08-23 Thread William Zhang
As STI timer is renamed to ARM A9 global timer, change BCM63138 to use the new global timer config symbol name. This patch applies on top of the my previous patch [1]. [1]: https://lists.denx.de/pipermail/u-boot/2022-August/491060.html Signed-off-by: William Zhang --- Changes in v2: - Fix

[PATCH v2 1/2] timer: sti: convert sti-timer to arm a9 global timer

2022-08-23 Thread William Zhang
STI timer is actually ARM Cortex A9 global timer. Convert the driver to use generic global timer name and make it consistent with Linux kernel global timer driver. This also allows any A9 based device to use this driver. Signed-off-by: William Zhang --- (no changes since v1) MAINTAINERS

Re: [PATCH v11 6/9] bootmenu: add removable media entries

2022-08-23 Thread Masahisa Kojima
Hi Akashi-san, On Wed, 24 Aug 2022 at 10:57, Takahiro Akashi wrote: > > On Fri, Aug 19, 2022 at 12:05:50PM +0900, Masahisa Kojima wrote: > > Hi Akashi-san, > > > > On Fri, 19 Aug 2022 at 10:31, Takahiro Akashi > > wrote: > > > > > > On Wed, Aug 17, 2022 at 06:36:11PM +0900, Masahisa Kojima

[PATCH v12 9/9] test: unit test for eficonfig

2022-08-23 Thread Masahisa Kojima
Provide a unit test for the eficonfig command. Signed-off-by: Masahisa Kojima --- Changes in v12: - update menu handling Changes in v11: - fix expected result when no BootOrder is defined Newly added in v10 configs/sandbox_defconfig | 1 +

[PATCH v12 8/9] doc:eficonfig: add documentation for eficonfig command

2022-08-23 Thread Masahisa Kojima
Add documentation for eficonfig command. Signed-off-by: Masahisa Kojima --- Changes in v12: - CONFIG_BOOTMENU_DISABLE_UBOOT_CONSOLE condition is added to show newly added boot option No update since v10 Changes in v10: - describe how to boot system after editting by eficonfig Changes in v8:

[PATCH v12 7/9] doc:bootmenu: add description for UEFI boot support

2022-08-23 Thread Masahisa Kojima
The bootmenu enumerates the UEFI boot options for boot device selection. This commit adds the description how the UEFI boot work in bootmenu. This commit also adds "Synopsis", "Description" and "Configuration" sections to follow the U-Boot command documentation format. Signed-off-by: Masahisa

[PATCH v12 6/9] eficonfig: add "Change Boot Order" menu entry

2022-08-23 Thread Masahisa Kojima
This commit adds the menu entry to update UEFI BootOrder variable. User moves the entry with UP/DOWN key, changes the order with PLUS/MINUS key, press SPACE to activate or deactivate the entry, then finalizes the order by ENTER key. If the entry is activated, the boot index is added into the

[PATCH v12 5/9] bootmenu: add removable media entries

2022-08-23 Thread Masahisa Kojima
UEFI specification requires booting from removal media using a architecture-specific default image name such as BOOTAA64.EFI. This commit adds the removable media entries into bootmenu, so that user can select the removable media and boot with default image. The bootmenu automatically enumerates

[PATCH v12 4/9] eficonfig: add "Delete Boot Option" menu entry

2022-08-23 Thread Masahisa Kojima
This commit adds the menu entry to delete the UEFI boot option. User moves the entry with UP/DOWN key, changes, then presses ENTER key to delete the selected boot option. Signed-off-by: Masahisa Kojima --- No update since v11 Changes in v11: - update function interface to show boot selection

[PATCH v12 3/9] menu: add KEY_PLUS, KEY_MINUS and KEY_SPACE handling

2022-08-23 Thread Masahisa Kojima
This is preparation to support menu-driven UEFI BootOrder variable updated by KEY_PLUS, KEY_MINUS and KEY_SPACE. Signed-off-by: Masahisa Kojima Reviewed-by: Heinrich Schuchardt Reviewed-by: Ilias Apalodimas --- No update since v11 Changes in v11: - add SPACE key handling Newly created in v7

[PATCH v12 1/9] eficonfig: menu-driven addition of UEFI boot option

2022-08-23 Thread Masahisa Kojima
This commit add the "eficonfig" command. The "eficonfig" command implements the menu-driven UEFI boot option maintenance feature. This commit implements the addition of new boot option. User can select the block device volume having efi_simple_file_system_protocol and select the file corresponding

[PATCH v12 2/9] eficonfig: add "Edit Boot Option" menu entry

2022-08-23 Thread Masahisa Kojima
This commit adds the menu entry to edit the existing BOOT variable contents. User selects the item from the boot option list, then user can edit the description, file path and optional_data. Note that automatically generated boot option entry by bootmenu to support the removable media device

[PATCH v12 0/9] enable menu-driven UEFI variable maintenance

2022-08-23 Thread Masahisa Kojima
This series adds the menu-driven UEFI boot variable maintenance through the "eficonfig" new command. This series also adds the removable media support in bootmenu. Initrd file selection and python based unit test are added in v10. Source code can be cloned with: $ git clone

Re: mvebu - switch to orion-timer

2022-08-23 Thread Tony Dinh
Hi Stefan, I would like to see this too. I was thinking of doing it per board, but it is more appropriate to enable it for Arch_Kirkwood and Arch_MVEBU. Thanks, Tony On Tue, Aug 23, 2022 at 3:33 PM Pali Rohár wrote: > > Hello Stefan! Now when U-Boot contains new orion-timer.c driver, which >

Re: [PATCH v11 6/9] bootmenu: add removable media entries

2022-08-23 Thread Takahiro Akashi
On Fri, Aug 19, 2022 at 12:05:50PM +0900, Masahisa Kojima wrote: > Hi Akashi-san, > > On Fri, 19 Aug 2022 at 10:31, Takahiro Akashi > wrote: > > > > On Wed, Aug 17, 2022 at 06:36:11PM +0900, Masahisa Kojima wrote: > > > UEFI specification requires booting from removal media using > > > a

[PATCH] kontron-sl-mx8mm: Let CONFIG_SPL_FIT_IMAGE_TINY be selected

2022-08-23 Thread Fabio Estevam
When CONFIG_IMX_HAB is selected the 'hab_status' command reports several error events, indicating that the BootROM failed to authenticate the SPL. After inspecting the content of the memory location that corresponds to the DTB load address, the content did not match with the DTB binary, showing

[PATCH 2/2] timer: bcmbca: use arm global timer for bcm63138 SoS

2022-08-23 Thread William Zhang
As STI timer is renamed to ARM A9 global timer, change BCM63138 to use the new global timer config symbol name. This patch applies on top of the my previous patch [1]. [1]: https://lists.denx.de/pipermail/u-boot/2022-August//491060.html Signed-off-by: William Zhang ---

[PATCH 1/2] timer: sti: convert sti-timer to arm a9 global timer

2022-08-23 Thread William Zhang
STI timer is actually ARM Cortex A9 global timer. Convert the driver to use generic global timer name and make it consistent with Linux kernel global timer driver. This also allows any A9 based device to use this driver. Signed-off-by: William Zhang --- MAINTAINERS

mvebu - switch to orion-timer

2022-08-23 Thread Pali Rohár
Hello Stefan! Now when U-Boot contains new orion-timer.c driver, which Michael wrote, I think that it mvebu platform should switch to use it. Because build process for armada boards prints deprecation warning that new timer is not being used. Could you look at it, if it is possible to do global

[PATCH v3 5/7] doc: fru: add documentation for the fru command and APIs

2022-08-23 Thread Jae Hyun Yoo
Add a usage document for the 'fru' u-boot command. Add kerneldocs for . Signed-off-by: Jae Hyun Yoo --- Changes from v2: * Added kerneldocs to 'include/fru.h'. (Simon) Changes from v1: * Newly added in v2. (Heinrich) doc/usage/cmd/fru.rst | 144 +

[PATCH v3 7/7] test: cmd: fru: add unit test for the fru command

2022-08-23 Thread Jae Hyun Yoo
Add test cases for the fru command. Signed-off-by: Jae Hyun Yoo --- Changes from v2: * Newly added in v3. (Simon) include/test/suites.h | 1 + test/cmd/Makefile | 1 + test/cmd/fru.c| 84 +++ test/cmd_ut.c | 6 4 files

[PATCH v3 4/7] cmd: fru: add product info area parsing support

2022-08-23 Thread Jae Hyun Yoo
Add product info area parsing support. Custom board fields can be added dynamically using linked list so that each board support can utilize them in their own custom way. Signed-off-by: Jae Hyun Yoo --- Changes from v2: * Changed 'struct fru_board_info_member' to 'struct

[PATCH v3 6/7] test: py: fru: add a test for the fru command

2022-08-23 Thread Jae Hyun Yoo
Add a simple test for the 'fru' command. Signed-off-by: Jae Hyun Yoo --- Changes from v2: * Added CONFIG_CMD_FRU=y only into the sandbox_defconfig. (Simon) Changes from v1: * Newly added in v2. (Heinrich) configs/sandbox_defconfig | 1 + test/py/tests/test_fru.py | 47

[PATCH v3 3/7] cmd: fru: fix a sandbox segfault issue

2022-08-23 Thread Jae Hyun Yoo
This command doesn't work with sandbox because direct memory access causes a segfault error. Fix it up using map_sysmem(). Signed-off-by: Jae Hyun Yoo Reviewed-by: Simon Glass --- Changes from v2: * Added a 'Reviewed-by' tag. (Simon) Changes from v1: * Newly added in v2.

[PATCH v3 1/7] xilinx: common: refactor FRU handling support

2022-08-23 Thread Jae Hyun Yoo
Refactor FRU handling support to remove Xilinx customization dependency. With this change, single or multiple custom board fields and multi-records can be added dynamically using linked list so that each board support can utilize them in their own custom way. It's a preparation change for moving

[PATCH v3 0/7] cmd/fru: move FRU handling support to common region

2022-08-23 Thread Jae Hyun Yoo
Hello, The FRU handling was added as a Xilinx board dependent support but it is also useful for other boards, so this commit moves the FRU handling support to the common region so that it can be enabled by CONFIG_CMD_FRU. To provide manufacturer specific custom info fields and multi-records

[PATCH v3 2/7] cmd: fru: move FRU handling support to common region

2022-08-23 Thread Jae Hyun Yoo
From: Graeme Gregory The FRU handling was added as a Xilinx board dependent support but it is also useful for other boards too, so this commit moves the FRU handling support to the common region so that it can be enabled by CONFIG_CMD_FRU. Signed-off-by: Graeme Gregory Signed-off-by: Jae Hyun

Re: [RESEND PATCH 1/2] rpi: Copy properties from firmware dtb to the loaded dtb

2022-08-23 Thread Antoine Mazeas
Thanks Simon, Can I ask you to clarify what you meant by "drop the private firmware"? For the record, this patch was tested using the vendored firmware from Raspberry Pi, v1.20220331, and subsequently v1.20220811 when it came out. I'm happy to do the requested change now if you think it is

Re: ethernet dt aliases implications in U-Boot and Linux

2022-08-23 Thread Rob Herring
On Tue, Aug 9, 2022 at 4:39 PM Tim Harvey wrote: > > On Tue, Aug 9, 2022 at 2:31 PM Pali Rohár wrote: > > > > On Tuesday 09 August 2022 16:48:23 Sean Anderson wrote: > > > On 8/8/22 5:45 PM, Michal Suchánek wrote: > > > > On Mon, Aug 08, 2022 at 02:38:35PM -0700, Stephen Hemminger wrote: > > >

[PATCH] post: memory: Fix format strings

2022-08-23 Thread Sean Anderson
This fixes numerous cases of format strings not matching their arguments. Also keep the format strings on one line for easier grepping. Signed-off-by: Sean Anderson --- post/drivers/memory.c | 30 -- 1 file changed, 12 insertions(+), 18 deletions(-) diff --git

[PATCH v2 2/2] dts: imx8mp-rsb3720: modify configrations to load fip into memory

2022-08-23 Thread Ying-Chun Liu (PaulLiu)
From: "Ying-Chun Liu (PaulLiu)" The changes of commit 6a21c695213b ("arm: dts: imx8mp: add of-list support to common imx8mp-u-boot.dtsi") breaks the loading of the fip. This commit fixes the break by modify the configuration properly. Signed-off-by: Ying-Chun Liu (PaulLiu) Cc: Stefano Babic

[PATCH v2 1/2] dts: imx8mp: assign binman_configuration node name to config-SEQ

2022-08-23 Thread Ying-Chun Liu (PaulLiu)
From: "Ying-Chun Liu (PaulLiu)" assign a node name for config-SEQ so that the board dts can modify the configuration more easily. Signed-off-by: Ying-Chun Liu (PaulLiu) Cc: Stefano Babic Cc: Fabio Estevam Cc: NXP i.MX U-Boot Team --- v2: just rebase to the latest master branch. ---

[PATCH v2 0/2] dts: imx8mp-rsb3720: modify configrations to load fip into memory

2022-08-23 Thread Ying-Chun Liu (PaulLiu)
From: "Ying-Chun Liu (PaulLiu)" The changes of commit 6a21c695213b ("arm: dts: imx8mp: add of-list support to common imx8mp-u-boot.dtsi") breaks the loading of the fip. This commit fixes the break by modify the configuration properly. v2: just rebase to the latest master branch. Ying-Chun Liu

[PATCH] ARM: stm32: Switch DHSOM to FMC2 EBI driver

2022-08-23 Thread Marek Vasut
Perform long overdue conversion of ad-hoc FMC2 EBI bus initialization to upstream FMC2 EBI driver. No functional change. Signed-off-by: Marek Vasut Cc: Patrice Chotard Cc: Patrick Delaunay --- .../dts/stm32mp15xx-dhcom-picoitx-u-boot.dtsi | 8 --- arch/arm/dts/stm32mp15xx-dhcom-u-boot.dtsi

Re: [PATCH] ARM: imx: Deduplicate i.MX8M SNVS LPGPR unlock

2022-08-23 Thread Fabio Estevam
On 23/08/2022 14:05, Marek Vasut wrote: Pull this LPGPR unlock into common code, since it is used in multiple systems already. Signed-off-by: Marek Vasut Cc: Fabio Estevam Cc: Peng Fan Cc: Stefano Babic Cc: Ye Li Cc: uboot-imx Reviewed-by: Fabio Estevam

[PATCH] vbe: Enable command only with BOOTSTD_FULL

2022-08-23 Thread Simon Glass
Avoid enabling this command by default. This saves about 1KB of code space. Signed-off-by: Simon Glass --- cmd/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/Kconfig b/cmd/Kconfig index 211ebe9c878..8ea064b8d2f 100644 --- a/cmd/Kconfig +++ b/cmd/Kconfig @@

[PATCH v4 7/7] tpm: Allow committing non-volatile data

2022-08-23 Thread Simon Glass
Add an option to tell the TPM to commit non-volatile data immediately it is changed, rather than waiting until later. This is needed in some situations, since if the device reboots it may not write the data. Add definitions for the rest of the Cr50 commands while we are here. Signed-off-by:

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

2022-08-23 Thread Simon Glass
Add a vendor-specific TPM2 command for this and implement it for Cr50. Note: This is not part of the TPM spec, but is a Cr50 extension. Signed-off-by: Simon Glass --- Changes in v4: - Rename function and add arguments for the command/subcmd drivers/tpm/cr50_i2c.c | 163

[PATCH v4 5/7] tpm: Allow reporting the internal state

2022-08-23 Thread Simon Glass
It is useful to read information about the current TPM state, where supported, e.g. for debugging purposes when verified boot fails. Add support for this to the TPM interface as well as Cr50. Add a simple sandbox test. Signed-off-by: Simon Glass --- (no changes since v1) cmd/tpm-common.c

[PATCH v4 4/7] tpm: sandbox: Allow init of TPM in a different phase

2022-08-23 Thread Simon Glass
At present the emulator assumes that the TPM is inited in the same phase where it is used. But in fact SPL may init the TPM, so we don't want to complain when U-Boot proper later uses it. Remove this check. It might be best to save this information into the device state for the TPM, so that we

[PATCH v4 3/7] tpm: Correct the define-space command in TPMv2

2022-08-23 Thread Simon Glass
The message format is incorrect. Fix it. Signed-off-by: Simon Glass --- (no changes since v2) Changes in v2: - Use constants instead of open-coded values lib/tpm-v2.c | 22 +++--- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/lib/tpm-v2.c b/lib/tpm-v2.c index

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

2022-08-23 Thread Simon Glass
The offset here is incorrect. Fix it. Signed-off-by: Simon Glass --- (no changes since v1) lib/tpm-v1.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/tpm-v1.c b/lib/tpm-v1.c index 22a769c5874..d0e3ab1b21d 100644 --- a/lib/tpm-v1.c +++ b/lib/tpm-v1.c @@ -456,12

[PATCH v4 1/7] tpm: Require a digest source when extending the PCR

2022-08-23 Thread Simon Glass
This feature is used for measured boot, so we can add a log entry to the TCPA with some information about where the digest comes from. It is not currently supported in the TPM drivers, but add it to the API so that code which expects it can signal its request. Signed-off-by: Simon Glass --- (no

[PATCH v4 0/7] tpm: Various minor fixes and enhancements

2022-08-23 Thread Simon Glass
This series contains some minor enhancements for the TPM code to make it work with Chromium OS verified boot. Changes in v4: - Rename function and add arguments for the command/subcmd - Rename function and add arguments for the command/subcmd Changes in v3: - Drop limits on the TPM hash size -

[PATCH] spi: stm32_spi: Fix GPIO chipselect polarity handling

2022-08-23 Thread Marek Vasut
The GPIO chipselect signal polarity is handled by the GPIO core code, the driver code is only responsible for asserting and deasserting the GPIO. Do not invert the GPIO polarity in the driver code. For example, In case CS GPIO is active low, then the DT must contain GPIO_ACTIVE_LOW flag and the

[PATCH 1/2] usb: gadget: designware-udc: Drop the driver

2022-08-23 Thread Marek Vasut
This driver is not used by any system and is long unmaintained, drop it. There is a DWC2 OTG driver which is maintained, see CONFIG_USB_GADGET_DWC2_OTG . Signed-off-by: Marek Vasut --- Cc: Heiko Schocher Cc: Patrice Chotard Cc: Patrick Delaunay --- drivers/serial/usbtty.h |2

[PATCH 2/2] usb: gadget: Clean up Makefile ifdeffery

2022-08-23 Thread Marek Vasut
Take the USB_ETHER ifdef block apart and make use of obj-$(VAR) instead to include the source files in build. The duplicate CI_UDC entry is now removed, the USB_DEVICE ifdef is now reduced to core.o ep.o addition, the ether.o can be conditionally compiled in using USB_ETHER. No functional change.

[PATCH] ARM: imx: Deduplicate i.MX8M SNVS LPGPR unlock

2022-08-23 Thread Marek Vasut
Pull this LPGPR unlock into common code, since it is used in multiple systems already. Signed-off-by: Marek Vasut Cc: Fabio Estevam Cc: Peng Fan Cc: Stefano Babic Cc: Ye Li Cc: uboot-imx --- arch/arm/include/asm/arch-imx8m/imx-regs.h| 5 + arch/arm/mach-imx/imx8m/soc.c

[PATCH] board: ti: common: board_detect: Fix EEPROM read quirk

2022-08-23 Thread Matwey V. Kornilov
There are three different kinds of EEPROM possibly present on boards. 1. 1byte address. For those we should avoid 2byte address in order not to rewrite the data. Second byte of the address can potentially be interpreted as the data to write. 2. 2byte address with defined behaviour.

Please pull u-boot-marvell/master

2022-08-23 Thread Stefan Roese
Hi Tom, please pull this next batch of mostly Marvell related patches: - kirkwood: pogo_v4 & nsa310s: Add distro boot (Tony) - kirkwood: add DM timer support and use it on lsxl boards (Michael) - kirkwood: convert the Buffalo

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

2022-08-23 Thread Michael Walle
Am 2022-08-23 17:01, schrieb Stefan Roese: Applied to u-boot-marvell/master, with my small fix for the ds109 board Great! Thanks, Stefan. -michael

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

2022-08-23 Thread Stefan Roese
On 17.08.22 21:37, Michael Walle wrote: 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

Re: [RESEND PATCH] arm: kirkwood: nsa310s: Add Distro boot capability

2022-08-23 Thread Stefan Roese
On 12.08.22 01:40, Tony Dinh wrote: - Add distro boot to board include file and deconfig file - Miscellaneous changes: - Remove Gerald from maintainer list (email bounced) - Add CONFIG_SUPPORT_PASSING_ATAGS and friends to support legacy kernel method of booting (e.g.

Re: [PATCH] arm: mvebu: mbus: Fix mbus driver to work also after U-Boot relocation

2022-08-23 Thread Stefan Roese
On 10.08.22 14:46, Pali Rohár wrote: mbus driver is initialized from arch_cpu_init() callback which is called before relocation. This driver stores lot of functions and structure pointers into global variables, so it is data position dependent. Therefore after relocations all pointers are

Re: [PATCH] arm: mvebu: turris_mox: Set "sfp" label in eth1 DT node when only Mox SFP is detected

2022-08-23 Thread Stefan Roese
On 10.08.22 12:54, Pali Rohár wrote: When Mox SFP module is connected after Topaz or Peridot module then port DT node already contains "sfp" label. But Mox SFP module can be connected also without Topaz or Peridot module in which case it is connected directly into he eth1 DT node, which is

Re: [PATCH] arm: mvebu: turris_omnia: Show MCU version

2022-08-23 Thread Stefan Roese
On 10.08.22 11:00, Pali Rohár wrote: There are already more MCU firmware versions for Turris Omnia in production, so display git commit (version) of the MCU firmware during U-Boot startup. It will help to identify what version of MCU firmware is Turris Omnia using. MCU firmware for Turris Omnia

Re: [PATCH] arm: kirkwood: pogo_v4: Add Distro boot capability

2022-08-23 Thread Stefan Roese
On 09.08.22 05:01, Tony Dinh wrote: - Add distro boot to board include file and deconfig file - Miscellaneous changes: - Add CONFIG_SUPPORT_PASSING_ATAGS and friends to support legacy kernel method of booting (e.g. OpenWrt) with appended DTB. - Add CONFIG_LTO and

Re: [PATCH] arm: mvebu: Define env_sf_get_env_addr() for all Armada boards in SPL

2022-08-23 Thread Stefan Roese
On 08.08.22 19:13, Pali Rohár wrote: SPI0 CS0 Flash is mapped to address range 0xD400 - 0xD7FF by BootROM. Proper U-Boot removes this direct mapping. So it is available only in SPL. This applies for all 32-bit Armada BootROMs. SPL mvebu code is used only on 32-bit Armada SoCs. So move

Re: [PATCH v2 2/2] cmd: mvebu/bubt: Check for A38x/A37xx OTP secure bits and secure boot

2022-08-23 Thread Stefan Roese
On 23.08.22 14:44, Pali Rohár wrote: On Tuesday 23 August 2022 07:05:33 Stefan Roese wrote: Hi Pali, On 09.08.22 21:42, Pali Rohár wrote: For obvious reasons BootROMS rejects unsigned images when secure boot is enabled in OTP secure bits. So check for OPT secure bits and do not allow flashing

Re: [PATCH v1 08/26] imx6ul/imx6ull: synchronise device trees with linux

2022-08-23 Thread Frieder Schrempf
Am 03.08.22 um 15:21 schrieb Frieder Schrempf: > Hi Marcel, hi Stefano, > > Am 03.08.22 um 15:02 schrieb Stefano Babic: >> On 03.08.22 14:58, Marcel Ziswiler wrote: >>> Hi Frieder >>> >>> On Mon, 2022-08-01 at 10:08 +0200, Frieder Schrempf wrote: Hi Marcel, Am 21.07.22 um 15:27

Re: [PATCH] fdt_support: add optional board_rng_seed() hook

2022-08-23 Thread Simon Glass
Hi Rasmus, On Tue, 23 Aug 2022 at 07:06, Rasmus Villemoes wrote: > > On 23/08/2022 15.38, Simon Glass wrote: > > >> +/** > >> + * board_rng_seed() - Provide a seed to be passed via /chosen/rng-seed > >> + * > >> + * This function is called if CONFIG_BOARD_RNG_SEED is set, and must > >> + * be

[PATCH 6/6] imx: imx6ul: kontron-sl-mx6ul: Sync devicetrees

2022-08-23 Thread Frieder Schrempf
From: Frieder Schrempf Sync the devicetrees with Linux and adjust the board names. Signed-off-by: Frieder Schrempf --- Note: * The devicetree changes this is based on are still pending in Linux (see

[PATCH 5/6] imx: imx6ul: kontron-sl-mx6ul: Migrate to use CONFIG_EXTRA_ENV_TEXT

2022-08-23 Thread Frieder Schrempf
From: Frieder Schrempf Move the environment from the board header to a separate text file and also drop those variables that are already set in env_default.h from the Kconfig options or are not needed anymore. Signed-off-by: Frieder Schrempf --- board/kontron/sl-mx6ul/sl-mx6ul.env | 4

[PATCH 4/6] imx: imx6ul: kontron-sl-mx6ul: Select correct boot and env device

2022-08-23 Thread Frieder Schrempf
From: Frieder Schrempf Instead of checking both, SPI NOR and MMC for loading U-Boot proper and the environment, implement a way to detect the actual boot device even if the BootROM doesn't report it and we can't rely solely on the fuse settings, as by default we use MMC as primary boot device

[PATCH 3/6] imx: imx6ul: kontron-sl-mx6ul: Fix CONFIG_ENV_SPI_BUS

2022-08-23 Thread Frieder Schrempf
From: Frieder Schrempf The SPI NOR is on ECSPI1 so CONFIG_ENV_SPI_BUS should be 1 to detect the environment on the SPI NOR. Signed-off-by: Frieder Schrempf --- configs/kontron-sl-mx6ul_defconfig | 1 - 1 file changed, 1 deletion(-) diff --git a/configs/kontron-sl-mx6ul_defconfig

[PATCH 1/6] Makefile: Make flash.bin target available for all platforms

2022-08-23 Thread Frieder Schrempf
From: Frieder Schrempf There is no reason for restricting the use of the flash.bin target to the i.MX8 platform. Others can benefit from this as well. Signed-off-by: Frieder Schrempf --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index

[PATCH 2/6] imx: imx6ul: kontron-sl-mx6ul: Enable migrated Kconfig options

2022-08-23 Thread Frieder Schrempf
From: Frieder Schrempf The board support was merged at the same time as some Kconfig options for SPL were migrated/renamed. As a result some essential features like serial output, MMC support, etc. are currently missing. Fix this by enabling the required options. Signed-off-by: Frieder Schrempf

[PATCH 0/6] imx: imx6ul: kontron-sl-mx6ul: Fixes and improvements

2022-08-23 Thread Frieder Schrempf
From: Frieder Schrempf This series fixes some issues with the kontron-sl-mx6ul board configuration. It also syncs devicetrees with changes in the Linux kernel. Notes: * This series is based on imx/master and fixes the previously merged sync patch from Marcel [1]. * The devicetree changes

Re: [PATCH] image: Ensure image header name is null terminated

2022-08-23 Thread Rasmus Villemoes
On 23/08/2022 15.38, Simon Glass wrote: > Hi John, > > On Tue, 23 Aug 2022 at 03:46, John Keeping wrote: >> >> On Tue, Aug 23, 2022 at 03:59:07PM +1000, Joel Stanley wrote: >>> When building with GCC 12: >>> >>> ../include/image.h:779:9: warning: ‘strncpy’ specified bound 32 equals >>>

Re: [PATCH] fdt_support: add optional board_rng_seed() hook

2022-08-23 Thread Rasmus Villemoes
On 23/08/2022 15.38, Simon Glass wrote: >> +/** >> + * board_rng_seed() - Provide a seed to be passed via /chosen/rng-seed >> + * >> + * This function is called if CONFIG_BOARD_RNG_SEED is set, and must >> + * be provided by the board. It should return, via @buf, some suitable >> + * seed value

Re: [RFC PATCH] imx8mp: fix boot hang when booting NXP kernel 5.15.32

2022-08-23 Thread Marek Vasut
On 8/23/22 15:36, Rasmus Villemoes wrote: We have observed a somewhat weird bug: When booting the downstream NXP kernel lf-5.15.32-2.0.0 [fa6c3168595c], sometimes the board would hang during imx_lcdifv3_probe(). Adding some printk debugging revealed that the hang always happened at the

Re: [PATCH] binman: Sort tests and rework test-file numbers

2022-08-23 Thread Simon Glass
On Tue, 23 Aug 2022 at 04:46, Stefan Herbrechtsmeier wrote: > > From: Stefan Herbrechtsmeier > > Tests should be in order of the test-file numbers. Sort the tests > according to the test-file numbers and rework the test-file numbers to > eliminate duplicate numbers. > > Signed-off-by: Stefan

Re: [PATCH 1/1] boot: simplify bootmeth_vbe_simple_ft_fixup()

2022-08-23 Thread Simon Glass
On Tue, 23 Aug 2022 at 02:32, Heinrich Schuchardt wrote: > > Don't assign a value to a variable if it is not used afterwards. > Move variables to the code fragment where they are used. > > Addresses-Coverity: CID 356243 ("Code maintainability issues (UNUSED_VALUE)") > Signed-off-by: Heinrich

Re: [PATCH 1/1] boot: fix vbe_find_first_device()

2022-08-23 Thread Simon Glass
On Tue, 23 Aug 2022 at 02:25, Heinrich Schuchardt wrote: > > uclass_find_first_device() may return NULL if no device for the uclass > exists. Handle this case gracefully. > > Addresses-Coverity: CID 356244 ("Null pointer dereferences (FORWARD_NULL)") > Signed-off-by: Heinrich Schuchardt > --- >

Re: [PATCH] fdt_support: add optional board_rng_seed() hook

2022-08-23 Thread Simon Glass
?Hi, On Mon, 22 Aug 2022 at 01:34, Rasmus Villemoes wrote: > > A recurring theme on LKML is the boot process deadlocking due to some > process blocking waiting for random numbers, while the kernel's > Cryptographic Random Number Generator (crng) is not initalized yet, > but that very blocking

Re: [PATCH] image: Ensure image header name is null terminated

2022-08-23 Thread Simon Glass
Hi John, On Tue, 23 Aug 2022 at 03:46, John Keeping wrote: > > On Tue, Aug 23, 2022 at 03:59:07PM +1000, Joel Stanley wrote: > > When building with GCC 12: > > > > ../include/image.h:779:9: warning: ‘strncpy’ specified bound 32 equals > > destination size [-Wstringop-truncation] > > 779 |

Re: [PATCH] common/console.c: prevent pre-console buffer contents from being added to itself

2022-08-23 Thread Simon Glass
Hi Rasmus, On Tue, 23 Aug 2022 at 05:38, Rasmus Villemoes wrote: > > Ping. > > The previous patch has already been applied [cff29636933a, > common/console.c: use CONFIG_VAL() with PRE_CON_BUF_* variables], and I > realize this one might be more "controversial" in how it makes >

Re: [RESEND PATCH 1/2] rpi: Copy properties from firmware dtb to the loaded dtb

2022-08-23 Thread Simon Glass
Hi Antoine, On Mon, 22 Aug 2022 at 16:00, Antoine Mazeas wrote: > > Thanks Simon, > > Can I ask you to clarify what you meant by "drop the private firmware"? Replace the private binary with a full U-Boot implementation. I hope that the vendor might do it one day. > For the record, this patch

[RFC PATCH] imx8mp: fix boot hang when booting NXP kernel 5.15.32

2022-08-23 Thread Rasmus Villemoes
We have observed a somewhat weird bug: When booting the downstream NXP kernel lf-5.15.32-2.0.0 [fa6c3168595c], sometimes the board would hang during imx_lcdifv3_probe(). Adding some printk debugging revealed that the hang always happened at the writel(CTRL_SW_RESET, lcdifv3->base +

[PATCH] arm64: zynqmp: add ref_clk property for REFCLKPER calculation

2022-08-23 Thread Michal Simek
From: Piyush Mehta Added ref_clk 'ref' property for GUCTL_REFCLKPER and GFLADJ_REFCLK_FLADJ calculation. This property configure correct value for SOF/ITP counter and period of ref_clk. This patch adds 'ref' property for both dwc3_0 and dwc3_1 cores. Signed-off-by: Piyush Mehta Signed-off-by:

[PATCH] arm64: zynqmp: Add missing tca6416 to zynqmp SC

2022-08-23 Thread Michal Simek
Add missing tca6416 i2c gpio controller to SC dts file. Signed-off-by: Michal Simek --- arch/arm/dts/zynqmp-e-a2197-00-revA.dts | 12 1 file changed, 12 insertions(+) diff --git a/arch/arm/dts/zynqmp-e-a2197-00-revA.dts b/arch/arm/dts/zynqmp-e-a2197-00-revA.dts index

[PATCH] arm: dts: Add xlnx prefix to GEM compatible string

2022-08-23 Thread Michal Simek
From: Harini Katakam cdns,zynq/zynqmp were recentle deprecated in Linux in favour of xlnx prefix. Add this new compatible string and retain the existing string for compatibility with uboot drivers. Signed-off-by: Harini Katakam Signed-off-by: Michal Simek --- arch/arm/dts/zynq-7000.dtsi | 4

[PATCH v3 2/2] cmd: mvebu/bubt: Check for A38x/A37xx OTP secure bits and secure boot

2022-08-23 Thread Pali Rohár
For obvious reasons BootROMS rejects unsigned images when secure boot is enabled in OTP secure bits. So check for OPT secure bits and do not allow flashing unsigned images when secure boot is enabled. Access to OTP via U-Boot fuse API is currently implemented only for A38x and A37xx SoCs.

[PATCH v3 1/2] cmd: mvebu/bubt: Check for A38x image data checksum

2022-08-23 Thread Pali Rohár
Currently for A38x image is checked only header checksum. So check also for image data checksum to prevent flashing broken image. Signed-off-by: Pali Rohár Reviewed-by: Stefan Roese --- Changes in v3: * Compile fix (move another code chunk from patch 2/2 to 1/2) Changes in v2: * Compile fix

Re: [PATCH v2 2/2] cmd: mvebu/bubt: Check for A38x/A37xx OTP secure bits and secure boot

2022-08-23 Thread Pali Rohár
On Tuesday 23 August 2022 07:05:33 Stefan Roese wrote: > Hi Pali, > > On 09.08.22 21:42, Pali Rohár wrote: > > For obvious reasons BootROMS rejects unsigned images when secure boot is > > enabled in OTP secure bits. So check for OPT secure bits and do not allow > > flashing unsigned images when

Re: [PATCH v2 1/2] cmd: mvebu/bubt: Check for A38x image data checksum

2022-08-23 Thread Pali Rohár
On Tuesday 23 August 2022 12:28:48 Stefan Roese wrote: > Hi Pali, > > On 09.08.22 21:42, Pali Rohár wrote: > > Currently for A38x image is checked only header checksum. > > So check also for image data checksum to prevent flashing broken image. > > > > Signed-off-by: Pali Rohár > > > > --- > >

Re: [PATCH] common/console.c: prevent pre-console buffer contents from being added to itself

2022-08-23 Thread Rasmus Villemoes
Ping. The previous patch has already been applied [cff29636933a, common/console.c: use CONFIG_VAL() with PRE_CON_BUF_* variables], and I realize this one might be more "controversial" in how it makes gd->precon_buf_idx serve as a "flag" when negative, but I'd really like to make progress towards

[PATCH] binman: Sort tests and rework test-file numbers

2022-08-23 Thread Stefan Herbrechtsmeier
From: Stefan Herbrechtsmeier Tests should be in order of the test-file numbers. Sort the tests according to the test-file numbers and rework the test-file numbers to eliminate duplicate numbers. Signed-off-by: Stefan Herbrechtsmeier --- tools/binman/ftest.py | 113

Re: [PATCH 23/31] clk: mediatek: add support to configure clock driver parent

2022-08-23 Thread Weijie Gao
On Sat, 2022-08-13 at 00:18 -0400, Sean Anderson wrote: > On 8/3/22 11:36 PM, Weijie Gao wrote: > > This patch adds support for a clock node to configure its parent > > clock > > where possible. > > > > Signed-off-by: Weijie Gao > > --- > > drivers/clk/mediatek/clk-mtk.c | 79

Re: [PATCH v2 1/2] cmd: mvebu/bubt: Check for A38x image data checksum

2022-08-23 Thread Stefan Roese
Hi Pali, On 09.08.22 21:42, Pali Rohár wrote: Currently for A38x image is checked only header checksum. So check also for image data checksum to prevent flashing broken image. Signed-off-by: Pali Rohár --- Changes in v2: * Compile fix (move code chunk from patch 2/2 to 1/2) ---

Re: [PATCH] ARM: dts: Use clock-output-names for dra7

2022-08-23 Thread Tony Lindgren
* Romain Naour [220823 08:25]: > Hello, > > Le 04/02/2022 à 09:08, Tony Lindgren a écrit : > > With the TI clocks supporting the use of clock-output-names devicetree > > property, we no longer need to use non-standard node names for clocks. > > > > Depends-on: 31aa7056bbec ("ARM: dts: Don't use

Re: [PATCH] image: Ensure image header name is null terminated

2022-08-23 Thread John Keeping
On Tue, Aug 23, 2022 at 03:59:07PM +1000, Joel Stanley wrote: > When building with GCC 12: > > ../include/image.h:779:9: warning: ‘strncpy’ specified bound 32 equals > destination size [-Wstringop-truncation] > 779 | strncpy(image_get_name(hdr), name, IH_NMLEN); > |

[PATCH v3 3/5] board: sl28: add user friendly names for the boot sources

2022-08-23 Thread Michael Walle
During startup the SPL will print where the u-boot proper is read from. Instead of using the default names, provide more user friendly names. Signed-off-by: Michael Walle --- board/kontron/sl28/spl.c | 16 1 file changed, 16 insertions(+) diff --git a/board/kontron/sl28/spl.c

[PATCH v3 5/5] board: sl28: remove COUNTER_FREQUENCY_REAL

2022-08-23 Thread Michael Walle
The frequency of the system counter is static which is given by the COUNTER_FREQUENCY option. Remove COUNTER_FREQUENCY_REAL. Signed-off-by: Michael Walle --- include/configs/kontron_sl28.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/configs/kontron_sl28.h

[PATCH v3 4/5] board: sl28: support dynamic prompts

2022-08-23 Thread Michael Walle
Depending on the boot source, set different CLI prompts. This will help the user to figure out in which mode the bootloader was started. There are two special modes: failsafe and SDHC boot. Signed-off-by: Michael Walle --- board/kontron/sl28/sl28.c | 20

[PATCH v3 2/5] board: sl28: implement additional bootsources

2022-08-23 Thread Michael Walle
The board is able to boot from the following source: - user-updateble SPI flash - write-protected part of the same SPI flash - eMMC - SD card Implement the needed function hooks to support all of these boot sources. Signed-off-by: Michael Walle --- board/kontron/sl28/common.c| 22

  1   2   >