aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2023-12-18Merge branch 'next' of https://source.denx.de/u-boot/custodians/u-boot-riscv ↵WIP/18Dec2023-nextTom Rini18-46/+273
into next - VisionFive2: Enable CONFIG_SYSRESET - StarFive: Modify starfive timer driver - AMD/Xilinx: Add MicroBlaze V support - Unmatched: Migrate to text environment
2023-12-18Merge branch 'master' of https://source.denx.de/u-boot/custodians/u-boot-spi ↵Tom Rini11-7/+210
into next - spi_nor_read_sfdp_dma_unsafe (Vaishnav) - w25q01/02 (Jim)
2023-12-18Merge tag 'v2024.01-rc5' into nextTom Rini78-2227/+1015
Prepare v2024.01-rc5
2023-12-18Prepare v2024.01-rc5v2024.01-rc5Tom Rini2-2/+2
Signed-off-by: Tom Rini <trini@konsulko.com>
2023-12-18riscv: sifive: unmatched: migrate to text environmentYong-Xuan Wang3-38/+20
Migrate to the new environment format and drop most of the config.h. Signed-off-by: Yong-Xuan Wang <yongxuan.wang@sifive.com> Reviewed-by: Tom Rini <trini@konsulko.com>
2023-12-18timer: starfive: Add Starfive timer supportKuan Lim Lee1-7/+9
Add timer driver in Starfive SoC. It is an timer that outside of CPU core and inside Starfive SoC. Signed-off-by: Kuan Lim Lee <kuanlim.lee@starfivetech.com> Signed-off-by: Wei Liang Lim <weiliang.lim@starfivetech.com> Changes for v2: - correct driver name, comment, variable Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2023-12-18riscv: Add support for AMD/Xilinx MicroBlaze VMichal Simek12-1/+238
MicroBlaze V is new AMD/Xilinx soft-core 32bit RISC-V processor IP. It is hardware compatible with classic MicroBlaze processor. The patch contains initial wiring and configuration for initial HW design with memory, cpu, interrupt controller, timers and uartlite console (interrupt controller is listed but U-Boot is not using it). Provided DT is just describing one configuration and should be taken only as example. Signed-off-by: Michal Simek <michal.simek@amd.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com> Reviewed-by: Padmarao Begari <padmarao.begari@microchip.com>
2023-12-18configs: visionfive2: Enable CONFIG_SYSRESET configJaehoon Chung1-0/+1
Enable CONFIG_SYSRESET config to do reset. Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2023-12-18riscv: dts: jh7110: Add a gpio-restart nodeJaehoon Chung1-0/+5
Add gpio-restart node to do reset. Before applied this patch, System Reset Extension doesn't appear with sbi command. OpenSBI 1.3 Machine: Vendor ID 489 Architecture ID 8000000000000007 Implementation ID 4210427 Extensions: sbi_set_timer sbi_console_putchar ...[snip]... IPI Extension RFENCE Extension Hart State Management Extension Performance Monitoring Unit Extension After applied this patch, System Reset Extension is supported from SBI. OpenSBI 1.3 Machine: Vendor ID 489 Architecture ID 8000000000000007 Implementation ID 4210427 Extensions: sbi_set_timer sbi_console_putchar ...[snip]... IPI Extension RFENCE Extension Hart State Management Extension System Reset Extension Performance Monitoring Unit Extension Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
2023-12-17Merge tag 'efi-next-20231217' of ↵WIP/17Dec2023-nextTom Rini28-729/+771
https://source.denx.de/u-boot/custodians/u-boot-efi into next Pull request for efi-next-20231217 Documentation: * replace MD5 and SHA1 by SHA256 in examples UEFI: * Refactor boot manager and bootefi command to let the EFI boot method work without shell.
2023-12-17doc: Replace examples of MD5 and SHA1 with SHA256Sean Anderson17-109/+109
Both SHA1 and (especially) MD5 are no longer as safe as they once were for cryptographic use. Replaces examples which use them with examples using SHA256 instead. This will provide more-secure defaults for users who use documentation examples as a base for their own use. This is not too necessary for non-verified-boot scenarios (since someone could just replace the checksum), but I wanted to be complete. Signed-off-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Peter Robinson <pbrobinson@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2023-12-17bootmeth: use efi_loader interfaces instead of bootefi commandAKASHI Takahiro7-37/+15
Now that efi_loader subsystem provides interfaces that are equivalent with bootefi command, we can replace command invocations with APIs. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-17cmd: efidebug: ease efi configuration dependencyAKASHI Takahiro1-2/+2
Now it is clear that the command actually depends on interfaces, not "bootefi bootmgr" command. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-17cmd: bootefi: move library interfaces under lib/efi_loaderAKASHI Takahiro3-528/+551
In the prior commits, interfaces for executing EFI binary and boot manager were carved out. Move them under efi_loader directory so that they can be called from other places without depending on bootefi command. Only efi_selftest-related code will be left in bootefi.c. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-17cmd: bootefi: localize global device paths for efi_selftestAKASHI Takahiro1-6/+13
Device paths allocated in bootefi_test_prepare() will be immediately consumed by do_efi_selftest() and there is no need to keep them for later use. Introduce test-specific varialbles to make it easier to move other bootmgr functions into library directory in the next commit. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-17cmd: bootefi: carve out binary execution interfaceAKASHI Takahiro1-14/+32
Carve binary execution code out of do_bootefi_image() in order to move binary-execution specific code into library directory in the later commit. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-17cmd: bootefi: carve out EFI boot manager interfaceAKASHI Takahiro1-19/+24
Carve EFI boot manager related code out of do_bootefi_image() in order to move boot manager specific code into library directory in the later commit. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-17cmd: bootefi: re-organize do_bootefi()AKASHI Takahiro3-30/+68
Replicate some code and re-organize do_bootefi() into three cases, which will be carved out as independent functions in the next two commits. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-17cmd: bootefi: unfold do_bootefi_image()AKASHI Takahiro1-64/+37
Unfold do_bootefi_image() into do_bootefi() in order to make it easier to re-organize do_bootefi() in the next commit. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2023-12-15Revert "board: ti: am62x/am62ax: Update virtual interrupt allocations in ↵Tom Rini2-21/+21
board config" After talking with the author off-list I was reminded that this part of the series was not supposed to be merged, only parts 1-3 upon further review. This reverts commit 58a277c207927530469f0ae56eff7d5f702d5486. Signed-off-by: Tom Rini <trini@konsulko.com>
2023-12-15Merge tag 'clk-2024.01-next' of ↵WIP/15Dec2023-nextTom Rini18-277/+288
https://source.denx.de/u-boot/custodians/u-boot-clk into next clock patches for u-boot/next The main thing in here is Igor's conversion of soc_clk_dump to a clk_ops member. There's also a write-protect feature for nuvoton clocks. Signed-off-by: Sean Anderson <seanga2@gmail.com>
2023-12-15Merge tag 'clk-2024.01-rc5' of ↵WIP/15Dec2023Tom Rini8-12/+39
https://source.denx.de/u-boot/custodians/u-boot-clk clock changes for u-boot/master This has some clock fixes which should go in before the release. It's a bit late in the cycle, but most of these have tests to go along with them. Signed-off-by: Sean Anderson <seanga2@gmail.com>
2023-12-15Merge branch '2023-12-15-assorted-TI-platform-updates' into nextTom Rini13-973/+419
- Assorted updates and fixes for some TI K3 platforms and SoCs
2023-12-15board: ti: k3: Remove need for CFG_SYS_SDRAM_BASEWIP/2023-12-15-assorted-TI-platform-updatesAndrew Davis7-18/+6
The base address of extended DDR does not change across the K3 family. Setting this per SoC is not needed. Remove this definition to help remove the last bits from K3 include/configs/*.h files. Signed-off-by: Andrew Davis <afd@ti.com>
2023-12-15test: dm: clk_ccf: fix building errorYang Xiwen1-1/+2
Fix unused variable error produced by building tests Fixes: d3061824 (test: dm: clk_ccf: test ccf_clk_ops) Signed-off-by: Yang Xiwen <forbidden405@outlook.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20231216-b4-fix_build-v1-1-b8e79c94744f@outlook.com
2023-12-15board: ti: am62x/am62ax: Update virtual interrupt allocations in board configVishal Mahaveer2-21/+21
Updates as a result of TIFS core now reserving a virtual interrupt for enabling interrupts between DM to TIFS core. Because of this change other virtual interrupt counts decrease by one. Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-12-15board: ti: am62x/am62ax: Update MCU GPIO interrupt allocation in board configVishal Mahaveer2-4/+28
Share the MCU GPIO interrupts between A53 core and DM R5 core. Allocating 2 instances each to A53 and DM R5. Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-12-15board: ti: am62ax: Add C7x resource allocation entries to board configVishal Mahaveer1-17/+29
Update am62ax rm-cfg with allocation entries for C7x core. Following updates are added for C7x: - Share split BCDMA tx and rx channels between DM R5 and C7x - Share rings for split BCDMA tx and rx channels between DM R5 and C7x - Add Global events and Virtual interrupts for C7x Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-12-15board: ti: am62x/am62ax: Formatting updates to board config filesVishal Mahaveer2-573/+326
Minor formatting updates to the rm board configuration file for am62x and am62ax boards. Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
2023-12-15arm: mach-k3: Merge initial memory mapsAndrew Davis1-226/+2
The Device vs Normal memory map is the same for all K3 SoCs. Merge the SoC specific maps into one. Signed-off-by: Andrew Davis <afd@ti.com> Reviewed-by: Nishanth Menon <nm@ti.com> Tested-by: Nishanth Menon <nm@ti.com>
2023-12-15arm: mach-k3: Remove non-cached memory map areasAndrew Davis1-27/+3
All normal memory areas should be mapped as such. We added these un-cached holes in our memory map to hack around the remoteproc driver missing the proper cache maintenance operations. The problem is having these non-cached memory map areas causes stability issues later in system operation due to the nature of the K3 coherency architecture. Plus these are board specific carveouts and instead should have been added at the board level, not here in the SoC common code area. Remove these non-cached memory map areas. Signed-off-by: Andrew Davis <afd@ti.com> Reviewed-by: Nishanth Menon <nm@ti.com> Tested-by: Nishanth Menon <nm@ti.com>
2023-12-15arm: mach-k3: Do not map ATF and OPTEE regions in MMUAndrew Davis1-4/+10
ATF and OPTEE regions may be firewalled from non-secure entities. To prevent access to this area we leave a hole there in the MMU map. This is the same idea as [0] but we complete that patch by adding the same for AM65, J721e, J7200, and J721s2 here. [0] commit 0688ff3ae23c ("arm: mach-k3: arm64-mmu: do not map ATF and OPTEE regions in A53 MMU") Signed-off-by: Andrew Davis <afd@ti.com>
2023-12-15arm: mach-k3: Let the compiler size the mem_map listsAndrew Davis1-29/+6
NR_MMU_REGIONS is a copy/paste from another platform that extends this list later. We do not do that, so let the list be the size of the initializer list. Signed-off-by: Andrew Davis <afd@ti.com> Reviewed-by: Nishanth Menon <nm@ti.com> Tested-by: Nishanth Menon <nm@ti.com>
2023-12-15arm: mach-k3: Move K3 common schema.yaml out of board directoryAndrew Davis3-80/+14
This file is common for all K3, move it out of board/ directory and into mach-k3. As we need to change the path in k3-binman.dtsi let's take this opportunity to switch to absolute paths which makes adding non-TI boards (like Toradex Verdin) not need to override these paths. Signed-off-by: Andrew Davis <afd@ti.com>
2023-12-15test: dm: clk_ccf: test ccf_clk_opsYang Xiwen5-4/+17
Assign ccf_clk_ops to .ops of clk_ccf driver so that it can act as an clk provider. Also add "#clock-cells=<1>" to its device tree node. Add "i2c_root" to clk_test in the device tree and driver for testing. Get "i2c_root" clock in CCF unit tests and add tests for it. Signed-off-by: Yang Xiwen <forbidden405@outlook.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20231111-enable_count-v3-2-08a821892fa9@outlook.com
2023-12-15Merge tag 'u-boot-stm32-20231215' of ↵Tom Rini17-65/+108
https://source.denx.de/u-boot/custodians/u-boot-stm into next _ run savedefconfig on all STM32 defconfig STM32 MCU: _ Sync stm32f469-disco DT with Linux 6.5 _ rework ltdc node for stm32f769-disco _ clk: stm32f: Fix settings for LCD_CLK _ Support display on stm32f469-disco board STM32 MPU: _ stm32mp_dfu : Fix board_get_alt_info_mtd() _ stm32mp_dfu : Simplify MTD device parsing
2023-12-15clk: nuvoton: add read only feature for clk driverJim Liu3-9/+19
Add a flag to set ahb/apb/fiu/spi clock divider as read-only The spi clock setting is related to booting flash, it is setup by early bootloader. It just protects the clock source and can't modify it in uboot. Signed-off-by: Jim Liu <JJLIU0@nuvoton.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20231114090004.3746024-1-JJLIU0@nuvoton.com
2023-12-15cmd: clk: Make soc_clk_dump staticIgor Prusov2-4/+2
After introducing dump to clk_ops there is no need to override or expose this symbol anymore. Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com> Tested-by: Patrice Chotard <patrice.chotard@foss.st.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> Link: https://lore.kernel.org/r/20231109105516.24892-9-ivprusov@sberdevices.ru
2023-12-15clk: treewide: switch to clock dump from clk_opsIgor Prusov11-128/+108
Switch to using new dump operation in clock provider drivers instead of overriding soc_clk_dump. Tested-by: Patrice Chotard <patrice.chotard@foss.st.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> Link: https://lore.kernel.org/r/20231109105516.24892-8-ivprusov@sberdevices.ru
2023-12-15cmd: clk: Use dump function from clk_opsIgor Prusov1-0/+9
Add another loop to dump additional info from clock providers that implement dump operation. Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com> Tested-by: Patrice Chotard <patrice.chotard@foss.st.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> Link: https://lore.kernel.org/r/20231109105516.24892-7-ivprusov@sberdevices.ru
2023-12-15clk: Add dump operation to clk_opsIgor Prusov1-0/+13
This adds dump function to struct clk_ops which should replace soc_clk_dump. It allows clock drivers to provide custom dump implementation without overriding generic CCF dump function. Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com> Tested-by: Patrice Chotard <patrice.chotard@foss.st.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> [ Fixed parameter name in documentation ] Signed-off-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20231109105516.24892-6-ivprusov@sberdevices.ru
2023-12-15clk: amlogic: Move driver and ops structsIgor Prusov1-17/+17
Move driver and ops structs to avoid forward declaration after switching to dump in clk_ops. Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org> Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> Link: https://lore.kernel.org/r/20231109105516.24892-5-ivprusov@sberdevices.ru
2023-12-15clk: k210: Move soc_clk_dump functionIgor Prusov1-46/+46
Move clock dump function to avoid forward declaration after switching to dump in clk_ops. Reviewed-by: Sean Anderson <seanga2@gmail.com> Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> Link: https://lore.kernel.org/r/20231109105516.24892-4-ivprusov@sberdevices.ru
2023-12-15clk: ast2600: Move soc_clk_dump functionIgor Prusov1-35/+35
Move clock dump function to avoid forward declaration after switching to dump in clk_ops. Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> Link: https://lore.kernel.org/r/20231109105516.24892-3-ivprusov@sberdevices.ru
2023-12-15clk: zynq: Move soc_clk_dump to Zynq clock driverIgor Prusov2-57/+58
Move clock dump function in preparation for switching to dump function in clk_ops. Acked-by: Michal Simek <michal.simek@amd.com> Signed-off-by: Igor Prusov <ivprusov@sberdevices.ru> Link: https://lore.kernel.org/r/20231109105516.24892-2-ivprusov@sberdevices.ru
2023-12-15dm: test: clk: Add test for ccf clk_set_rate()Igor Prusov1-0/+9
Add a simple test case which sets clock rate to its current value. Signed-off-by: Igor Prusov <ivprusov@salutedevices.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20231205232334.2931-3-ivprusov@salutedevices.com
2023-12-15clk: Check that composite clock's div has set_rate()Igor Prusov1-1/+1
It's possible for composite clocks to have a divider that does not implement set_rate() operation. For example, sandbox_clk_composite() registers composite clock with a divider that only has get_rate(). Currently clk_composite_set_rate() only checks thate rate_ops are present, so for sandbox it will cause NULL dereference during clk_set_rate(). This patch adds rate_ops->set_rate check tp clk_composite_set_rate(). Signed-off-by: Igor Prusov <ivprusov@salutedevices.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20231205232334.2931-2-ivprusov@salutedevices.com
2023-12-15clk: get correct ops for clk_enable() and clk_disable()Yang Xiwen1-0/+2
assign clk_dev_ops(clkp->dev) to ops to ensure correct clk operations are called on clocks. This fixes the incorrect enable_count issue as described in [1]. [1]: https://lore.kernel.org/all/SEZPR06MB695927A6DEEEF8489A06897396A7A@SEZPR06MB6959.apcprd06.prod.outlook.com/ Signed-off-by: Yang Xiwen <forbidden405@outlook.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20231111-enable_count-v2-2-20e3728600b5@outlook.com
2023-12-15clk: check parent_name in clk_register to avoid confusing log_error() outputYang Xiwen1-8/+10
For some gate clocks and fixed clocks without a parent, calling clk_register will print an useless error message indicating that parent is missing. Fix that by gaurding log_xxx() with an if-statement. Signed-off-by: Yang Xiwen <forbidden405@outlook.com> Suggested-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Sean Anderson <seanga2@gmail.com> Link: https://lore.kernel.org/r/20230807-clk-fix-v2-1-0b688e21fb4e@outlook.com
2023-12-15Merge patch series "bootm: Handle compressed arm64 images with bootm"Tom Rini3-23/+55
To quote the author: This little series corrects a problem I noticed with arm64 images, where the kernel is not recognised if compression is used: U-Boot> tftp image.fit Using ethernet@7d580000 device TFTP from server 192.168.4.7; our IP address is 192.168.4.147 Filename 'image.fit'. Load address: 0x1000000 Loading: ################################################## 23 MiB 20.5 MiB/s done Bytes transferred = 24118272 (1700400 hex) U-Boot> bootm ## Loading kernel from FIT Image at 01000000 ... Using 'conf-768' configuration Trying 'kernel' kernel subimage Description: Linux Type: Kernel Image (no loading done) Compression: gzip compressed Data Start: 0x01000120 Data Size: 13662338 Bytes = 13 MiB Verifying Hash Integrity ... OK Bad Linux ARM64 Image magic! With this series: U-Boot> tftp 20000000 image.fit Using ethernet@7d580000 device TFTP from server 192.168.4.7; our IP address is 192.168.4.147 Filename 'image.fit'. Load address: 0x20000000 Loading: ################################################## 23.5 MiB 20.8 MiB/s done Bytes transferred = 24642560 (1780400 hex) U-Boot> bootm 0x20000000 ## Loading kernel from FIT Image at 20000000 ... Using 'conf-768' configuration Trying 'kernel' kernel subimage Description: Linux Type: Kernel Image (no loading done) Compression: zstd compressed Data Start: 0x20000120 Data Size: 14333475 Bytes = 13.7 MiB Verifying Hash Integrity ... OK Using kernel load address 80000 ## Loading fdt from FIT Image at 20000000 ... Using 'conf-768' configuration Trying 'fdt-768' fdt subimage Description: Raspberry Pi 4 Model B Type: Flat Device Tree Compression: zstd compressed Data Start: 0x215f820c Data Size: 9137 Bytes = 8.9 KiB Architecture: AArch64 Verifying Hash Integrity ... OK Uncompressing Flat Device Tree to 3aff3010 Booting using the fdt blob at 0x3aff3010 Working FDT set to 3aff3010 Uncompressing Kernel Image (no loading done) to 80000 Moving Image from 0x80000 to 0x200000, end=2b00000 Using Device Tree in place at 000000003aff3010, end 000000003afff4c4 Working FDT set to 3aff3010 Starting kernel ... [ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd083] The problem is that the arm64 magic is checked before the image is decompressed. However this is only part of it. The kernel_noload image type doesn't work with compression, since the kernel is not loaded. So this series deals with that by using an lmb-allocated buffer for the uncompressed kernel. Another issue is that the arm64 handling is done too early, before the image is loaded. This series moves it to after loading, so that compression can be handled. A patch is included to show the kernel load-address, so it is easy to see what is going on. One annoying feature of arm64 is that the image is often copied to another address. It might be possible for U-Boot to figure that out earlier and decompress it to the right place, but perhaps not. With all of this it should be possible to boot a compressed kernel on any of the 990 arm64 boards supported by Linux, although I have only tested two.