summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-08-30common: spl: spl: Init DRAM size in R5/A53 SPLChintan Vankar
Initialize DRAM size in SPL stage since networking requires DDR to be initialized. Reviewed-by: Dhruva Gole <[email protected]> Reviewed-by: Tom Rini <[email protected]> Signed-off-by: Kishon Vijay Abraham I <[email protected]> Signed-off-by: Chintan Vankar <[email protected]>
2024-08-30lib: crypto: fix ASYMMETRIC_KEY_TYPE dependencyTomas Paukrt
Fix the dependency to avoid a warning if RSA_VERIFY_WITH_PKEY is enabled. Fixes: b7463f198da6 ("Make ASYMMETRIC_KEY_TYPE depend on FIT_SIGNATURE") Signed-off-by: Tomas Paukrt <[email protected]>
2024-08-30list: use list_count_nodes() to count list entriesSughosh Ganu
Use the API function list_count_nodes() to count the number of list entries. Signed-off-by: Sughosh Ganu <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-30mx6slevk: Convert to OF_UPSTREAMFabio Estevam
Instead of using the local imx6sl-evk, imx6sl-pinfunc.h and imx6sl.dtsi devicetree copies from U-Boot, convert the imx6sl-evk board to OF_UPSTREAM so that the upstream kernel devicetree can be used instead. Signed-off-by: Fabio Estevam <[email protected]>
2024-08-30mx6slevk: Keep a single defconfigFabio Estevam
Remove mx6slevk_spinor_defconfig and mx6slevk_spl_defconfig in favor of having a single mx6slevk_defconfig to help reducing the maintenance effort. Signed-off-by: Fabio Estevam <[email protected]>
2024-08-30mx6slevk: Fix the boot device numberFabio Estevam
The SD card is registered as mmc device 0. Fix it accordingly so that the board can boot to Linux from the SD card. Signed-off-by: Fabio Estevam <[email protected]>
2024-08-30mx6slevk: Convert to watchdog driver modelFabio Estevam
Commit 68dcbdd594d4 ("ARM: imx: Add weak default reset_cpu()") caused the 'reset' command in U-Boot to not cause a board reset. Fix it by switching to the watchdog driver model via sysreset, which is the preferred method for implementing the watchdog reset. Signed-off-by: Fabio Estevam <[email protected]>
2024-08-30board: phytec: phycore_imx8mp: Add mtd spi partitionsBenjamin Hahn
Depending on if a SPI-NOR flash is populated add the mtd partition table to the device tree. For this we have to also probe the flash before booting. Signed-off-by: Benjamin Hahn <[email protected]>
2024-08-30configs: phycore-imx8mp_defconfig: Enable SPI NOR flash supportBenjamin Hahn
Enable SPI NOR flash support in U-Boot. Signed-off-by: Benjamin Hahn <[email protected]>
2024-08-30imx: ele_ahab: Add HUK derivation supportMathieu Othacehe
Add a new ahab_derive command that derives the hardware unique key (HUK) into a 16 or 32 bytes key and stores it at the given address. Signed-off-by: Mathieu Othacehe <[email protected]> Reviewed-by: Ye Li <[email protected]>
2024-08-29Merge tag 'u-boot-imx-master-20240829' of ↵Tom Rini
https://gitlab.denx.de/u-boot/custodians/u-boot-imx CI: https://source.denx.de/u-boot/custodians/u-boot-imx/-/pipelines/22162 - Fix an issue with "tools/buildman/buildman imx8ulp_evk" failing every other time.
2024-08-29mach-imx: do not use if_changed more than once per targetJerome Forissier
doc/develop/makefiles.rst has the following note: if_changed should not be used more than once per target. It stores the executed command in a corresponding .cmd file and multiple calls would result in overwrites and unwanted results when the target is up to date and only the tests on changed commands trigger execution of commands. The mach-imx Makefile does not follow this recommandation, so fix it by implementing a single command that performs both the cpp_cfg and imx9_check actions. This change fixes an issue with "tools/buildman/buildman imx8ulp_evk" failing every other time [1]. [1] https://lists.denx.de/pipermail/u-boot/2024-August/563192.html Fixes: f637dfe8c468 ("mach-imx: Add i.MX93 binman support.") Signed-off-by: Jerome Forissier <[email protected]>
2024-08-28bootstage: Fix unstash of records from SPLJonas Karlman
The commit b81e31a1e6c5 ("bootstash: Do not provide a default address for all") changed a bootstage unstash call to bootstage stash, this has resulted in bootstage records stashed in SPL no longer get unstaged in U-Boot proper. Fix this by changing back to a unstage call. Fixes: b81e31a1e6c5 ("bootstash: Do not provide a default address for all") Signed-off-by: Jonas Karlman <[email protected]> Reviewed-by: Simon Glass <[email protected]> Reviewed-by: Tom Rini <[email protected]>
2024-08-28bootstage: Fix unstash of records from SPLJonas Karlman
The commit b81e31a1e6c5 ("bootstash: Do not provide a default address for all") changed a bootstage unstash call to bootstage stash, this has resulted in bootstage records stashed in SPL no longer get unstaged in U-Boot proper. Fix this by changing back to a unstage call. Fixes: b81e31a1e6c5 ("bootstash: Do not provide a default address for all") Signed-off-by: Jonas Karlman <[email protected]> Reviewed-by: Simon Glass <[email protected]> Reviewed-by: Tom Rini <[email protected]>
2024-08-28mtd: rawnand: meson: read/write access for boot ROM pagesArseniy Krasnov
Boot ROM on Meson needs some pages to be read/written in a special mode: 384 byte ECC mode (so called "short" by Amlogic) and with scrambling enabled. Such pages are located on the chip in the following way (for example): [ p0 ][ p1 ][ p2 ][ p3 ][ p4 ][ p5 ][ p6 ][ p7 ] ... [ pN ] ^ ^ ^ ^ pX is page number "X". "^" means "special" page used by boot ROM - e.g. every 2nd page in the range of [0, 7]. Step (2 here) and last page in range is read from the device tree. Signed-off-by: Arseniy Krasnov <[email protected]> Reviewed-by: Michael Trimarchi <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Neil Armstrong <[email protected]>
2024-08-28mtd: rawnand: meson: refactor use of 'meson_nfc_cmd_access()'Arseniy Krasnov
Move call 'meson_nfc_cmd_seed()' and check for 'NAND_NEED_SCRAMBLING' to 'meson_nfc_cmd_access()', thus removing code duplication. Signed-off-by: Arseniy Krasnov <[email protected]> Reviewed-by: Michael Trimarchi <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Neil Armstrong <[email protected]>
2024-08-28mtd: rawnand: nand_base: support for 'NAND_IS_BOOT_MEDIUM' flagArseniy Krasnov
Based on Linux kernel: commit f922bd798bb9 ("mtd: rawnand: add an option to specify NAND chip as a boot device") Allow to define a NAND chip as a boot device. This can be helpful for the selection of the ECC algorithm and strength in case the boot ROM supports only a subset of controller provided options. Signed-off-by: Arseniy Krasnov <[email protected]> Reviewed-by: Michael Trimarchi <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Neil Armstrong <[email protected]>
2024-08-27mmc: fix signed vs unsigned compare in read check in _spl_load()Franco Venturi
Fix signed vs unsigned compare in read check in _spl_load() Issue: when info->read() returns a negative value because of an error, the comparison of 'read' (signed) with 'sizeof(*header)' (unsigned silently converts the negative value into a very large unsigned value and the check on the error condition always return false, i.e. the error is not detected Symptoms: if spl_load_image_fat() is unable to find the file 'uImage', the SPL phase of the boot process just hangs after displaying the following line: Trying to boot from MMC1 Fix: cast 'sizeof(*header)' to int so the compare is now between signed types Reference: https://stackoverflow.com/questions/17293749/sizeof-operator-in-if-statement Signed-off-by: Franco Venturi <[email protected]> Reviewed-by: Sean Anderson <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2024-08-27gpio: Add G7 Aspeed gpio controller driverBilly Tsai
In the 7th generation of the SoC from Aspeed, the control logic of the GPIO controller has been updated to support per-pin control. Each pin now has its own 32-bit register, allowing for individual control of the pin’s value, direction, interrupt type, and other settings. Signed-off-by: Billy Tsai <[email protected]>
2024-08-27tools/scripts/Kconfig: Update references from kconfig-language.txt to rstHiago De Franco
The Linux kernel documentation has transitioned from using kconfig-language.txt to kconfig-language.rst. Therefore update all occurrences of kconfig-language.txt. Signed-off-by: Hiago De Franco <[email protected]>
2024-08-27dm: core: Make SPL_DM_SEQ_ALIAS select SPL_STRTOGaskell, Oliver
Enabling CONFIG_DM_SEQ_ALIAS enables code which relies on `trailing_strtol()` - which is only linked in SPL when CONFIG_SPL_STRTO is enabled. CONFIG_SPL_STRTO is not enabled by default - to ensure this function is available in SPL, CONFIG_SPL_DM_SEQ_ALIAS should select CONFIG_SPL_STRTO. Signed-off-by: Oliver Gaskell <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27arm: dts: nuvoton: add dts support for npcm845 yosemite4Jim Liu
Signed-off-by: Jim Liu <[email protected]>
2024-08-27lib: move phdr increment to for loop headingMaxim Moskalets
Shifting this pointer in the loop will be more logical when working with the code later, because you can see at a glance what exactly changes at each iteration. Moreover, the code remains equivalent because this variable is not used after the loop. Signed-off-by: Maxim Moskalets <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27Merge patch series "dm: core: Avoid multiple calls to fdt_parent_offset()"Tom Rini
Jonas Karlman <[email protected]> says: Use of fdt_parent_offset() is very expensive as detailed by the function documentation: NOTE: This function is expensive, as it must scan the device tree structure from the start to nodeoffset, *twice*. This series remove multiple calls to fdt_parent_offset() or ofnode_get_parent() when instead a single call can be made and the returned value can be reused. This series help reduce boot time by around: - ~137ms on a Radxa ROCK Pi 4 (RK3399) - ~33ms on a Radxa ZERO 3W (RK3566)
2024-08-27timer: npcm: Change counter sourceJim Liu
The counter value read from TDR register may not be correct. Read SECCNT and CNTR25M instead to get the correct timestamp. Signed-off-by: Jim Liu <[email protected]>
2024-08-27dm: core: regmap: Avoid multiple calls to ofnode_get_parent()Jonas Karlman
Until a live tree is used in U-Boot proper after relocation, use of ofnode_get_parent() will trigger a call to the very expensive fdt_parent_offset(), as detailed by the function documentation: NOTE: This function is expensive, as it must scan the device tree structure from the start to nodeoffset, *twice*. Re-use the returned value from a single call instead of having to make multiple calls for same node. Signed-off-by: Jonas Karlman <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27dm: core: ofnode: Avoid multiple calls to ofnode_get_parent()Jonas Karlman
Until a live tree is used in U-Boot proper after relocation, use of ofnode_get_parent() will trigger a call to the very expensive fdt_parent_offset() as detailed by the function documentation: NOTE: This function is expensive, as it must scan the device tree structure from the start to nodeoffset, *twice*. Re-use the returned value from a single call instead of having to make multiple calls for same node. Signed-off-by: Jonas Karlman <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27dm: core: fdtaddr: Avoid multiple calls to fdt_parent_offset()Jonas Karlman
Use of fdt_parent_offset() is very expensive as detailed by the function documentation: NOTE: This function is expensive, as it must scan the device tree structure from the start to nodeoffset, *twice*. Re-use the returned value from a single call instead of having to make multiple calls for same nodeoffset. Signed-off-by: Jonas Karlman <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27gpio: npcm: Add SGPIO support for Nuvoton NPCM SoCsJim Liu
Add Nuvoton BMC NPCM7xx/NPCM8xx sgpio driver. BMC can use this driver to increase 64 GPI pins and 64 GPO pins to use. Signed-off-by: Jim Liu <[email protected]>
2024-08-27test/py: spi: Add tests for SPI flash deviceLove Kumar
Add test cases for sf commands to verify various SPI flash operations such as erase, write and read. It also adds qspi lock unlock cases. This test relies on boardenv_* configurations to run it for different SPI flash family such as single SPI, QSPI, and OSPI. Signed-off-by: Love Kumar <[email protected]>
2024-08-27cmd: bind: Use device sequence instead for driver bind/unbindZixun LI
Currently uclass index is used for bind/unbind which ignores alias sequence numbering. Use device sequence number instead as it's the number explicitly set in the DT. Also update documentation to use sequence number. Signed-off-by: Zixun LI <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27dm: core: Show device sequence instead in dm_dump_tree()Zixun LI
Currently uclass index is shown in DM tree dump which ignores alias sequence numbering. The result could be confusing since these 2 numbers could be different. Show device sequence number instead as it's more meaningful. Also update documentation to use sequence number. Signed-off-by: Zixun LI <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27mtd: nand: raw: omap_gpmc: Check return value of gpmc_nand_initVignesh Raghavendra
If the function is called with no NAND device attached, then this function can return error value, proceeding further ignoring the same can cause system crash. This is seen when "mtd list" is run with no NAND addon cards connected. Signed-off-by: Vignesh Raghavendra <[email protected]> Acked-by: Roger Quadros <[email protected]>
2024-08-27omap3: omap3evm: Migrate to OF_UPSTREAMDerald D. Woods
This commit brings the omap3evm inline with the remaining OMAP3XXX variants. Signed-off-by: Derald D. Woods <[email protected]>
2024-08-27sandbox: Fix pinmux warnings with non-test devicetreesSean Anderson
The sandbox pinmux driver is used in the non-test devicetree as well as the test one. I didn't realize this when I modified the driver for tests, and so broke the regular use case (which only resulted in warnings). First, making the pinmux and the UART group available pre-relocation to avoid ENODEV errors. Then, convert the pin groups and functions to the new style, adding onewire group as well. Fixes: 7f0f1806e3a ("test: pinmux: Add test for pin muxing") Closes: https://source.denx.de/u-boot/u-boot/-/issues/2 Signed-off-by: Sean Anderson <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27ata: sata_rescan must scan for block devicesHeinrich Schuchardt
A system may have multiple SATA controller. Removing the controller with the lowest sequence number before probing all SATA controllers makes no sense. In sata_rescan we remove all block devices which are children of SATA controllers. We also have to remove the bootdev devices as they will be created when scanning for block devices. After probing all SATA controllers we must scan for block devices otherwise we end up without any SATA block device. Signed-off-by: Heinrich Schuchardt <[email protected]> Reviewed-by: Tony Dinh <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2024-08-27pci: mediatek: add support for upstream split PCIe nodeChristian Marangi
Add support for upstream linux split PCIe node. Upstream linux have an alternative way to declare PCIe nodes that splits them in dedicated nodes for each line instead of putting them all in one node. Detect this by checking if the mediatek,generic-pciecfg node is passed as it's used to reference the common address for all the PCIe lines. Signed-off-by: Christian Marangi <[email protected]>
2024-08-27remoteproc: uclass: Modify uc_pdata->name to use combination of device name ↵MD Danish Anwar
and device's parent name uc_pdata->name is populated from device tree property "remoteproc-name". For those devcices that don't set "remoteproc-name", uc_pdata->name falls back to dev->name. If two devices have same name, this will result into uc_pdata->name not being unique and rproc_init() will fail. Fix this by using combination of dev->name and dev->parent->name instead of using just the dev->name to populate uc_pdata->name. Signed-off-by: MD Danish Anwar <[email protected]> Reviewed-by: Roger Quadros <[email protected]> Reviewed-by: Andrew Davis <[email protected]>
2024-08-27ata: dwc_ahsata: create boot deviceHeinrich Schuchardt
For each block device we must create a sibling boot device. Signed-off-by: Heinrich Schuchardt <[email protected]>
2024-08-27Merge patch series "bootstd: Try again to resolve infinite-loop bug"Tom Rini
Simon Glass <[email protected]> says: This little series tries to resolve a problem found with an earlier fix.
2024-08-27Merge patch series "arch: arm: dts: ti: Add missing fss range"Tom Rini
Jonathan Humphreys <[email protected]> says: Upstream DTS added explicit ranges to the fss node. It did not include the 32 bit memory space needed by the R5 to access OSPI. With the upstream DTS sync, OSPI boot no longer works. Adding the missing range here. It is also being added in the upstream DTS, so after the next upstream DTS sync, these patches can be removed. Fixes: 5024a96db8e ("Subtree merge tag 'v6.10-dts' of devicetree-rebasing repo [1] into dts/upstream")
2024-08-27bootstd: Make bootdev_next_prio() continue after failureSimon Glass
When a device fails to probe, the next device should be tried, until either we find a suitable device or run out of devices. A device should never be tried twice. When we run out of devices of a particular priority, the hunter should be used to generate devices of the next priority. Only if all attempts fail should this function return an error. Update the function to use the latent 'found' boolean to determine whether another loop iteration is warranted, rather than setting 'dev' to NULL, which creates confusion, suggesting that no devices have been scanned and the whole process is starting from the beginning. Note that the upcoming bootflow_efi() test is used to test this behaviour. Signed-off-by: Simon Glass <[email protected]> Fixes: https://source.denx.de/u-boot/custodians/u-boot-dm/-/issues/17
2024-08-27Revert "bootdev: avoid infinite probe loop"Simon Glass
This turns out to be insufficient to fix the problem, since when bootdev_next_prio() exits, the caller has no idea that this really is the end. Nor is it, since there may be other devices which should be checked. The caller iterates which calls iter_incr() which calls bootdev_next_prio() again, which finds the same device and the loop continues. We never did create a test for this[1], which makes it hard to be sure which problem was fixed. The original code had the virtue of staying in the loop looking for a bootdev, so let's go back to that and try to fix this another way. A future patch will make bootdev_next_prio() continue after failure which should provide same effect. This reverts commit 9d92c418acfb7576e12e2bd53fed294bb9543724. Signed-off-by: Simon Glass <[email protected]>
2024-08-27arch: arm: dts: k3-j721e-r5-sk: Add missing fss rangeJonathan Humphreys
Upstream DTS added explicit ranges to the fss node. It did not include the 32 bit memory space needed by the R5 to access OSPI. With the upstream DTS sync, OSPI boot no longer works. Adding the missing range here. It is also being added in the upstream DTS, so after the next upstream DTS sync, this patch can be removed. See 0c0e03ec22 (arm64: dts: ti: k3-j721e: Use exact ranges for FSS node) Fixes: 5024a96db8e ("Subtree merge tag 'v6.10-dts' of devicetree-rebasing repo [1] into dts/upstream") Signed-off-by: Jonathan Humphreys <[email protected]>
2024-08-27arch: arm: dts: k3-j721e-r5-evm: Add missing fss rangeJonathan Humphreys
Upstream DTS added explicit ranges to the fss node. It did not include the 32 bit memory space needed by the R5 to access OSPI. With the upstream DTS sync, OSPI boot no longer works. Adding the missing range here. It is also being added in the upstream DTS, so after the next upstream DTS sync, this patch can be removed. See 0c0e03ec22 (arm64: dts: ti: k3-j721e: Use exact ranges for FSS node) Fixes: 5024a96db8e ("Subtree merge tag 'v6.10-dts' of devicetree-rebasing repo [1] into dts/upstream") Signed-off-by: Jonathan Humphreys <[email protected]>
2024-08-27arch: arm: dts: k3-j7200-r5-evm: Add missing fss rangeJonathan Humphreys
Upstream DTS added explicit ranges to the fss node. It did not include the 32 bit memory space needed by the R5 to access OSPI. With the upstream DTS sync, OSPI boot no longer works. Adding the missing range here. It is also being added in the upstream DTS, so after the next upstream DTS sync, this patch can be removed. See f00e626085 (arm64: dts: ti: k3-j7200: Use exact ranges for FSS node) Fixes: 5024a96db8e ("Subtree merge tag 'v6.10-dts' of devicetree-rebasing repo [1] into dts/upstream") Signed-off-by: Jonathan Humphreys <[email protected]> Reviewed-by: Aniket Limaye <[email protected]>
2024-08-27arch: arm: dts: k3-am69-r5-sk: Add missing fss rangeJonathan Humphreys
Upstream DTS added explicit ranges to the fss node. It did not include the 32 bit memory space needed by the R5 to access OSPI. With the upstream DTS sync, OSPI boot no longer works. Adding the missing range here. It is also being added in the upstream DTS, so after the next upstream DTS sync, this patch can be removed. See f062a015f4 (arm64: dts: ti: k3-j784s4: Use exact ranges for FSS node) Fixes: 5024a96db8e ("Subtree merge tag 'v6.10-dts' of devicetree-rebasing repo [1] into dts/upstream") Signed-off-by: Jonathan Humphreys <[email protected]>
2024-08-27arch: arm: dts: k3-j784s4-r5-evm: Add missing fss rangeJonathan Humphreys
Upstream DTS added explicit ranges to the fss node. It did not include the 32 bit memory space needed by the R5 to access OSPI. With the upstream DTS sync, OSPI boot no longer works. Adding the missing range here. It is also being added in the upstream DTS, so after the next upstream DTS sync, this patch can be removed. See f062a015f4 (arm64: dts: ti: k3-j784s4: Use exact ranges for FSS node) Fixes: 5024a96db8e ("Subtree merge tag 'v6.10-dts' of devicetree-rebasing repo [1] into dts/upstream") Signed-off-by: Jonathan Humphreys <[email protected]> Reviewed-by: Andrew Davis <[email protected]>
2024-08-26Merge patch series "Tidy up console recording in tests"Tom Rini
Simon Glass <[email protected]> says: This series started as a small fix for checking for an empty line, but in the process several other problems were found and fixed: - fix tests which use console recording but don't set the flag - drop unnecessary resetting of the console in tests - drop unnecessary blank line before MMC output - update the docs a little - fix buildman test failure on newer Pythons - a few other minor things This series also renames the confusing flag names, so that they are easier to remember - just a UTF_ (unit-test flags) prefix.
2024-08-26test: Tidy up checking for console endSimon Glass
Use the ut_assert_console_end() function provided, rather than doing it separately. Signed-off-by: Simon Glass <[email protected]>