Compare commits

...

306 Commits

Author SHA1 Message Date
Tom Rini
30b77f6aa1 CI: Sage: Drop rpi_arm64 lwIP variants
With commit 17ceb774a1 ("rpi_arm64: Enable MBEDTLS/LWIP/WGET and
WGET_HTTPS"), we can drop the tests for switching from the legacy stack
to lwIP.

Signed-off-by: Tom Rini <trini@konsulko.com>
2026-05-29 11:03:25 -06:00
Tom Rini
2f87266d56 Merge tag 'rpi-2026.07-rc3' of https://source.denx.de/u-boot/custodians/u-boot-raspberrypi
Updates for RPi for 2026.07-rc4:

- mmc: bcmstb: Fix non-removable check in bcm2712 init
- mmc: bcm2835_sdhci: Parse generic MMC device tree properties
- rpi_arm64: Enable MBEDTLS/LWIP/WGET and WGET_HTTPS
- video: arm: rpi: Add brcm,bcm2712-hdmi0 compatible
2026-05-29 08:32:13 -06:00
Jan Čermák
8de24e226d mmc: bcmstb: Fix non-removable check in bcm2712 init
sdhci_brcmstb_init_2712() reads host->mmc->host_caps to decide whether
to force card-detect for a non-removable eMMC, or to route the CD signal
for a removable SD card. At the time this function runs from
sdhci_bcmstb_probe(), however, host->mmc->host_caps is still zero, that
field is only populated later by the MMC uclass, after the driver's
probe returns. mmc_of_parse() has already filled plat->cfg.host_caps
from the device tree by this point, so check that field instead.

Without the fix, every BCM2712 SDHCI instance takes the else branch and
writes SDIO_CFG_SD_PIN_SEL = SDIO_CFG_SD_PIN_SEL_CARD (0x02), including
the non-removable eMMC on boards such as CM5 on Home Assistant Yellow.
The SDIO_CFG block lies outside the SDHCI core's reset scope, so this
value persists across SDHCI_RESET_ALL into the next stage. On the
BCM2712, having SD_PIN_SEL set to "SD" when the Linux kernel performs
its first set_power(MMC_POWER_UP) write racily prevents the SDHCI
POWER_ON bit from latching (see [1] for the whole backstory) - the
voltage bits stick but POWER_ON drops - which wedges the first CMD0 the
full 10 s software timeout. On Home Assistant Yellow this manifested as
a ~20 s eMMC probe delay on roughly one in two Linux boots when U-Boot
was the previous stage. Booting directly from the Pi firmware (no U-Boot
in between) left SD_PIN_SEL at its default and did not exhibit the race.

Reading plat->cfg.host_caps lets init_2712 see the "non-removable"
property and take the correct branch, leaving SD_PIN_SEL untouched for
the eMMC.

[1] https://github.com/home-assistant/operating-system/pull/3700#issuecomment-4430229511

Fixes: 10127cdbab ("mmc: bcmstb: Add support for bcm2712 SD controller")
Signed-off-by: Jan Čermák <sairon@sairon.cz>
Reviewed-by: Ivan T. Ivanov <iivanov@suse.de>
2026-05-28 20:55:57 +01:00
Tom Rini
987907ae4b Merge tag 'u-boot-stm32-20260526' of https://source.denx.de/u-boot/custodians/u-boot-stm
CI: https://source.denx.de/u-boot/custodians/u-boot-stm/-/pipelines/30256

- Add support dynamic A/B bank bootup for STM32MP15
- Increase SYS_MALLOC_F_LEN for stm32mp15_defconfig to fix boot with optee-4.10.0
- Enable Arm SMC watchdog for STM32MP1
- Update part number for TM32MP251/3 SoC's family
2026-05-26 08:22:05 -06:00
Patrice Chotard
0c035ff60c stm32mp2: update part number for STM32MP251/3
update part number for STM32MP251/3 for last cut revision.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2026-05-26 13:46:30 +02:00
Yann Gautier
d6ddbbb000 ARM: dts: stm32: enable SMC watchdog for STM32MP15 SCMI config
For this configuration, the watchdog (iwdg1) is secured and managed by
OP-TEE. Add an watchdog node with arm,smc-wdt compatible, and disable
iwdg2 node which is then no more used.

Signed-off-by: Yann Gautier <yann.gautier@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-05-26 13:46:30 +02:00
Yann Gautier
a3a09d28d5 configs: stm32mp13: activate watchdog
No watchdog was enabled for STM32MP13 platform. Add the required flags to
support it. As done for STM32MP15 (in SCMI config) and STM32MP2x, we use
the Arm SMC watchdog. The required nodes were already present in Linux
imported DT files (stm32mp13.dtsi & stm32mp135f-dk.dts).
To enable this SMC watchdog on other platforms based on STM32MP13, check
that both the following flags are enabled in the dedicated config file:
CONFIG_WDT=y
CONFIG_WDT_ARM_SMC=y
And that there is a node in Linux board DT that enables the feature, as
it is done in stm32mp135f-dk.dts:
&arm_wdt {
	timeout-sec = <32>;
	status = "okay";
};

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Signed-off-by: Yann Gautier <yann.gautier@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-05-26 13:46:30 +02:00
Lionel Debieve
5b2e264a77 configs: stm32mp15: enable WDT_ARM_SMC driver
Enable the arm watchdog over SMC driver. This allows using a secure
watchdog, based on IWDG1 peripheral and managed by OP-TEE.
The driver will be probed if a watchdog node with "arm,smc-wdt"
compatible is enabled.

Signed-off-by: Lionel Debieve <lionel.debieve@foss.st.com>
Signed-off-by: Yann Gautier <yann.gautier@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-05-26 13:46:30 +02:00
Patrice Chotard
70456905ec configs: stm32mp15: Increase SYS_MALLOC_F_LEN
Using stm32mp15_defconfig with stm32mp157c-dk2-scmi.dtsi device tree
with optee-4.10.0, we got:

U-Boot 2026.07-rc2-00052-g215496fec59b (May 18 2026 - 15:05:34 +0200)

CPU: STM32MP157CAC Rev.B
Model: STMicroelectronics STM32MP157C-DK2 SCMI Discovery Board
Board: stm32mp1 in trusted mode (st,stm32mp157c-dk2-scmi)
alloc space exhausted ptr 80060 limit 80000
optee optee: PTA_BSEC invoke failed TEE err: 0, err:fffffff4
alloc space exhausted ptr 80040 limit 80000
alloc space exhausted ptr 80020 limit 80000
DRAM:  alloc space exhausted ptr 80040 limit 80000
RAM init failed: -12
initcall_run_f(): initcall dram_init() failed

CONFIG_SYS_MALLOC_F_LEN need to be increased to fix this issue

Reported-by: Yann Gautier <yann.gautier@foss.st.com>
Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2026-05-26 13:46:30 +02:00
Dario Binacchi
4369c6a050 board: st: factorize STM32MP FWU multi-bank support
Factorize FWU multi-bank support code common to STM32MP1 and
STM32MP2 platforms into a dedicated shared source file.

No functional change intended.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-05-26 13:46:30 +02:00
Dario Binacchi
560d8f3270 board: st: stm32mp15: support dynamic A/B bank bootup
Following commit 4300f9f4c5 ("board: st: stm32mp25: support dynamic
A/B bank bootup"), this patch enables automatic detection of the active
A/B bank on STM32MP15 platforms by retrieving partition GUIDs from FWU
metadata.

This ensures the system correctly identifies the bootable partitions
even in multi-bank scenarios, falling back to a standard bootable flag
scan if the UUIDs are missing.

To enable A/B bank bootup on STM32MP15 boards, add the following Kconfig
options to the  stm32mp15[_basic]_defconfig:

 CONFIG_FWU_MULTI_BANK_UPDATE=y
 CONFIG_FWU_MDATA=y
 CONFIG_FWU_NUM_BANKS=2
 CONFIG_FWU_NUM_IMAGES_PER_BANK=3
 CONFIG_CMD_FWU_METADATA=y
 CONFIG_FWU_MDATA_V2=y

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-05-26 13:46:30 +02:00
Liel Harel
29c7796a71 mmc: bcm2835_sdhci: Parse generic MMC device tree properties
The bcm2835 SDHCI driver sets up the MMC host configuration via
sdhci_setup_cfg(), but does not parse generic MMC device tree
properties.

As a result, properties such as bus-width are ignored. On Raspberry Pi
Compute Module 4, the eMMC node describes an 8-bit bus, but U-Boot
initialized the device as 4-bit.

Call mmc_of_parse() before sdhci_setup_cfg() so that generic MMC
properties are folded into the host configuration before the MMC core
selects the bus width.

Before this change, mmc info reported:

    Bus Speed: 52000000
    Bus Width: 4-bit

After this change, mmc info reports:

    Bus Speed: 52000000
    Bus Width: 8-bit

Tested on Raspberry Pi Compute Module 4 with onboard eMMC.

Signed-off-by: Liel Harel <liel.harel@gmail.com>
Reviewed-by: Peter Robinson <pbrobinson@gmail.com>
Tested-by: Peter Robinson <pbrobinson@gmail.com> # on the CM4 as well
2026-05-26 12:11:50 +01:00
Peter Robinson
17ceb774a1 rpi_arm64: Enable MBEDTLS/LWIP/WGET and WGET_HTTPS
Enable LWIP and HTTPS on the Raspberry Pi arm64 platform to be able to
use it in the boot process.

Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
Reviewed-by: Matthias Brugger <mbrugger@suse.com>
2026-05-26 12:11:50 +01:00
Peter Robinson
812aca5791 video: arm: rpi: Add brcm,bcm2712-hdmi0 compatible
The 'brcm,bcm2712-hdmi0' compatible string is used on RPi5.
There appears to be no change that impacts early boot output
on the display controller so add the RPi5 compatible string.

Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
Reviewed-by: Matthias Brugger <mbrugger@suse.com>
2026-05-26 12:11:50 +01:00
Tom Rini
76d62273bc Prepare v2026.07-rc3
Signed-off-by: Tom Rini <trini@konsulko.com>
2026-05-25 11:05:37 -06:00
Wadim Egorov
a208934801 Makefile: binman: Search board directory before srctree
A file like rm-cfg.yaml accidentally left in the source tree root
shadows the board-specific copy. binman builds the wrong YAML, the
resulting rm-cfg.bin may match a different SoC, and we end up with
the following error:

  k3_system_controller sysctrler: k3_sysctrler_start:
      Boot Notification response failed. ret = -110

Move the board directory ahead of the srctree root so that the
most-specific match wins.

Signed-off-by: Wadim Egorov <w.egorov@phytec.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-25 09:48:35 -06:00
Tom Rini
97208cb762 Merge tag 'xilinx-for-v2026.07-rc3' of https://source.denx.de/u-boot/custodians/u-boot-microblaze
AMD/Xilinx/FPGA changes for v2026.07-rc3

versal/fpga:
- Fix unaligned buffer handling

versal2:
- Fix buffer overflow in SOC name array
2026-05-25 09:43:44 -06:00
Tom Rini
ba932756ca configs: Resync with savedefconfig
Resync all defconfig files using qconfig.py

Signed-off-by: Tom Rini <trini@konsulko.com>
2026-05-25 09:37:02 -06:00
Tom Rini
7c419d4b57 global: Update URL for U-Boot project
Our official domain is now u-boot-project.org, so update all in-tree
references to use the correct domain.

Reviewed-by: Tony Dinh <mibodhi@gmail.com>
Reviewed-by: Peter Robinson <pbrobinson@gmail.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
2026-05-25 09:30:47 -06:00
Tom Rini
e875c10c6f Merge patch series "Fix speculative access to firewalled regions on AM62 SoCs"
Anshul Dalal <anshuld@ti.com> says:

This patch series fixes firewall exceptions observed on AM62 family of
devices due to speculative accesses made by the A53 core to secure DDR
regions.

Link: https://lore.kernel.org/r/20260520-am62_firewall_exception_fix-v3-0-9ca3dc40aea4@ti.com
2026-05-25 09:29:54 -06:00
Anshul Dalal
37e6b640ef mach-k3: enable mmu after reserved memory is unmapped
Currently the sequence to enable caches for the A53/A72 core on K3
devices looks as follows:

 1. Map entire DDR banks
 2. Setup page tables (done by mmu_setup)
 3. Enable MMU
 4. Unmap reserved-memory regions
 5. Enable caches

However there is a brief period of execution between #3 and #4 where the
core can issue speculative accesses to the entire DDR space (including
the reserved-memory regions) despite the caches being disabled.

A firewall exception is triggered whenever such speculative access is
made to secure DDR region of TFA or OP-TEE. This patch fixes the issue
by re-ordering the sequence as follows:

 1. Map entire DDR banks
 2. Setup page tables
 3. Unmap reserved-memory regions
 4. Enable MMU
 5. Enable caches

Fixes: f1c694b8fd ("mach-k3: map all banks using mem_map_from_dram_banks")
Reported-by: Suhaas Joshi <s-joshi@ti.com>
Signed-off-by: Anshul Dalal <anshuld@ti.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2026-05-25 09:29:50 -06:00
Anshul Dalal
b53128d528 arm: armv8: mmu: move mmu enablement out of mmu_setup
Currently mmu_setup for ARMv8 performs two functions, first it sets up
the page tables based the memory map provided by the board and then it
enables the MMU.

However for some platforms runtime fixes to the generated page tables
are required before the MMU can be enabled, such as K3 family of SoCs.

Therefore this patch moves the enablement of the MMU out of mmu_setup
and to a standalone mmu_enable function to give more granular control to
the platforms.

Note that no functional changes are intended from this patch.

Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Anshul Dalal <anshuld@ti.com>
2026-05-25 09:29:50 -06:00
Moteen Shah
7e11adf054 am57xx: restore bootm_size for ARMv7 HighMem constraint
babae80169 removed bootm_size from ti_common.env to allow K3 boards
to process images larger than 256MB, but preserved it in
ti_armv7_keystone2.env for ARMv7 Keystone2 boards. AM57xx (also ARMv7)
was not covered by that preservation.

Without bootm_size, env_get_bootm_size() falls back to gd->ram_size,
causing initrd_high to be computed as the top of all RAM. On ARM32
boards with more RAM than the DMA zone (e.g. AM572x IDK with 2GiB),
this places the ramdisk above 0xafe00000 (HighMem), which is not
directly accessible by the kernel after MMU setup, causing a silent
crash.

With bootm_size=0x10000000, initrd_high is constrained to
0x80000000 + 0x10000000 = 0x90000000, keeping the ramdisk in the
DMA zone and allowing the kernel to access it correctly.

Fixes: babae80169 ("include: env: ti_common: remove bootm_size")

Reviewed-by: Neha Malcom Francis <n-francis@ti.com>
Signed-off-by: Moteen Shah <m-shah@ti.com>
2026-05-25 09:29:30 -06:00
Francois Berder
8a5989acc6 arm64: versal2: Fix buffer overflow in soc_name_decode
The size of name buffer was not computed correctly.
The suffix format is "--rel.-el" (9 chars instead of 6),
and the longest platform name is "emu-mmd" (7 chars instead of 4).
Fix comment and name size.

Fixes: 40f5046c22 ("arm64: versal2: Add support for AMD Versal Gen 2")
Signed-off-by: Francois Berder <fberder@outlook.fr>
Signed-off-by: Michal Simek <michal.simek@amd.com>
Link: https://lore.kernel.org/r/BESP194MB280513B376D54A815F3FD507DA0E2@BESP194MB2805.EURP194.PROD.OUTLOOK.COM
2026-05-25 15:14:05 +02:00
Pranav Tilak
9793931f36 fpga: versalpl: Fix unaligned buffer handling
When fpga load is called with a misaligned buffer address, the
versal_align_dma_buffer() function shifts the pointer forward to the
next aligned boundary and uses memcpy() to copy the data. Since the
destination is ahead of the source and the regions overlap, memcpy()
produces undefined behavior; in practice U-Boot's generic memcpy()
copies forward, repeating the first ARCH_DMA_MINALIGN-aligned chunk
throughout the buffer.

Replace memcpy() with memmove() which correctly handles overlapping
regions by copying backwards when the destination is ahead of the
source.

Fixes: 26e054c943 ("arm64: versal: fpga: Add PL bit stream load support")
Signed-off-by: Pranav Tilak <pranav.vinaytilak@amd.com>
Signed-off-by: Michal Simek <michal.simek@amd.com>
Link: https://lore.kernel.org/r/20260507113359.3665220-1-pranav.vinaytilak@amd.com
2026-05-25 15:14:05 +02:00
Tom Rini
987c93fc68 Merge branch 'master' of https://source.denx.de/u-boot/custodians/u-boot-sh
This is Renesas R-Car X5H support for U-Boot on its RSIP Cortex-M33 core
in addition to already support U-Boot on Cortex-A720AE core. The first
two patches also switch X5H to OF_UPSTREAM.
2026-05-22 13:30:42 -06:00
Marek Vasut
9d47a5a4d5 arm: renesas: Add Renesas R-Car R8A78000 X5H Cortex-M33 RSIP port
Add support for building U-Boot for Cortex-M33 RSIP core in Renesas
R-Car Gen5 R8A78000 X5H SoC. The main goal is to start U-Boot on the
Cortex-M33 RSIP core, which initializes the hardware and then starts
the Cortex-M33 SCP and Cortex-A720 cores which run the SCP firmware
and applications software respectively. The SCP is responsible for
platform resource management, and is used to start other CPU cores.

The Cortex-M33 build contains its own r8a78000_ironhide_cm33_defconfig
which configures the build for aarch32 instruction set compatible with
the ARMv8M core. The build also uses -cm33 DT and -u-boot.dtsi which
are derived from their non-CM33 counterparts, and add CM33 specifics.

The arch/arm/mach-renesas/u-boot-rsip.lds is derived from generic
arch/arm/cpu/u-boot.lds with adjustments to cater to the RSIP core,
those are entrypoint before vectors, __data_start/__data_end symbols
for data-only relocation, and placement of BSS into read-write SRAM
area.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
3b2ce3743c arm: renesas: Generate u-boot-elf.shdr for R-Car Gen5 RSIP
Add target to generate u-boot-elf.shdr for R-Car Gen5 Cortex-M33
RSIP core. The resulting .shdr SREC file can be written into the
HF at offset 0.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
3bcee350f0 arm: renesas: Generate u-boot-elf.scif for R-Car Gen5 RSIP
Add target to generate u-boot-elf.scif for R-Car Gen5 Cortex-M33
RSIP core. The resulting .scif SREC file can be loaded using the
SCIF loader to start U-Boot on the RSIP core.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
5fa536f698 arm64: dts: renesas: Update reset IDs on R-Car Gen5 R8A78000 X5H
The current DT reset ID encoding in R-Car Gen5 R8A78000 X5H U-Boot DTs
is inherited from downstream BSP. New reset bindings for this SoC are
now submitted and under review [1]. Replace the DT reset IDs with the
ones used in the new bindings.

[1] https://lore.kernel.org/all/053c312d07445517d8f9c84bfe3cc8fb72d4cd9a.1776793163.git.geert+renesas@glider.be/

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
3681df4f34 arm64: dts: renesas: Switch to remap drivers on R-Car Gen5 R8A78000 X5H
Point every direct user of SCMI clock protocol at CPG node instead
of SCMI clock protocol node. Point every direct user of SCMI reset
and power domain protocol at a matching newly introduced MDLC node
instead of the SCMI reset and power domain protocol nodes.

This allows the CPG and MDLC remap drivers bound to CPG node and MDLC
nodes to remap between DT clock, reset and power domain IDs and SCMI
clock, reset and power domain IDs. This makes U-Boot on R-Car X5H
compatible with multiple SCP firmware versions. Currently supported
versions of SCP firmware are 4.28, 4.31 and 4.32.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
2d0ec0891b arm64: renesas: Select R-Car Gen5 R8A78000 X5H MDLC power domain and reset driver
Select the R8A78000 power domain and reset driver on R-Car Gen5 X5H
SoC by default. The power domain and reset driver is used to remap
DT power domain and reset IDs to SCMI power domain and reset IDs,
which is necessary to support multiple SCP firmware versions with
varying SCMI clock IDs across versions.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
53297db126 power: domain: Add Renesas R-Car R8A78000 X5H MDLC power domain and reset driver
Add Renesas R-Car R8A78000 X5H MDLC power domain and reset driver,
which serves as a remap driver between DT power domain and reset IDs
and SCMI power domain and reset IDs in case U-Boot runs on Cortex-A,
and as a direct hardware access driver for RSIP.

The R-Car X5H SCP firmware uses different SCMI power domain and
reset IDs in different versions of the SCP firmware, which makes
this remapping necessary. The SCMI base protocol version is updated
for each new SCP firmware version, it is therefore possible to
determine which SCP firmware version is running on the platform
from the base protocol and then determine which remapping table to
use for DT power domain and reset ID to SCMI power domain and reset
ID remapping.

Currently supported versions are SCP 4.28, 4.31, 4.32 .

The DT power domain and reset ID to SCMI power domain and reset ID
remap and call mechanism is simple. Unlike SCMI clock protocol driver,
the SCMI reset and power domain protocol drivers register only a single
device. This driver looks up that single device, obtains its reset or
power domain ops, sets up struct reset_ctl or struct power_domain with
remapped SCMI ID, and invokes operations directly on the device.

In case of RSIP, all power domains are already enabled by BootROM or
early SoC initialization code, the driver therefore only acts as a
stub for the power domain part. The reset part operates as a direct
hardware access reset driver.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
567a4cdd14 arm64: renesas: Select R-Car Gen5 R8A78000 X5H CPG clock driver
Select the R8A78000 clock driver on R-Car Gen5 X5H SoC by default.
The clock driver is used to remap DT clock IDs to SCMI clock IDs,
which is necessary to support multiple SCP firmware versions with
varying SCMI clock IDs across versions.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
24039ffefb clk: renesas: Add Renesas R-Car R8A78000 X5H CPG clock driver
Add Renesas R-Car R8A78000 X5H CPG clock driver, which serves as a
remap driver between DT clock IDs and SCMI clock IDs in case U-Boot
runs on the Cortex-A, and as a trivial clock driver for RSIP.

The R-Car X5H SCP firmware uses different SCMI clock IDs in different
versions of the SCP firmware, which makes this remapping necessary.
The SCMI base protocol version is updated for each new SCP firmware
version, it is therefore possible to determine which SCP firmware
version is running on the platform from the base protocol and then
determine which remapping table to use for DT clock ID to SCMI clock
ID remapping.

Currently supported versions are SCP 4.28, 4.31, 4.32 .

The DT clock ID to SCMI clock ID remap and call mechanism is a bit
complex. The driver looks up the SCMI clock protocol device on probe
and stores pointer to it in private data. On each clock request which
has to be remapped, the device sequence ID of this SCMI clock protocol
device is incremented by the remapped SCMI clock ID + 1 and used to
look up matching clock device by sequence number. If the device is
found, it is converted to clock, which can be used in regular clock
operations. This look up has to be done because the SCMI clock driver
registers a subdevice for each clock, and this look up is the only way
to find the correct SCMI clock subdevice. Since the SCMI device and
the clock subdevices are registered in the same function, we can depend
on the device sequence numbers to be monotonically incrementing, with
SCMI clock protocol device being sequence number N, the first SCMI
clock subdevice being sequence number N+1 and so on.

In case of RSIP, all clocks are already enabled by BootROM or early
SoC initialization code, the driver therefore only acts as a stub.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
3e24519d6f arm64: renesas: Select HSCIF for DEBUG UART on R-Car Gen5 R8A78000 X5H
The R-Car Gen5 R8A78000 X5H uses HSCIF as default serial console
interface. Select CFG_HSCIF to make debug UART code also configure
serial console interface as HSCIF instead of SCIF in case the
CONFIG_DEBUG_UART would be enabled.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
9692469b18 arm64: dts: renesas: Use SCP_CLOCK_ID_CLK_S0D6_PERE_MAIN on R-Car X5H
Use macro SCP_CLOCK_ID_CLK_S0D6_PERE_MAIN for SCMI clock 1691
instead of hardcoding the number in DT. No functional change.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Marek Vasut
d77f8443c7 arm64: dts: renesas: Switch to upstream DT on Renesas R-Car X5H R8A78000
Enable OF_UPSTREAM to use upstream Linux kernel DT source as a base
for U-Boot control DT. Retain currently present parts of the DT which
are not yet part of upstream Linux kernel DT in -u-boot.dtsi files
until they get replaced by upstream equivalents. Add renesas/ prefix
to the DEFAULT_DEVICE_TREE as part of the switch.

Unused i2c2..i2c8 nodes have been removed, and will become available
once upstream Linux kernel DT adds those nodes.

The DRAM_RSV_SIZE has been updated to cover first 518 MiB of DRAM,
which are reserved for firmware and other use.

Note that all DT parts in -u-boot.dtsi are not considered stable DT
bindings and may change before they land in Linux kernel and become
stable DT ABI.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-21 21:48:05 +02:00
Tom Rini
744cf5d4e3 Merge tag 'u-boot-dfu-20260521' of https://source.denx.de/u-boot/custodians/u-boot-dfu
u-boot-dfu-20260521

CI: https://source.denx.de/u-boot/custodians/u-boot-dfu/-/pipelines/30195

Usb Gadget:
* f_acm: Fix memory leak in acm_add()
* atmel: Fix gadget support on bus reset
2026-05-21 10:26:29 -06:00
Tom Rini
46b29a7d12 Merge tag 'u-boot-nvme-fixes-20260521' of https://source.denx.de/u-boot/custodians/u-boot-ufs
- Add myself as Maintainer of NVMe
- fix command ID wraparound handling
- apple: Check memalign return value
- Staticize and constify driver ops
- Fix PRP list pointer arithmetic for chained transfers
2026-05-21 08:16:56 -06:00
Zixun LI
7f34bb50a5 usb: gadget: atmel: do not disable endpoints in reset_all_endpoints()
Endpoints should not be disabled on bus reset inside UDC driver,
otherwise a race condition will happen between gadget driver. Gadget
driver will free the requests and disable endpoints in disconnect ops.

Also remove outdated comment about it in usba_ep_disable().

Signed-off-by: Zixun LI <admin@hifiphile.com>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
Fixes: 59310d1ecb ("usb: gadget: introduce 'enabled' flag in struct usb_ep")
Link: https://patch.msgid.link/20260515-udc_ep-v2-1-cd335b4e62e4@hifiphile.com
[mkorpershoek: removed empty newline between Fixes: and sob]
Signed-off-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
2026-05-20 12:09:29 +02:00
Prashant Kamble
4f51050598 nvme: Fix PRP list pointer arithmetic for chained transfers
The PRP setup code advances prp_pool using u64 pointer
arithmetic:

        prp_pool += page_size;

This increments the pointer by page_size * sizeof(u64)
bytes instead of page_size bytes, resulting in invalid
PRP list addresses when multiple PRP list pages are
required.

The issue becomes visible for large transfers, typically
above 2 MiB when MDTS > 9.

Fix it by using byte-wise pointer arithmetic when
advancing to the next PRP list page.

Signed-off-by: Prashant Kamble <prashant.kamble223@gmail.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patch.msgid.link/20260518022535.17197-1-prashant.kamble223@gmail.com
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
2026-05-20 09:51:44 +02:00
Marek Vasut
4e91d9ff33 nvme: Staticize and constify driver ops
Set the ops structure as static const. The structure is not accessible
from outside of this driver and is not going to be modified at runtime.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patch.msgid.link/20260508122128.512798-1-marek.vasut+renesas@mailbox.org
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
2026-05-20 09:44:37 +02:00
Francois Berder
63f0f19803 nvme: apple: Check memalign return value
memalign returns NULL if it fails.
This commit ensures that we handle this failure before
filling the buffer with 0s.

Signed-off-by: Francois Berder <fberder@outlook.fr>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patch.msgid.link/BESP194MB280542535B098A33C8A815EEDA3A2@BESP194MB2805.EURP194.PROD.OUTLOOK.COM
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
2026-05-20 09:44:37 +02:00
Prashant Kamble
d6eb327828 nvme: fix command ID wraparound handling
nvme_get_cmd_id() returns 0 after cmdid reaches USHRT_MAX,
but fails to reset cmdid itself. As a result, all subsequent
calls keep returning 0 indefinitely.

Reset cmdid when wraparound occurs so command IDs continue
incrementing correctly.

Signed-off-by: Prashant Kamble <prashant.kamble223@gmail.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patch.msgid.link/20260518060915.45607-1-prashant.kamble223@gmail.com
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
2026-05-20 09:44:37 +02:00
Neil Armstrong
49f8b8de4e MAINTAINERS: Add myself to the list of NVMe maintainers
Adding myself to continue Bin's work to help maintain the
NVMe support in U-boot.

Acked-by: Tom Rini <trini@konsulko.com>
Link: https://patch.msgid.link/20260519-u-boot-pci-nvme-maintainer-v1-1-363593cbbfdc@linaro.org
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
2026-05-20 09:44:37 +02:00
Tom Rini
38dbe637c9 Merge tag 'efi-2026-07-rc3' of https://source.denx.de/u-boot/custodians/u-boot-efi
Pull request efi-2026-07-rc3

CI: https://source.denx.de/u-boot/custodians/u-boot-efi/-/pipelines/30152

Documentation:

* For reset command describe when the -edl option is available and fix a
  typo.

UEFI:

* If efi_allocate_pages() is with EFI_ALLOCATE_ADDRESS fails, return
  EFI_NOT_FOUND.
* Fix HII keyboard layout pointer computation and extend HII keyboard
  layout tests.

Others:

* In reset command online help show -edl option only when enabled.
2026-05-18 09:12:11 -06:00
Tom Rini
78319e074d Merge tag 'ubi-updates-for-2026.07-rc3' of https://source.denx.de/u-boot/custodians/u-boot-ubi
UBI updates for 2026.07-rc3

Fix from Peter:
- fs: ubifs: remove dead code
  Fixes: d5888d509c ("fs: ubifs: fix bugs involving symlinks in ubifs_findfile")
  (hs. correct the commit ID)
2026-05-18 08:57:51 -06:00
Peter Collingbourne
0646ee0ed8 fs: ubifs: remove dead code
This code is dead because it appears after an infinite loop; remove it.

Fixes: d5888d509c ("fs: ubifs: fix bugs involving symlinks in ubifs_findfile")
Signed-off-by: Peter Collingbourne <peter@pcc.me.uk>
Reviewed-by: Heiko Schocher <hs@nabladev.com>

hs: corrected the commit ID
2026-05-18 09:19:56 +02:00
Vincent Stehlé
5824ed13bc efi_selftest: test hii keyboard layouts more
The HII database test for keyboard layouts register two package lists with
two keyboard layouts each, but the test verifies only the GUID of the first
keyboard layout.
This does not catch the bugs happening with the keyboard layouts after the
first one in a package.

Verify all the keyboard layout GUIDs in the unit test to prevent this.

Signed-off-by: Vincent Stehlé <vincent.stehle@arm.com>
Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>
Cc: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Cc: Tom Rini <trini@konsulko.com>
2026-05-18 08:38:16 +02:00
Vincent Stehlé
ec95a60d9d efi_loader: fix hii keyboard layout pointer computation
The EFI_HII_KEYBOARD_LAYOUT field `layout_length' is expressed in bytes,
but we add it to the `layout' pointer with (scaled) pointer arithmetic.
When adding an HII keyboard package with multiple keyboard layouts, this
results in only the first layout being added correctly; fix it.

Fixes: 8d3b77e36e ("efi: hii: add keyboard layout package support")
Signed-off-by: Vincent Stehlé <vincent.stehle@arm.com>
Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>
Cc: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Cc: Tom Rini <trini@konsulko.com>
Cc: AKASHI Takahiro <akashi.tkhro@gmail.com>
2026-05-18 08:38:16 +02:00
Quentin Schulz
e49c84f7bb doc: usage: cmd: reset: specify when the -edl option is available
The option is only available when CONFIG_SYSRESET_QCOM_PSCI is enabled,
so let's make that explicit in the boot cmd documentation.

Due to the implementation in drivers/sysreset/sysreset-uclass.c
do_reset() function, all options to the reset command are passed to all
sysreset drivers' sysreset_ops.request_arg callback (including -w) which
is only available when CONFIG_SYSRESET_CMD_RESET_ARGS=y. -w, however,
works also without this option.

Fixes: ef06c5d76f ("cmd: boot: Add '-edl' option to reset command documentation")
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-18 08:37:13 +02:00
Quentin Schulz
fe725640ec doc: usage: cmd: reset: fix typo
"Do warm WARM" doesn't mean anything, I'm assuming the intent was to say
"Do WARM reset" so reword.

Fixes: 34e452dd02 ("doc: usage: Group all shell command docs into cmd/ sub-directory")
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-18 08:37:13 +02:00
Quentin Schulz
1076feb8a3 cmd: boot: fix edl being shown when not supported
edl is implemented in the sysreset_ops.request_arg callback of the
qcom-psci sysreset driver. That callback is only called from
sysreset_request_arg() which is compiled only when
CONFIG_SYSRESET_CMD_RESET_ARGS=y.

Therefore, only show the edl option if that symbol is enabled.

It is in a separate if block because any option but -w will only be
handled when CONFIG_SYSRESET_CMD_RESET_ARGS=y as seen with the
implementation in do_reset() in drivers/sysreset/sysreset-uclass.c.

Fixes: ef06c5d76f ("cmd: boot: Add '-edl' option to reset command documentation")
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-18 08:37:13 +02:00
Harsimran Singh Tungal
d0d1c4a4f5 efi_loader: fix AllocatePages overlap status
Return EFI_NOT_FOUND for EFI_ALLOCATE_ADDRESS overlap

When efi_allocate_pages() is called with EFI_ALLOCATE_ADDRESS, UEFI
expects EFI_NOT_FOUND if the requested address range is already
allocated or unavailable. U-Boot currently returns
EFI_OUT_OF_RESOURCES when efi_update_memory_map() detects an overlap
after a successful lmb_alloc_mem(), which does not match
EFI_ALLOCATE_ADDRESS semantics.

Return EFI_NOT_FOUND for EFI_ALLOCATE_ADDRESS requests that fail due
to an overlapping EFI memory descriptor, while keeping
EFI_OUT_OF_RESOURCES for other allocation types.

The UEFI specification [1] specifies that
EFI_BOOT_SERVICES.AllocatePages must return EFI_NOT_FOUND when the
requested address range is unavailable or already allocated;
EFI_OUT_OF_RESOURCES applies to non‑address‑specific allocation
failures.

[1] https://uefi.org/specs/UEFI/2.10_A/07_Services_Boot_Services.html

Signed-off-by: Harsimran Singh Tungal <harsimransingh.tungal@arm.com>

The UEFI specification does not clearly specify the behavior.
But let's follow the EDK II precedent here.

Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-18 08:32:58 +02:00
Tom Rini
9704971031 Merge patch series "configs: airoha: an7581: defconfig fixes & improvements"
Mikhail Kshevetskiy <mikhail.kshevetskiy@iopsys.eu> says:

This patch series fixes an7581_evb_defconfig.

Link: https://lore.kernel.org/r/20260427135326.773903-1-mikhail.kshevetskiy@iopsys.eu
2026-05-15 17:08:16 -06:00
Mikhail Kshevetskiy
0fcbe38192 configs: airoha: an7581: disable ENV_IS_IN_MTD to avoid boot panic
Booting image generated with

  make an7581_evb_defconfig

will results in

  U-Boot 2026.04-00924-gfb815bd8793b (Apr 27 2026 - 15:08:30 +0300)

  CPU:   Airoha AN7581
  DRAM:  512 MiB
  Core:  35 devices, 19 uclasses, devicetree: separate
  MMC:   mmc@1fa0e000: 0
  Loading Environment from MMC... *** Warning - No block device, using default environment

  Loading Environment from MTD... *** Warning - get_mtd_device_nm() failed, using default environment

  BUG at drivers/mtd/mtdcore.c:898/__put_mtd_device()!
  BUG!
  resetting ...

This happens because no any mtd partition defined in dts/mtdparts.
Disabling of ENV_IS_IN_MTD fixes an issue.

Signed-off-by: Mikhail Kshevetskiy <mikhail.kshevetskiy@iopsys.eu>
2026-05-15 17:08:11 -06:00
Mikhail Kshevetskiy
7bb8c707b1 configs: airoha: an7581: enable position independent code
This enables U-Boot loading from any 4K aligned address.
It makes U-Boot debugging a bit simpler.

Signed-off-by: Mikhail Kshevetskiy <mikhail.kshevetskiy@iopsys.eu>
2026-05-15 17:08:11 -06:00
Mark Kettenis
215496fec5 smbios: Do not fall back on devicetree without valid mapping
The smbios_get_val_si() function may get called for a sysinfo
property for which there is no mapping to a devicetree property.
Avoid a NULL pointer dereference in this case by skipping the
read of the mapped property from the device tree.

Fixes: 83b28b55d7 ("smbios: add support for dynamic generation of Type 9 system slot tables")
Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Raymond Mao <raymondmaoca@gmail.com>
2026-05-15 08:18:11 -06:00
Tom Rini
f3af40cff9 Merge tag 'fsl-qoriq-for-2026.07-rc3' of https://source.denx.de/u-boot/custodians/u-boot-fsl-qoriq
CI: https://source.denx.de/u-boot/custodians/u-boot-fsl-qoriq/-/pipelines/30120

- Various fix/improvments for powerpc
- Correct usage of number of memory banks for nxp and ten64
- Staticize and constify scmi sandbox driver ops
2026-05-15 08:15:32 -06:00
Marek Vasut
8bd84cca34 firmware: scmi: sandbox: Staticize and constify driver ops
Set the ops structure as static const. The structure is not accessible
from outside of this driver and is not going to be modified at runtime.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:31 +08:00
Vincent Jardin
43257fa9e3 board: nxp: common: support CONFIG_FSL_USE_PCA9547_MUX
Use select_i2c_ch_pca9547() only when CONFIG_FSL_USE_PCA9547_MUX
is set, but several call in board/nxp/lx2160a/lx2160a.c invoke
it unconditionally,
or using unrelated Kconfigs (CONFIG_EMC2305, CONFIG_VID).

Compilation with LX2160A target that omits the mux therefore fails with

  error: implicit declaration of function 'select_i2c_ch_pca9547'

Add a static inline stub with -EOPNOTSUPP for the
!CONFIG_FSL_USE_PCA9547_MUX case so all cases compile cleanly.

Adapted from the convention used by include/scmi_nxp_protocols.h for
SCMI subprotocol stubs.

There is no functional change for NXP boards: all eight upstream
LX2160A defconfigs (lx2160ardb / lx2160aqds / lx2162aqds and their
secure / stmm / verified_boot variants) already set
CONFIG_FSL_USE_PCA9547_MUX=y, so the real declaration wins.

The purpose is to support new boards that do not use the PCA9547.

Signed-off-by: Vincent Jardin <vjardin@free.fr>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:31 +08:00
Vincent Jardin
7252890625 board: nxp: lx2160a: without QIXIS, MC-ENET, PCI, LTC3882
The shared LX2160A board file calls helpers that only exist when
their subsystem is enabled. Gate them on the matching CONFIG_*:
 - pci_init() under CONFIG_PCI.
 - fdt_fixup_mc_ddr() and fsl_rgmii_init() under CONFIG_FSL_MC_ENET.
 - qixis_*() and the QIXIS branch of checkboard() under
   CONFIG_FSL_QIXIS; cpu_name(buf) moves out so the non-QIXIS path
   still prints "Board: <name>".
 - EVENT_SPY_SIMPLE on init_func_vid moves inside the
   CONFIG_VOL_MONITOR_LTC3882_READ guard (was outside, dangling
   symbol when LTC3882 off).

 #if / #ifdef, not IS_ENABLED(), because the helpers are themselves
conditionally compiled.

While here, lx2160a_common.h: fix BOOT_TARGET_DEVICES_MMC
1 arg vs 2 args and gate the MMC target on CONFIG_CMD_MMC,
not CONFIG_MMC.

No functional change for NXP boards: LX2160ARDB, LX2160AQDS, or
LX2162AQDS, but mainly build clean up in order to support
other NXP lx2160a boards without those HW dependencies.

Signed-off-by: Vincent Jardin <vjardin@free.fr>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:31 +08:00
Francois Berder
12cf77821d board: ten64: Fix OOB read in ft_board_setup
base and size arrays can both contain up to total_memory_banks
elements.
This commit fixes the for loop condition to ensure that it does
not attempt to read past the end of both arrays.

Signed-off-by: Francois Berder <fberder@outlook.fr>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:31 +08:00
Francois Berder
408cab5f9d board: nxp: Fix OOB read in ft_board_setup
base and size arrays can both contain up to total_memory_banks
elements.
This commit fixes the for loop condition to ensure that it does
not attempt to read past the end of both arrays.

Signed-off-by: Francois Berder <fberder@outlook.fr>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:31 +08:00
Michael Walle
9a621ea635 p2041rdb: convert README to rst
Convert the README to reST format.

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:31 +08:00
Peng Fan
b8124202d7 p2041rdb: remove NAND defconfig
The RDB doesn't support NAND boot at all, remove the config for it.
Apparently, it was introduced by commit dd84058d24 ("kconfig: add
board Kconfig and defconfig files") which ran some scripts. Maybe that
script was wrong or the source boards.cfg was wrong. In any case, there
is no NAND flash on the RDB.

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:31 +08:00
Michael Walle
f0e57510cf p2041rdb: update README and fix typos
Nowadays, u-boot can build the pbl image itself. Refer to that image in
the documentation. Also fix some typos.

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:30 +08:00
Michael Walle
656dc03812 p2041rdb: support SDcard boot
The RCW was just supporting SPI boot. Add a second one for the SDcard
boot. While at it, use the same naming scheme as for the other NXP
boards.

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:30 +08:00
Michael Walle
4839ba9045 p2041rdb: use the upstream device tree
Switch to the upstream device tree, which already includes the UART
nodes we need for the DM.

We also need to increase malloc area before relocation otherwise you'll
get the following error and the board panics:

	DRAM:  Initializing....using SPD
	alloc space exhausted ptr 414 limit 400

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:30 +08:00
Michael Walle
e742f676e5 boards/nxp: remove empty fdt_fixup_board_enet()
Remove any empty function which is just called by the board code. There
is no need to define this function at all.

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:30 +08:00
Michael Walle
6af1851cb6 boards/nxp: remove board_eth_init()
board_eth_init() is dead code since commit e524f3a449 ("net: Remove
eth_legacy.c"). Remove it.

I'm not sure, all the shenanigans are covered by the new DM-version. The
MDIO mux and iomux controls probably are. The fman configuration
probably isn't. OTOH, nobody cared for years and the called
fm_info_set_phy_address() was also removed years ago.

This also removes fdt_fixup_board_enet() for the ls1043a and ls1046a
because it relies on the local variable "mdio_mux" being initialized by
the board_eth_init().

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:30 +08:00
Michael Walle
5a39262a4a boards: remove dead fman code
Commit cc2bf624eb ("net: fm: Remove non-DM_ETH code") removed the call
to board_ft_fman_fixup_port(). Thus remove the dead code in the board
files.

I'm not sure, all that DT shenanigans are covered by the new DM-version
of the fman code, but it seems no one complained for the past 4 years.

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:30 +08:00
Michael Walle
cae1cfe2ca spi: fsl_espi: fix read transactions
Since commit 7917c2e356 ("spi: fsl_espi: fix din offset") MTD is
basically broken because any read transaction will get wrong data. While
the commit in question will fix simple transfers (where both
SPI_XFER_BEGIN and SPI_XFER_END is set), it will break the most common
case, where opcode and address is send first and then data comes as a
second transfer.

This basically reverts commit 7917c2e356 ("spi: fsl_espi: fix din
offset") and make the fix particular for this simple case. Instead of
providing two buffers for reading and writing, just malloc one which is
used for both. This will work because the data is first written on the
SPI bus and then it will be read (and overwite the written data) into
the same buffer.

Suggested-by: Tomas Alvarez Vanoli <tomas.alvarez-vanoli@hitachienergy.com>
Fixes: 7917c2e356 ("spi: fsl_espi: fix din offset")
Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:30 +08:00
Michael Walle
09bc47cc33 caam: don't write memory at 0 on PPC
For non-secure boot environments pamu_init() isn't called but the CAAM
will still call sec_config_pamu_table() -> config_pamu() which then uses
an uninitialized ppaact variable. In fact, that variable is initialized
with 0, so the config_pamu() will happily assume the structure is there
and will operate on that memory. Call pamu_init() in the non-secure boot
case, too.

Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:29 +08:00
Michael Walle
674f35a884 powerpc: fix call to cpu_init_r
Commit 6c171f7a18 ("common: board: make initcalls static") broke the
call to cpu_init_r. That is because PPC is already defined to 1, see:

  powerpc-linux-gnu-gcc -dM -E - < /dev/null

This will conflict with the CONFIG_IS_ENABLED(PPC). Change it to
IS_ENABLED(CONFIG_PPC).

Fixes: 6c171f7a18 ("common: board: make initcalls static")
Signed-off-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-15 19:28:29 +08:00
Emanuele Ghidoli
03d70a9220 arm: dts: k3-am69-aquila: fix combined boot firmware image build
The combined boot firmware firmware-aquila-am69-gp.bin depends on
tiboot3-am69-gp-aquila.bin, which in turn requires the GP variant
of the TI system firmware blob (ti-fs-firmware-j784s4-gp.bin).

Fix the combined boot firmware image build by adding the missing binman
nodes.

Fixes: f62d4535cf ("arm: dts: k3-am69-aquila: add combined boot firmware image")
Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com>
Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Reviewed-by: Neha Malcom Francis <n-francis@ti.com>
2026-05-14 07:58:14 -06:00
Tom Rini
f020dfd9bf Merge tag 'i2c-updates-for-2026.07-rc3' of https://source.denx.de/u-boot/custodians/u-boot-i2c
updates for 2026.07-rc3

- designware_i2c: Staticize driver ops from Marek
- i2c: Remove legacy CONFIG_SYS_I2C_SOFT
-
2026-05-14 07:56:53 -06:00
Tom Rini
0c464b6cc3 i2c: Remove legacy CONFIG_SYS_I2C_SOFT
The last users of this legacy i2c stack have been removed or converted
to a modern part of the stack instead. Remove this code and references
to it.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Heiko Schocher <hs@nabladev.com>
2026-05-14 11:17:20 +02:00
Marek Vasut
5f82b15958 i2c: designware_i2c: Staticize driver ops
Set the ops structure as static. The structure is not accessible
from outside of this driver.

Reviewed-by: Heiko Schocher <hs@nabladev.com>
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-14 11:12:56 +02:00
Tom Rini
1a0fac05c3 Merge tag 'ab-master-12052026' of https://source.denx.de/u-boot/custodians/u-boot-tpm
- A single UAF fix from Kory for out fwumdata tool
2026-05-13 07:57:51 -06:00
Tom Rini
944427c3da Merge tag 'u-boot-stm32-20260512' of https://source.denx.de/u-boot/custodians/u-boot-stm
CI: https://source.denx.de/u-boot/custodians/u-boot-stm/-/pipelines/30081

- reset: stm32: Fix compilation error
- Remove remaining non-existant STM32_RESET flag
- configs: stm32mp13: Add SPI-NAND UBI boot support
- Support metadata-driven A/B boot for STM32MP25
2026-05-13 07:54:10 -06:00
Francois Berder
c8f6823442 usb: gadget: f_acm: Fix memory leak in acm_add
If udc_device_get_by_index fails, the f_acm struct was not released.
Free it before returning the error.

Signed-off-by: Francois Berder <fberder@outlook.fr>
Reviewed-by: Marek Vasut <marek.vasut+usb@mailbox.org>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
Link: https://patch.msgid.link/BESP194MB2805271AD5DBE47B322F8DC3DA3A2@BESP194MB2805.EURP194.PROD.OUTLOOK.COM
Signed-off-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
2026-05-13 13:11:07 +02:00
Christian Pötzsch
36d4c65358 virtio: fix return value check
The virtio_blk_do_single_req function returns ulong, which normally is
the processed size, but in an error case can be the actual error. Use
the special IS_ERR_VALUE macro to test for error.

Addresses-Coverity-ID: CID 645833 (DEADCODE) & CID 645834 (NO_EFFECT)
Signed-off-by: Christian Pötzsch <christian.poetzsch@kernkonzept.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-12 12:38:49 -06:00
Janne Grunau
a1a47eee67 arm: apple: Add Apple M3 (t8122) support
Apple's M3 SoC is similar to M1 and M2 but uses a different memory map.
The main difference is that RAM starts at 0x100_0000_0000 like on t600x
and t602x (M1 and M2 Pro/Max/Ultra). Otherwise IO blocks have been
rearranged.
U-boot's existing drivers are compatible with the hardware and M3 device
trees will carry "apple,t8103-*" compatible strings. Only
apple-atcphy-reset might need a new compatible due to USB4 / DisplayPort
changes the Linux driver has to deal with.

Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:11:36 -06:00
Tom Rini
bdf4d12fc2 Merge patch series "Switch Apple silicon boards to upstream device trees"
Janne Grunau <j@jannau.net> says:

The Linux device trees for Apple silicon devices cover now most of the
hardware as u-boot's internal device trees for M1 devices. Linux has in
addition device trees M2 and M1 and M2 Pro/Max/Ultra devices which were
never added in u-boot.
The most common use case for u-boot on Apple silicon devices does not
use DTBs from u-boot but passes runtime modified device trees from an
earlier boot loader (m1n1).
This change regresses support for the SPI on M1 and M1 Pro/Max notebooks
as SPI keyboard support is not in upstream Linux. This regression is in
my opinion acceptable due to the limited use of u-boot's DTBs for these
targets.

Link: https://lore.kernel.org/r/20260507-apple-dt-upstream-v2-0-35181f2b0509@jannau.net
2026-05-12 12:11:17 -06:00
Janne Grunau
5aec4e746f arm: dts: Switch Apple silicon devices to dts/upstream
The device tree on Apple silicon devices is passed from a previous
bootloader stage. The bootloader fills in dynamic information so
u-boot can not use its own device tree.
As documented in doc/board/apple/m1.rst it is possible to build boot
bundles (bootloader + device tree + gzipped u-boot binary). These are
useful for testing.
Instead of using u-boot's own device trees for M1 (t8103) devices use
upstream device trees from dts/upstream/src/arm64/apple. The u-boot
device trees have not seen updates since 2022. The upstream linux device
trees have feature parity for the M1 devices. In addition linux has
device trees for M1 Pro/Max/Ultra, M2 and M2 Pro/Max/Ultra devices.
Keep t8103-j274 as default device tree to avoid further updates.

Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:11:08 -06:00
Janne Grunau
fad7b438f0 doc: device-tree-bindings: Remove apple,pinctrl.yaml
Remove outdated apple,pinctrl.yaml. The dts/upstream contains the
current version of this binding.

Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:11:08 -06:00
Janne Grunau
4587d7180b doc: board: apple: Mention M2 and M2 Pro/Max/Ultra SoCs
These SoCs are supported since 2022/2023 but were never added to the
documentation. The devices very similar to the equivalent M1 devices.
The biggest difference is that the M2 and M2 Pro/Max based laptops no
longer use SPI for the keyboard.

Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:11:08 -06:00
Janne Grunau
0f0ff73bac arm: apple: Switch to board based text env
The main use case for u-boot on Apple silicon based devices is to
provide an EFI based bootloader for operating systems. This uses a
generic u-boot image with DTBs passed from an earlier boot loader
(m1n1). Use the generic board name "mac" for this purpose.

Signed-off-by: Janne Grunau <j@jannau.net>
2026-05-12 12:08:15 -06:00
Janne Grunau
1b5500cefe MAINTAINERS: Add Janne Grunau as reviewer for Apple M1 SoC support
I'm one of the co-maintainers of Apple silicon support in the Linux
kernel and have contributed to u-boot's Apple SoC support.

Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:08:08 -06:00
Janne Grunau
60c6065df1 MAINTAINERS: Add missing Apple M1 specific files
The files weren't added to MAINTAINERS but clearly belong to Apple
silicon (M1) support.

Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:08:08 -06:00
Janne Grunau
74471e0e18 watchdog: apple: Add "apple,t8103-wdt" compatible
After discussion with the devicetree maintainers we agreed to not extend
lists with the generic compatible "apple,wdt" anymore [1]. Use
"apple,t8103-wdt" as base compatible as it is the SoC driver and
bindings were originally written for.
The t602x (M2 Pro/Max/Ultra) devicetrees submitted in [2] use this
compatible as fallback instead of "apple,wdt".

Link: https://lore.kernel.org/asahi/12ab93b7-1fc2-4ce0-926e-c8141cfe81bf@kernel.org/ [1]
Link: https://lore.kernel.org/asahi/20250828-dt-apple-t6020-v1-0-507ba4c4b98e@jannau.net/ [2]
Signed-off-by: Janne Grunau <j@jannau.net>
Reviewed-by: Stefan Roese <stefan.roese@mailbox.org>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:08:05 -06:00
Janne Grunau
6df6f97431 spi: apple: Add "apple,t8103-spi" compatible
After discussion with the devicetree maintainers we agreed to not extend
lists with the generic compatible "apple,spi" anymore [1]. Use
"apple,t8103-spi" as base compatible as it is the SoC driver and
bindings were originally written for.
The t602x (M2 Pro/Max/Ultra) devicetrees submitted in [2] use this
compatible as fallback instead of "apple,spi".

Link: https://lore.kernel.org/asahi/12ab93b7-1fc2-4ce0-926e-c8141cfe81bf@kernel.org/ [1]
Link: https://lore.kernel.org/asahi/20250828-dt-apple-t6020-v1-0-507ba4c4b98e@jannau.net/ [2]
Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:08:01 -06:00
Janne Grunau
39117feb21 power: domain: apple: Add "apple,t8103-pmgr-pwrstate" compatible
After discussion with the devicetree maintainers we agreed to not extend
lists with the generic compatible "apple,pmgr-pwrstate" anymore [1]. Use
"apple,t8103-pmgr-pwrstate" as base compatible as it is the SoC driver
and bindings were originally written for.
The t602x (M2 Pro/Max/Ultra) devicetrees submitted in [2] use this
compatible as fallback instead of "apple,pmgr-pwrstate".

Link: https://lore.kernel.org/asahi/12ab93b7-1fc2-4ce0-926e-c8141cfe81bf@kernel.org/ [1]
Link: https://lore.kernel.org/asahi/20250828-dt-apple-t6020-v1-0-507ba4c4b98e@jannau.net/ [2]
Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:07:57 -06:00
Janne Grunau
1588f7b8a3 pinctrl: apple: Add "apple,t8103-pinctrl" compatible
After discussion with the devicetree maintainers we agreed to not extend
lists with the generic compatible "apple,pinctrl" anymore [1]. Use
"apple,t8103-pinctrl" as fallback compatible as it is the SoC driver and
bindings were originally written for.
The t602x (M2 Pro/Max/Ultra) devicetrees submitted in [2] use this
compatible as fallback instead of "apple,t8103-pinctrl".

Link: https://lore.kernel.org/asahi/12ab93b7-1fc2-4ce0-926e-c8141cfe81bf@kernel.org/ [1]
Link: https://lore.kernel.org/asahi/20250828-dt-apple-t6020-v1-0-507ba4c4b98e@jannau.net/ [2]
Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:07:54 -06:00
Janne Grunau
29080b2a99 nvme: apple: add "apple,t8103-nvme-ans2" compatible
After discussion with the devicetree maintainers we agreed to not extend
lists with the generic compatible "apple,nvme-ans2" anymore [1]. Add
"apple,t8103-nvme-ans2" as fallback compatible as this is the SoC the
driver and bindings were originally written for.
The t602x (M2 Pro/Max/Ultra) devicetrees submitted in [2] use this
compatible as fallback instead of "apple,t8103-nvme-ans2".

Link: https://lore.kernel.org/asahi/12ab93b7-1fc2-4ce0-926e-c8141cfe81bf@kernel.org/ [1]
Link: https://lore.kernel.org/asahi/20250828-dt-apple-t6020-v1-0-507ba4c4b98e@jannau.net/ [2]
Signed-off-by: Janne Grunau <j@jannau.net>
Acked-by: Mark Kettenis <kettenis@openbsd.org>
2026-05-12 12:07:49 -06:00
Ernest Van Hoecke
f62d4535cf arm: dts: k3-am69-aquila: add combined boot firmware image
Add nodes to the binman configuration to create single binaries that
combine tiboot3-am69-*-aquila.bin, tispl.bin and u-boot.img into
firmware-aquila-am69-*.bin, with the proper offsets.

These binaries can be used to flash U-Boot via a single binary of three,
as it is done now.

Signed-off-by: Ernest Van Hoecke <ernest.vanhoecke@toradex.com>
Reviewed-by: Neha Malcom Francis <n-francis@ti.com>
Acked-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-12 11:43:36 -06:00
Tze Yee Ng
b42c67188c mmc: sdhci-cadence: trigger tuning for SD HS mode on SD6HC (v6) PHY
The Cadence SD6HC (SDHCI spec v4.20+) controller uses a soft PHY whose
DLL delay characteristics vary with PVT (Process, Voltage, Temperature)
and board-level trace routing.

A static delay value programmed via device tree for SD High Speed mode is
insufficient because the optimal sampling point varies per board, SD card,
and operating conditions. Runtime calibration is required.

While the SD Physical Layer Specification does not mandate tuning for
SD HS mode (only for UHS-I SDR50/SDR104), the Cadence SD6HC PHY
requires runtime calibration of its receive data delay line to find a
valid sampling window under constrained clock conditions.

The tuning is triggered from the set_ios_post callback because at that
moment hardware has committed the new bus width, clock frequency, and speed
mode to the controller registers. This ensuring the tuning sequence runs
at the correct SD HS operating conditions.

The tuning is gated by a device tree property "cdns,sd-hs-tuning" so
that only boards requiring runtime calibration opt in. When enabled,
the driver performs a 40-tap DLL sweep using CMD19 to find the largest
consecutive passing window, then programs the midpoint into
PHY_DLL_SLAVE_CTRL_REG.

To enable on a board, add to the MMC node in device tree:

    &mmc {
        cdns,sd-hs-tuning;
    };

Signed-off-by: Tze Yee Ng <tze.yee.ng@altera.com>
2026-05-12 11:42:41 -06:00
Patrice Chotard
612256838a reset: stm32: Fix compilation error
The following compilation error occurs when environment variable
KBUILD_OUTPUT is not set :

drivers/reset/stm32/stm32-reset-mp21.c:8:10: fatal error: stm32-reset-core.h: No such file or directory
    8 | #include <stm32-reset-core.h>
      |          ^~~~~~~~~~~~~~~~~~~~

As stm32-reset-core.h is located in same directory than stm32-reset-mp21.c,
we should use #include "stm32-reset-core.h".

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Raphaël Gallais-Pou <rgallaispou@gmail.com>
2026-05-12 15:52:53 +02:00
Patrice Chotard
43ba37376b arm/mach-stm32: Remove remaining non-existent STM32_RESET
Symbol CONFIG_STM32_RESET does not exist.
Don't select it.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de>
2026-05-12 15:52:36 +02:00
Dario Binacchi
4300f9f4c5 board: st: stm32mp25: support dynamic A/B bank bootup
Enable automatic detection of the active A/B bank by retrieving
partition GUIDs from FWU metadata.

This ensures the system correctly identifies the bootable partitions
even in multi-bank scenarios, falling back to a standard bootable flag
scan if the UUIDs are missing.

To enable A/B bank bootup on stm32mp25 boards, add the following Kconfig
options to the stm32mp25_defconfig:

 CONFIG_FWU_MULTI_BANK_UPDATE=y
 CONFIG_FWU_MDATA=y
 CONFIG_FWU_NUM_BANKS=2
 CONFIG_FWU_NUM_IMAGES_PER_BANK=3
 CONFIG_CMD_FWU_METADATA=y
 CONFIG_FWU_MDATA_V2=y

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-05-12 15:52:01 +02:00
Dario Binacchi
63fc73ff31 test: dm: fwu_mdata: add test for fwu_mdata_get_image_guid
Add a new unit test for the fwu_mdata_get_image_guid() function.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-12 15:52:01 +02:00
Dario Binacchi
97cdde6dfa fwu: add helper to get image GUID by type and bank index
Introduce fwu_mdata_get_image_guid() to retrieve a specific image GUID
from the FWU metadata based on the bank index and image type GUID.

This allows identifying the correct partition in multi-bank (A/B)
scenarios, ensuring the correct image is targeted depending on the
current bank.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2026-05-12 15:52:01 +02:00
Dario Binacchi
2dc71c48bf test: cmd: part: add UUID lookup tests
Extend the 'part' command unit tests to include partition lookup via
UUID.

This ensures that the 'number', 'start', and 'size' subcommands
consistently handle UUIDs as partition identifiers, maintaining
parity with the name-based lookup functionality.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-12 15:52:01 +02:00
Dario Binacchi
703f8c313d cmd: part: support lookup by UUID
The 'part' command currently allows looking up a partition only by its
number or name.

Extend the 'number', 'start', and 'size' subcommands to support looking
up the partition via its UUID. Unlike names, UUIDs guarantee unique
partition identification, avoiding ambiguity.

The logic is updated to check if the provided string is a valid UUID
before falling back to a name-based search. The help strings for these
subcommands are updated accordingly.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-12 15:52:01 +02:00
Dario Binacchi
a392450189 test: cmd: add unit tests for part command
Add unit tests for the 'part' command, specifically for the 'number',
'start', and 'size' subcommands.

These tests establish a baseline for the current partition lookup
functionality by name. This foundation will be used by subsequent
patches to extend the command, ensuring consistent behavior as new
features are introduced.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-12 15:52:01 +02:00
Dario Binacchi
27a928553a test: dm: part: add test for part_get_info_by_uuid
Add a new unit test for the part_get_info_by_uuid() function.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-12 15:52:01 +02:00
Dario Binacchi
2a55938b42 lib: uuid: add partition type GUID for extended bootloader
The Extended Boot Loader Partition (XBOOTLDR) is a standard defined by
the Discoverable Partitions Specification (DPS) to host boot loader
resources outside of the EFI System Partition ([1], [2]).

Defining this GUID (bc13c2ff-59e6-4262-a352-b275fd6f7172) allows U-Boot
to correctly identify and label these partitions using the "xbootldr"
shorthand.

[1] https://uapi-group.org/specifications/specs/discoverable_partitions_specification/#extended-boot-loader-partition:~:text=UEFI%20Specification.-,Extended%20Boot%20Loader%20Partition,-bc13c2ff%2D59e6%2D4262
[2] https://uapi-group.org/specifications/specs/boot_loader_specification/
Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-12 15:52:01 +02:00
Austin Shirley
467dc9a44b configs: stm32mp13: add SPI-NAND UBI boot support
The STM32MP13 default environment only handles MMC and serial/USB boot.
When TF-A reports BOOT_FLASH_SPINAND the boot_device variable is set to
'spi-nand' but bootcmd_stm32mp never redirects boot_targets to ubifs0,
so distro_bootcmd falls through to MMC/USB.

This change mirrors the STM32MP15 logic:
 - Add a BOOT_TARGET_UBIFS entry to BOOT_TARGET_DEVICES so that
   bootcmd_ubifs0 is defined (ubi part UBI; ubifsmount ubi0:boot).
 - Add the 'spi-nand' / 'nand' clause to bootcmd_stm32mp so that
   boot_targets is set to 'ubifs0' when booting from NAND.

Signed-off-by: Austin Shirley <austin@deadband.dev>
Cc: Patrick Delaunay <patrick.delaunay@foss.st.com>
Cc: Patrice Chotard <patrice.chotard@foss.st.com>
Cc: Tom Rini <trini@konsulko.com>
Cc: uboot-stm32@st-md-mailman.stormreply.com
2026-05-12 15:50:47 +02:00
Kory Maincent
d5ea30b233 tools: fwumdata: Fix use-after-free in parse_config()
In parse_config(), devname is dynamically allocated by sscanf().
When sscanf() fails to fill enough fields (rc < 3), devname is freed and
the loop continues to the next line. However, if the next call to sscanf()
fails to match (rc == 0), devname is not written and still holds the stale
freed pointer. The subsequent free(devname) then operates on
already-freed memory.

Fix this by resetting devname to NULL before each sscanf() call, so
that a non-matching call leaves a NULL pointer and the subsequent
free() becomes a harmless no-op.

Reported-by: Coverity Scan
Link: https://lists.denx.de/pipermail/u-boot/2026-April/614161.html
Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2026-05-12 09:31:51 +03:00
Tom Rini
5732bd0f45 Prepare v2026.07-rc2
Signed-off-by: Tom Rini <trini@konsulko.com>
2026-05-11 16:05:08 -06:00
Tom Rini
07316f1fe7 Merge tag 'dm-pull-11may26b' of git://git.denx.de/u-boot-dm
CI: https://source.denx.de/u-boot/custodians/u-boot-dm/-/pipelines/30065

- Add missing bintool docstrings
- Minor patman fix
- Fix small ACPI bug
2026-05-11 14:44:30 -06:00
Tom Rini
1d8526fa7c Merge patch series "j721s2: j784s4: Add workaround for errata i2437"
Udit Kumar <u-kumar1@ti.com> says:

Add a necessary hardware errata workaround for J721S2 and J784S4.

Bootlogs
https://gist.github.com/uditkumarti/da2a489a78d3241ecd2791c9df1c1317

Link: https://lore.kernel.org/r/20260415152152.3048491-1-u-kumar1@ti.com
2026-05-11 12:33:52 -06:00
Neha Malcom Francis
c5c3b27873 arch: mach-k3: j784s4_init: Add workaround for errata i2437
Add the workaround proposed for J784S4 errata i2437 (link) for SE
clock-gating turning off too early. Without this, a hardware bug present
in C7120 leads to C7120 CPU hanging.

Link: https://www.ti.com/lit/pdf/sprz536
Signed-off-by: Neha Malcom Francis <n-francis@ti.com>
Signed-off-by: Udit Kumar <u-kumar1@ti.com>
2026-05-11 12:32:00 -06:00
Neha Malcom Francis
d99cb46a2c arch: mach-k3: j721s2_init: Add workaround for errata i2437
Add the workaround proposed for J721S2 errata i2437 (link) for SE
clock-gating turning off too early. Without this, a hardware bug present
in C7120 leads to C7120 CPU hanging.

Link: https://www.ti.com/lit/pdf/sprz530
Signed-off-by: Neha Malcom Francis <n-francis@ti.com>
Signed-off-by: Udit Kumar <u-kumar1@ti.com>
2026-05-11 12:32:00 -06:00
Udit Kumar
ad681c8164 arm: mach-k3: arm: mach-k3: Add writel_verify macro for register write verification
Add a helper macro to write and verify a 32-bit value to a memory-mapped
register. This is essential for hardware errata workarounds that require
confirmation that register writes have taken effect before proceeding with
initialization.

Signed-off-by: Udit Kumar <u-kumar1@ti.com>
2026-05-11 12:32:00 -06:00
Tom Rini
02ef1859b4 configs: Resync with savedefconfig
Resync all defconfig files using qconfig.py

Signed-off-by: Tom Rini <trini@konsulko.com>
2026-05-11 12:26:03 -06:00
Peter Collingbourne
d5888d509c fs: ubifs: fix bugs involving symlinks in ubifs_findfile
When encountering a symlink pointing to an absolute path, ubifs_findfile
would return the target of the symlink as the result instead of resolving
any following components in the original path. Fix it by following the
same code path that is used for relative paths except that we set the
next inode to the root if we see a leading slash.

The existing code used memcpy and sprintf to copy the symlink target
into a fixed size stack buffer and was therefore vulnerable to buffer
overflows with a sufficiently long symlink target. Fix it by using a
heap buffer for the temporary path during path resolution.

Signed-off-by: Peter Collingbourne <peter@pcc.me.uk>
Fixes: 9d7952e4c6 ("ubifs: Add support for looking up directory and relative symlinks")
2026-05-11 12:18:56 -06:00
Simon Glass
08bcf962c5 binman: Use bintool wrappers for PKCS#11 tools in tests
The PKCS#11 signing tests in ftest.py call tools.run('softhsm2-util', ...)
directly (and the equivalent for pkcs11-tool and p11-kit), even though
the test setup has already constructed the corresponding Bintool
instances. As Quentin Schulz observed on v1, the bintool wrapper for
these tools is currently used only as an "is this installed?" probe.

Route the eight remaining call sites in ftest.py through
<bintool>.run_cmd(...), which the Bintool base class already provides.
The change is test-side only; no production binman code calls these
tools.

Suggested-by: Quentin Schulz <quentin.schulz@cherry.de>
Signed-off-by: Simon Glass <sjg@chromium.org>
2026-05-11 12:05:10 -06:00
Simon Glass
44f9ccfdad binman: Flesh out the softhsm2-util bintool docstring
The Sphinx-generated bintools.rst currently produces an empty section
for this bintool, since its class docstring is only a single line and
so the body under the heading is blank.

Extend the docstring with a short description of what softhsm2-util
does and how binman uses it, so the generated documentation has useful
content.

Suggested-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Simon Glass <sjg@chromium.org>
2026-05-11 12:05:10 -06:00
Simon Glass
40c94fbf62 binman: Flesh out the pkcs11-tool bintool docstring
The Sphinx-generated bintools.rst currently produces an empty section
for this bintool, since its class docstring is only a single line and
so the body under the heading is blank.

Extend the docstring with a short description of what pkcs11-tool does
and how binman uses it, so the generated documentation has useful
content.

Suggested-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Simon Glass <sjg@chromium.org>
2026-05-11 12:05:10 -06:00
Simon Glass
4dc8f10edf binman: Flesh out the p11-kit bintool docstring
The Sphinx-generated bintools.rst currently produces an empty section
for this bintool, since its class docstring is only a single line and
so the body under the heading is blank.

Extend the docstring with a short description of what p11-kit does and
how binman uses it, so the generated documentation has useful content.

Suggested-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Simon Glass <sjg@chromium.org>
2026-05-11 12:05:10 -06:00
Ludwig Nussel
49fc812eb4 patman: fix use in worktree
When using a worktree '.git' actually is a file and pygit2
init_repository() does not like that. The intention is not to create
a new git repo anyway so use normal constructor instead of
init_repository().

Signed-off-by: Ludwig Nussel <ludwig.nussel@siemens.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-11 12:05:10 -06:00
Heinrich Schuchardt
3d09ec64eb acpi: fix initial RSDT and XSDT size
When creating the RSDT and the XSDT table they contain no entries.
The table size therefore must equal the header size.

Without this change a NULL deference has been observed in
acpi_find_table() when running `ut dm` on sandbox64_defconfig
executed via `sudo ./u-boot -D`.

Fixes: 94ba15a3f1 ("x86: Move base tables to a writer function")
Fixes: 7e586f6907 ("acpi: Put table-setup code in its own function")
Fixes: ab5efd576c ("x86: acpi: Adjust order in acpi_table.c")
Fixes: 867bcb63e7 ("x86: Generate a valid ACPI table")
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Simon Glass <sjg@chromium.org>

Update dm_test_acpi_ctx_and_base_tables() in test/dm/acpi.c to expect
sizeof(struct acpi_table_header) for the initial table length (instead
of sizeof(*rsdt) / sizeof(*xsdt)), and to compute the checksum over
header->length bytes rather than the full struct size:
Signed-off-by: Simon Glass <sjg@chromium.org>
2026-05-11 12:04:43 -06:00
Tom Rini
22a285380e Merge tag 'u-boot-at91-fixes-2026.07-a' of https://source.denx.de/u-boot/custodians/u-boot-at91
First set of u-boot-at91 fixes for the 2026.07 cycle:

- Cleanup some useless code
2026-05-09 07:31:55 -06:00
Tom Rini
0dcb892fea Merge branch 'master' of git://source.denx.de/u-boot-usb
- DWC3 crash fix, Kconfig logic corrections
2026-05-09 07:31:22 -06:00
Balaji Selvanathan
cc8195b13b usb: dwc3: Fix crash on fastboot exit due to incorrect memory free
The dwc3_free_one_event_buffer() function incorrectly called free()
on event buffer structures allocated with devm_kzalloc(). This
caused heap corruption and a synchronous abort when exiting
fastboot mode via "fastboot continue".

Device-managed memory is automatically freed when the device is
removed, so manual deallocation causes the heap allocator to access
corrupted metadata.

Fixes: 884b10e86a ("usb: dwc3: core: fix memory leaks in event buffer cleanup")
Signed-off-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
Reviewed-by: Marek Vasut <marek.vasut+usb@mailbox.org>
2026-05-09 02:26:58 +02:00
Tom Rini
5040410102 usb: Correct dependencies around USB_EMUL
The symbol USB_EMUL is how sandbox has access to USB. It's
implementation however enforces a few other requirements. It must have
SCSI enabled, and in turn that means it must have BLK enabled. Finally,
we should not be using SANDBOX itself as a symbol to decide what to
build or not build here, as SANDBOX is selected for COMPILE_TEST builds
as well and so may not have enabled the sandbox specific USB support.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Marek Vasut <marek.vasut+usb@mailbox.org>
2026-05-09 00:24:53 +02:00
Tom Rini
93f96c7d8d reset: Correct dependencies for RESET_RZG2L_USBPHY_CTRL
As exposed by "make randconfig", we have an issue with the dependencies
for RESET_RZG2L_USBPHY_CTRL. As this functionally depends on
REGULATOR_RZG2L_USBPHY, express this dependency directly in Kconfig as
well.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-09 00:24:53 +02:00
Tom Rini
ebe2af6cd8 usb: gadget: Correct dependencies for USB_RENESAS_USBHS
The USB_RENESAS_USBHS functionality can only work with DM_USB_GADGET
enabled, so express this dependency in Kconfig.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-09 00:24:53 +02:00
Aristo Chen
28eed2103c test: fit: Use shared make_fname from fit_util
test_fit.py declares a local make_fname closure that is byte-identical
to fit_util.make_fname. Drop the local copy and call the shared helper
at all seven call sites so there is one definition to maintain.

No behavioural change. Both implementations return
os.path.join(ubman.config.build_dir, basename).

Signed-off-by: Aristo Chen <aristo.chen@canonical.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-08 15:49:27 -06:00
Ludwig Nussel
18806dae0e virtio: fix boot device hunting in qemu with virtio
Commit 70101c3217 ("virtio: mmio: Return error codes on probe
failures") returns -ENODEV where it would return 0 before. That path is
apparently hit in qemu and breaks boot device discovery
(virtio_bootdev_hunt() expects only ENOENT). So return -ENOENT in
that path instead.
The remaining two error returns in the function are untouched as I
don't know where they play a role.

Signed-off-by: Ludwig Nussel <ludwig.nussel@siemens.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Acked-by: Kuan-Wei Chiu <visitorckw@gmail.com>
2026-05-08 15:49:27 -06:00
Rasmus Villemoes
55b152e6f0 boot: image-fit.c: check target, not source, for 8-byte alignment when loading FDT
A number of our boards no longer boot with v2026.04, ironically as a
result of the effort to ensure 8-byte alignment of the dtb passed to
the kernel and getting rid of the fdt_high=0xffffffff.

The problem exists when the FIT image does specify a (properly
aligned) load address to use for the fdt. For example, we have

	fdt-am335x-boneblack.dtb {
		description = "Flattened Device Tree blob";
		data = /incbin/(...);
		...
		load = <0x88000000>;
	}

Now, with v2026.04 and depending on just exactly where that data ends
up, in a good case we see

     Loading fdt from 0x8a8c6e10 to 0x88000000
     Booting using the fdt blob at 0x88000000
  Working FDT set to 88000000
     Loading Kernel Image to 86008000
  WARNING:
  The 'fdt_high' environment variable is set to ~0. This is known to cause
  boot failures due to placement of DT at non-8-byte-aligned addresses.
  This system will likely fail to boot. Unset the 'fdt_high' environment
  variable and submit a fix upstream.
     Using Device Tree in place at 88000000, end 8801af2f
  Working FDT set to 88000000
  Starting kernel ...
  [    0.000000] Booting Linux on physical CPU 0x0

and the board boots (though with that ominous warning). However,
modifying the .its file a little, e.g. just removing the word "blob"
from the description, we end up with

     Loading fdt from 0x8a8c6e14 to 0x88000000
     Booting using the fdt blob at 0x9df94718
  Working FDT set to 9df94718
     Loading Kernel Image to 86008000
  WARNING:
  The 'fdt_high' environment variable is set to ~0. This is known to cause
  boot failures due to placement of DT at non-8-byte-aligned addresses.
  This system will likely fail to boot. Unset the 'fdt_high' environment
  variable and submit a fix upstream.
  Failed to reserve memory for fdt at 0x9df94718
  FDT creation failed!
  resetting ...

Notice how the "Loading fdt from" line still claims to load the fdt to
that 0x88000000 address, but since this "else if" clause looks at the
source address (buf) and comes before the "else if (load != data)"
clause, we end up doing the "allocate another buffer to use as target"
instead of actually copying to 0x88000000, but then the "fdt_high=~0"
logic in boot_relocate_fdt() obviously fails to do an lmb-reservation
of that area, and the boot fails.

When there's no load= property in the fdt node, this should not change
anything. But when there is, it is the alignment of that target which
is relevant, not the alignment of the fdt blob within the FIT
image. With this patch applied, we instead get the expected

     Loading fdt from 0x8a8c6e14 to 0x88000000
     Booting using the fdt blob at 0x88000000
  Working FDT set to 88000000
     Loading Kernel Image to 86008000
  WARNING:
  The 'fdt_high' environment variable is set to ~0. This is known to cause
  boot failures due to placement of DT at non-8-byte-aligned addresses.
  This system will likely fail to boot. Unset the 'fdt_high' environment
  variable and submit a fix upstream.
     Using Device Tree in place at 88000000, end 8801af2f
  Working FDT set to 88000000

  Starting kernel ...

Signed-off-by: Rasmus Villemoes <ravi@prevas.dk>
Fixes: 8fbcc0e0e8 ("boot: Assure FDT is always at 8-byte aligned address")
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-08 15:49:27 -06:00
Raymond Mao
0a31d3128e lib: fdtdec: validate bloblist FDT before consuming libfdt size
Coverity Scan defects are observed in fdtdec_apply_bloblist_dtos(),
since the live FDT taken from the bloblist is passed to libfdt helpers
which consume header size/offset fields:
- fdt_open_into()
- fdt_pack()

Validate the bloblist FDT with fdt_check_full() before calling
fdt_open_into() and again after applying overlays before calling
fdt_pack(). This makes the libfdt consumers operate on a checked FDT
blob while keeping the existing flow unchanged.

Also normalize libfdt return codes from this path to errno values,
including the overlay callback path through bloblist_apply_blobs().

Fixes: b70cbbfbf9 ("fdtdec: apply DT overlays from bloblist")
Addresses-Coverity-ID: CID 645837: (TAINTED_SCALAR)
Signed-off-by: Raymond Mao <raymond.mao@riscstar.com>
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>
2026-05-08 15:49:27 -06:00
Brad Klingerman
26b17dbdb0 Makefile: remove block from conv=block, sync in SPL alignment dd
The line that produces $(SPL_BIN)-align.bin invokes dd with
conv=block,sync but no cbs= operand. The result of dd conv=block
without cbs= is unspecified. GNU coreutils outputs anyway, but
uutils (default in Ubuntu 26.04 LTS) errors out for files with
newlines, including SPL binaries, producing:

    dd: conv=block or conv=ubnblock specified without cbs=N

Either the block operand must be removed, or cbs=N must be added.
conv=block is for converting newline-terminated variable-length
records to fixed-length space-padded ones, which is meaningless
for a binary SPL image. The intent of the rule is 4-byte
alignment, which conv=sync alone provides by padding the final
block to bs= bytes with NULs.

During build, u-boot-spl-align.bin errors silently due to '@'.

Reproduced with uutils dd 0.8.0:

    $ dd if=/dev/urandom of=/tmp/in bs=1 count=10000
    $ dd if=/tmp/in of=/tmp/out conv=block,sync bs=4
    dd: conv=block or conv=unblock specified without cbs=N
    $ dd if=/tmp/in of=/tmp/out conv=sync bs=4
    [succeeds]

Output is byte-identical to GNU dd's output for binary input.

Signed-off-by: Brad Klingerman <bdklingerman@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2026-05-08 15:49:27 -06:00
Tom Rini
3cdd19089f Merge tag 'mmc-for-2026.07-rc2' of https://source.denx.de/u-boot/custodians/u-boot-mmc
- Enable FPWM bits for tps65941
- Use max-frequency to get clock rate for msm_sdhci
- Fix and update for pfuze100
2026-05-06 20:13:39 -06:00
Tom Rini
e08877916e Merge tag 'mips-fixes-for-v2026.07' of https://source.denx.de/u-boot/custodians/u-boot-mips
- mips: mtmips: align MT7621 image blobs to 8-byte boundary
2026-05-06 08:55:26 -06:00
Tom Rini
8399b039b0 Merge tag 'efi-2026-07-rc2-2' of https://source.denx.de/u-boot/custodians/u-boot-efi
Pull request efi-2026-07-rc2-2

CI: https://source.denx.de/u-boot/custodians/u-boot-efi/-/pipelines/29993

UEFI:

* initialize variables in efi_dp_from_http()
* cmd: eficonfig: adjust struct eficonfig_entry, field key
* efi_dt_fixup: use fdtdec_get_bool() for reading boolean no-map property
* efi_selftest_memory: check for duplicates first
* simplify efi_mem_sort() using list_for_each_entry_safe

Others:

* lmb: document allocation flags constants
2026-05-06 08:45:57 -06:00
Tom Rini
980f8a4589 Merge tag 'net-20260506' of https://source.denx.de/u-boot/custodians/u-boot-net
Pull request net-20260506.

net:
- phy: dp83867: default to 2ns delay if unspecified in device-tree
- nfs: fix buffer overflow in nfs_readlink_reply()
- cpsw: Add cpsw-switch DT binding support
- phy: add common PHY polarity properties support
- phy: adin: add support for the ADIN1200 phy
- macb: support for instances with less features
- phy: mscc: add support for the VSC8572

net-lwip:
- wget: correct diagnostic output
2026-05-06 08:44:55 -06:00
Tom Rini
ffdce9d3fb Merge tag 'fsl-qoriq-for-2026.07-rc2' of https://source.denx.de/u-boot/custodians/u-boot-fsl-qoriq
- Add USB Hub (USB5744) management support for ten64
- Various DT fixes for ls1088a
- Fix dead default for SYS_L3_SIZE for powerpc
2026-05-06 08:43:32 -06:00
Shiji Yang
de79075f0f mips: mtmips: align MT7621 image blobs to 8-byte boundary
MT7621 doesn't boot on u-boot v2026.04. Fix it by correcting the
u-boot aligned offset.

Fixes: d9e183a04c ("MIPS: Assure end of U-Boot is at 8-byte aligned offset")
Signed-off-by: Shiji Yang <yangshiji66@outlook.com>
Reviewed-by: Weijie Gao <weijie.gao@mediatek.com>
2026-05-06 16:20:27 +02:00
Charles Perry
5245bdc98b net: phy: mscc: add support for the VSC8572
This is similar to the VSC8574 according to the Linux commit that adds
support for it [1].

This was tested on an HX1000 board with SGMII (PIC64-HX SoC which has a
GEM MAC).

[1]: https://lore.kernel.org/all/dfabe39a52efcd2cfff9358f271b8673143503b8.1480497966.git.neill.whillans@codethink.co.uk/

Signed-off-by: Charles Perry <charles.perry@microchip.com>
Reviewed-by: Manikandan Muralidharan <manikandan.m@microchip.com>
2026-05-06 11:07:22 +02:00
Christian DREHER
9717831e29 net: macb: add gigabit implementation for fixed-link
A fixed gigabit link on a non-gigabit controller is only rejected
during PHY init (even though there is no PHY to init), because, on
device-tree parsing, the controller is not probed, and it is still
unknown whether it is gigabit-capable.

This code was only tested on emulator with a full-duplex RGMII
interface, but is expected to work in GMII or half-duplex as well.

Signed-off-by: Christian DREHER <christian.dreher@nanoxplore.com>
2026-05-06 11:07:22 +02:00
Christian DREHER
d7fe1f4333 net: macb: do not set user_io when it does not exist
Cadence Ethernet MAC has a feature named user_io, which provides
some input and some output signals for arbitrary purpose in the SoC.
From the driver code, I understand that, on Atmel SoC, it is used to
drive the PHY mode.

At least on Cadence IP7014 r1p12, this feature is optional, and I am
working on a SoC that does not instantiate it. The presence of this
feature is advertised in DCFG1, this patch merely disables the access
to the user_io register based on this information.

I did not apply this change to the non-gigabit capable versions of
the IP, as I do not have documentation for them, and a new non-gigabit
instance is unlikely to appear. I prefer avoiding regressions on old
systems.

Signed-off-by: Christian DREHER <christian.dreher@nanoxplore.com>
2026-05-06 11:07:22 +02:00
Christian DREHER
361bb8f827 net: macb: use SA1 for MAC filtering on GEM
The MACB uses specific address registers (SA Top and Bottom) to
filter source or destination MAC addresses.
On the Gigabit Ethernet version, SA1B is @0x88.
On the non-GEM version, SA1B is @0x98.

Before this commit, the code was always writing 0x98. By chance,
on GEM, this is the address of SA3B, allowing the driver to work
anyway.

The motivation for this change is to be able to use the driver on
an instance of the GEM with less than 4 SA registers.

Signed-off-by: Christian DREHER <christian.dreher@nanoxplore.com>
2026-05-06 11:07:22 +02:00
Christian DREHER
9e23095298 net: macb: include arch/clk.h only when necessary
It does not exist in my setup (an on-going arm64 SoC), and removing
it does not cause any missing declaration, but some code called when
CONFIG_CLK is missing calls get_macb_pclk_rate, which is only defined
in arch/arm/mach-at91/include/mach/clk.h

Signed-off-by: Christian DREHER <christian.dreher@nanoxplore.com>
2026-05-06 11:07:22 +02:00
Rasmus Villemoes
52309be1d5 net: phy: adin: add support for the ADIN1200 phy
The ADIN1200 chip is register compatible with the ADIN1300, but only
supports 10/100 Mbit.

Signed-off-by: Rasmus Villemoes <ravi@prevas.dk>
2026-05-06 11:07:22 +02:00
Lucien.Jheng
615c536717 test: dm: add PHY common props unit tests and sandbox DT nodes
Add sandbox DM unit tests for the PHY common properties library and the
corresponding device tree test nodes to arch/sandbox/dts/test.dts.
Also enable CONFIG_PHY_COMMON_PROPS in configs/sandbox_defconfig so
the tests are built and run in the sandbox environment.

The test file covers rx/tx polarity lookups for all relevant cases:

  - missing property (defaults to PHY_POL_NORMAL)
  - single value without names array (applies to all modes)
  - count mismatch between values and names arrays (-EINVAL)
  - name found by exact match
  - name not found with no "default" fallback (-EINVAL)
  - name not found with a "default" entry (uses fallback value)
  - unsupported polarity value (-EOPNOTSUPP)

Ported from Linux KUnit test:
  linux/drivers/phy/phy-common-props-test.c

Signed-off-by: Lucien.Jheng <lucienzx159@gmail.com>
2026-05-06 11:07:22 +02:00
Lucien.Jheng
c008ffdf61 net: phy: airoha: air_en8811: use standard rx-polarity/tx-polarity properties
Replace the proprietary airoha,pnswap-rx / airoha,pnswap-tx boolean
device tree properties with the standard rx-polarity and tx-polarity
properties defined in phy-common-props.yaml.

Backward compatibility is maintained by reading the legacy boolean
properties first and passing them as the default_pol argument to
phy_get_rx/tx_polarity(). If the standard properties are absent the
legacy values are used transparently, so existing device trees remain
functional without modification.

Link: https://git.kernel.org/linus/66d8a334b57e64e43810623b3d88f0ce9745270b
Signed-off-by: Lucien.Jheng <lucienzx159@gmail.com>
2026-05-06 11:07:22 +02:00
Lucien.Jheng
9eca7fd0d3 phy: add common PHY properties support
Add a new PHY_COMMON_PROPS library that provides helper functions for
PHY drivers to read standardized polarity properties from the device
tree node:

  - phy_get_rx_polarity() / phy_get_tx_polarity()
  - phy_get_manual_rx_polarity() / phy_get_manual_tx_polarity()

The dt-bindings/phy/phy.h header with PHY_POL_NORMAL, PHY_POL_INVERT,
and PHY_POL_AUTO constants is provided via dts/upstream/include, which
is already in the build include path.

Ported from Merge tag 'phy-for-7.0':
  git://git.kernel.org/pub/scm/linux/kernel/git/phy/linux-phy

Link: https://git.kernel.org/linus/e7556b59ba65179612bce3fa56bb53d1b4fb20db
Signed-off-by: Lucien.Jheng <lucienzx159@gmail.com>
2026-05-06 11:07:22 +02:00
Markus Schneider-Pargmann (TI)
5bb7ae8921 net: cpsw: Support new cpsw-switch DT bindings
Upstream devicetrees use a newer DT binding using cpsw-switch
compatibles. The bindings are a bit different, so two functions are
introduced to capture the differences, cpsw_eth_of_to_plat_switch() and
cpsw_eth_of_to_plat_legacy().

Signed-off-by: Markus Schneider-Pargmann (TI) <msp@baylibre.com>
2026-05-06 11:07:22 +02:00
Markus Schneider-Pargmann (TI)
a1bc52f489 net: cpsw: Use driver data for phy_sel
Use driver data to pass the correct gmii_sel function. This way new
compatibles don't need manual compatible matching as is done in
cpsw_phy_sel().

Signed-off-by: Markus Schneider-Pargmann (TI) <msp@baylibre.com>
2026-05-06 11:07:22 +02:00
Markus Schneider-Pargmann (TI)
63f6f88bb0 net: cpsw: Remove compat string argument
The string is already in the priv struct, remove it from the argument
list.

Signed-off-by: Markus Schneider-Pargmann (TI) <msp@baylibre.com>
2026-05-06 11:07:22 +02:00
Markus Schneider-Pargmann (TI)
845c55dde8 net: cpsw: Fix error message
It should complain about mac_control here.

Signed-off-by: Markus Schneider-Pargmann (TI) <msp@baylibre.com>
2026-05-06 11:07:22 +02:00
Heinrich Schuchardt
94625af011 net: lwip/wget: don't print progress bar when silent
When the EFI sub-system request to silence output, do not output a progress
bar.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Jerome Forissier <jerome.forissier@arm.com>
2026-05-06 11:07:22 +02:00
Heinrich Schuchardt
e093a4ecbe net: lwip/wget: don't print content size twice
If wget_info->silent is set, we should not print anything.

If wget_info->silent we print the received content size.
Printing the value of the Content-Length header is redundant

For chunked transfer no Content-Length header is sent.
The content length is returned as HTTPC_CONTENT_LEN_INVALID by the LwIP
library. In this case we were incorrectly printing '4 GiB'.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Jerome Forissier <jerome.forissier@arm.com>
2026-05-06 11:07:22 +02:00
Heinrich Schuchardt
4877a07ed3 net: lwip/wget: missing linefeed in diagnostic output
With NET_LWIP wget produces this output with an overlong line
and missing white space:

    => wget $kernel_addr_r http://example.com/
    #################################################  4 GiB540 bytes transferred in 2 ms (263.7 KiB/s)
    Bytes transferred = 540 (21c hex)

Removing the condition on inserting a line feed yields:

    => wget $kernel_addr_r http://example.com/
    #################################################  4 GiB
    540 bytes transferred in 2 ms (263.7 KiB/s)
    Bytes transferred = 540 (21c hex)

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Jerome Forissier <jerome.forissier@arm.com>
2026-05-06 11:07:22 +02:00
Sebastian Josue Alba Vives
d6694018ea net: nfs: fix buffer overflow in nfs_readlink_reply()
nfs_readlink_reply() validates rlen only against the incoming packet
length (inherited from CVE-2019-14195), but not against the destination
buffer nfs_path_buff[2048]. A malicious NFS server can send a valid
READLINK reply where pathlen + rlen exceeds sizeof(nfs_path_buff),
overflowing the BSS buffer into adjacent memory.

The recent fix in fd6e3d3409 addressed the same overflow class in
net/lwip/nfs.c but left the legacy path in net/nfs-common.c unpatched.

Add bounds checks before both memcpy calls in nfs_readlink_reply():
- relative path branch: reject if pathlen + rlen >= sizeof(nfs_path_buff)
- absolute path branch: reject if rlen >= sizeof(nfs_path_buff)

Fixes: cf3a4f1e86 ("net: nfs: Fix CVE-2019-14195")
Cc: stable@vger.kernel.org
Signed-off-by: Sebastian Alba Vives <sebasjosue84@gmail.com>
Reviewed-by: Jerome Forissier <jerome.forissier@arm.com>
2026-05-06 11:07:22 +02:00
Siddharth Vadapalli
e86d1c0b88 net: phy: dp83867: default to 2ns delay if unspecified in device-tree
Since Linux commit c360eb0c3ccb ("dt-bindings: net: ethernet-controller:
Add informative text about RGMII delays"), the interpretation of RGMII
delays has changed. Prior to the commit, the RGMII Variant among "rgmii",
"rgmii-id", "rgmii-rxid" and "rgmii-txid" clearly specified whether it is
the MAC or the PHY that "should" add the delay. However, post that commit,
the RGMII Variant only specifies whether or not there is a delay on the
PCB traces between the MAC and the PHY, leaving it open as to who adds the
delay.

Hence, instead of enforcing the existence of the device-tree properties
"ti,rx-internal-delay" and "ti,tx-internal-delay", default to a delay
of 2ns, while continuing to override this delay with the aforementioned
properties, if they exist in the device-tree.

This is in line with the Linux driver implementation updated by commit
6bf78849371d ("net: phy: dp83867: use 2ns delay if not specified in DTB").

Signed-off-by: Siddharth Vadapalli <s-vadapalli@ti.com>
Reviewed-by: Anshul Dalal <anshuld@ti.com>
2026-05-06 11:07:22 +02:00
Mathew McBride
dea0973723 configs: ten64: add USB start to preboot
There are two reasons why the USB stack needs to be
started before handing to bootflow or other boot
sequences:

1. When a USB hub is present on the board, we need to
do the required sequences to make it usable

2. To make USB storage devices 'visible' to bootflow
without further intervention

Signed-off-by: Mathew McBride <matt@traverse.com.au>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:49 +08:00
Mathew McBride
e7e0cd82b7 arm: dts: remove local copy of Ten64 board DTS
This board has been migrated to the upstream / kernel
device tree version (OF_UPSTREAM), so remove the
old 'local' copies that are no longer required.

However, the -u-boot.dtsi append needs to remain,
because the SoC fsl-ls1088a-u-boot.dtsi is required
for some devices (like PCIe controllers and DPAA2 ethernet)
to properly enumerate under U-Boot.

Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Mathew McBride <matt@traverse.com.au>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:49 +08:00
Mathew McBride
9bcbb5f268 configs: ten64: switch to OF_UPSTREAM
Two recent additions to the mainline device tree allow us
to switch away from the local U-Boot copy:

* Board/embedded controller (traverse,ten64-controller)
  is now in the mainline device tree.
* USB Hub (USB5744) connections were also added to
  the mainline device tree but not in U-Boot.

The LS1088A and Ten64 device trees in U-Boot were actually
'synced' to mainline some time ago, so the content
(except for the changes mentioned above) is identical.

Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Mathew McBride <matt@traverse.com.au>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:49 +08:00
Mathew McBride
6cdd17aed5 configs: ten64: enable USB_ONBOARD_HUB (USB5744) option
Ten64 board revs A through C have a Microchip USB5744
hub on the board, which must be configured over I2C
at boot time to become usable.

This function has not been part of the mainline
U-Boot for this board until now, as a mainline driver
and device-tree binding is now available for the USB5744.

Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Mathew McBride <matt@traverse.com.au>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:49 +08:00
Mathew McBride
327ac9cc80 configs: ten64: enable OF_BOARD_FIXUP
We have added board_fix_fdt to remove elements from U-Boot's
internal FDT related to the USB hub, so CONFIG_OF_BOARD_FIXUP
needs to be enabled to utilize it.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:48 +08:00
Mathew McBride
3b5f6b62b0 board: ten64: remove USB hub references from internal FDT when needed
More recent revisions of the Ten64 board do not have a USB Hub
(USB5744). The references to the USB5744 need to be removed in U-Boot's
internal FDT to avoid the USB5744 setup being invoked on these boards.

Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Mathew McBride <matt@traverse.com.au>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:48 +08:00
Mathew McBride
024c3e86ea board: ten64: add fdt fixup to hide usb hub topology
The USB Hub (microchip,usb5744) can enter a dis-/reconnect loop
if a driver tries to re-initialise the hub over I2C.

On the Ten64 board, this process only needs to be run once
per system reset cycle, which is carried out by U-Boot.

As there are distributions shipping with the affected
driver by default, the best solution is to remove
the USB hub topology information from the FDT passed
to the operating system, so the OS won't attempt
to re-initialise the USB hub under any circumstance.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:48 +08:00
Mathew McBride
d360217d4a arm: gpio: include integer type definitions for gpio.h
Both consumers and sub-arch specific versions of gpio.h
may reference stdint or other non-C90 type definitions.

Ensure the common ones are available by including linux/types.h
before any other headers.

This issue came to light when the usb onboard hub driver
was enabled for ten64_tfa_defconfig:

In file included from ./arch/arm/include/asm/gpio.h:2,
		 from common/usb_onboard_hub.c:10:
./arch/arm/include/asm/arch/gpio.h:17:9: error: unknown type name 'ulong'
   17 |         ulong addr;
./arch/arm/include/asm/arch/gpio.h:18:9: error: unknown type name 'ulong'
   18 |         ulong size;
./arch/arm/include/asm/arch/gpio.h:19:9: error: unknown type name 'uint'
   19 |         uint ngpios;

(In this instance, the cited errors actually originate from
arch/arm/include/asm/arch-fsl-layerscape/gpio.h, which is included
by the arm top level asm/gpio.h)

Implemented as per suggestion from Quentin Schulz in Link:

Signed-off-by: Mathew McBride <matt@traverse.com.au>
Link: https://lore.kernel.org/u-boot/35038a9a-fa5a-4f9f-b34e-17cc80a7824c@cherry.de/
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 16:04:48 +08:00
Ye Li
aedaa8250b arm: dts: layerscape: Fix SPI flash compatible string issue
When CONFIG_DM_SPI_FLASH is enabled, sf command will default find
device from DT which requires to use "jedec,spi-nor" compatible
string not obsoleted "spi-flash". So update NXP LS DTS to use
new compatible string

Signed-off-by: Ye Li <ye.li@nxp.com>
Acked-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:30:11 +08:00
Ye Li
8c60833124 arm: dts: layerscape: Fix DT build warning in SPI nodes
There are lots of DT warning in layerscape DTS files like:
node name for SPI buses should be 'spi' and SPI bus unit address
format error.
Update the spi node name and flash node name to avoid build warning

Signed-off-by: Ye Li <ye.li@nxp.com>
Acked-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:30:11 +08:00
Ye Li
d47f02d9ca arm: dts: fsl-ls1088a: Enable USB nodes
Enable USB nodes in -u-boot.dtsi. After sync dts with kernel, USB
nodes status are set to disabled. So "usb start" does not work on
ls1088ardb and ls1088aqds.

Fixes: 10ff7e6b04 ("arm: dts: fsl-ls1088a: sync usb controller nodes with Linux")
Signed-off-by: Ye Li <ye.li@nxp.com>
Tested-by: Wei Lu <w.lu@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:30:00 +08:00
Ye Li
5fadfd623a arm: dts: fsl-ls1088a: Enable SD device
Due to update of fsl-ls1088a.dtsi in previous patch, the esdhc
node is disabled, so u-boot can't to probe any eSDHC controller.

Fixes: fd4f7b0158 ("arm: dts: fsl-ls1088a: move and sync existing bindings to be under /soc")
Signed-off-by: Ye Li <ye.li@nxp.com>
Tested-by: Wei Lu <w.lu@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:29:59 +08:00
Ye Li
8e33f7ac90 arm: dts: fsl-ls1088a: Set dpmac nodes default to disabled
Disable ethernet controller dpmac nodes in fsl-ls1088a.dtsi. Board
dts is responsible to enable them. Otherwise will meet failure from
ldpaa_eth driver on LS1088AQDS board, because only few dpmac
controllers can be enabled on this board.

Signed-off-by: Ye Li <ye.li@nxp.com>
Tested-by: Wei Lu <w.lu@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:29:44 +08:00
Ye Li
5a0343350a arm: dts: fsl-ls1088a-qds: Fix missed -u-boot.dtsi
LS1088AQDS u-boot contains multiple DTB files:
fsl-ls1088a-qds-21-x.dtb and fsl-ls1088a-qds-29-x.dtb.
It does not use default device tree fsl-ls1088a-qds.dtb

However, the nodes updated in fsl-ls1088a-qds-u-boot.dtsi are not
included for fsl-ls1088a-qds-21-x.dts and fsl-ls1088a-qds-29-x.dts,
so fail to get any output from serial.

Signed-off-by: Ye Li <ye.li@nxp.com>
Tested-by: Wei Lu <w.lu@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:29:44 +08:00
Ye Li
33ff22c0b1 arm: layerscape: Check zero size memory bank before lmb_add
In layerspace's lmb_arch_add_memory implementation, all memory bank
are added to lmb, even some is with zero size. This will cause lmb
treating it as overlap with available memory by lmb_addrs_overlap
and merge with available memory. Finally causing available memory
start address changed to 0.

For example, on LX2160, before zero memory bank added to lmb, there
are two available memory regions:
  - region 0, start 0x80000000, size 0x7be00000
  - region 1, start 0x2080000000, size 0x700000000
After zero size memory bank added, merge to one region:
  - region 0, start 0, size 0x2780000000
This wrong new region causes efi_memory_init issue when allocating bounce
buffer because of conflict address (with uboot reserved) is allocated.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:29:33 +08:00
Julian Braha
34127dff31 powerpc: fix dead default for SYS_L3_SIZE
The 'default ... if SYS_L3_SIZE_512KB' statement is written twice, making
the second instance dead code.

Based on the context, I believe the author of the code intended to set a
default value of '1048576' when SYS_L3_SIZE_1024KB is set.

This dead code was detected by kconfirm, a static analysis tool for
Kconfig.

Fixes: b85d75951f ("powerpc: Migrate SYS_L3_SIZE to Kconfig")
Signed-off-by: Julian Braha <julianbraha@gmail.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:28:35 +08:00
Varadarajan Narayanan
f07c15c16a mmc: msm_sdhci: Use max-frequency to get clock rate
msm_sdc_clk_init() uses clock-frequency to get the clock rate for SDC
clocks. However, the DT files seem to use max-frequency for the same.
Since msm_sdc_clk_init() doesn't find clock-frequency in the DT, it sets
201500000 as the clock rate and this results in timeout errors on IPQ
platforms.

Additionally, clock-frequency is not DT bindings compliant. Hence, get
clock rate using DT bindings compliant max-frequency.

Signed-off-by: Varadarajan Narayanan <varadarajan.narayanan@oss.qualcomm.com>
Reviewed-by: Sumit Garg <sumit.garg@oss.qualcomm.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:20:30 +08:00
Peng Fan
2a628fee83 power: regulator: Correct Kconfig for PFUZE100
Use CONFIG_$(PHASE_)DM_REGULATOR_PFUZE100 as the build condition for
pfuze100 regulator driver.
Add Kconfig option for SPL_DM_REGULATOR_PFUZE100.
To avoid break current platforms, set the Kconfig default value same
as PMIC_PFUZE100.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:20:30 +08:00
Peng Fan
e015bc1b8d power: regulator: pfuze100: support non-independent mode
Some BUCKs could work in single/dual phase mode, not in independent
mode. In single/dual phase mode, registers of both regulators,
must be identically set. So configure mode and value for both BUCKs.

CONF registers are not touched, leave them as default OTP settings.

PFUZE100/200 SW3A/B, could work in single/dual phase mode, so introduce
a new macro by adding a pointer to the SW3B descriptor.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:20:30 +08:00
Peng Fan
b7b7aa741f power: regulator: pfuze100: support high output voltage mode
Some PFUZE regulators can operate in either low or high output voltage mode,
with different minimum voltages and voltage step sizes selected by a hardware
control bit. However, the current PFUZE100 regulator driver assumes low output
voltage mode only, resulting in incorrect voltage calculation and programming
when high voltage mode is enabled.

Extend the regulator descriptor to describe high output voltage mode by adding
a mask to detect the mode and a dedicated voltage description (min_uV and
step size). Update voltage get/set handling to dynamically select the correct
voltage parameters based on the high voltage mode bit.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:20:30 +08:00
Peng Fan
356b7598cd power: regulator: pfuze100: Fix min_uV usage
regulator-min-microvolt in device tree is not always match the minimal
voltage in the pmic datasheet, direclty using the min value from device
tree as base may cause wrong voltage settings being written.

Directly use the min_uV from datasheet to avoid wrong settings.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:20:30 +08:00
Neha Malcom Francis
1526438a93 power: regulator: tps65941: Enable FPWM bits
Depending on the phase selection (single or multi), the FPWM bits
configured forces the regulator to operate in PWM mode. In case of
multi-phase selection, the FPWM_MP bits enforce the regulator to also
operate in multi-phase. This fixes correct multi-phase operation.

While at this, correct incorrect macro alignment as well.

Fixes: 065a452ae6 ("power: regulator: tps65941: add regulator support")
Link: https://www.ti.com/lit/ds/symlink/tps6594-q1.pdf
Signed-off-by: Keerthy <j-keerthy@ti.com>
Signed-off-by: Takuma Fujiwara <t-fujiwara1@ti.com>
Signed-off-by: Neha Malcom Francis <n-francis@ti.com>
Reviewed-by: Udit Kumar <u-kumar1@ti.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
2026-05-06 10:20:29 +08:00
Tom Rini
ae8987f4e6 Merge patch series "binman: Fix preload signing with encrypted FIT"
Yan WANG <yan.wang@softathome.com> says:

This series improves the reliability and efficiency of binman preload
header generation and test it against an encrypted FIT image signed with
a preload header.

When a preload header references other entries (e.g. an encrypted FIT)
through the collection etype, the referenced entries may be rebuilt
multiple times during binman processing. This becomes problematic when
the referenced entry produces non-deterministic output, such as FIT
encryption using random IVs or timestamps, since rebuilding the entry
changes the data.

This series ensures that referenced entries are built only once and that
preload signing is performed after all data is collected. It also avoids
unnecessary repacking or repeated signing operations by the preload.

The changes include:
  * generate preload header placeholders in ObtainContents() and sign
    data only once in ProcessContentsUpdate()
  * mark referenced entries as build_done in the collection etype to
    avoid rebuilding data
  * add a functional test for signing an encrypted FIT with a preload
    header

Link: https://lore.kernel.org/r/20260417083050.499955-1-yan.wang@softathome.com
2026-05-05 10:37:16 -06:00
Paul HENRYS
b20d69e5f5 tools: binman: Test signing an encrypted FIT with a preload header
Add a test to verify the preload header correctly signs an encrypted
FIT. This test exercises the case where encryption uses random IVs that
would change between mkimage calls.

Signed-off-by: Paul HENRYS <paul.henrys_ext@softathome.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-05 10:37:09 -06:00
yan wang
9ff82a771c binman: collection: Set build_done on referenced entries
The collection etype uses phandles in the 'content' property to
reference other entries. Mark each referenced entry with build_done
to avoid rebuilding the same entry data multiple times.

This is important for cases where rebuilding may change the data
content, e.g. due to timestamps or random IVs in encryption.

Refactor GetContentsByPhandle() to return both the entry object and
its data.

Signed-off-by: yan wang <yan.wang@softathome.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-05 10:37:09 -06:00
Paul HENRYS
5006121b44 binman: Generate preload header and sign data only once
To optimize preload generation, generate the header and signatures only
after all data has been collected in ProcessContentsUpdate(). This
avoids signing the data multiple times.

Since header_size is known upfront (from __init__), create a placeholder
in `ObtainContents()` to avoid an extra packing pass when
ProcessContentsUpdate() detects a size change.

This reduces unnecessary repacking and signing operations.

Signed-off-by: Paul HENRYS <paul.henrys_ext@softathome.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-05 10:37:09 -06:00
Aristo Chen
e6112ab2d7 configs: phycore_am62x_r5_ethboot: Drop duplicate CONFIG entries
CONFIG_SPL_MMC=n and CONFIG_SPL_DM_SPI=n are each listed twice in the
defconfig. Remove the redundant occurrences so each option appears only
once.

Signed-off-by: Aristo Chen <aristo.chen@canonical.com>
2026-05-05 10:36:42 -06:00
Aristo Chen
f7f2864e19 configs: phycore_am62ax_r5_ethboot: Drop duplicate CONFIG_SPL_MMC
CONFIG_SPL_MMC=n is listed twice in the defconfig. Remove the redundant
occurrence so each option appears only once.

Signed-off-by: Aristo Chen <aristo.chen@canonical.com>
2026-05-05 10:36:42 -06:00
Aristo Chen
7c3945a231 configs: r8a78000_ironhide: Drop duplicate CONFIG_SCMI_FIRMWARE
CONFIG_SCMI_FIRMWARE=y is listed twice in the defconfig. Remove the
redundant occurrence so each option appears only once.

Signed-off-by: Aristo Chen <aristo.chen@canonical.com>
2026-05-05 10:36:42 -06:00
Tom Rini
d5f178c9a0 Merge patch series "configs: toradex: Enable EFI"
Francesco Dolcini <francesco.dolcini@toradex.com> says:

Enable standard EFI support for all the arm64 Toradex boards, as
required for booting standard aarch64 Linux distribution, following the
ARM recommendations for SystemReady compliance.

The RTC used on these boards is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady
Link: https://lore.kernel.org/r/20260424104213.303752-1-francesco@dolcini.it
2026-05-05 10:36:08 -06:00
Francesco Dolcini
a97668cd8b configs: verdin-imx95: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
d52f67197b configs: verdin-imx8mp: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
9f5c862ecc configs: verdin-imx8mm: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
1327724ffd configs: verdin-am62p: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
3a304e7347 configs: verdin-am62: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
1dda05fe99 configs: toradex-smarc-imx95: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
1bd90ebe2c configs: toradex-smarc-imx8mp: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
398fca82ae configs: colibri-imx8x: Enable EFI
Enable standard EFI support, as required for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
6912d61909 configs: aquila-am69: Enable EFI related options
Enable EFI related options, as suggested for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Francesco Dolcini
2c34e32b9b configs: apalis-imx8: Enable EFI
Enable standard EFI support, as required for booting standard aarch64
Linux distribution, following the ARM recommendations for SystemReady
compliance [1].

The RTC used on this board is not currently supported by U-Boot,
therefore it is not enabled at the moment.

Link: https://developer.arm.com/documentation/DUI1101/4-5/Configure-U-Boot-for-SystemReady [1]
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
2026-05-05 10:35:36 -06:00
Randolph Sapp
b1c28ad5fa efi_mem_sort: use list_for_each_entry_safe instead
Use list_for_each_entry_safe and comparisons against the current and
next efi_mem_desc. This reduces the computation required for merging
regions, prevents unnecessary additional iterations of the list, and
requires less temporary values.

Signed-off-by: Randolph Sapp <rs@ti.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-05 16:29:08 +02:00
Randolph Sapp
025c4cbd42 efi_selftest_memory: check for duplicates first
Check for duplicate memory mappings before reporting any incorrect
attributes. Could be that second allocation has the correct type while
the first doesn't. Knowing there is a duplicate in this scenario is
more helpful than just reporting the first mismatch.

Signed-off-by: Randolph Sapp <rs@ti.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-05 16:29:08 +02:00
Randolph Sapp
3ad3243f8a efi_dt_fixup: use fdtdec_get_bool
Use the more straightforward fdtdec_get_bool instead of fdt_getprop and
a return code check.

Signed-off-by: Randolph Sapp <rs@ti.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Anshul Dalal <anshuld@ti.com>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-05 16:29:08 +02:00
Randolph Sapp
a2f2731008 lmb: allocation flags macro documentation
Update the allocation flags inline documentation to follow the kernel
object like macro documentation specification.

Use active voice for the short descriptions.

Signed-off-by: Randolph Sapp <rs@ti.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-05 16:29:08 +02:00
Heinrich Schuchardt
7d48344aff cmd: eficonfig: adjust struct eficonfig_entry, field key
The number EFICONFIG_ENTRY_NUM_MAX - 1 must be printable
to field key of struct eficonfig_entry.

Fixes: 1f0583beeb ("eficonfig: set EFICONFIG_ENTRY_NUM_MAX to INT_MAX - 1")
Fixes: 23aa0502a4 ("eficonfig: increase the number of menu entries")
Addresses-Coverity-ID: 583414 - Out-of-bounds write
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-05 16:29:08 +02:00
Heinrich Schuchardt
2898031803 efi_loader: initialize variables in efi_dp_from_http()
When using lwIP, efi_dp_from_http() may fail to initialize ip or mask.
Initialize the variables before the call.

Addresses-Coverity-ID: 645840 - Uninitialized variables (UNINIT)
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-05 16:29:08 +02:00
Tom Rini
70434636c3 Merge branch 'master' of https://source.denx.de/u-boot/custodians/u-boot-sh
DT clean ups, Kconfig clean up, R-Car Gen5 remoteproc and watchdog
driver, and R-Car Gen5 CM33 initial build support.
2026-05-05 08:16:52 -06:00
Marek Vasut
20b124d1bc arm64: renesas: Add Cortex-M33 build option to R-Car Gen5
The R-Car Gen5 SoCs contains Cortex-M33, Cortex-R52 and Cortex-A720AE
cores. Add U-Boot build options for the Cortex-M33 core.

Since the Cortex-M33 core is a 32bit core, select V8M and ARM64 for
RCAR64 accordingly. Select TMU timer on the 32bit core, where it is
used instead of the ARMv8 timer. Adjust TMU timer base address to match
the address map of the Cortex-M33 core. Disable unused OF_BOARD_SETUP
as well as unavailable POSITION_INDEPENDENT configuration options.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Udit Kumar <u-kumar1@ti.com>
2026-05-05 12:53:53 +02:00
Marek Vasut
7ad9d8a24c watchdog: Add Renesas R-Car Gen5 window watchdog driver
Add support of Renesas R-Car Gen5 window watchdog timer. Timeout
configuration is derived from CONFIG_WATCHDOG_TIMEOUT_MSECS, which
is more accurate than the 1-second granularity 'timeout' passed to
.start callback.

Reviewed-by: Stefan Roese <stefan.roese@mailbox.org>
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-05 12:53:53 +02:00
Marek Vasut
9f71b271db remoteproc: renesas: Add Renesas R-Car Gen5 remote processor driver
Add R-Car Gen5 RSIP controller remoteproc driver capable of starting
the SCP, Cortex-R52 and Cortex-A720 cores in Renesas R-Car R8A78000
X5H SoC. The SCP core is started by releasing the core from reset,
the Cortex-R52 and Cortex-A720 are started using the SCP SCMI call.
The entry point for SCP core is fixed to its STCM, entry points for
Cortex-R52 and Cortex-A720 are set during rproc load.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-05 12:53:53 +02:00
Marek Vasut
8528f2ed20 arm: renesas: Fix Kconfig indent
Indent using tabs and two spaces for help text. No functional change.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-05 12:53:53 +02:00
Marek Vasut
529e62ecc7 arm: dts: renesas: Remove duplicate AVB pinmux assignment on V3M
Both R-Car V3M Eagle and V3MSK U-Boot DT extras contain AVB pinmux
assignment, which is a leftover from before the same pinmux was part
of upstream DTs. Remove the duplicate AVB pinmux assignment in favor
of the upstream DT content. No functional change.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-05 12:53:53 +02:00
Marek Vasut
d0abd8b4c5 arm: dts: renesas: Clean up RPC DT nodes
Remove duplicate properties which are present both in arch/arm/dts/
and upstream dts/upstream/src/arm64/renesas/ in favor of those in
upstream DTs. Since those are duplicates, this causes no functional
change. Remove unused num-cs and bank-width DT properties.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
2026-05-05 12:53:53 +02:00
Tom Rini
57460fde4b Merge branch 'master' of git://git.denx.de/u-boot-coldfire
- stmark2 / mcf5441x updates
2026-05-04 14:41:59 -06:00
Heinrich Schuchardt
ba1209d7a7 fat: initialize ret in disk_rw()
If fat_sect_size = 0 and nr_sect = 0, the value of ret is never initialized.
A random return value is returned.

Initialize ret to 0.

Addresses-Coverity-ID: - 645495 Uninitialized scalar variable
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-04 14:35:10 -06:00
Angelo Dureghello
44684aabc2 m68k: set proper u-boot image size for initial boot
There is a value of 256K hardcoded as u-boot image size. This
produce bank tty as soon as the image size grows over the limit.
Fix it by using value preset by CONFIG_SYS_MONITOR_LEN.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>
2026-05-04 22:19:49 +02:00
Angelo Dureghello
07d824e5bb m68k: mcf5441x: create stub to use imx drivers
Some NXP imx hardware ip module as the esdhc controller are exactly the
same in some new ColdFire cpus. For the specific case, mcf5441x needs to
use the existing fsl_esdhc_imx.c driver for the esdhc device.

Create a stub to be able to use NXP "imx" serie drivers as the
fsl_esdhc_imx in the ColdFire architecture.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>
2026-05-04 22:19:49 +02:00
Angelo Dureghello
b17db4fadc configs: stmark2: add bdinfo command
Enable bdinfo command.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>

---
Changes in v2:
- recreated by make menuconfig
2026-05-04 22:19:49 +02:00
Angelo Dureghello
28fc1cbab3 configs: stmark2: add support for mmc
Add support for mmc.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>

---
Changes in v2:
- recreated by make menuconfig
2026-05-04 22:19:49 +02:00
Angelo Dureghello
cc4c0cbc29 mmc: Kconfig: allows m68k to use esdhc imx driver
Allow cpu families as mcf5441x (m68k) to use the fsl_esdhc_imx driver
since the hardware ip module is the same.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>

---
Changes in v2:
- moved before menuconfig changes
2026-05-04 22:19:49 +02:00
Angelo Dureghello
73b428c585 board: stmark2: remove old garbage
Remove old erroneous garbage.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>
2026-05-04 22:19:49 +02:00
Angelo Dureghello
a38b3fca74 board: stmark2: add sd boot command
Add command to boot from sd.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>
2026-05-04 22:19:49 +02:00
Angelo Dureghello
81b7e4da50 m68k: dts: stmark2: enable esdhc
Enable esdhc device.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>
2026-05-04 22:19:49 +02:00
Angelo Dureghello
988c983370 m68k: dts: mcf5441x: add mmc device for mcf5441x
Add mmc support for the mcf5441x family. There is only one esdhc
controller for this cpu family.

Signed-off-by: Angelo Dureghello <angelo@kernel-space.org>
2026-05-04 22:19:48 +02:00
Emanuele Ghidoli
2c733e6c85 common: memsize: fix occasionally failing alias probing
probe_ram_size_by_alias() detects whether a probe address still aliases
a lower address by writing through one address and reading through the
other.

On i.MX95 this occasionally reported a false non-alias when the alias
read happened immediately after the write.

A memory barrier alone, mb(), was tested but did not make the failure go
away. This suggests that ordering the CPU accesses is not sufficient for
this probe, likely because the issue is in the path to the memory
controller rather than in the core itself.

Read the written address back before checking the alias address. This
appears to force the write to become observable at the probe address
before using the alias read to decide whether the tested address range
exists.

If the readback does not match the written pattern, restore the saved
value and continue with the next check. This keeps the probe robust for
addresses that do not reliably retain the test pattern.

Fixes: 0977448b45 ("common: memsize: add RAM size probe based on alias detection")
Signed-off-by: Emanuele Ghidoli <emanuele.ghidoli@toradex.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-04 12:58:47 -06:00
Michal Simek
0fd32094c0 bloblist: fix pointer comparison in bloblist_apply_blobs()
The rec_from_blob() function returns a pointer, but the code was
comparing it using "rec <= 0" which is incorrect for pointer types.
Pointers should be compared using "== NULL" or "!= NULL".

Addresses-Coverity-ID: CID 645841: Incorrect expression (BAD_COMPARE)
Signed-off-by: Michal Simek <michal.simek@amd.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Raymond Mao <raymondmaoca@gmail.com>
2026-05-04 12:58:44 -06:00
Michal Simek
7dd93524ea fdt: check fdt_pack() return value in fdtdec_apply_bloblist_dtos()
The fdt_pack() function can return an error code, but its return value
was not being checked. Add proper error handling to propagate any
failure.

Also fix typo in comment: "Shink" -> "Shrink".

Addresses-Coverity-ID: CID 645839: Error handling issues (CHECKED_RETURN)
Signed-off-by: Michal Simek <michal.simek@amd.com>
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Raymond Mao <raymondmaoca@gmail.com>
2026-05-04 12:56:08 -06:00
Simon Glass
c7a6d4fdd7 .mailmap: Update my email address
Add a .mailmap entry so my sjg@chromium.org address is used for all
email.

Suggested-by: Quentin Schulz <quentin.schulz@cherry.de>
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de>
Tested-by: Quentin Schulz <quentin.schulz@cherry.de>
2026-05-04 12:40:01 -06:00
Franz Schnyder
92a04aea6d board: toradex: Quote variables in test cmd expression
With correct POSIX handling, unquoted empty variables can turn the
expression like
	test -n ${fdtfile}
into
	test -n

The POSIX handling for single argument `test` evaluates it as true,
so the fallback initialization will be skipped unexpectedly.
Quoting variable expansions in `test` expressions will always result in
correct behavior for empty and non-empty values.
This change was triggered by
commit 8b0619579b ("cmd: test: fix handling of single-argument form of test")
The aim is to have a less fragile codebase that is not dependent on a
quirk of the shell implementation.

Use quoted variable expansions in `test` expressions throughout.

Signed-off-by: Franz Schnyder <franz.schnyder@toradex.com>
Acked-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-05-04 11:07:43 -06:00
Tom Rini
bb0f3eebb3 Merge branch 'master' of https://source.denx.de/u-boot/custodians/u-boot-sunxi
Apologies for the delay, but please pull those sunxi changes into
v2026.07. Nothing earth shattering, mostly minor improvements like
better SPL power LED support, and fixes to some H616 DRAM setup. Also
some more forward looking enhancement for the SPI code. I also pulled in
Richard's raw NAND flash improvements for the H6/H616 SoC, though this
lacks proper peer testing due to the lack of mainline support for any
board actually employing those chips.
2026-05-01 08:12:31 -06:00
Tom Rini
21d842d4e5 Merge tag 'efi-2026-07-rc2' of https://source.denx.de/u-boot/custodians/u-boot-efi
Pull request efi-2026-07-rc2

CI: https://source.denx.de/u-boot/custodians/u-boot-efi/-/pipelines/29967

Documentation:

* .clang-format description
* qemu-arm: describe secure state steps
* mention that CONFIG_BOOTSTD_DEFAULTS provides network features when NET=y
* ti: k3: describe fTPM support

UEFI:

* cmd/bootefi: move efi_init_obj_list() to the start of do_bootefi
* correct return value of efi_bootmgr_run()
* correct efi_binary_run_dp() return value
* centralize messaging for efi_init_obj_list
* correct Kconfig dependencies for EFI_HTTP_BOOT

Others:

* .clang-format: add U-Boot specific for each macros

# -----BEGIN PGP SIGNATURE-----
#
# iQIzBAABCAAdFiEEbcT5xx8ppvoGt20zxIHbvCwFGsQFAmn0hjwACgkQxIHbvCwF
# GsRDVQ/+LADSJv/WxhsEayOe1f0H0wp42bssPZikyUxHGr6azNHjgngw2sExfFt0
# YE9j3HUclZy0LLlsykUk8f6uzHsL4DTLS1pqwoi1tYX/szotvW6fP5eUUxkUD06Y
# GYx8ub+Niq8F5/wT7VYj4cBxs8Pl3Zql4vp0nlBFdgxH0D9APH6ORucjNawa+vCv
# a7yqzSv9vyJXdsOKxpusfrcsz8pdd8UqXRmTwgPxarc8g0gqieLAwP/bECEeq5ZR
# FSKrWF9qYrLUEBVlwUx6jEVgq9JvzL1FP8p9w+WMdP++ani7ytaqL40KGorHm1mU
# JAwaDdWiRgodYGRNoP5aPZNvx1o+e0dRoioF2cL9Eob+6pXG053dN5VVZUgMfGPf
# 9xHfpAI47y+EvSPZEe1T/m7wAIOTBCP58rJGgTXvlCL1+dc3X4Ez68x5zcDMrJF/
# 0QnuAoaZS+XgyWwsCOR9cGHSzNT3rR3Wx/f2lKXklbCMQ+C+sp5UkRFNvYrhCqnk
# tg+sWH54oEKKQ0dTwGG+tsFhn8lsdXzhRKl1jN7w4DVY/R9YZu776biU3yzortfI
# ymbFmfOGmcPSD+lO7S1w+64zjvwnJT+rAzMLuYr3bIuhWpS4rd2phsEyLfcDSXwc
# 51imC2PSnp7Mx51F5qjCXligYC0kHh3BHpxxZok/fHjUVzx2c98=
# =RLJL
# -----END PGP SIGNATURE-----
# gpg: Signature made Fri 01 May 2026 04:53:48 AM CST
# gpg:                using RSA key 6DC4F9C71F29A6FA06B76D33C481DBBC2C051AC4
# gpg: Good signature from "Heinrich Schuchardt <xypron.glpk@gmx.de>" [unknown]
# gpg:                 aka "[jpeg image of size 1389]" [unknown]
# gpg: WARNING: This key is not certified with a trusted signature!
# gpg:          There is no indication that the signature belongs to the owner.
# Primary key fingerprint: 6DC4 F9C7 1F29 A6FA 06B7  6D33 C481 DBBC 2C05 1AC4
2026-05-01 08:12:13 -06:00
Richard Genoud
4c8d2a633e mtd: nand: raw: sunxi_spl: remove user data length reset
No need to reset user data length registers in SPL.

In SPL, only the first user data length register is used, so we don't
need to reset all of them.

Signed-off-by: Richard Genoud <richard.genoud@bootlin.com>
Acked-by: Andre Przywara <andre.przywara@arm.com>
2026-05-01 14:49:44 +02:00
Richard Genoud
dbed35acee mtd: rawnand: sunxi: introduce variable user data length
In Allwinner SoCs, user data can be added in OOB before each ECC data.
For older SoCs like A10, the user data size was the size of a register
(4 bytes) and was mandatory before each ECC step.
So, the A10 OOB Layout is:
[4Bytes USER_DATA_STEP0] [ECC_STEP0 bytes]
[4bytes USER_DATA_STEP1] [ECC_STEP1 bytes]
...
NB: the BBM is stored at the beginning of the USER_DATA_STEP0.

Now, for H6/H616 NAND flash controller, this user data can have a
different size for each step.
So, we are maximizing the user data length to use as many OOB bytes as
possible.

Fixes: 7d1de98011 ("mtd: rawnand: sunxi_spl: add support for H6/H616 nand controller")
Fixes: f163da5e6d ("mtd: rawnand: sunxi: add support for H6/H616 nand controller")
Signed-off-by: Richard Genoud <richard.genoud@bootlin.com>
2026-05-01 14:49:44 +02:00
Richard Genoud
a776cb833d mtd: rawnand: sunxi: clean sunxi_nand_chip_init()
In sunxi_nand_chip_init there's quite a lot of kfree/return, it's easy
to forget a kfree(), so use a goto/kfree instead.

Signed-off-by: Richard Genoud <richard.genoud@bootlin.com>
[Andre: rename goto label, keep return 0;]
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2026-05-01 14:49:37 +02:00
Heinrich Schuchardt
a48ddf81c2 .clang-format: add U-Boot specific for each macros
Formatting via clang-format is controlled by .clang-format.
For each statements should be formatted with a brace at the line end:

    for_each() {
    }

This requires clang-format to know that the symbol is not a function
but a for each macro. We use some for each macros which don't exist in
Linux. Add these to file .clang-format.

Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-01 12:22:38 +02:00
Quentin Schulz
ec45cf3dda doc: bootstd: specify CONFIG_BOOTSTD_DEFAULTS provides network features when NET=y
In the past, we only had one network stack which was called NET. The
network features were enabled for the legacy (and then only) networking
stack since commit 22353fa6b5 ("bootstd: Add some default filesystems
and commands"). Then instead on relying on NET legacy stack for enabling
networking features, the dependencies were (mostly) changed to depend on
CMD_NET in commit a0c739c184 ("boot: Create a common BOOT_DEFAULTS for
distro and bootstd"). Then a new stack (lwIP) appeared, then CMD_NET was
made available with this new stack in commit 98ad145db6 ("net: lwip:
add DHCP support and dhcp commmand") making the networking features
possible to enable and finally commit f1e978fd54 ("boot: Update tests
around network symbols in BOOT_DEFAULTS_CMDS") made it explicit that we
need *a* network stack to enable some networking features.

Align the bootstd documentation with what's actually implemented as
Kconfig dependencies. Note that BOOTSTD_DEFAULTS selects BOOT_DEFAULTS
which selects BOOT_DEFAULTS_CMDS which then selects network features.
The CMDLINE symbol needs to be enabled as well for BOOT_DEFAULTS to
select BOOT_DEFAULTS_CMDS, but I don't think we need to go that far into
explaining what's required to enable some commands.

Reported-by: Simon Glass <sjg@chromium.org>
Closes: https://lore.kernel.org/u-boot/CAFLszTgZC1FGy8965pHiG-u=FhrguftRv41ghQ_Qb_RRXx6tyg@mail.gmail.com/
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
2026-05-01 10:35:06 +02:00
Heinrich Schuchardt
562e41acde doc: .clang-format description
We cannot use .clang-format without modification. For instance U-Boot
has some for each macros that Linux does not have.

Adjust the description.

Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-01 10:33:08 +02:00
Shiva Tripathi
88e888c312 doc: board: ti: k3: Add fTPM support documentation
Add fTPM support documentation including an overview, configuration
steps for RPMB provisioning, OP-TEE TA build instructions, and
verification procedure.

Signed-off-by: Shiva Tripathi <s-tripathi1@ti.com>
2026-05-01 10:30:32 +02:00
Heinrich Schuchardt
82539af483 efi_loader: centralize messaging for efi_init_obj_list
If efi_init_obj_list() fails we cannot use the UEFI sub-system.

* Instead of having messages for this everywhere write an error message
  in efi_init_obj_list().
* Always use (ret != EFI_SUCCESS) when checking the return value of
  efi_init_obj_list().
* Remove the return code from the error message as it does not help
  users to understand which initialization went wrong.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-01 10:30:03 +02:00
Heinrich Schuchardt
257f9f5273 efi_loader: correct efi_binary_run_dp() return value
efi_binary_run_dp() is expected to return an efi_status_t value.

Reported-by: Simon Glass <sjg@chromium.org>
Fixes: 6422820ac3 ("efi_loader: split unrelated code from efi_bootmgr.c")
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-01 10:30:03 +02:00
Heinrich Schuchardt
96b33427ea efi_loader: correct return value of efi_bootmgr_run()
efi_bootmgr_run() is expected to return an efi_status_t value.

Reported-by: Simon Glass <sjg@chromium.org>
Fixes: 0bef4b0123 ("cmd: bootefi: move library interfaces under lib/efi_loader")
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-01 10:30:03 +02:00
Heinrich Schuchardt
7311130b73 cmd/bootefi: move efi_init_obj_list() to the start of do_bootefi
None of the bootefi commands can be executed if the EFI sub-system cannot
be initialized.

Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-01 10:30:03 +02:00
Johannes Krottmayer
c5230a45a7 doc: emulation: qemu-arm: add secure state steps
Add build steps for building U-Boot in secure state with
TF-A and OP-TEE. It includes the full steps for building
OP-TEE and TF-A to use with U-Boot. Also a short description
how to invoke QEMU with enabled EL3 and EL2. EL3 (machine
option secure=on) is required to run TF-A.

Signed-off-by: Johannes Krottmayer <krotti83@proton.me>
Acked-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Cc: Tom Rini <trini@konsulko.com>
Cc: Tuomas Tynkkynen <tuomas.tynkkynen@iki.fi>
2026-05-01 10:29:21 +02:00
Tom Rini
9d06ec9fd4 EFI Loader: Correct dependencies for EFI_HTTP_BOOT
As exposed by "make randconfig", we have an issue with the dependencies
for EFI_HTTP_BOOT. As this is implemented by running commands (as seen
by what it selects) it must depend on CMDLINE as well.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2026-05-01 09:11:07 +02:00
Tom Rini
301bad079b arm: at91: Drop unnecessary BOARD_EARLY_INIT_F usage
All of these platforms enable CONFIG_BOARD_EARLY_INIT_F and then have a
do-nothing board_early_init_f function. Change to not enabling the
option and so not needing an empty function.

Signed-off-by: Tom Rini <trini@konsulko.com>
2026-05-01 10:00:13 +03:00
Richard Genoud
6b33232e32 mtd: rawnand: sunxi: make the code mode self-explanatory
In sunxi_nfc_hw_ecc_{read,write}_chunk(), the ECC step was force to 0,
the reason is not trivial to get when reading the code.

The explanation is that, from the NAND flash controller perspective, we
are indeed at step 0 for user data length and ECC errors.

Just add a const value with an explanation to clarify things.

Signed-off-by: Richard Genoud <richard.genoud@bootlin.com>
Reviewed-By: Michael Trimarchi <michael@amarulasolutions.com>
Acked-by: Andre Przywara <andre.przywara@arm.com>
2026-05-01 00:35:59 +02:00
Richard Genoud
125bba0f61 mtd: rawnand: sunxi: Replace hard coded value by a define
The user data length (4) used all over the code hard coded.
And sometimes, it's not that trivial to know that it's the user data
length and not something else.
Moreover, for the H6/H616 this value is no more fixed by hardware, but
could be modified.

Using a define here makes the code more readable.

Suggested-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Richard Genoud <richard.genoud@bootlin.com>
Acked-by: Andre Przywara <andre.przywara@arm.com>
2026-05-01 00:35:59 +02:00
Yixun Lan
11b5cd22ba spi: sunxi: wait for TX/RX fifo reset done
Once reset SPI TX or RX fifo, the underlying hardware need to take
some time to actually settle down, the two bits will automatically
clear to 0, so use a poll mechanism to check status bits to make sure
it's done correctly.

On Cubie A7A board which using A733 SoC, we encoutered a SPI nor flash
timeout issue, it turns out that the SPI fifo reset take a few time to
settle down, Add a loop to poll the status.

This was the error message shows on A7A board once this issue happened.

=> sf probe
ERROR: sun4i_spi: Timeout transferring data
Failed to initialize SPI flash at 0:0 (error -2)

Signed-off-by: Yixun Lan <dlan@gentoo.org>
Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com>
Acked-by: Andre Przywara <andre.przywara@arm.com>
2026-04-30 23:31:03 +02:00
Andre Przywara
7ad8e387d6 sunxi: H616: dram: drop default TPR6 Kconfig value
CONFIG_DRAM_SUNXI_TPR6 is the only DRAM config parameter that has a
non-zero default value. Since we need to provide a value for all the
other parameters anyway, avoiding TPR6 makes no real difference.
To make matters worse, TPR6 is a compound value covering multiple DRAM
types, but also spans over three SoCs, which makes it hard to find one
good default value.

Drop the default from Kconfig, and put some explicit values in the
defconfigs for the few boards that were relying on the default so far.
The value is taken from one BSP, only the lower byte matters anyway for
those boards, all using DDR3 DRAM.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com>
Reviewed-by: Paul Kocialkowski <paulk@sys-base.io>
2026-04-30 23:31:03 +02:00
Jernej Skrabec
5a24cc0740 sunxi: H616: dram: fix LPDDR3 TPR6 parsing
Allwinner's DRAM initialisation code defines a parameter named TPR6,
presumably containing some "Vref" parameter, but containing values for
*all* DRAM types. The runtime code selects one byte based on the DRAM
type used.
This selection code was wrong for LPDDR3, the value is encoded in
bits [23:16], not [15:8]. Fix that in the code, which also aligns it
with the very similar code for the A133 and A523.

Signed-off-by: Jernej Skrabec <jernej.skrabec@gmail.com>
Reported-by: Philippe Simons <simons.philippe@gmail.com>
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Paul Kocialkowski <paulk@sys-base.io>
2026-04-30 23:31:03 +02:00
Lukas Schmid
9d3bbc99b9 pinctrl: sunxi: add I2C3 mux for D1/T113-s3 (PG10/PG11)
Boards based on the Allwinner D1/T113-s3, such as the
NetCube Systems Nagami, can expose a third I2C controller
on PG10/PG11. However, the sun20i_d1 pinctrl function table
lacked an entry for this mux.

Add the "i2c3" function with mux value 3 on PG10/PG11, allowing device
trees to enable the I2C3 controller.

Signed-off-by: Lukas Schmid <lukas.schmid@netcube.li>
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
2026-04-30 23:31:03 +02:00
Andre Przywara
06b3ae910f sunxi: configs: enable power LEDs on 64-bit boards
We recently gained a simple way to enable a power LED very early in the
SPL boot, through simple Kconfig variables.

Add those symbols to those boards' defconfigs where the DT indicates a
default-on power LED. The number used is <port bank> * 32 + <pin no>,
an active low setup means CONFIG_SPL_SUNXI_LED_STATUS_ACTIVE_HIGH must be
undefined.

This will light up the power LED very early in the (SPL) boot phase on
those 64-bit boards.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Paul Kocialkowski <paulk@sys-base.io>
2026-04-30 23:31:03 +02:00
Andre Przywara
c3297cb93e sunxi: configs: enable power LEDs on 32-bit boards
We recently gained a simple way to enable a power LED very early in the
SPL boot, through simple Kconfig variables.

Add those symbols to those boards' defconfigs where the DT indicates a
default-on power LED. The number used is <port bank> * 32 + <pin no>,
an active low setup means CONFIG_SPL_SUNXI_LED_STATUS_ACTIVE_HIGH must be
undefined. Since its default is "high", we can skip the symbol in the
defconfig in this case.

This will light up the power LED very early in the (SPL) boot phase on
those 32-bit boards.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Paul Kocialkowski <paulk@sys-base.io>
2026-04-30 23:31:02 +02:00
Andre Przywara
dc2427ab20 sunxi: spl: fix SPL_SUNXI_LED active low configuration
The newly introduced Allwinner SPL LED "framework" defined a
SPL_SUNXI_LED_STATUS_STATE Kconfig symbol, that was supposed to denote
the active-low vs. active-high polarity of the LED. However this is
a bool symbol, so it will simply vanish if not defined, and we cannot use
it directly inside a C statement.

Filter the symbol through the IS_ENABLED() macro, which will return 0 if
the symbol is not defined, which is the intended value here.

Since the STATUS_STATE name is a bit confusing, rename it to ACTIVE_HIGH
on the way, because that is its real meaning. Also the LED_STATUS_BIT
name for the GPIO number is similarly a remnant of the old status LED
code, so rename it to LED_STATUS_GPIO as well.

This fixes configuring LEDs with active-low polarity.

Fixes: 256557dd9a ("sunxi: remove usage of legacy LED API")
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Paul Kocialkowski <paulk@sys-base.io>
Closes: https://lore.kernel.org/u-boot/adfMQBPdntWy1KIq@shepard/
Acked-by: Quentin Schulz <quentin.schulz@cherry.de>
2026-04-30 23:31:02 +02:00
Heinrich Schuchardt
2472b31997 sunxi: use vendor prefix for $fdtfile on RISC-V too
Once we complete the support for RISC-V Allwinner D1 (sun20i), we will need
to prefix $fdtfile with the vendor prefix to match the Linux device-tree
directory structure.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Acked-by: Andre Przywara <andre.przywara@arm.com>
2026-04-30 23:31:02 +02:00
Chanhong Jung
b52670d37b gpio: 74x164: use dev_read_* APIs for live-tree compatibility
With CONFIG_OF_LIVE=y, dev_of_offset(dev) does not return a valid
flat-FDT offset, so fdtdec_get_int(gd->fdt_blob, offset, ...) inside
gen_74x164_probe() fails to locate the "registers-number" property and
always falls back to the default value of 1. This results in a 4-chip
74HC595 daisy chain being exposed as only 8 GPIOs instead of 32, and
any consumer referencing offsets >= 8 fails to bind with -ENOENT
("GPIO ... not found" / Error -22).

The "registers-default" property is ignored for the same reason, so
any configured power-on output pattern is silently discarded.

Replace the flat-FDT helpers with dev_read_u32_default() and
dev_read_u8_array_ptr(), which correctly walk both live and flat
trees. This matches how other DM GPIO drivers (e.g. pca953x_gpio.c)
read their per-device properties.

With gd->fdt_blob no longer referenced, also drop the now-unused
DECLARE_GLOBAL_DATA_PTR and <asm/global_data.h> include.

Tested on stm32mp153d-ssonic (CONFIG_OF_LIVE=y) with a 4-chip 74HC595
chain: all 32 GPIOs are now exposed, and 16 consumer LED nodes at
offsets 0..31 bind successfully.

Fixes: 9300f711ba ("dm: gpio: introduce 74x164 driver")
Signed-off-by: Chanhong Jung <happycpu@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-04-30 13:57:49 -06:00
Francesco Dolcini
b5633dddbd rtc: ds1307: Remove legacy non-DM code
The DS1307 driver depends on DM_RTC since commit d425d6056e ("rtc: Add
DM support to ds1307"), remove the related obsolete code.

Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-04-30 13:57:46 -06:00
João Marcos Costa
8ef8dee4f3 scripts/dtc: drop yaml in DT validation
The build issues found in dtc/yamltree were partially mitigated by a
previous commit (807bcd844a: "scripts/dtc: Fix pkg-config behavior under
sysroot"), but upstream dtc simply disabled yaml, and the same should be
done here in order to permanently avoid those issues.

Backport the change below from Linux v5.18 [1]:

ef8795f3f1c ("dt-bindings: kbuild: Use DTB files for validation")

I tested this patch with a couple Yocto builds: u-boot and u-boot-tools,
using the current master branch (rev. "c53b0708f9"), having removed
libyaml-native from u-boot-tools's dependencies.

[1] https://git.kernel.org/linus/ef8795f3f1ce

Signed-off-by: João Marcos Costa <joaomarcos.costa@bootlin.com>
Acked-by: Quentin Schulz <quentin.schulz@cherry.de>
2026-04-30 12:21:47 -06:00
Tom Rini
817653c53d Merge tag 'u-boot-stm32-20260430' of https://source.denx.de/u-boot/custodians/u-boot-stm
- arm; stm32mp2: Factorize TAMP_FWU_BOOT_IDX_MASK/OFFSET definition
- arm: stm32mp: Drop unnecessary BOARD_EARLY_INIT_F usage
- board: stm32mp25: support dynamic A/B bank bootup
- board: stm32pm1: Fix board_check_usb_power()
- clk: stm32: Add STM32MP23 support
- video: stm32: dsi: fix unchecked return values
- video: support Rocktech RK050HR345-CT106A panel
- Remove non-existent STM32_RESET flag
2026-04-30 09:10:18 -06:00
Heinrich Schuchardt
ae1966e243 arm/mach-stm32: don't select non-existent STM32_RESET
Symbol CONFIG_STM32_RESET does not exist.
Don't select it.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:12 +02:00
Dario Binacchi
49e78d1256 video: support Rocktech RK050HR345-CT106A panel
Add support for the Rocktech RK050HR345-CT106A RGB panel. This model
uses an Ilitek ILI9806E controller over the SPI bus for initialization
and register configuration only.

The driver is designed to be easily extensible to support other panels
with different sequences and timings by providing a specific descriptor
structure for each model.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:12 +02:00
Dario Binacchi
723e0360ee spi: stm32: extend support to STM32MP25
The SPI IP in this platform is fully compatible with the current driver
implementation, requiring only a new compatible string.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Dario Binacchi
011feb0028 spi: stm32: add support for bits-per-word setting
Implement the set_wordlen operation to allow dynamic bus width
configuration. This is required for peripherals with non-standard
requirements, such as display panels that need 9-bit word transfers
during the initialization and setup phase.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Dario Binacchi
dd5002856a spi: stm32: add stm32_spi_is_enabled() helper
Add a helper to check the SPE (SPI Enable) bit and replace the
open-coded bitwise check in stm32_spi_stopxfer() with this helper to
improve readability and consistency.

This is also a preparatory step for future driver updates that require
checking the SPI enable state across different code paths.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Dario Binacchi
17c022271d spi: stm32: clean up buffer length assignment
Remove redundant divisions by using the already available xferlen
variable for setting the rx/tx buffer lengths.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Dario Binacchi
2b3a73116a test: dm: spi: add testcase for spi_set_wordlen()
Add a unit test to verify that the SPI word length configuration is
correctly handled by the SPI uclass and successfully passed down to
the sandbox driver.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <simon.glass@canonical.com>
2026-04-30 08:01:11 +02:00
Dario Binacchi
ab5c0191e1 test: spi: add sandbox_spi_get_wordlen interface
Add the sandbox_spi_get_wordlen() public interface to retrieve the
internal word length state of the sandbox SPI device.

This is intended for use in sandbox SPI test cases to verify that
the word length is correctly propagated from the SPI uclass to
the driver.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <simon.glass@canonical.com>
2026-04-30 08:01:11 +02:00
Dario Binacchi
fa1801abc7 spi: sandbox_spi: support wordlen setup
The driver currently ignores the word length configuration. Implement
the set_wordlen operation to store and track the current word length.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <simon.glass@canonical.com>
2026-04-30 08:01:11 +02:00
Dario Binacchi
7b879ddbc5 spi: add support for bits-per-word setting
Allow dynamic configuration of the SPI word length. This is required
for controllers and slaves that need to operate with non-standard
word lengths, such as 9-bit wide transfers.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Simon Glass <simon.glass@canonical.com>
2026-04-30 08:01:11 +02:00
Tom Rini
5ab39c8a66 arm: stm32mp: Drop unnecessary BOARD_EARLY_INIT_F usage
All of these platforms enable CONFIG_BOARD_EARLY_INIT_F and then have a
do-nothing board_early_init_f function. Change to not enabling the
option and so not needing an empty function.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Patrice Chotard
5166658ac6 ARM: stm32mp2: Factorize TAMP_FWU_BOOT_IDX_MASK/OFFSET definition
Factorize TAMP_FWU_BOOT_IDX_MASK and TAMP_FWU_BOOT_IDX_OFFSET
definition which are common to STM32MP1 and STM32MP2 SoCs family.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Patrice Chotard
5a379cca5b clk: stm32: Add STM32MP23 support
Add STM32MP23 support.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Raphaël Gallais-Pou <rgallaispou@gmail.com>
2026-04-30 08:01:11 +02:00
Patrice Chotard
c8f7b41730 spi: add STM32MP23 OSPI support
Add STM32MP23 OSPI support.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Raphael Gallais-Pou
51678d9479 video: stm32: dsi: fix unchecked return values
Fix the following errors yielded by Coverity Scan:

CID 644836:         Error handling issues  (CHECKED_RETURN)
Calling device_chld_unbind without checking return value (as is done elsewhere 6 out of 7 times)
CID 644834:         Error handling issues  (CHECKED_RETURN)
Calling device_chld_remove without checking return value (as is done elsewhere 4 out of 5 times).

Link: https://lore.kernel.org/r/20260309212331.GF1388590@bill-the-cat/
Fixes: a6d047c0a8 ("video: stm32: remove all child of DSI bridge when its probe failed")

Signed-off-by: Raphael Gallais-Pou <rgallaispou@gmail.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
2026-04-30 08:01:11 +02:00
Patrice Chotard
ecde6614bc board: stm32pm1: Fix board_check_usb_power()
Depending of plugged power source (computer, wall charger, ...) it can
happen that we got the following message:

"****************************************************"
"*      USB TYPE-C charger not compliant with       *"
"*                   specification                  *"
"****************************************************"
"                                                    "
"### ERROR ### Please RESET the board ###            "

This issue has been detected on STM32MP135f-DK board.

It's due to max_uV and min_uV value are initialized at beginning of
board_check_usb_power() and can then be used for the 2 iteration of
adc_measurement().
max_uV/min_uV values issued of the first adc_measurement() iteration
are used as input of the second adc_measurement() iteration, which
can lead to incoherent pair of min_uV/max_uV values.

To ensure that adc_measurement() returns coherent value for max_uV and
min_uV, initialize max_uV and min_uV at each loop start.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Kory Maincent <kory.maincent@bootlin.com>
2026-04-30 08:01:11 +02:00
Tom Rini
9d3bc111ef Merge tag 'mediatek-for-master-2026-04-29' of https://source.denx.de/u-boot/custodians/u-boot-mediatek
* MMC fixes for Genio 520/720 (mt8189)
* SPI NOR Flash controller fixes
* SPI NOR Flash support for Genio 520/720
* PMIC controller fixes
* PMIC support for Genio 1200 (mt8195)
* Drop CONFIG_IDENT_STRING to be consistent across the platform
* Remove empty header on mt7622
2026-04-29 17:09:13 -06:00
Tom Rini
6211462c92 Merge branch 'master' of git://source.denx.de/u-boot-usb
- Fix UMS and eMMC HW partition selection
2026-04-29 17:09:13 -06:00
Tom Rini
13b3502157 socfpga: vining: Enable LTO
This platform is often close to the binary size limit and minor changes
lead to exceeding image size. Enable LTO for this platform.

Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Marek Vasut <marex@nabladev.com>
Cc: Tien Fong Chee <tien.fong.chee@altera.com>
2026-04-29 17:09:13 -06:00
Julien Stephan
a97c82bfdf power: pmic: mtk-pwrap: add MT8195 support
Add mt8195 support.

Support comes directly from commit e88edc977b00 ("soc: mediatek: pwrap:
add pwrap driver for MT8195 SoC") from the Linux Kernel.

Signed-off-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-8-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:27:05 -05:00
Julien Stephan
e262eb4cfe power: pmic: mtk-pwrap: use tabs for alignment
Fix mt8188_regs definition to use tabs instead of spaces for alignment
to be consistent with other definitions.

Reviewed-by: Macpaul Lin <macpaul.lin@mediatek.com>
Signed-off-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-7-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:26:52 -05:00
David Lechner
df660cc7b2 power: pmic: mtk-pwrap: use pmic compatible to select child info
Change the logic for selecting pmic_children_info to use the compatible
string from the devicetree instead of expecting the pwrap (part of the
MCU) to correspond to the separate PMIC chip.

In addition to being more correct, it also saves a few lines of code for
each MCU type that is added by dropping the enum and type field.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-6-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:26:48 -05:00
David Lechner
27fdacf420 power: pmic: mtk-pwrap: remove interrupt related code
Remove the interrupt related code in mtk-pwrap driver. This was just
enabling interrupts without any handler.

Even if we did have a handler, the only thing we could do is log a
message. Since U-Boot isn't long running, this likely wouldn't be very
useful.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-5-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:16:01 -05:00
David Lechner
b60d1c5262 power: pmic: mtk-pwrap: drop PWRAP_SLV_CAP_DUALIO on mt6359
Drop the PWRAP_SLV_CAP_DUALIO flag from the mt6359 PMIC definition. The
mt6359p variant of the PMIC does support dual I/O.

Prior to this change, the driver would attempt to write to the
PWRAP_DEW_DIO_EN register, which was not defined, so would write
register 0 (DONE2).

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Reviewed-by: Macpaul Lin <macpaul.lin@mediatek.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-4-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:08:18 -05:00
David Lechner
8c5f5ef2c9 power: pmic: mtk-pwrap: add init capability flag
Add a PWRAP_CAP_INIT capability flag to specify if it is safe to call
pwrap_init() or not. Not all targets define the registers accessed
by pwrap_init(). In that case, it is expected that an earlier bootloader
has already initialized the PMIC. If not, we now return an error instead
of trying to access undefined registers.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-3-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:08:18 -05:00
David Lechner
3996c20956 power: pmic: mtk-pwrap: add PWRAP_CAP_WDT_SRC flag
Add a PWRAP_CAP_WDT_SRC flag to indicate if a PMIC wrapper has a WDT_SRC
or not. Then use this to conditionally enable the watchdog timer.

Prior to this change, since the register was not defined, it defaulted
to 0, so the wrong register (DONE2) was being written to.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-2-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:08:18 -05:00
David Lechner
98116c0ef8 power: pmic: mtk-pwrap: fix file description
Fix the comment at the start of the file to accurately describe what
this file does. The old description was likely copied from the related
regulator driver.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260409-mtk-pmic-fixes-v2-1-73e83aa6345b@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:08:18 -05:00
Weijie Gao
3c14cd8388 configs: mt7622: remove empty header file
Remove the empty include/configs/mt7622.h header file as it is not needed.
The Kconfig entry that referenced it is also removed.

Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
Link: https://patch.msgid.link/20260428033625.109032-1-weijie.gao@mediatek.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-29 09:02:16 -05:00
Marek Vasut
b27a31665d cmd: ums: Switch HW partition before block access
An UMS session with eMMC device specifier "ums C mmc dev.part1,dev.part2"
exposes the same eMMC HW partition 'part2' twice instead of exposing both
HW partitions 'part1' and 'part2'. Fix this by switching the eMMC HW
partition before block device read/write access.

An eMMC is represented by a single struct blk_desc, with the currently
selected HW partition being stored in this struct blk_desc. Each call to
part_get_info_by_dev_and_name_or_num() with partition string dev[.partN]
does trigger HW partition switch by calling blk_get_device_part_str() ->
blk_get_device_part_str() -> get_dev_hwpart() -> get_dev_hwpart() ->
blk_dselect_hwpart(). The ums_init() iterates over the device specifier
string and calls part_get_info_by_dev_and_name_or_num() in a loop for
each dev[.partN] entry used as the partition string. If the device
specifier string contains more than one dev[.partN] partition strings
for the same dev device, then it is the HW partition described in the
last dev[.partN] partition string entry that is accessed for all dev
device partition strings in the device specifier string, because that
last dev[.partN] partition string entry was the last one that triggered
blk_dselect_hwpart() call for that device.

To access the expected HW partition for every dev[.partN] partition string
entry, it is necessary to call blk_dselect_hwpart() before each block read
or write. Store HW partition described for each dev[.partN] partition string
in struct ums and use the stored value to make it so.

The blk_dselect_hwpart() does test whether the currently selected HW
partition is already configured in hardware and does not reconfigure
the hardware if that is the case, therefore for the majority of block
reads and writes, blk_dselect_hwpart() is a no-op with negligible
performance impact.

Example reproducer is listed below. The last sector of both eMMC HW BOOT
partitions is populated with distinct test pattern and UMS is launched:

"
=> mmc dev 1 1 ; mmc read $loadaddr 0x1fff 1 ; md $loadaddr 4
switch to partitions #1, OK
mmc1(part 1) is current device
MMC read: dev # 1, block # 8191, count 1 ... 1 blocks read: OK
84000000: 1234abcd 1234abcd 1234abcd 1234abcd  ..4...4...4...4.

=> mmc dev 1 2 ; mmc read $loadaddr 0x1fff 1 ; md $loadaddr 4
switch to partitions #2, OK
mmc1(part 2) is current device
MMC read: dev # 1, block # 8191, count 1 ... 1 blocks read: OK
84000000: 567890ef 567890ef 567890ef 567890ef  ..xV..xV..xV..xV

=> ums 0 mmc 1.1,1.2
UMS: LUN 0, dev mmc 1, hwpart 1, sector 0x0, count 0x2000
UMS: LUN 1, dev mmc 1, hwpart 2, sector 0x0, count 0x2000
"

Read of the two block devices on host without this fix produces
identical data present in HW BOOT partition 2:

"
$ dd if=/dev/sdX of=mmc-a.bin ; dd if=/dev/sdY of=mmc-b.bin
$ hexdump -C mmc-a.bin | tail -n 3 | head -n 1 ; \
  hexdump -C mmc-b.bin | tail -n 3 | head -n 1
003ffe00  ef 90 78 56 ef 90 78 56  ef 90 78 56 ef 90 78 56  |..xV..xV..xV..xV|
003ffe00  ef 90 78 56 ef 90 78 56  ef 90 78 56 ef 90 78 56  |..xV..xV..xV..xV|
"

Read of the two block devices on host with this fix produces the
expected distinct data from either HW BOOT partition 1 or 2:

"
$ dd if=/dev/sdX of=mmc-a.bin ; dd if=/dev/sdY of=mmc-b.bin
$ hexdump -C mmc-a.bin | tail -n 3 | head -n 1 ; \
  hexdump -C mmc-b.bin | tail -n 3 | head -n 1
003ffe00  cd ab 34 12 cd ab 34 12  cd ab 34 12 cd ab 34 12  |..4...4...4...4.|
003ffe00  ef 90 78 56 ef 90 78 56  ef 90 78 56 ef 90 78 56  |..xV..xV..xV..xV|
"

Reported-by: Christoph Niedermaier <cniedermaier@dh-electronics.com>
Signed-off-by: Marek Vasut <marex@nabladev.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2026-04-29 10:32:04 +02:00
David Lechner
8c15436fb2 configs: mediatek: add required config for SNOR on Genio 520/720 EVK
Enable options to be able to access the SNOR flash on Genio 520/720 EVK
boards.

Reviewed-by: Macpaul Lin <macpaul.lin@mediatek.com>
Link: https://patch.msgid.link/20260406-mtk-genio-720-snor-v1-2-cbfd5fc4e59a@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:19:52 -05:00
David Lechner
f1b077c512 arm: dts: mediatek: add Genio 520/720 SNOR support
Add devicetree nodes needed to enable SNOR support on Genio 520 and 720
EVKs. This is copied from the most recent upstream submission [1] of the
devicetree for these boards, so there should be minimal differences when
we eventually switch to OF_UPSTREAM.

Link: https://lore.kernel.org/linux-mediatek/20251111070031.305281-10-jh.hsu@mediatek.com/ [1]
Link: https://patch.msgid.link/20260406-mtk-genio-720-snor-v1-1-cbfd5fc4e59a@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:19:52 -05:00
Meiker Gao
6c881e9980 spi: mtk_snor: Remove status register write procedure in probe()
Remove status register write procedure in probe(). This is handled in
spi-nor-core by the SPI_NOR_HAS_LOCK flag.

Signed-off-by: Meiker Gao <ot_meiker.gao@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-8-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:16:32 -05:00
Macpaul Lin
28bd639677 spi: mtk_snor: fix zeroed data in DMA read bounce path
Implement proper bounce buffer handling for the read path to fix zeroed
data when using DMA. In the bounce path, map the bounce buffer with
dma_map_single(), perform DMA using bounce_dma, then copy data from the
bounce buffer to the user buffer, and finally unmap with
dma_unmap_single().

Signed-off-by: Macpaul Lin <macpaul.lin@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-7-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:11:19 -05:00
Noah.Shen
1cfcd7100d spi: mtk_snor: support newer SOCs
Add support for some newer SOCs. New compatible strings are added to the
lookup table. Some SOCs also need a extra bit clocked out as a hardware
quirk, so a new capability structure and code is added to support that.

Signed-off-by: Noah.Shen <noah.shen@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-6-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:11:19 -05:00
Noah.Shen
78950bb207 spi: mtk-snor: add bounds checking in mtk_snor_cmd_program()
Add bounds checking of the various lengths in mtk_snor_cmd_program() to
prevent reading or writing registers out of bounds.

Signed-off-by: Noah.Shen <noah.shen@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-5-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:11:19 -05:00
Noah.Shen
55944a68d5 spi: mtk_snor: check return value of mtk_snor_cmd_exec()
Always check the return value of mtk_snor_cmd_exec() and propagate the
error.

Signed-off-by: Noah.Shen <noah.shen@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-4-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:11:19 -05:00
Noah.Shen
3b0a037052 spi: mtk_snor: conditionally copy tx/rx data
Only write out data for OUT command and read in data for IN commands.

Signed-off-by: Noah.Shen <noah.shen@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-3-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:11:19 -05:00
Noah.Shen
4eac47d4eb spi: mtk_snor: avoid alloc in mtk_snor_cmd_program()
Rework mtk_snor_cmd_program() to avoid allocating a temporary buffer
for tx data. This improves performance a bit by avoiding the need to
allocate memory and copy data an extra time.

Signed-off-by: Noah.Shen <noah.shen@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-2-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:11:19 -05:00
Noah.Shen
4f9842e479 spi: mtk_snor: clean up comments
Avoid use of C++-style comments and fix multi-line comment style.

Signed-off-by: Noah.Shen <noah.shen@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260406-mtk-spi-nor-improvements-v1-1-66f675cbbd3e@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 13:11:19 -05:00
David Lechner
95c06da44f configs: mediatek: mt8395_genio_1200_evk_ufs: remove CONFIG_IDENT_STRING
Remove CONFIG_IDENT_STRING from the mt8395_genio_1200_evk_ufs defconfig.
This makes it consistent with other mediatek defconfigs and frees the
option for use by downstream users. This only affects the version string
printed by U-Boot, so it doesn't have any functional impact.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mtk-configs-remove-ident-string-v1-5-66d5fc3d67be@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:53:35 -05:00
David Lechner
eb1551fddc configs: mediatek: mt8395_genio_1200_evk: remove CONFIG_IDENT_STRING
Remove CONFIG_IDENT_STRING from the mt8395_genio_1200_evk defconfig.
This makes it consistent with other mediatek defconfigs and frees the
option for use by downstream users. This only affects the version string
printed by U-Boot, so it doesn't have any functional impact.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mtk-configs-remove-ident-string-v1-4-66d5fc3d67be@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:53:35 -05:00
David Lechner
9b471cb9b2 configs: mediatek: mt8390_genio_700_evk: remove CONFIG_IDENT_STRING
Remove CONFIG_IDENT_STRING from the mt8390_genio_700_evk defconfig. This
makes it consistent with other mediatek defconfigs and frees the option
for use by downstream users. This only affects the version string
printed by U-Boot, so it doesn't have any functional impact.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mtk-configs-remove-ident-string-v1-3-66d5fc3d67be@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:53:35 -05:00
David Lechner
4c435a7ffb configs: mediatek: mt8370_genio_510_evk: remove CONFIG_IDENT_STRING
Remove CONFIG_IDENT_STRING from the mt8370_genio_510_evk defconfig. This
makes it consistent with other mediatek defconfigs and frees the option
for use by downstream users. This only affects the version string
printed by U-Boot, so it doesn't have any functional impact.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mtk-configs-remove-ident-string-v1-2-66d5fc3d67be@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:53:35 -05:00
David Lechner
ba97dd5c10 configs: mediatek: mt8365_evk: remove CONFIG_IDENT_STRING
Remove CONFIG_IDENT_STRING from the mt8365_evk defconfig. This makes it
consistent with other mediatek defconfigs and frees the option for use
by downstream users. This only affects the version string printed by
U-Boot, so it doesn't have any functional impact.

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mtk-configs-remove-ident-string-v1-1-66d5fc3d67be@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:53:35 -05:00
ht.lin
8436dd6b0e mmc: mtk-sd: fix msdc cmd ready check
Correct the check condition in msdc_cmd_is_ready() for MSDC_PS_DAT0
polling. Without this change, it may not be able to detect if the SD
controller is busy correctly for issuing the command.

Fixes: d24b693959 ("mmc: mtk-sd: add SD/MMC host controller driver for MT7623 SoC")
Signed-off-by: ht.lin <ht.lin@mediatek.com>
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Tested-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mmc-mtk-sd-fixes-v1-3-5b840c546af2@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:45:07 -05:00
David Lechner
93f67d893b mmc: mtk-sd: enable async_fifo_crcsts on mt8189
Enable the async_fifo_crcsts option for mediatek,mt8189-mmc compatible.

Without this option, writing will fail in HS200 mode.

Fixes: b3d16267b5 ("mmc: mtk-sd: add mediatek,mt8189-mmc compatible")
Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Tested-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mmc-mtk-sd-fixes-v1-2-5b840c546af2@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:45:07 -05:00
David Lechner
336602a2f9 mmc: mtk-sd: enable DMA on mediatek,mt8189-mmc
Enable DMA on mediatek,mt8189-mmc compatible. The issue that was
preventing DMA from working correctly was fixed by the
get_effective_memsize() implementation in commit a7c682565b ("arm:
mediatek: add support of MT8189 SoC family").

Reviewed-by: Julien Stephan <jstephan@baylibre.com>
Tested-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20260421-mmc-mtk-sd-fixes-v1-1-5b840c546af2@baylibre.com
Signed-off-by: David Lechner <dlechner@baylibre.com>
2026-04-28 10:45:07 -05:00
1307 changed files with 11951 additions and 12400 deletions

View File

@@ -748,6 +748,57 @@ ForEachMacros:
- 'ynl_attr_for_each_nested'
- 'ynl_attr_for_each_payload'
- 'zorro_for_each_dev'
# U-Boot specific
- '__for_each_child_of_node'
- '__usbhs_for_each_pipe'
- '__usbhsg_for_each_uep'
- '_for_each_zynqmp_part'
- 'alist_for_each'
- 'alist_for_each_filter'
- 'cvmx_coremask_for_each_core'
- 'cvmx_coremask_for_each_node'
- 'dev_for_each_property'
- 'dev_for_each_subnode'
- 'expr_list_for_each_sym'
- 'fdt_for_each_node_by_compatible'
- 'fdt_for_each_property_offset'
- 'fdt_for_each_subnode'
- 'for_each_bin_hdr_v0'
- 'for_each_bl_params_node'
- 'for_each_child_withdel'
- 'for_each_console_dev'
- 'for_each_ext_hdr_v0'
- 'for_each_label'
- 'for_each_label_withdel'
- 'for_each_marker'
- 'for_each_marker_of_type'
- 'for_each_memory_map_entry_reversed'
- 'for_each_mmc_mode_by_pref'
- 'for_each_opt_hdr_v1'
- 'for_each_property_withdel'
- 'for_each_sd_mode_by_pref'
- 'for_each_supported_width'
- 'for_each_tpm_device'
- 'for_each_w1_device'
- 'for_each_zynqmp_image'
- 'for_each_zynqmp_part'
- 'for_each_zynqmp_part_in_image'
- 'mtd_for_each_device'
- 'ofnode_for_each_compatible_node'
- 'ofnode_for_each_prop'
- 'ofnode_for_each_subnode'
- 'pko_for_each_port'
- 'sfi_for_each_mentry'
- 'ubi_for_each_free_peb'
- 'ubi_for_each_protected_peb'
- 'ubi_for_each_scrub_peb'
- 'ubi_for_each_used_peb'
- 'ubi_rb_for_each_entry'
- 'usbhs_for_each_dfifo'
- 'usbhs_for_each_pipe'
- 'usbhs_for_each_pipe_with_dcp'
- 'usbhsg_for_each_uep'
- 'usbhsg_for_each_uep_with_dcp'
IncludeBlocks: Preserve
IncludeCategories:

View File

@@ -153,20 +153,13 @@ Raspberry Pi 4 (rpi_arm64):
LABGRID_EXPORTER: "sage-exporter-rpi4-1"
LG_PLACE: "rpi4-1"
TEST_PY_BD: "rpi_arm64"
OVERRIDE: "-a UNIT_TEST -a ~CMD_EFIDEBUG -a CMD_BOOTMENU -a CMD_LOG -a ~CMD_BOOTEFI_SELFTEST -a CMD_TFTPPUT -a FIT -a FIT_SIGNATURE -a FIT_BEST_MATCH -a SYS_BOOTM_LEN=0x4000000 -a BOOTSTAGE -a BOOTSTAGE_STASH -a CMD_BOOTSTAGE -a BOOTSTAGE_STASH_ADDR=0x02400000"
Raspberry Pi 4 (rpi_arm64, lwIP):
<<: *sage_lab_dfn
needs: [ "Raspberry Pi 4 (rpi_arm64)" ]
variables:
LABGRID_EXPORTER: "sage-exporter-rpi4-1"
LG_PLACE: "rpi4-1"
TEST_PY_BD: "rpi_arm64"
OVERRIDE: "-a UNIT_TEST -a ~CMD_EFIDEBUG -a CMD_BOOTMENU -a CMD_LOG -a ~CMD_BOOTEFI_SELFTEST -a FIT -a FIT_SIGNATURE -a FIT_BEST_MATCH -a SYS_BOOTM_LEN=0x4000000 -a BOOTSTAGE -a BOOTSTAGE_STASH -a CMD_BOOTSTAGE -a BOOTSTAGE_STASH_ADDR=0x02400000 -a NET_LWIP"
# DHCP is not being run first, needs to be investigated.
TEST_PY_TEST_SPEC: "not test_efi_helloworld_net_http"
OVERRIDE: "-a UNIT_TEST -a ~CMD_EFIDEBUG -a CMD_BOOTMENU -a CMD_LOG -a ~CMD_BOOTEFI_SELFTEST -a FIT -a FIT_SIGNATURE -a FIT_BEST_MATCH -a SYS_BOOTM_LEN=0x4000000 -a BOOTSTAGE -a BOOTSTAGE_STASH -a CMD_BOOTSTAGE -a BOOTSTAGE_STASH_ADDR=0x02400000"
Raspberry Pi 4 (rpi_4_32b):
<<: *sage_lab_dfn
needs: [ "Raspberry Pi 4 (rpi_arm64, lwIP)" ]
needs: [ "Raspberry Pi 4 (rpi_arm64)" ]
variables:
LABGRID_EXPORTER: "sage-exporter-rpi4-1"
LG_PLACE: "rpi4-1"
@@ -197,20 +190,13 @@ Raspberry Pi 3 (rpi_arm64):
LABGRID_EXPORTER: "sage-exporter-rpi3-1"
LG_PLACE: "rpi3-1"
TEST_PY_BD: "rpi_arm64"
OVERRIDE: "-a UNIT_TEST -a ~CMD_EFIDEBUG -a CMD_BOOTMENU -a CMD_LOG -a ~CMD_BOOTEFI_SELFTEST -a CMD_TFTPPUT -a FIT -a FIT_SIGNATURE -a FIT_BEST_MATCH -a SYS_BOOTM_LEN=0x4000000 -a BOOTSTAGE -a BOOTSTAGE_STASH -a CMD_BOOTSTAGE -a BOOTSTAGE_STASH_ADDR=0x02400000"
Raspberry Pi 3 (rpi_arm64, lwIP):
<<: *sage_lab_dfn
needs: [ "Raspberry Pi 3 (rpi_arm64)" ]
variables:
LABGRID_EXPORTER: "sage-exporter-rpi3-1"
LG_PLACE: "rpi3-1"
TEST_PY_BD: "rpi_arm64"
OVERRIDE: "-a UNIT_TEST -a ~CMD_EFIDEBUG -a CMD_BOOTMENU -a CMD_LOG -a ~CMD_BOOTEFI_SELFTEST -a FIT -a FIT_SIGNATURE -a FIT_BEST_MATCH -a SYS_BOOTM_LEN=0x4000000 -a BOOTSTAGE -a BOOTSTAGE_STASH -a CMD_BOOTSTAGE -a BOOTSTAGE_STASH_ADDR=0x02400000 -a NET_LWIP"
# DHCP is not being run first, needs to be investigated.
TEST_PY_TEST_SPEC: "not test_efi_helloworld_net_http"
OVERRIDE: "-a UNIT_TEST -a ~CMD_EFIDEBUG -a CMD_BOOTMENU -a CMD_LOG -a ~CMD_BOOTEFI_SELFTEST -a FIT -a FIT_SIGNATURE -a FIT_BEST_MATCH -a SYS_BOOTM_LEN=0x4000000 -a BOOTSTAGE -a BOOTSTAGE_STASH -a CMD_BOOTSTAGE -a BOOTSTAGE_STASH_ADDR=0x02400000"
Raspberry Pi 3 (rpi_3_32b):
<<: *sage_lab_dfn
needs: [ "Raspberry Pi 3 (rpi_arm64, lwIP)" ]
needs: [ "Raspberry Pi 3 (rpi_arm64)" ]
variables:
LABGRID_EXPORTER: "sage-exporter-rpi3-1"
LG_PLACE: "rpi3-1"

View File

@@ -137,6 +137,7 @@ Sean Anderson <sean.anderson@linux.dev> <sean.anderson@seco.com>
Shaohui Xie <Shaohui.Xie@freescale.com>
Shravya Kumbham <shravya.kumbham@amd.com> <shravya.kumbham@xilinx.com>
Shubhrajyoti Datta <shubhrajyoti.datta@amd.com> <shubhrajyoti.datta@xilinx.com>
Simon Glass <sjg@chromium.org> <simon.glass@canonical.com>
Siva Durga Prasad Paladugu <siva.durga.prasad.paladugu@amd.com> <siva.durga.paladugu@xilinx.com>
Siva Durga Prasad Paladugu <siva.durga.prasad.paladugu@amd.com> <sivadur@xilinx.com>
Srinivas Goud <srinivas.goud@amd.com> <srinivas.goud@xilinx.com>

View File

@@ -133,15 +133,22 @@ F: drivers/mmc/snps_dw_mmc.c
APPLE M1 SOC SUPPORT
M: Mark Kettenis <kettenis@openbsd.org>
R: Janne Grunau <j@jannau.net>
S: Maintained
F: arch/arm/include/asm/arch-apple/
F: arch/arm/mach-apple/
F: board/apple/
F: configs/apple_m1_defconfig
F: doc/board/apple/
F: drivers/input/apple_spi_kbd.c
F: drivers/iommu/apple_dart.c
F: drivers/mailbox/apple-mbox.c
F: drivers/nvme/nvme_apple.c
F: drivers/pci/pcie_apple.c
F: drivers/phy/phy-apple-atc.c
F: drivers/pinctrl/pinctrl-apple.c
F: drivers/power/domain/apple-pmgr.c
F: drivers/spi/apple_spi.c
F: drivers/watchdog/apple_wdt.c
F: include/configs/apple.h
@@ -1109,7 +1116,7 @@ EFI CLIENT
M: Simon Glass <sjg@chromium.org>
M: Heinrich Schuchardt <xypron.glpk@gmx.de>
S: Maintained
W: https://docs.u-boot.org/en/latest/develop/uefi/u-boot_on_efi.html
W: https://docs.u-boot-project.org/en/latest/develop/uefi/u-boot_on_efi.html
F: board/efi/efi-x86_app
F: configs/efi-x86_app*
F: doc/develop/uefi/u-boot_on_efi.rst
@@ -1499,6 +1506,7 @@ T: git https://source.denx.de/u-boot/custodians/u-boot-nios.git
F: arch/nios2/
NVMe
M: Neil Armstrong <neil.armstrong@linaro.org>
M: Bin Meng <bmeng.cn@gmail.com>
S: Maintained
F: drivers/nvme/

View File

@@ -3,7 +3,7 @@
VERSION = 2026
PATCHLEVEL = 07
SUBLEVEL =
EXTRAVERSION = -rc1
EXTRAVERSION = -rc3
NAME =
# *DOCUMENTATION*
@@ -1578,6 +1578,9 @@ spl/u-boot-spl.srec: spl/u-boot-spl FORCE
%.scif: %.srec
$(Q)$(MAKE) $(build)=arch/arm/mach-renesas $@
%.shdr: %.srec
$(Q)$(MAKE) $(build)=arch/arm/mach-renesas $@
OBJCOPYFLAGS_u-boot-nodtb.bin := -O binary \
$(if $(CONFIG_X86_16BIT_INIT),-R .start16 -R .resetvec) \
$(if $(CONFIG_MPC85XX_HAVE_RESET_VECTOR),$(if $(CONFIG_OF_SEPARATE),-R .bootpg -R .resetvec))
@@ -1682,7 +1685,7 @@ cmd_binman = $(srctree)/tools/binman/binman $(if $(BINMAN_DEBUG),-D) \
build -u -d $(binman_dtb) -O . -m \
--allow-missing --fake-ext-blobs \
$(if $(BINMAN_ALLOW_MISSING),--ignore-missing) \
-I . -I $(srctree) -I $(srctree)/board/$(BOARDDIR) \
-I . -I $(srctree)/board/$(BOARDDIR) -I $(srctree) \
$(foreach f,$(of_list_dirs),-I $(f)) -a of-list=$(of_list) \
$(foreach f,$(BINMAN_INDIRS),-I $(f)) \
-a atf-bl1-path=${BL1} \

94
README
View File

@@ -628,98 +628,6 @@ The following options need to be configured:
If you do not have i2c muxes on your board, omit this define.
- Legacy I2C Support:
If you use the software i2c interface (CONFIG_SYS_I2C_SOFT)
then the following macros need to be defined (examples are
from include/configs/lwmon.h):
I2C_INIT
(Optional). Any commands necessary to enable the I2C
controller or configure ports.
eg: #define I2C_INIT (immr->im_cpm.cp_pbdir |= PB_SCL)
I2C_ACTIVE
The code necessary to make the I2C data line active
(driven). If the data line is open collector, this
define can be null.
eg: #define I2C_ACTIVE (immr->im_cpm.cp_pbdir |= PB_SDA)
I2C_TRISTATE
The code necessary to make the I2C data line tri-stated
(inactive). If the data line is open collector, this
define can be null.
eg: #define I2C_TRISTATE (immr->im_cpm.cp_pbdir &= ~PB_SDA)
I2C_READ
Code that returns true if the I2C data line is high,
false if it is low.
eg: #define I2C_READ ((immr->im_cpm.cp_pbdat & PB_SDA) != 0)
I2C_SDA(bit)
If <bit> is true, sets the I2C data line high. If it
is false, it clears it (low).
eg: #define I2C_SDA(bit) \
if(bit) immr->im_cpm.cp_pbdat |= PB_SDA; \
else immr->im_cpm.cp_pbdat &= ~PB_SDA
I2C_SCL(bit)
If <bit> is true, sets the I2C clock line high. If it
is false, it clears it (low).
eg: #define I2C_SCL(bit) \
if(bit) immr->im_cpm.cp_pbdat |= PB_SCL; \
else immr->im_cpm.cp_pbdat &= ~PB_SCL
I2C_DELAY
This delay is invoked four times per clock cycle so this
controls the rate of data transfer. The data rate thus
is 1 / (I2C_DELAY * 4). Often defined to be something
like:
#define I2C_DELAY udelay(2)
CONFIG_SOFT_I2C_GPIO_SCL / CONFIG_SOFT_I2C_GPIO_SDA
If your arch supports the generic GPIO framework (asm/gpio.h),
then you may alternatively define the two GPIOs that are to be
used as SCL / SDA. Any of the previous I2C_xxx macros will
have GPIO-based defaults assigned to them as appropriate.
You should define these to the GPIO value as given directly to
the generic GPIO functions.
CFG_SYS_I2C_NOPROBES
This option specifies a list of I2C devices that will be skipped
when the 'i2c probe' command is issued.
e.g.
#define CFG_SYS_I2C_NOPROBES {0x50,0x68}
will skip addresses 0x50 and 0x68 on a board with one I2C bus
CONFIG_SOFT_I2C_READ_REPEATED_START
defining this will force the i2c_read() function in
the soft_i2c driver to perform an I2C repeated start
between writing the address pointer and reading the
data. If this define is omitted the default behaviour
of doing a stop-start sequence will be used. Most I2C
devices can use either method, but some require one or
the other.
- SPI Support: CONFIG_SPI
Enables SPI driver (so far only tested with
@@ -2373,5 +2281,5 @@ Contributing
The U-Boot projects depends on contributions from the user community.
If you want to participate, please, have a look at the 'General'
section of https://docs.u-boot.org/en/latest/develop/index.html
section of https://docs.u-boot-project.org/en/latest/develop/index.html
where we describe coding standards and the patch submission process.

View File

@@ -1082,6 +1082,7 @@ config ARCH_APPLE
imply CMD_GPT
imply BOOTSTD_FULL
imply OF_HAS_PRIOR_STAGE
imply OF_UPSTREAM
config ARCH_OWL
bool "Actions Semi OWL SoCs"

View File

@@ -810,8 +810,10 @@ __weak void mmu_setup(void)
el = current_el();
set_ttbr_tcr_mair(el, gd->arch.tlb_addr, get_tcr(NULL, NULL),
MEMORY_ATTRIBUTES);
}
/* enable the mmu */
void mmu_enable(void)
{
set_sctlr(get_sctlr() | CR_M);
}
@@ -881,6 +883,7 @@ void dcache_enable(void)
if (!mmu_status()) {
__asm_invalidate_tlb_all();
mmu_setup();
mmu_enable();
}
/* Set up page tables only once (it is done also by mmu_setup()) */

View File

@@ -1143,7 +1143,7 @@ int arch_early_init_r(void)
#ifdef CONFIG_SYS_HAS_SERDES
fsl_serdes_init();
#endif
#ifdef CONFIG_SYS_FSL_HAS_RGMII
#if defined(CONFIG_SYS_FSL_HAS_RGMII) && defined(CONFIG_FSL_MC_ENET)
/* some dpmacs in armv8a based freescale layerscape SOCs can be
* configured via both serdes(sgmii, 10gbase-r, xlaui etc) bits and via
* EC*_PMUX(rgmii) bits in RCW.
@@ -1158,6 +1158,10 @@ int arch_early_init_r(void)
* function of SOC, the dpmac will be enabled as RGMII even if it was
* also enabled before as SGMII. If ECx_PMUX is not configured for
* RGMII, DPMAC will remain configured as SGMII from fsl_serdes_init().
*
* fsl_rgmii_init() itself is only built under CONFIG_FSL_MC_ENET
* (drivers/net/ldpaa_eth/); gate the call the same way so builds
* without MC-ENET still link.
*/
fsl_rgmii_init();
#endif
@@ -1549,7 +1553,8 @@ void lmb_arch_add_memory(void)
gd->arch.resv_ram < ram_start + ram_size)
ram_size = gd->arch.resv_ram - ram_start;
#endif
lmb_add(ram_start, ram_size);
if (ram_size > 0)
lmb_add(ram_start, ram_size);
}
}
#endif

View File

@@ -32,13 +32,6 @@ dtb-$(CONFIG_TARGET_A5Y17LTE) += exynos78x0-axy17lte.dtb
dtb-$(CONFIG_TARGET_A3Y17LTE) += exynos78x0-axy17lte.dtb
dtb-$(CONFIG_TARGET_A7Y17LTE) += exynos78x0-axy17lte.dtb
dtb-$(CONFIG_ARCH_APPLE) += \
t8103-j274.dtb \
t8103-j293.dtb \
t8103-j313.dtb \
t8103-j456.dtb \
t8103-j457.dtb
dtb-$(CONFIG_ARCH_DAVINCI) += \
da850-lcdk.dtb \
da850-lego-ev3.dtb
@@ -907,11 +900,7 @@ dtb-$(CONFIG_RZA1) += \
r7s72100-gr-peach.dtb
dtb-$(CONFIG_RCAR_GEN5) += \
r8a78000-ironhide.dtb
ifdef CONFIG_RCAR_GEN5
DTC_FLAGS += -R 4 -p 0x1000
endif
r8a78000-ironhide-cm33.dtb
dtb-$(CONFIG_TARGET_AT91SAM9261EK) += at91sam9261ek.dtb

View File

@@ -17,7 +17,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q128a {
dflash0: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -25,7 +25,7 @@
spi-max-frequency = <1000000>; /* input clock */
};
dflash1: sst25wf040b {
dflash1: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -33,7 +33,7 @@
reg = <1>;
};
dflash2: en25s64 {
dflash2: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -48,7 +48,7 @@
clocks = <&sysclk>;
};
dspi0: dspi@2100000 {
dspi0: spi@2100000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -178,7 +178,7 @@
clocks = <&clockgen 4 0>;
};
qspi: quadspi@1550000 {
qspi: spi@1550000 {
compatible = "fsl,ls1021a-qspi";
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -26,29 +26,29 @@
bus-num = <0>;
status = "okay";
dflash0: sst25wf040b {
dflash0: sst25wf040b@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash1: en25s64 {
dflash1: en25s64@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash2: n25q128a {
dflash2: n25q128a@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
@@ -60,29 +60,29 @@
bus-num = <0>;
status = "okay";
dflash3: sst25wf040b {
dflash3: sst25wf040b@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash4: en25s64 {
dflash4: en25s64@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash5: n25q128a {
dflash5: n25q128a@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
@@ -94,10 +94,10 @@
bus-num = <0>;
status = "okay";
dflash8: en25s64 {
dflash8: en25s64@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;

View File

@@ -21,7 +21,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q128a {
dflash0: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -31,7 +31,7 @@
reg = <0>;
};
dflash1: sst25wf040b {
dflash1: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -41,7 +41,7 @@
reg = <1>;
};
dflash2: en25s64 {
dflash2: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -28,7 +28,7 @@
bus-num = <0>;
status = "okay";
dspiflash: n25q12a {
dspiflash: n25q12a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -54,7 +54,7 @@
clocks = <&sysclk>;
};
dspi0: dspi@2100000 {
dspi0: spi@2100000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -67,7 +67,7 @@
status = "disabled";
};
dspi1: dspi@2110000 {
dspi1: spi@2110000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -306,7 +306,7 @@
clock-names = "ipg";
status = "disabled";
};
qspi: quadspi@1550000 {
qspi: spi@1550000 {
compatible = "fsl,ls1021a-qspi";
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -21,7 +21,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q128a {
dflash0: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -31,7 +31,7 @@
reg = <0>;
};
dflash1: sst25wf040b {
dflash1: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -41,7 +41,7 @@
reg = <1>;
};
dflash2: en25s64 {
dflash2: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -54,7 +54,7 @@
clocks = <&sysclk>;
};
dspi0: dspi@2100000 {
dspi0: spi@2100000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -67,7 +67,7 @@
status = "disabled";
};
dspi1: dspi@2110000 {
dspi1: spi@2110000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -311,7 +311,7 @@
status = "disabled";
};
qspi: quadspi@1550000 {
qspi: spi@1550000 {
compatible = "fsl,ls1021a-qspi";
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -0,0 +1,9 @@
// SPDX-License-Identifier: GPL-2.0+
/*
* Copyright 2024 NXP
*
*/
#include <config.h>
#include "fsl-ls1088a-qds-u-boot.dtsi"

View File

@@ -0,0 +1,9 @@
// SPDX-License-Identifier: GPL-2.0+
/*
* Copyright 2024 NXP
*
*/
#include <config.h>
#include "fsl-ls1088a-qds-u-boot.dtsi"

View File

@@ -144,7 +144,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q128a {
dflash0: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -152,7 +152,7 @@
spi-max-frequency = <1000000>; /* input clock */
};
dflash1: sst25wf040b {
dflash1: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -160,7 +160,7 @@
reg = <1>;
};
dflash2: en25s64 {
dflash2: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -18,11 +18,3 @@
ethernet9 = &dpmac1;
};
};
&i2c0 {
uc: board-controller@7e {
compatible = "traverse,ten64-controller";
reg = <0x7e>;
};
};

View File

@@ -1,388 +0,0 @@
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
/*
* Device Tree file for Traverse Technologies Ten64
* (LS1088A) board
* Based on fsl-ls1088a-rdb.dts
* Copyright 2017-2020 NXP
* Copyright 2019-2023 Traverse Technologies
*
* Author: Mathew McBride <matt@traverse.com.au>
*/
/dts-v1/;
#include "fsl-ls1088a.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
/ {
model = "Traverse Ten64";
compatible = "traverse,ten64", "fsl,ls1088a";
aliases {
serial0 = &duart0;
serial1 = &duart1;
};
chosen {
stdout-path = "serial0:115200n8";
};
buttons {
compatible = "gpio-keys";
/* Fired by system controller when
* external power off (e.g ATX Power Button)
* asserted
*/
button-powerdn {
label = "External Power Down";
gpios = <&gpio1 17 GPIO_ACTIVE_LOW>;
linux,code = <KEY_POWER>;
};
/* Rear Panel 'ADMIN' button (GPIO_H) */
button-admin {
label = "ADMIN button";
gpios = <&gpio3 8 GPIO_ACTIVE_HIGH>;
linux,code = <KEY_WPS_BUTTON>;
};
};
leds {
compatible = "gpio-leds";
led-0 {
label = "ten64:green:sfp1:down";
gpios = <&gpio3 11 GPIO_ACTIVE_HIGH>;
};
led-1 {
label = "ten64:green:sfp2:up";
gpios = <&gpio3 12 GPIO_ACTIVE_HIGH>;
};
led-2 {
label = "ten64:admin";
gpios = <&sfpgpio 12 GPIO_ACTIVE_HIGH>;
};
};
sfp_xg0: dpmac2-sfp {
compatible = "sff,sfp";
i2c-bus = <&sfplower_i2c>;
tx-fault-gpios = <&sfpgpio 0 GPIO_ACTIVE_HIGH>;
tx-disable-gpios = <&sfpgpio 1 GPIO_ACTIVE_HIGH>;
mod-def0-gpios = <&sfpgpio 2 GPIO_ACTIVE_LOW>;
los-gpios = <&sfpgpio 3 GPIO_ACTIVE_HIGH>;
maximum-power-milliwatt = <2000>;
};
sfp_xg1: dpmac1-sfp {
compatible = "sff,sfp";
i2c-bus = <&sfpupper_i2c>;
tx-fault-gpios = <&sfpgpio 4 GPIO_ACTIVE_HIGH>;
tx-disable-gpios = <&sfpgpio 5 GPIO_ACTIVE_HIGH>;
mod-def0-gpios = <&sfpgpio 6 GPIO_ACTIVE_LOW>;
los-gpios = <&sfpgpio 7 GPIO_ACTIVE_HIGH>;
maximum-power-milliwatt = <2000>;
};
};
/* XG1 - Upper SFP */
&dpmac1 {
sfp = <&sfp_xg1>;
pcs-handle = <&pcs1>;
phy-connection-type = "10gbase-r";
managed = "in-band-status";
};
/* XG0 - Lower SFP */
&dpmac2 {
sfp = <&sfp_xg0>;
pcs-handle = <&pcs2>;
phy-connection-type = "10gbase-r";
managed = "in-band-status";
};
/* DPMAC3..6 is GE4 to GE8 */
&dpmac3 {
phy-handle = <&mdio1_phy5>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs3_0>;
};
&dpmac4 {
phy-handle = <&mdio1_phy6>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs3_1>;
};
&dpmac5 {
phy-handle = <&mdio1_phy7>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs3_2>;
};
&dpmac6 {
phy-handle = <&mdio1_phy8>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs3_3>;
};
/* DPMAC7..10 is GE0 to GE3 */
&dpmac7 {
phy-handle = <&mdio1_phy1>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs7_0>;
};
&dpmac8 {
phy-handle = <&mdio1_phy2>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs7_1>;
};
&dpmac9 {
phy-handle = <&mdio1_phy3>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs7_2>;
};
&dpmac10 {
phy-handle = <&mdio1_phy4>;
phy-connection-type = "qsgmii";
managed = "in-band-status";
pcs-handle = <&pcs7_3>;
};
&duart0 {
status = "okay";
};
&duart1 {
status = "okay";
};
&emdio1 {
status = "okay";
mdio1_phy5: ethernet-phy@c {
reg = <0xc>;
};
mdio1_phy6: ethernet-phy@d {
reg = <0xd>;
};
mdio1_phy7: ethernet-phy@e {
reg = <0xe>;
};
mdio1_phy8: ethernet-phy@f {
reg = <0xf>;
};
mdio1_phy1: ethernet-phy@1c {
reg = <0x1c>;
};
mdio1_phy2: ethernet-phy@1d {
reg = <0x1d>;
};
mdio1_phy3: ethernet-phy@1e {
reg = <0x1e>;
};
mdio1_phy4: ethernet-phy@1f {
reg = <0x1f>;
};
};
&esdhc {
status = "okay";
};
&i2c0 {
status = "okay";
sfpgpio: gpio@76 {
compatible = "ti,tca9539";
reg = <0x76>;
#gpio-cells = <2>;
gpio-controller;
admin_led_lower {
gpio-hog;
gpios = <13 GPIO_ACTIVE_HIGH>;
output-low;
};
};
at97sc: tpm@29 {
compatible = "atmel,at97sc3204t";
reg = <0x29>;
};
};
&i2c2 {
status = "okay";
rx8035: rtc@32 {
compatible = "epson,rx8035";
reg = <0x32>;
};
};
&i2c3 {
status = "okay";
i2c-mux@70 {
compatible = "nxp,pca9540";
#address-cells = <1>;
#size-cells = <0>;
reg = <0x70>;
sfpupper_i2c: i2c@0 {
#address-cells = <1>;
#size-cells = <0>;
reg = <0>;
};
sfplower_i2c: i2c@1 {
#address-cells = <1>;
#size-cells = <0>;
reg = <1>;
};
};
};
&pcs_mdio1 {
status = "okay";
};
&pcs_mdio2 {
status = "okay";
};
&pcs_mdio3 {
status = "okay";
};
&pcs_mdio7 {
status = "okay";
};
&qspi {
status = "okay";
en25s64: flash@0 {
compatible = "jedec,spi-nor";
#address-cells = <1>;
#size-cells = <1>;
reg = <0>;
spi-max-frequency = <20000000>;
spi-rx-bus-width = <4>;
spi-tx-bus-width = <4>;
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
label = "bl2";
reg = <0 0x100000>;
};
partition@100000 {
label = "bl3";
reg = <0x100000 0x200000>;
};
partition@300000 {
label = "mcfirmware";
reg = <0x300000 0x200000>;
};
partition@500000 {
label = "ubootenv";
reg = <0x500000 0x80000>;
};
partition@580000 {
label = "dpl";
reg = <0x580000 0x40000>;
};
partition@5C0000 {
label = "dpc";
reg = <0x5C0000 0x40000>;
};
partition@600000 {
label = "devicetree";
reg = <0x600000 0x40000>;
};
};
};
nand: flash@1 {
compatible = "spi-nand";
#address-cells = <1>;
#size-cells = <1>;
reg = <1>;
spi-max-frequency = <20000000>;
spi-rx-bus-width = <4>;
spi-tx-bus-width = <4>;
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
/* reserved for future boot direct from NAND flash
* (this would use the same layout as the 8MiB NOR flash)
*/
partition@0 {
label = "nand-boot-reserved";
reg = <0 0x800000>;
};
/* recovery / install environment */
partition@800000 {
label = "recovery";
reg = <0x800000 0x2000000>;
};
/* ubia (first OpenWrt) - a/b names to prevent confusion with ubi0/1/etc. */
partition@2800000 {
label = "ubia";
reg = <0x2800000 0x6C00000>;
};
/* ubib (second OpenWrt) */
partition@9400000 {
label = "ubib";
reg = <0x9400000 0x6C00000>;
};
};
};
};
&usb0 {
status = "okay";
};
&usb1 {
status = "okay";
};

View File

@@ -55,9 +55,14 @@
&usb0 {
compatible = "fsl,layerscape-dwc3", "snps,dwc3";
status = "okay";
};
&usb1 {
compatible = "fsl,layerscape-dwc3", "snps,dwc3";
status = "okay";
};
&esdhc {
status = "okay";
};

View File

@@ -978,51 +978,61 @@
dpmac1: ethernet@1 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <1>;
status = "disabled";
};
dpmac2: ethernet@2 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <2>;
status = "disabled";
};
dpmac3: ethernet@3 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <3>;
status = "disabled";
};
dpmac4: ethernet@4 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <4>;
status = "disabled";
};
dpmac5: ethernet@5 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <5>;
status = "disabled";
};
dpmac6: ethernet@6 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <6>;
status = "disabled";
};
dpmac7: ethernet@7 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <7>;
status = "disabled";
};
dpmac8: ethernet@8 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <8>;
status = "disabled";
};
dpmac9: ethernet@9 {
compatible = "fsl,qoriq-mc-dpmac";
reg = <9>;
status = "disabled";
};
dpmac10: ethernet@a {
compatible = "fsl,qoriq-mc-dpmac";
reg = <0xa>;
status = "disabled";
};
};
};

View File

@@ -31,7 +31,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q128a {
dflash0: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -40,7 +40,7 @@
spi-cpha;
reg = <0>;
};
dflash1: sst25wf040b {
dflash1: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";
@@ -49,7 +49,7 @@
spi-cpha;
reg = <1>;
};
dflash2: en25s64 {
dflash2: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -22,7 +22,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q512a {
dflash0: n25q512a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -118,7 +118,7 @@
interrupts = <0 35 0x4>; /* Level high type */
};
dspi: dspi@2100000 {
dspi: spi@2100000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -127,7 +127,7 @@
spi-num-chipselects = <6>;
};
qspi: quadspi@1550000 {
qspi: spi@1550000 {
compatible = "fsl,ls2080a-qspi";
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -25,7 +25,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q512a {
dflash0: n25q512a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -113,7 +113,7 @@
bus-num = <0>;
status = "okay";
dflash0: n25q512a {
dflash0: n25q512a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "jedec,spi-nor";

View File

@@ -31,28 +31,28 @@
bus-num = <0>;
status = "okay";
dflash0: n25q128a {
dflash0: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash1: sst25wf040b {
dflash1: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash2: en25s64 {
dflash2: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
@@ -64,28 +64,28 @@
bus-num = <0>;
status = "okay";
dflash3: n25q128a {
dflash3: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash4: sst25wf040b {
dflash4: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash5: en25s64 {
dflash5: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
@@ -97,28 +97,28 @@
bus-num = <0>;
status = "okay";
dflash6: n25q128a {
dflash6: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash7: sst25wf040b {
dflash7: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash8: en25s64 {
dflash8: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;

View File

@@ -134,7 +134,7 @@
<1 10 0x8>; /* Hypervisor PPI, active-low */
};
fspi: flexspi@20c0000 {
fspi: spi@20c0000 {
compatible = "nxp,lx2160a-fspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -221,7 +221,7 @@
status = "disabled";
};
dspi0: dspi@2100000 {
dspi0: spi@2100000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -230,7 +230,7 @@
spi-num-chipselects = <6>;
};
dspi1: dspi@2110000 {
dspi1: spi@2110000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -239,7 +239,7 @@
spi-num-chipselects = <6>;
};
dspi2: dspi@2120000 {
dspi2: spi@2120000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -41,28 +41,28 @@
bus-num = <0>;
status = "okay";
dflash0: n25q128a {
dflash0: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash1: sst25wf040b {
dflash1: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash2: en25s64 {
dflash2: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
@@ -74,28 +74,28 @@
bus-num = <0>;
status = "okay";
dflash3: n25q128a {
dflash3: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash4: sst25wf040b {
dflash4: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash5: en25s64 {
dflash5: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
@@ -107,28 +107,28 @@
bus-num = <0>;
status = "okay";
dflash6: n25q128a {
dflash6: n25q128a@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <0>;
};
dflash7: sst25wf040b {
dflash7: sst25wf040b@1 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;
reg = <1>;
};
dflash8: en25s64 {
dflash8: en25s64@2 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <3000000>;
spi-cpol;
spi-cpha;

View File

@@ -12,6 +12,11 @@
#if defined(CONFIG_CPU_V7R)
&binman {
tiboot3_am69_gp {
insert-template = <&tiboot3_j784s4_gp>;
filename = "tiboot3-am69-gp-aquila.bin";
};
tiboot3-am69-hs {
insert-template = <&tiboot3_j784s4_hs>;
filename = "tiboot3-am69-hs-aquila.bin";
@@ -28,6 +33,10 @@
filename = "ti-sysfw/ti-fs-firmware-j784s4-hs-enc.bin";
};
&ti_fs_gp {
filename = "ti-sysfw/ti-fs-firmware-j784s4-gp.bin";
};
&sysfw_inner_cert {
filename = "ti-sysfw/ti-fs-firmware-j784s4-hs-cert.bin";
};
@@ -78,6 +87,72 @@
u-boot-unsigned {
insert-template = <&u_boot_unsigned>;
};
firmware-aquila-am69-gp.bin {
filename = "firmware-aquila-am69-gp.bin";
blob-ext@1 {
filename = "tiboot3-am69-gp-aquila.bin";
};
blob-ext@2 {
filename = "tispl.bin_unsigned";
/*
* This value matches CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
* from R5 SPL config.
*/
offset = <0x80000>;
};
blob-ext@3 {
filename = "u-boot.img_unsigned";
offset = <(CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)>;
};
};
firmware-aquila-am69-hs.bin {
filename = "firmware-aquila-am69-hs.bin";
blob-ext@1 {
filename = "tiboot3-am69-hs-aquila.bin";
};
blob-ext@2 {
filename = "tispl.bin";
/*
* This value matches CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
* from R5 SPL config.
*/
offset = <0x80000>;
};
blob-ext@3 {
filename = "u-boot.img";
offset = <(CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)>;
};
};
firmware-aquila-am69-hs-fs.bin {
filename = "firmware-aquila-am69-hs-fs.bin";
blob-ext@1 {
filename = "tiboot3-am69-hs-fs-aquila.bin";
};
blob-ext@2 {
filename = "tispl.bin";
/*
* This value matches CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
* from R5 SPL config.
*/
offset = <0x80000>;
};
blob-ext@3 {
filename = "u-boot.img";
offset = <(CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)>;
};
};
};
#endif

View File

@@ -173,7 +173,7 @@
status = "okay";
flash@0 {
compatible = "spi-flash";
compatible = "jedec,spi-nor";
spi-max-frequency = <20000000>;
reg = <0>;
};

View File

@@ -205,7 +205,7 @@
clocks = <&sysclk>;
};
dspi0: dspi@2100000 {
dspi0: spi@2100000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -218,7 +218,7 @@
status = "disabled";
};
dspi1: dspi@2110000 {
dspi1: spi@2110000 {
compatible = "fsl,vf610-dspi";
#address-cells = <1>;
#size-cells = <0>;
@@ -231,7 +231,7 @@
status = "disabled";
};
qspi: quadspi@1550000 {
qspi: spi@1550000 {
compatible = "fsl,ls1021a-qspi";
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -181,6 +181,23 @@
status = "disabled";
};
nor_flash: spi@11018000 {
compatible = "mediatek,mt8189-nor","mediatek,mt8186-nor";
reg = <0 0x11018000 0 0x1000>;
clocks = <&topckgen_clk CLK_TOP_SFLASH_SEL>,
<&pericfg_ao_clk CLK_PERAO_SFLASH>,
<&pericfg_ao_clk CLK_PERAO_SFLASH_F>,
<&pericfg_ao_clk CLK_PERAO_SFLASH_H>,
<&pericfg_ao_clk CLK_PERAO_SFLASH_P>;
clock-names = "spi", "sf", "axi_f", "axi_h", "axi_p";
assigned-clocks = <&topckgen_clk CLK_TOP_SFLASH_SEL>;
assigned-clock-parents = <&topckgen_clk CLK_TOP_UNIVPLL_D6_D8>;
interrupts = <GIC_SPI 390 IRQ_TYPE_LEVEL_HIGH 0>;
#address-cells = <1>;
#size-cells = <0>;
status = "disabled";
};
xhci0: usb@11200000 {
compatible = "mediatek,mt8189-xhci", "mediatek,mtk-xhci";
reg = <0 0x11200000 0 0x1000>,

View File

@@ -162,6 +162,21 @@
regulator-always-on;
};
&nor_flash {
pinctrl-names = "default";
pinctrl-0 = <&nor_pins>;
status = "okay";
flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <52000000>;
spi-rx-bus-width = <2>;
spi-tx-bus-width = <2>;
};
};
&pio {
mmc0_default_pins: mmc0-default-pins {
pins-clk {
@@ -274,6 +289,22 @@
};
};
nor_pins: nor-pins {
pins-ck-io {
pinmux = <PINMUX_GPIO150__FUNC_SPINOR_CK>,
<PINMUX_GPIO152__FUNC_SPINOR_IO0>,
<PINMUX_GPIO153__FUNC_SPINOR_IO1>;
drive-strength = <8>;
bias-pull-down;
};
pins-cs {
pinmux = <PINMUX_GPIO151__FUNC_SPINOR_CS>;
drive-strength = <8>;
bias-pull-up;
};
};
uart0_pins: uart0-pins {
pins {
pinmux = <PINMUX_GPIO31__FUNC_UTXD0>,

View File

@@ -49,7 +49,6 @@
compatible = "renesas,r7s72100-rpc-if";
reg = <0x3fefa000 0x100>, <0x18000000 0x08000000>;
bank-width = <2>;
num-cs = <1>;
status = "okay";
spi-max-frequency = <50000000>;
#address-cells = <1>;

View File

@@ -14,7 +14,6 @@
};
&rpc {
num-cs = <1>;
status = "okay";
spi-max-frequency = <50000000>;
#address-cells = <1>;

View File

@@ -6,18 +6,6 @@
*
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a774c0-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};
/delete-node/ &can0;
/delete-node/ &can1;
/delete-node/ &canfd;

View File

@@ -23,11 +23,6 @@
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};
&sdhi0 {
sd-uhs-sdr12;
sd-uhs-sdr25;

View File

@@ -5,18 +5,6 @@
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a7795-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};
/delete-node/ &ak4613;
/delete-node/ &audma0;
/delete-node/ &audma1;

View File

@@ -32,11 +32,6 @@
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};
&sdhi0 {
sd-uhs-sdr12;
sd-uhs-sdr25;

View File

@@ -23,11 +23,6 @@
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};
&sdhi0 {
sd-uhs-sdr12;
sd-uhs-sdr25;

View File

@@ -5,18 +5,6 @@
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a7796-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};
/delete-node/ &ak4613;
/delete-node/ &audma0;
/delete-node/ &audma1;

View File

@@ -32,11 +32,6 @@
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};
&sdhi0 {
sd-uhs-sdr12;
sd-uhs-sdr25;

View File

@@ -23,11 +23,6 @@
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};
&sdhi0 {
sd-uhs-sdr12;
sd-uhs-sdr25;

View File

@@ -5,18 +5,6 @@
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a77965-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};
/delete-node/ &ak4613;
/delete-node/ &audma0;
/delete-node/ &audma1;

View File

@@ -32,11 +32,6 @@
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};
&sdhi0 {
sd-uhs-sdr12;
sd-uhs-sdr25;

View File

@@ -5,7 +5,6 @@
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
#include "r8a77970-u-boot.dtsi"
#include <dt-bindings/gpio/gpio.h>
/ {
@@ -14,29 +13,8 @@
};
};
&avb {
pinctrl-0 = <&avb0_pins>;
pinctrl-names = "default";
};
&phy0 {
reset-gpios = <&gpio1 16 GPIO_ACTIVE_LOW>;
};
&pfc {
avb0_pins: avb {
mux {
groups = "avb0_link", "avb0_mdio", "avb0_rgmii", "avb0_txcrefclk";
function = "avb0";
};
};
};
&rpc {
num-cs = <1>;
status = "okay";
spi-max-frequency = <50000000>;
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -1,18 +0,0 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Device Tree Source extras for U-Boot on R-Car R8A77970 SoC
*
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a77970-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};

View File

@@ -5,7 +5,6 @@
* Copyright (C) 2019 Cogent Embedded, Inc.
*/
#include "r8a77970-u-boot.dtsi"
#include <dt-bindings/gpio/gpio.h>
/ {
@@ -25,29 +24,8 @@
};
};
&avb {
pinctrl-0 = <&avb0_pins>;
pinctrl-names = "default";
};
&phy0 {
reset-gpios = <&gpio1 16 GPIO_ACTIVE_LOW>;
};
&pfc {
avb0_pins: avb {
mux {
groups = "avb0_link", "avb0_mdio", "avb0_rgmii", "avb0_txcrefclk";
function = "avb0";
};
};
};
&rpc {
num-cs = <1>;
status = "okay";
spi-max-frequency = <50000000>;
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -5,8 +5,6 @@
* Copyright (C) 2019 Marek Vasut <marek.vasut@gmail.com>
*/
#include "r8a77980-u-boot.dtsi"
/ {
aliases {
spi0 = &rpc;
@@ -28,9 +26,7 @@
};
&rpc {
num-cs = <1>;
status = "okay";
spi-max-frequency = <50000000>;
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -1,18 +0,0 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Device Tree Source extras for U-Boot on R-Car R8A77980 SoC
*
* Copyright (C) 2019 Marek Vasut <marek.vasut@gmail.com>
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a77980-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};

View File

@@ -5,8 +5,6 @@
* Copyright (C) 2019 Cogent Embedded, Inc.
*/
#include "r8a77980-u-boot.dtsi"
/ {
aliases {
spi0 = &rpc;
@@ -14,9 +12,7 @@
};
&rpc {
num-cs = <1>;
status = "okay";
spi-max-frequency = <50000000>;
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -5,8 +5,6 @@
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
#include "r8a77990-u-boot.dtsi"
/ {
sysinfo {
compatible = "renesas,rcar-sysinfo";
@@ -33,11 +31,6 @@
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};
&sdhi0 {
sd-uhs-sdr12;
sd-uhs-sdr25;

View File

@@ -1,18 +0,0 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Device Tree Source extras for U-Boot on R-Car R8A77990 SoC
*
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a77990-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};

View File

@@ -5,8 +5,6 @@
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
#include "r8a77995-u-boot.dtsi"
/ {
sysinfo {
compatible = "renesas,rcar-sysinfo";
@@ -22,8 +20,3 @@
bootph-all;
};
};
&rpc {
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0x04000000>;
status = "disabled";
};

View File

@@ -1,18 +0,0 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Device Tree Source extras for U-Boot on R-Car R8A77995 SoC
*
* Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a77995-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x100>, <0 0x08000000 0 0>;
clocks = <&cpg CPG_MOD 917>;
bank-width = <2>;
status = "disabled";
};
};
};

View File

@@ -5,8 +5,6 @@
* Copyright (C) 2020 Renesas Electronics Corp.
*/
#include "r8a779a0-u-boot.dtsi"
/ {
aliases {
spi0 = &rpc;
@@ -16,8 +14,6 @@
&rpc {
#address-cells = <1>;
#size-cells = <0>;
num-cs = <1>;
spi-max-frequency = <50000000>;
status = "okay";
flash@0 {

View File

@@ -1,19 +0,0 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Device Tree Source extras for U-Boot on R-Car R8A779A0 SoC
*
* Copyright (C) 2020 Renesas Electronics Corp.
*/
/ {
soc {
rpc: spi@ee200000 {
compatible = "renesas,r8a779a0-rpc-if", "renesas,rcar-gen3-rpc-if";
reg = <0 0xee200000 0 0x200>, <0 0x08000000 0 0x04000000>;
clocks = <&cpg CPG_MOD 629>;
bank-width = <2>;
num-cs = <1>;
status = "disabled";
};
};
};

View File

@@ -93,11 +93,6 @@
bootph-all;
};
&rpc {
bank-width = <2>;
num-cs = <1>;
};
&soc {
apmu@e6170000 { /* Remoteproc */
compatible = "renesas,r8a779g0-cr52";

View File

@@ -5,36 +5,16 @@
* Copyright (C) 2025 Renesas Electronics Corp.
*/
#include "r8a779h0-u-boot.dtsi"
/ {
aliases {
spi0 = &rpc;
};
};
&pfc {
qspi0_pins: qspi0 {
groups = "qspi0_ctrl", "qspi0_data4";
function = "qspi0";
};
};
&rpc {
pinctrl-0 = <&qspi0_pins>;
pinctrl-names = "default";
#address-cells = <1>;
#size-cells = <0>;
spi-max-frequency = <40000000>;
status = "disabled";
flash@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "s25fs512s", "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <40000000>;
spi-tx-bus-width = <1>;
spi-rx-bus-width = <1>;
};

View File

@@ -1,11 +0,0 @@
// SPDX-License-Identifier: GPL-2.0
/*
* Device Tree Source extras for U-Boot on R-Car R8A779H0 SoC
*
* Copyright (C) 2025 Renesas Electronics Corp.
*/
&rpc {
bank-width = <2>;
num-cs = <1>;
};

View File

@@ -0,0 +1,130 @@
// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
/*
* Device Tree Source extras for U-Boot for the Ironhide CM33 board
*
* Copyright (C) 2026 Renesas Electronics Corp.
*/
#include "r8a78000-ironhide-u-boot.dtsi"
/ {
model = "Renesas Ironhide board CM33 based on r8a78000";
compatible = "renesas,ironhide-cm33", "renesas,r8a78000-cm33";
aliases {
serial1 = &hscif1;
};
chosen {
stdout-path = "serial1:1843200n8";
};
/delete-node/ firmware;
/delete-node/ memory@40000000;
/delete-node/ memory@60600000;
/delete-node/ memory@1080000000;
/delete-node/ memory@1200000000;
/delete-node/ memory@1400000000;
/delete-node/ memory@1600000000;
/delete-node/ memory@1800000000;
/delete-node/ memory@1a00000000;
/delete-node/ memory@1c00000000;
/delete-node/ memory@1e00000000;
/delete-node/ reserved-memory;
memory@b8400000 {
device_type = "memory";
reg = <0x0 0xb8400000 0x0 0x00200000>;
};
dummy_clk_rclk: dummy-clk-rclk {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <32768>;
};
dummy_clk_sasyncd4_rt: dummy-clk-sasyncd4-rt {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <16660000>;
};
ctl: syscon@5fffd000 {
compatible = "renesas,r8a78000-ctl",
"renesas,rcar-gen5-ctl",
"syscon";
reg = <0 0x5fffd000 0 0xc4>;
};
watchdog@5fffd800 {
compatible = "renesas,r8a78000-wwdt",
"renesas,rcar-gen5-wwdt";
clocks = <&dummy_clk_rclk>, <&dummy_clk_sasyncd4_rt>;
clock-names = "cnt", "bus";
reg = <0 0x5fffd800 0 0x10>;
syscon = <&ctl>;
};
scp@c1340000 {
compatible = "renesas,r8a78000-rproc";
reg = <0 0xc1340000 0 0x80000>;
};
};
&cpg {
/delete-property/ firmware;
};
&eth_pcs {
/* Stub clock */
clocks = <&dummy_clk_rclk>;
};
&hscif1 {
pinctrl-0 = <&hscif1_pins>;
pinctrl-names = "default";
uart-has-rtscts;
status = "okay";
};
&mdlc_hscn {
/delete-property/ firmware;
};
&mdlc_pere {
/delete-property/ firmware;
};
&mmc0 {
status = "disabled";
};
&mp_phy {
/* Stub clock */
clocks = <&dummy_clk_rclk>;
};
&pfc {
hscif1_pins: hscif1 {
groups = "hscif1_data", "hscif1_ctrl";
function = "hscif1";
};
};
&rswitch3 {
/* Stub clock */
clocks = <&dummy_clk_rclk>;
};
&soc {
dma-ranges = <0 0x00000000 0 0xa0000000 0 0x20000000>;
};
&ufs0 {
/delete-property/ power-domains;
};
&ufs1 {
/delete-property/ power-domains;
status = "disabled";
};

View File

@@ -0,0 +1,8 @@
// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
/*
* Device Tree Source for the Ironhide CM33 board
*
* Copyright (C) 2026 Renesas Electronics Corp.
*/
#include "../../../dts/upstream/src/arm64/renesas/r8a78000-ironhide.dts"

View File

@@ -5,4 +5,190 @@
* Copyright (C) 2025 Renesas Electronics Corp.
*/
#include <dt-bindings/net/ti-dp83869.h>
#include "r8a78000-u-boot.dtsi"
/ {
aliases {
i2c0 = &i2c0;
i2c1 = &i2c1;
mmc0 = &mmc0;
};
reg_1p8v: regulator-1p8v {
compatible = "regulator-fixed";
regulator-name = "fixed-1.8V";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-boot-on;
regulator-always-on;
};
reg_3p3v: regulator-3p3v {
compatible = "regulator-fixed";
regulator-name = "fixed-3.3V";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-boot-on;
regulator-always-on;
};
};
&cpg {
firmware = <&scmi>;
};
&eth_pcs {
phys = <&mp_phy 2 1>;
status = "okay";
};
&hscif0 {
pinctrl-0 = <&hscif0_pins>;
pinctrl-names = "default";
};
&i2c0 {
pinctrl-0 = <&i2c0_pins>;
pinctrl-names = "default";
clock-frequency = <400000>;
status = "okay";
eeprom@50 {
compatible = "rohm,br24g01", "atmel,24c01";
reg = <0x50>;
pagesize = <8>;
};
};
&i2c1 {
pinctrl-0 = <&i2c1_pins>;
pinctrl-names = "default";
clock-frequency = <400000>;
status = "okay";
};
&mdlc_hscn {
firmware = <&scmi>;
};
&mdlc_pere {
firmware = <&scmi>;
};
&mmc0 {
pinctrl-0 = <&mmc0_pins>;
pinctrl-1 = <&mmc0_pins>;
pinctrl-names = "default", "state_uhs";
bus-width = <8>;
full-pwr-cycle-in-suspend;
mmc-hs200-1_8v;
mmc-hs400-1_8v;
no-sd;
no-sdio;
non-removable;
vmmc-supply = <&reg_3p3v>;
vqmmc-supply = <&reg_1p8v>;
status = "okay";
};
&mp_phy {
status = "okay";
};
&pfc {
pinctrl-0 = <&scif_clk_pins>;
pinctrl-names = "default";
eth25g2_pins: eth25g2 {
groups = "eth25g2_mdio", "eth25g2_link", "eth25g2_phyint";
function = "eth25g2";
drive-strength = <24>;
};
ethes0_pins: ethes0 {
groups = "ethes0_match", "ethes0_capture", "ethes0_pps";
function = "ethes0";
drive-strength = <24>;
};
hscif0_pins: hscif0 {
groups = "hscif0_data", "hscif0_ctrl";
function = "hscif0";
};
i2c0_pins: i2c0 {
groups = "i2c0";
function = "i2c0";
};
i2c1_pins: i2c1 {
groups = "i2c1";
function = "i2c1";
};
mmc0_pins: mmc0 {
groups = "mmc0_data8", "mmc0_ctrl", "mmc0_ds";
function = "mmc0";
drive-strength = <24>;
};
rsw3_pins: rsw3 {
groups = "rsw3_match", "rsw3_capture", "rsw3_pps";
function = "rsw3";
drive-strength = <24>;
};
scif_clk_pins: scif-clk {
groups = "scif_clk";
function = "scif_clk";
};
};
&rswitch3 {
pinctrl-0 = <&rsw3_pins>, <&eth25g2_pins>, <&ethes0_pins>;
pinctrl-names = "default";
status = "okay";
ethernet-ports {
#address-cells = <1>;
#size-cells = <0>;
/*
* NOTE: Only port@4 is configured for R-Car X5H board.
* Other ports (0-3, 5-12) are currently unused or not
* connected.
*/
port@4 {
reg = <4>;
renesas,connect_to_xpcs;
phy-handle = <&dp83869_phy>;
phy-mode = "sgmii";
phys = <&eth_pcs 5>;
mdio {
#address-cells = <1>;
#size-cells = <0>;
dp83869_phy: ethernet-phy@2 {
reg = <2>;
ti,sgmii-interface;
ti,max-output-impedance;
ti,refclk-output-enable;
ti,clk-output-sel = <DP83869_CLK_O_SEL_REF_CLK>;
};
};
};
};
};
&ufs0 {
status = "okay";
};
&ufs1 {
status = "okay";
};

View File

@@ -1,257 +0,0 @@
// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
/*
* Device Tree Source for the Ironhide board
*
* Copyright (C) 2025 Renesas Electronics Corp.
*/
/dts-v1/;
#include "r8a78000.dtsi"
#include <dt-bindings/net/ti-dp83869.h>
/ {
model = "Renesas Ironhide board based on r8a78000";
compatible = "renesas,ironhide", "renesas,r8a78000";
aliases {
i2c0 = &i2c0;
i2c1 = &i2c1;
i2c2 = &i2c2;
i2c3 = &i2c3;
i2c4 = &i2c4;
i2c5 = &i2c5;
i2c6 = &i2c6;
i2c7 = &i2c7;
i2c8 = &i2c8;
mmc0 = &mmc0;
serial0 = &hscif0;
};
chosen {
stdout-path = "serial0:1843200n8";
};
memory@40000000 {
device_type = "memory";
reg = <0x0 0x40000000 0x0 0x80000000>;
};
memory@1080000000 {
device_type = "memory";
reg = <0x10 0x80000000 0x0 0x80000000>;
};
memory@1200000000 {
device_type = "memory";
reg = <0x12 0x00000000 0x1 0x00000000>;
};
memory@1400000000 {
device_type = "memory";
reg = <0x14 0x00000000 0x1 0x00000000>;
};
memory@1600000000 {
device_type = "memory";
reg = <0x16 0x00000000 0x1 0x00000000>;
};
memory@1800000000 {
device_type = "memory";
reg = <0x18 0x00000000 0x1 0x00000000>;
};
memory@1a00000000 {
device_type = "memory";
reg = <0x1a 0x00000000 0x1 0x00000000>;
};
memory@1c00000000 {
device_type = "memory";
reg = <0x1c 0x00000000 0x1 0x00000000>;
};
memory@1e00000000 {
device_type = "memory";
reg = <0x1e 0x00000000 0x1 0x00000000>;
};
reg_1p8v: regulator-1p8v {
compatible = "regulator-fixed";
regulator-name = "fixed-1.8V";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-boot-on;
regulator-always-on;
};
reg_3p3v: regulator-3p3v {
compatible = "regulator-fixed";
regulator-name = "fixed-3.3V";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-boot-on;
regulator-always-on;
};
};
&extal_clk {
clock-frequency = <16666600>;
};
&extalr_clk {
clock-frequency = <32768>;
};
&hscif0 {
pinctrl-0 = <&hscif0_pins>;
pinctrl-names = "default";
uart-has-rtscts;
status = "okay";
};
&i2c0 {
pinctrl-0 = <&i2c0_pins>;
pinctrl-names = "default";
clock-frequency = <400000>;
status = "okay";
eeprom@50 {
compatible = "rohm,br24g01", "atmel,24c01";
reg = <0x50>;
pagesize = <8>;
};
};
&i2c1 {
pinctrl-0 = <&i2c1_pins>;
pinctrl-names = "default";
clock-frequency = <400000>;
status = "okay";
};
&eth_pcs {
phys = <&mp_phy 2 1>;
status = "okay";
};
&mmc0 {
pinctrl-0 = <&mmc0_pins>;
pinctrl-1 = <&mmc0_pins>;
pinctrl-names = "default", "state_uhs";
bus-width = <8>;
full-pwr-cycle-in-suspend;
mmc-hs200-1_8v;
mmc-hs400-1_8v;
no-sd;
no-sdio;
non-removable;
vmmc-supply = <&reg_3p3v>;
vqmmc-supply = <&reg_1p8v>;
status = "okay";
};
&ufs0 {
status = "okay";
};
&ufs1 {
status = "okay";
};
&mp_phy {
status = "okay";
};
&pfc {
pinctrl-0 = <&scif_clk_pins>;
pinctrl-names = "default";
eth25g2_pins: eth25g2 {
groups = "eth25g2_mdio", "eth25g2_link", "eth25g2_phyint";
function = "eth25g2";
drive-strength = <24>;
};
ethes0_pins: ethes0 {
groups = "ethes0_match", "ethes0_capture", "ethes0_pps";
function = "ethes0";
drive-strength = <24>;
};
hscif0_pins: hscif0 {
groups = "hscif0_data", "hscif0_ctrl";
function = "hscif0";
};
i2c0_pins: i2c0 {
groups = "i2c0";
function = "i2c0";
};
i2c1_pins: i2c1 {
groups = "i2c1";
function = "i2c1";
};
mmc0_pins: mmc0 {
groups = "mmc0_data8", "mmc0_ctrl", "mmc0_ds";
function = "mmc0";
drive-strength = <24>;
};
rsw3_pins: rsw3 {
groups = "rsw3_match", "rsw3_capture", "rsw3_pps";
function = "rsw3";
drive-strength = <24>;
};
scif_clk_pins: scif-clk {
groups = "scif_clk";
function = "scif_clk";
};
};
&rswitch3 {
pinctrl-0 = <&rsw3_pins>, <&eth25g2_pins>, <&ethes0_pins>;
pinctrl-names = "default";
status = "okay";
ethernet-ports {
#address-cells = <1>;
#size-cells = <0>;
/*
* NOTE: Only port@4 is configured for R-Car X5H board.
* Other ports (0-3, 5-12) are currently unused or not
* connected.
*/
port@4 {
reg = <4>;
renesas,connect_to_xpcs;
phy-handle = <&dp83869_phy>;
phy-mode = "sgmii";
phys = <&eth_pcs 5>;
mdio {
#address-cells = <1>;
#size-cells = <0>;
dp83869_phy: ethernet-phy@2 {
reg = <2>;
ti,sgmii-interface;
ti,max-output-impedance;
ti,refclk-output-enable;
ti,clk-output-sel = <DP83869_CLK_O_SEL_REF_CLK>;
};
};
};
};
};
&scif_clk {
clock-frequency = <26000000>;
};

View File

@@ -5,9 +5,41 @@
* Copyright (C) 2025 Renesas Electronics Corp.
*/
#include <dt-bindings/clock/r8a78000-clock-scmi.h>
#include <dt-bindings/power/r8a78000-power-scmi.h>
#include <dt-bindings/reset/r8a78000-reset-scmi.h>
/ {
soc {
bootph-all;
firmware {
scmi: scmi {
compatible = "arm,scmi";
arm,poll-transport;
mbox-names = "tx", "rx";
mboxes = <&mailbox 0>, <&mailbox 1>;
shmem = <&cpu_scp_lpri0>, <&cpu_scp_hpri0>;
#address-cells = <1>;
#size-cells = <0>;
protocol@11 {
reg = <0x11>;
#power-domain-cells = <1>;
};
protocol@14 {
reg = <0x14>;
#clock-cells = <1>;
};
protocol@16 {
reg = <0x16>;
#reset-cells = <1>;
};
};
};
psci {
compatible = "arm,psci-1.0", "arm,psci-0.2";
method = "smc";
};
/* Placeholder clock until the clock provider is in place */
@@ -32,16 +64,12 @@
clk_stub_mmc: clk-stub-mmc {
compatible = "renesas,compound-clock";
#clock-cells = <0>;
clocks = <&scmi_clk SCP_CLOCK_ID_MDLC_SDHI0>,
<&scmi_clk 1691>;
clocks = <&cpg SCP_CLOCK_ID_MDLC_SDHI0>,
<&cpg SCP_CLOCK_ID_CLK_S0D6_PERE_MAIN>;
clock-names = "mdlc", "per";
};
};
&cpg {
bootph-all;
};
&extal_clk {
bootph-all;
};
@@ -50,90 +78,311 @@
bootph-all;
};
&gpio0 {
clocks = <&clk_stub_gpio>;
};
&gpio1 {
clocks = <&clk_stub_gpio>;
};
&gpio2 {
clocks = <&clk_stub_gpio>;
};
&gpio3 {
clocks = <&clk_stub_gpio>;
};
&gpio4 {
clocks = <&clk_stub_gpio>;
};
&gpio5 {
clocks = <&clk_stub_gpio>;
};
&gpio6 {
clocks = <&clk_stub_gpio>;
};
&gpio7 {
clocks = <&clk_stub_gpio>;
};
&gpio8 {
clocks = <&clk_stub_gpio>;
};
&gpio9 {
clocks = <&clk_stub_gpio>;
};
&gpio10 {
clocks = <&clk_stub_gpio>;
};
&i2c0 {
clocks = <&clk_stub_i2c0>;
};
&i2c1 {
clocks = <&clk_stub_i2c1>;
};
&i2c2 {
clocks = <&clk_stub_i2c1>;
};
&i2c3 {
clocks = <&clk_stub_i2c1>;
};
&i2c4 {
clocks = <&clk_stub_i2c1>;
};
&i2c5 {
clocks = <&clk_stub_i2c1>;
};
&i2c6 {
clocks = <&clk_stub_i2c1>;
};
&i2c7 {
clocks = <&clk_stub_i2c1>;
};
&i2c8 {
clocks = <&clk_stub_i2c1>;
};
&mmc0 {
clocks = <&clk_stub_mmc>;
};
&prr {
bootph-all;
};
&soc {
bootph-all;
mailbox: mfis_mbox@18842000 {
compatible = "renesas,mfis-mbox";
#mbox-cells = <1>;
reg = <0 0x18842004 0 0x8>;
interrupts = <GIC_SPI 4362 IRQ_TYPE_LEVEL_HIGH>;
};
pfc: pinctrl@c0400000 {
compatible = "renesas,pfc-r8a78000";
reg = <0 0xc1080000 0 0x104>, <0 0xc1080800 0 0x104>,
<0 0xc1081000 0 0x104>, <0 0xc0800000 0 0x104>,
<0 0xc0800800 0 0x104>, <0 0xc0400000 0 0x104>,
<0 0xc0400800 0 0x104>, <0 0xc0401000 0 0x104>,
<0 0xc0401800 0 0x104>, <0 0xc9b00000 0 0x104>,
<0 0xc9b00800 0 0x104>;
};
mmc0: mmc@c0880000 {
compatible = "renesas,rcar-gen5-sdhi";
reg = <0 0xc0880000 0 0x2000>;
clock-names = "core";
max-frequency = <200000000>;
clocks = <&clk_stub_mmc>;
status = "disabled";
};
mdlc_pere: system-controller@c08f0000 {
compatible = "renesas,r8a78000-mdlc";
reg = <0 0xc08f0000 0 0x1000>;
#power-domain-cells = <1>;
#reset-cells = <1>;
bootph-all;
};
ufs0: ufs@c0a80000 {
compatible = "renesas,r8a78000-ufs";
reg = <0 0xc0a80000 0 0x1100>, <0 0xc0a00000 0 0x40000>;
reg-names = "hcr", "phy";
interrupts = <GIC_SPI 4284 IRQ_TYPE_LEVEL_HIGH>;
power-domains = <&mdlc_pere X5H_POWER_DOMAIN_ID_UFS0>;
clocks = <&cpg SCP_CLOCK_ID_MDLC_UFS0>;
resets = <&mdlc_pere SCP_RESET_DOMAIN_ID_UFS0>;
freq-table-hz = <38400000 38400000>;
status = "disabled";
};
ufs1: ufs@c0a90000 {
compatible = "renesas,r8a78000-ufs";
reg = <0 0xc0a90000 0 0x1100>, <0 0xc0a40000 0 0x40000>;
reg-names = "hcr", "phy";
interrupts = <GIC_SPI 4285 IRQ_TYPE_LEVEL_HIGH>;
power-domains = <&mdlc_pere X5H_POWER_DOMAIN_ID_UFS1>;
clocks = <&cpg SCP_CLOCK_ID_MDLC_UFS1>;
resets = <&mdlc_pere SCP_RESET_DOMAIN_ID_UFS1>;
freq-table-hz = <38400000 38400000>;
status = "disabled";
};
scp: sram@c1000000 {
compatible = "arm,rcar-sram-ns", "mmio-sram";
reg = <0x0 0xc1000000 0x0 0x80000>;
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0x0 0xc1000000 0x80000>;
cpu_scp_lpri0: scp-shmem@60000 {
compatible = "arm,rcar-scp-shmem", "arm,scmi-shmem";
reg = <0x61200 0x0100>;
};
cpu_scp_hpri0: scp-shmem@60300 {
compatible = "arm,rcar-scp-shmem", "arm,scmi-shmem";
reg = <0x61300 0x100>;
};
};
cpg: clock-controller@c1320000 {
compatible = "renesas,r8a78000-cpg";
reg = <0 0xc1320000 0 0x10000>;
clocks = <&extal_clk>, <&extalr_clk>;
clock-names = "extal", "extalr";
#clock-cells = <1>;
bootph-all;
};
i2c0: i2c@c11d0000 {
compatible = "renesas,i2c-r8a78000",
"renesas,rcar-gen5-i2c";
reg = <0 0xc11d0000 0 0x40>;
i2c-scl-internal-delay-ns = <110>;
#address-cells = <1>;
#size-cells = <0>;
clocks = <&clk_stub_i2c0>;
status = "disabled";
};
i2c1: i2c@c06c0000 {
compatible = "renesas,i2c-r8a78000",
"renesas,rcar-gen5-i2c";
reg = <0 0xc06c0000 0 0x40>;
i2c-scl-internal-delay-ns = <110>;
#address-cells = <1>;
#size-cells = <0>;
clocks = <&clk_stub_i2c1>;
status = "disabled";
};
gpio0: gpio@c1080110 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc1080110 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 0 28>;
clocks = <&clk_stub_gpio>;
};
gpio1: gpio@c1080910 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc1080910 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 32 22>;
clocks = <&clk_stub_gpio>;
};
gpio2: gpio@c1081110 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc1081110 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 64 29>;
clocks = <&clk_stub_gpio>;
};
gpio3: gpio@c0800110 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc0800110 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 96 17>;
clocks = <&clk_stub_gpio>;
};
gpio4: gpio@c0800910 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc0800910 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 128 16>;
clocks = <&clk_stub_gpio>;
};
gpio5: gpio@c0400110 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc0400110 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 160 23>;
clocks = <&clk_stub_gpio>;
};
gpio6: gpio@c0400910 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc0400910 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 192 31>;
clocks = <&clk_stub_gpio>;
};
gpio7: gpio@c0401110 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc0401110 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 224 31>;
clocks = <&clk_stub_gpio>;
};
gpio8: gpio@c0401910 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc0401910 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 256 32>;
gpio-reserved-ranges = <16 10>;
clocks = <&clk_stub_gpio>;
};
gpio9: gpio@c9b00110 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc9b00110 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 288 17>;
clocks = <&clk_stub_gpio>;
};
gpio10: gpio@c9b00910 {
compatible = "renesas,gpio-r8a78000",
"renesas,rcar-gen5-gpio";
reg = <0 0xc9b00910 0 0xc0>;
#gpio-cells = <2>;
gpio-controller;
gpio-ranges = <&pfc 0 320 14>;
clocks = <&clk_stub_gpio>;
};
mp_phy: mp_phy@c9a00000 {
compatible = "renesas,r8a78000-multi-protocol-phy";
reg = <0 0xc9a00000 0 0x100000>;
#phy-cells = <2>;
clocks = <&cpg SCP_CLOCK_ID_MDLC_MPPHY01>,
<&cpg SCP_CLOCK_ID_MDLC_MPPHY11>,
<&cpg SCP_CLOCK_ID_MDLC_MPPHY21>,
<&cpg SCP_CLOCK_ID_MDLC_MPPHY31>,
<&cpg SCP_CLOCK_ID_MDLC_MPPHY02>;
clock-names = "mpphy01", "mpphy11", "mpphy21",
"mpphy31", "mpphy02";
power-domains = <&mdlc_hscn X5H_POWER_DOMAIN_ID_MPP0>,
<&mdlc_hscn X5H_POWER_DOMAIN_ID_MPP1>,
<&mdlc_hscn X5H_POWER_DOMAIN_ID_MPP2>,
<&mdlc_hscn X5H_POWER_DOMAIN_ID_MPP3>;
resets = <&mdlc_hscn SCP_RESET_DOMAIN_ID_MPPHY01>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_MPPHY11>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_MPPHY21>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_MPPHY31>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_MPPHY02>;
status = "disabled";
};
rswitch3: ethernet@c9bc0000 {
compatible = "renesas,r8a78000-ether-switch3",
"renesas,etherswitch";
reg = <0 0xc9bc0000 0 0x40000>, <0 0xc9b80000 0 0x240000>;
reg-names = "base", "secure_base";
power-domains = <&mdlc_hscn X5H_POWER_DOMAIN_ID_RSW>;
clocks = <&cpg SCP_CLOCK_ID_MDLC_RSW3>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSN>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3AES>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES0>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES1>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES2>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES3>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES4>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES5>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES6>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3TSNTES7>,
<&cpg SCP_CLOCK_ID_MDLC_RSW3MFWD>;
clock-names = "rsw3", "rsw3tsn", "rsw3aes",
"rsw3tsntes0", "rsw3tsntes1", "rsw3tsntes2",
"rsw3tsntes3", "rsw3tsntes4", "rsw3tsntes5",
"rsw3tsntes6", "rsw3tsntes7", "rsw3mfwd";
status = "disabled";
};
eth_pcs: phy@c9c50000 {
compatible = "renesas,r8a78000-ether-pcs";
reg = <0 0xc9c50000 0 0x4000>;
#phy-cells = <1>;
clocks = <&cpg SCP_CLOCK_ID_MDLC_XPCS0>,
<&cpg SCP_CLOCK_ID_MDLC_XPCS1>,
<&cpg SCP_CLOCK_ID_MDLC_XPCS2>,
<&cpg SCP_CLOCK_ID_MDLC_XPCS3>,
<&cpg SCP_CLOCK_ID_MDLC_XPCS4>,
<&cpg SCP_CLOCK_ID_MDLC_XPCS5>,
<&cpg SCP_CLOCK_ID_MDLC_XPCS6>,
<&cpg SCP_CLOCK_ID_MDLC_XPCS7>;
clock-names = "xpcs0", "xpcs1", "xpcs2", "xpcs3",
"xpcs4", "xpcs5", "xpcs6", "xpcs7";
resets = <&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS0>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS1>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS2>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS3>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS4>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS5>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS6>,
<&mdlc_hscn SCP_RESET_DOMAIN_ID_XPCS7>;
reset-names = "xpcs0", "xpcs1", "xpcs2", "xpcs3",
"xpcs4", "xpcs5", "xpcs6", "xpcs7";
status = "disabled";
};
mdlc_hscn: system-controller@c9c90000 {
compatible = "renesas,r8a78000-mdlc";
reg = <0 0xc9c90000 0 0x1000>;
#power-domain-cells = <1>;
#reset-cells = <1>;
bootph-all;
};
};

File diff suppressed because it is too large Load Diff

View File

@@ -47,7 +47,6 @@
&rpc {
pinctrl-0 = <&qspi_pins>;
pinctrl-names = "default";
num-cs = <1>;
spi-max-frequency = <40000000>;
#address-cells = <1>;
#size-cells = <0>;

View File

@@ -21,6 +21,13 @@
pinctrl1 = &pinctrl_z;
};
arm_wdt: watchdog {
compatible = "arm,smc-wdt";
arm,smc-id = <0xbc000000>;
timeout-sec = <32>;
status = "okay";
};
binman: binman {
multiple-images;
};
@@ -103,7 +110,7 @@
};
&iwdg2 {
bootph-all;
status = "disabled";
};
/* pre-reloc probe = reserve video frame buffer in video_reserve() */

View File

@@ -1 +0,0 @@
#include "t8103-u-boot.dtsi"

View File

@@ -1,129 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* Apple Mac mini (M1, 2020)
*
* target-type: J274
*
* Copyright The Asahi Linux Contributors
*/
/dts-v1/;
#include "t8103.dtsi"
#include "t8103-jxxx.dtsi"
/ {
compatible = "apple,j274", "apple,t8103", "apple,arm-platform";
model = "Apple Mac mini (M1, 2020)";
aliases {
ethernet0 = &ethernet0;
};
};
&wifi0 {
brcm,board-type = "apple,atlantisb";
};
/*
* Provide labels for the USB type C ports.
*/
&typec0 {
label = "USB-C Back-left";
};
&typec1 {
label = "USB-C Back-right";
};
/*
* Force the bus number assignments so that we can declare some of the
* on-board devices and properties that are populated by the bootloader
* (such as MAC addresses).
*/
&port01 {
bus-range = <2 2>;
};
&port02 {
bus-range = <3 3>;
ethernet0: ethernet@0,0 {
reg = <0x30000 0x0 0x0 0x0 0x0>;
/* To be filled by the loader */
local-mac-address = [00 10 18 00 00 00];
};
};
&i2c1 {
clock-frequency = <50000>;
speaker_amp: codec@31 {
compatible = "ti,tas5770l", "ti,tas2770";
reg = <0x31>;
reset-gpios = <&pinctrl_ap 181 GPIO_ACTIVE_HIGH>;
#sound-dai-cells = <0>;
};
};
&i2c2 {
status = "okay";
clock-frequency = <50000>;
jack_codec: codec@48 {
compatible = "cirrus,cs42l83", "cirrus,cs42l42";
reg = <0x48>;
reset-gpios = <&pinctrl_nub 11 GPIO_ACTIVE_HIGH>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <183 IRQ_TYPE_LEVEL_LOW>;
#sound-dai-cells = <0>;
cirrus,ts-inv = <1>;
};
};
/ {
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "Mac mini integrated audio";
#address-cells = <1>;
#size-cells = <0>;
simple-audio-card,dai-link@0 {
reg = <0>;
format = "left_j";
tdm-slot-width = <32>;
mclk-fs = <64>;
link0_cpu: cpu {
sound-dai = <&mca 0>;
bitclock-master;
frame-master;
};
link0_codec: codec {
sound-dai = <&speaker_amp>;
};
};
simple-audio-card,dai-link@1 {
bitclock-inversion;
frame-inversion;
reg = <1>;
format = "i2s";
mclk-fs = <64>;
tdm-slot-width = <32>;
link1_cpu: cpu {
sound-dai = <&mca 2>;
bitclock-master;
frame-master;
};
link1_codec: codec {
sound-dai = <&jack_codec>;
};
};
};
};

View File

@@ -1 +0,0 @@
#include "t8103-u-boot.dtsi"

View File

@@ -1,116 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* Apple MacBook Pro (13-inch, M1, 2020)
*
* target-type: J293
*
* Copyright The Asahi Linux Contributors
*/
/dts-v1/;
#include "t8103.dtsi"
#include "t8103-jxxx.dtsi"
/ {
compatible = "apple,j293", "apple,t8103", "apple,arm-platform";
model = "Apple MacBook Pro (13-inch, M1, 2020)";
};
&wifi0 {
brcm,board-type = "apple,honshu";
};
/*
* Provide labels for the USB type C ports.
*/
&typec0 {
label = "USB-C Left-back";
};
&typec1 {
label = "USB-C Left-front";
};
&spi3 {
status = "okay";
hid-transport@0 {
compatible = "apple,spi-hid-transport";
reg = <0>;
spi-max-frequency = <8000000>;
/*
* cs-setup and cs-hold delays are derived from Apple's ADT
* Mac OS driver meta data secify 45 us for 'cs to clock' and
* 'clock to cs' delays.
*/
spi-cs-setup-delay-ns = <20000>;
spi-cs-hold-delay-ns = <20000>;
spi-cs-inactive-delay-ns = <250000>;
spien-gpios = <&pinctrl_ap 195 0>;
interrupts-extended = <&pinctrl_nub 13 IRQ_TYPE_LEVEL_LOW>;
};
};
/*
* Remove unused PCIe ports and disable the associated DARTs.
*/
&pcie0_dart_1 {
status = "disabled";
};
&pcie0_dart_2 {
status = "disabled";
};
/delete-node/ &port01;
/delete-node/ &port02;
&i2c2 {
status = "okay";
clock-frequency = <50000>;
jack_codec: codec@48 {
compatible = "cirrus,cs42l83", "cirrus,cs42l42";
reg = <0x48>;
reset-gpios = <&pinctrl_nub 11 GPIO_ACTIVE_HIGH>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <183 IRQ_TYPE_LEVEL_LOW>;
#sound-dai-cells = <0>;
cirrus,ts-inv = <1>;
};
};
&i2c4 {
status = "okay";
};
/ {
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "MacBook integrated audio";
#address-cells = <1>;
#size-cells = <0>;
simple-audio-card,dai-link@0 {
bitclock-inversion;
frame-inversion;
reg = <0>;
format = "i2s";
mclk-fs = <64>;
tdm-slot-width = <32>;
link0_cpu: cpu {
sound-dai = <&mca 2>;
bitclock-master;
frame-master;
};
link0_codec: codec {
sound-dai = <&jack_codec>;
};
};
};
};

View File

@@ -1 +0,0 @@
#include "t8103-u-boot.dtsi"

View File

@@ -1,111 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* Apple MacBook Air (M1, 2020)
*
* target-type: J313
*
* Copyright The Asahi Linux Contributors
*/
/dts-v1/;
#include "t8103.dtsi"
#include "t8103-jxxx.dtsi"
/ {
compatible = "apple,j313", "apple,t8103", "apple,arm-platform";
model = "Apple MacBook Air (M1, 2020)";
};
&wifi0 {
brcm,board-type = "apple,shikoku";
};
/*
* Provide labels for the USB type C ports.
*/
&typec0 {
label = "USB-C Left-back";
};
&typec1 {
label = "USB-C Left-front";
};
&spi3 {
status = "okay";
hid-transport@0 {
compatible = "apple,spi-hid-transport";
reg = <0>;
spi-max-frequency = <8000000>;
/*
* cs-setup and cs-hold delays are derived from Apple's ADT
* Mac OS driver meta data secify 45 us for 'cs to clock' and
* 'clock to cs' delays.
*/
spi-cs-setup-delay-ns = <20000>;
spi-cs-hold-delay-ns = <20000>;
spi-cs-inactive-delay-ns = <250000>;
spien-gpios = <&pinctrl_ap 195 0>;
interrupts-extended = <&pinctrl_nub 13 IRQ_TYPE_LEVEL_LOW>;
};
};
/*
* Remove unused PCIe ports and disable the associated DARTs.
*/
&pcie0_dart_1 {
status = "disabled";
};
&pcie0_dart_2 {
status = "disabled";
};
/delete-node/ &port01;
/delete-node/ &port02;
&i2c3 {
clock-frequency = <50000>;
jack_codec: codec@48 {
compatible = "cirrus,cs42l83", "cirrus,cs42l42";
reg = <0x48>;
reset-gpios = <&pinctrl_nub 11 GPIO_ACTIVE_HIGH>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <183 IRQ_TYPE_LEVEL_LOW>;
#sound-dai-cells = <0>;
cirrus,ts-inv = <1>;
};
};
/ {
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "MacBook integrated audio";
#address-cells = <1>;
#size-cells = <0>;
simple-audio-card,dai-link@0 {
bitclock-inversion;
frame-inversion;
reg = <0>;
format = "i2s";
mclk-fs = <64>;
tdm-slot-width = <32>;
link0_cpu: cpu {
sound-dai = <&mca 2>;
bitclock-master;
frame-master;
};
link0_codec: codec {
sound-dai = <&jack_codec>;
};
};
};
};

View File

@@ -1 +0,0 @@
#include "t8103-u-boot.dtsi"

View File

@@ -1,117 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* Apple iMac (24-inch, 4x USB-C, M1, 2020)
*
* target-type: J456
*
* Copyright The Asahi Linux Contributors
*/
/dts-v1/;
#include "t8103.dtsi"
#include "t8103-jxxx.dtsi"
/ {
compatible = "apple,j456", "apple,t8103", "apple,arm-platform";
model = "Apple iMac (24-inch, 4x USB-C, M1, 2020)";
aliases {
ethernet0 = &ethernet0;
};
};
&wifi0 {
brcm,board-type = "apple,capri";
};
&i2c0 {
hpm2: usb-pd@3b {
compatible = "apple,cd321x";
reg = <0x3b>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <106 IRQ_TYPE_LEVEL_LOW>;
interrupt-names = "irq";
};
hpm3: usb-pd@3c {
compatible = "apple,cd321x";
reg = <0x3c>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <106 IRQ_TYPE_LEVEL_LOW>;
interrupt-names = "irq";
};
};
/*
* Provide labels for the USB type C ports.
*/
&typec0 {
label = "USB-C Back-right";
};
&typec1 {
label = "USB-C Back-right-middle";
};
/*
* Force the bus number assignments so that we can declare some of the
* on-board devices and properties that are populated by the bootloader
* (such as MAC addresses).
*/
&port01 {
bus-range = <2 2>;
};
&port02 {
bus-range = <3 3>;
ethernet0: ethernet@0,0 {
reg = <0x30000 0x0 0x0 0x0 0x0>;
/* To be filled by the loader */
local-mac-address = [00 10 18 00 00 00];
};
};
&i2c1 {
clock-frequency = <50000>;
jack_codec: codec@48 {
compatible = "cirrus,cs42l83", "cirrus,cs42l42";
reg = <0x48>;
reset-gpios = <&pinctrl_nub 11 GPIO_ACTIVE_HIGH>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <183 IRQ_TYPE_LEVEL_LOW>;
#sound-dai-cells = <0>;
cirrus,ts-inv = <1>;
};
};
/ {
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "iMac integrated audio";
#address-cells = <1>;
#size-cells = <0>;
simple-audio-card,dai-link@0 {
bitclock-inversion;
frame-inversion;
reg = <0>;
format = "i2s";
mclk-fs = <64>;
tdm-slot-width = <32>;
link0_cpu: cpu {
sound-dai = <&mca 2>;
bitclock-master;
frame-master;
};
link0_codec: codec {
sound-dai = <&jack_codec>;
};
};
};
};

View File

@@ -1 +0,0 @@
#include "t8103-u-boot.dtsi"

View File

@@ -1,105 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* Apple iMac (24-inch, 2x USB-C, M1, 2020)
*
* target-type: J457
*
* Copyright The Asahi Linux Contributors
*/
/dts-v1/;
#include "t8103.dtsi"
#include "t8103-jxxx.dtsi"
/ {
compatible = "apple,j457", "apple,t8103", "apple,arm-platform";
model = "Apple iMac (24-inch, 2x USB-C, M1, 2020)";
aliases {
ethernet0 = &ethernet0;
};
};
&wifi0 {
brcm,board-type = "apple,santorini";
};
/*
* Provide labels for the USB type C ports.
*/
&typec0 {
label = "USB-C Back-right";
};
&typec1 {
label = "USB-C Back-left";
};
/*
* Force the bus number assignments so that we can declare some of the
* on-board devices and properties that are populated by the bootloader
* (such as MAC addresses).
*/
&port02 {
bus-range = <3 3>;
ethernet0: ethernet@0,0 {
reg = <0x30000 0x0 0x0 0x0 0x0>;
/* To be filled by the loader */
local-mac-address = [00 10 18 00 00 00];
};
};
/*
* Remove unused PCIe port and disable the associated DART.
*/
&pcie0_dart_1 {
status = "disabled";
};
/delete-node/ &port01;
&i2c1 {
clock-frequency = <50000>;
jack_codec: codec@48 {
compatible = "cirrus,cs42l83", "cirrus,cs42l42";
reg = <0x48>;
reset-gpios = <&pinctrl_nub 11 GPIO_ACTIVE_HIGH>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <183 IRQ_TYPE_LEVEL_LOW>;
#sound-dai-cells = <0>;
cirrus,ts-inv = <1>;
};
};
/ {
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "iMac integrated audio";
#address-cells = <1>;
#size-cells = <0>;
simple-audio-card,dai-link@0 {
bitclock-inversion;
frame-inversion;
reg = <0>;
format = "i2s";
mclk-fs = <64>;
tdm-slot-width = <32>;
link0_cpu: cpu {
sound-dai = <&mca 2>;
bitclock-master;
frame-master;
};
link0_codec: codec {
sound-dai = <&jack_codec>;
};
};
};
};

View File

@@ -1,143 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* Apple M1 Mac mini, MacBook Air/Pro, iMac 24" (M1, 2020/2021)
*
* This file contains parts common to all Apple M1 devices using the t8103.
*
* target-type: J274, J293, J313, J456, J457
*
* Copyright The Asahi Linux Contributors
*/
#include <dt-bindings/spmi/spmi.h>
/ {
aliases {
serial0 = &serial0;
serial2 = &serial2;
wifi0 = &wifi0;
};
chosen {
#address-cells = <2>;
#size-cells = <2>;
ranges;
stdout-path = "serial0";
framebuffer0: framebuffer@0 {
compatible = "apple,simple-framebuffer", "simple-framebuffer";
reg = <0 0 0 0>; /* To be filled by loader */
/* Format properties will be added by loader */
status = "disabled";
};
};
memory@800000000 {
device_type = "memory";
reg = <0x8 0 0x2 0>; /* To be filled by loader */
};
};
&serial0 {
status = "okay";
};
&serial2 {
status = "okay";
};
&i2c0 {
hpm0: usb-pd@38 {
compatible = "apple,cd321x";
reg = <0x38>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <106 IRQ_TYPE_LEVEL_LOW>;
interrupt-names = "irq";
typec0: connector {
compatible = "usb-c-connector";
power-role = "dual";
data-role = "dual";
ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
typec0_con_hs: endpoint {
remote-endpoint = <&typec0_usb_hs>;
};
};
};
};
};
hpm1: usb-pd@3f {
compatible = "apple,cd321x";
reg = <0x3f>;
interrupt-parent = <&pinctrl_ap>;
interrupts = <106 IRQ_TYPE_LEVEL_LOW>;
interrupt-names = "irq";
typec1: connector {
compatible = "usb-c-connector";
power-role = "dual";
data-role = "dual";
ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
typec1_con_hs: endpoint {
remote-endpoint = <&typec1_usb_hs>;
};
};
};
};
};
};
/* USB controllers */
&dwc3_0 {
port {
typec0_usb_hs: endpoint {
remote-endpoint = <&typec0_con_hs>;
};
};
};
&dwc3_1 {
port {
typec1_usb_hs: endpoint {
remote-endpoint = <&typec1_con_hs>;
};
};
};
/*
* Force the bus number assignments so that we can declare some of the
* on-board devices and properties that are populated by the bootloader
* (such as MAC addresses).
*/
&port00 {
bus-range = <1 1>;
pwren-gpios = <&smc 13 0>;
wifi0: network@0,0 {
compatible = "pci14e4,4425";
reg = <0x10000 0x0 0x0 0x0 0x0>;
/* To be filled by the loader */
local-mac-address = [00 00 00 00 00 00];
apple,antenna-sku = "XX";
};
};
&spmi {
status = "okay";
pmu@f {
compatible = "apple,sera-pmu";
reg = <0xf SPMI_USID>;
};
};

File diff suppressed because it is too large Load Diff

View File

@@ -1,25 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
&serial0 {
bootph-all;
};
&pmgr {
bootph-all;
};
&ps_sio_busif {
bootph-all;
};
&ps_sio {
bootph-all;
};
&ps_uart_p {
bootph-all;
};
&ps_uart0 {
bootph-all;
};

View File

@@ -1,696 +0,0 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* Apple T8103 "M1" SoC
*
* Other names: H13G, "Tonga"
*
* Copyright The Asahi Linux Contributors
*/
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/apple-aic.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/pinctrl/apple.h>
/ {
compatible = "apple,t8103", "apple,arm-platform";
#address-cells = <2>;
#size-cells = <2>;
cpus {
#address-cells = <2>;
#size-cells = <0>;
cpu0: cpu@0 {
compatible = "apple,icestorm";
device_type = "cpu";
reg = <0x0 0x0>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
cpu1: cpu@1 {
compatible = "apple,icestorm";
device_type = "cpu";
reg = <0x0 0x1>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
cpu2: cpu@2 {
compatible = "apple,icestorm";
device_type = "cpu";
reg = <0x0 0x2>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
cpu3: cpu@3 {
compatible = "apple,icestorm";
device_type = "cpu";
reg = <0x0 0x3>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
cpu4: cpu@10100 {
compatible = "apple,firestorm";
device_type = "cpu";
reg = <0x0 0x10100>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
cpu5: cpu@10101 {
compatible = "apple,firestorm";
device_type = "cpu";
reg = <0x0 0x10101>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
cpu6: cpu@10102 {
compatible = "apple,firestorm";
device_type = "cpu";
reg = <0x0 0x10102>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
cpu7: cpu@10103 {
compatible = "apple,firestorm";
device_type = "cpu";
reg = <0x0 0x10103>;
enable-method = "spin-table";
cpu-release-addr = <0 0>; /* To be filled by loader */
};
};
timer {
compatible = "arm,armv8-timer";
interrupt-parent = <&aic>;
interrupt-names = "phys", "virt", "hyp-phys", "hyp-virt";
interrupts = <AIC_FIQ AIC_TMR_GUEST_PHYS IRQ_TYPE_LEVEL_HIGH>,
<AIC_FIQ AIC_TMR_GUEST_VIRT IRQ_TYPE_LEVEL_HIGH>,
<AIC_FIQ AIC_TMR_HV_PHYS IRQ_TYPE_LEVEL_HIGH>,
<AIC_FIQ AIC_TMR_HV_VIRT IRQ_TYPE_LEVEL_HIGH>;
};
clkref: clock-ref {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <24000000>;
clock-output-names = "clkref";
};
clk_120m: clock-120m {
compatible = "fixed-clock";
#clock-cells = <0>;
clock-frequency = <120000000>;
clock-output-names = "clk_120m";
};
soc {
compatible = "simple-bus";
#address-cells = <2>;
#size-cells = <2>;
ranges;
nonposted-mmio;
i2c0: i2c@235010000 {
compatible = "apple,t8103-i2c", "apple,i2c";
reg = <0x2 0x35010000 0x0 0x4000>;
clocks = <&clkref>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 627 IRQ_TYPE_LEVEL_HIGH>;
pinctrl-0 = <&i2c0_pins>;
pinctrl-names = "default";
#address-cells = <0x1>;
#size-cells = <0x0>;
power-domains = <&ps_i2c0>;
};
i2c1: i2c@235014000 {
compatible = "apple,t8103-i2c", "apple,i2c";
reg = <0x2 0x35014000 0x0 0x4000>;
clocks = <&clkref>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 628 IRQ_TYPE_LEVEL_HIGH>;
pinctrl-0 = <&i2c1_pins>;
pinctrl-names = "default";
#address-cells = <0x1>;
#size-cells = <0x0>;
power-domains = <&ps_i2c1>;
};
i2c2: i2c@235018000 {
compatible = "apple,t8103-i2c", "apple,i2c";
reg = <0x2 0x35018000 0x0 0x4000>;
clocks = <&clkref>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 629 IRQ_TYPE_LEVEL_HIGH>;
pinctrl-0 = <&i2c2_pins>;
pinctrl-names = "default";
#address-cells = <0x1>;
#size-cells = <0x0>;
power-domains = <&ps_i2c2>;
status = "disabled"; /* not used in all devices */
};
i2c3: i2c@23501c000 {
compatible = "apple,t8103-i2c", "apple,i2c";
reg = <0x2 0x3501c000 0x0 0x4000>;
clocks = <&clkref>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 630 IRQ_TYPE_LEVEL_HIGH>;
pinctrl-0 = <&i2c3_pins>;
pinctrl-names = "default";
#address-cells = <0x1>;
#size-cells = <0x0>;
power-domains = <&ps_i2c3>;
};
i2c4: i2c@235020000 {
compatible = "apple,t8103-i2c", "apple,i2c";
reg = <0x2 0x35020000 0x0 0x4000>;
clocks = <&clkref>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 631 IRQ_TYPE_LEVEL_HIGH>;
pinctrl-0 = <&i2c4_pins>;
pinctrl-names = "default";
#address-cells = <0x1>;
#size-cells = <0x0>;
power-domains = <&ps_i2c4>;
status = "disabled"; /* only used in J293 */
};
spi3: spi@23510c000 {
compatible = "apple,t8103-spi", "apple,spi";
reg = <0x2 0x3510c000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 617 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&clk_120m>;
pinctrl-0 = <&spi3_pins>;
pinctrl-names = "default";
power-domains = <&ps_spi3>;
#address-cells = <1>;
#size-cells = <0>;
status = "disabled"; /* only used in J293/J313 */
};
serial0: serial@235200000 {
compatible = "apple,s5l-uart";
reg = <0x2 0x35200000 0x0 0x1000>;
reg-io-width = <4>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 605 IRQ_TYPE_LEVEL_HIGH>;
/*
* TODO: figure out the clocking properly, there may
* be a third selectable clock.
*/
clocks = <&clkref>, <&clkref>;
clock-names = "uart", "clk_uart_baud0";
power-domains = <&ps_uart0>;
status = "disabled";
};
serial2: serial@235208000 {
compatible = "apple,s5l-uart";
reg = <0x2 0x35208000 0x0 0x1000>;
reg-io-width = <4>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 607 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&clkref>, <&clkref>;
clock-names = "uart", "clk_uart_baud0";
power-domains = <&ps_uart2>;
status = "disabled";
};
aic: interrupt-controller@23b100000 {
compatible = "apple,t8103-aic", "apple,aic";
#interrupt-cells = <3>;
interrupt-controller;
reg = <0x2 0x3b100000 0x0 0x8000>;
power-domains = <&ps_aic>;
};
pmgr: power-management@23b700000 {
compatible = "apple,t8103-pmgr", "apple,pmgr", "syscon", "simple-mfd";
#address-cells = <1>;
#size-cells = <1>;
reg = <0x2 0x3b700000 0 0x14000>;
};
pinctrl_ap: pinctrl@23c100000 {
compatible = "apple,t8103-pinctrl", "apple,pinctrl";
reg = <0x2 0x3c100000 0x0 0x100000>;
power-domains = <&ps_gpio>;
gpio-controller;
#gpio-cells = <2>;
gpio-ranges = <&pinctrl_ap 0 0 212>;
apple,npins = <212>;
interrupt-controller;
#interrupt-cells = <2>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 190 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 191 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 192 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 193 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 194 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 195 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 196 IRQ_TYPE_LEVEL_HIGH>;
i2c0_pins: i2c0-pins {
pinmux = <APPLE_PINMUX(192, 1)>,
<APPLE_PINMUX(188, 1)>;
};
i2c1_pins: i2c1-pins {
pinmux = <APPLE_PINMUX(201, 1)>,
<APPLE_PINMUX(199, 1)>;
};
i2c2_pins: i2c2-pins {
pinmux = <APPLE_PINMUX(163, 1)>,
<APPLE_PINMUX(162, 1)>;
};
i2c3_pins: i2c3-pins {
pinmux = <APPLE_PINMUX(73, 1)>,
<APPLE_PINMUX(72, 1)>;
};
i2c4_pins: i2c4-pins {
pinmux = <APPLE_PINMUX(135, 1)>,
<APPLE_PINMUX(134, 1)>;
};
spi3_pins: spi3-pins {
pinmux = <APPLE_PINMUX(46, 1)>,
<APPLE_PINMUX(47, 1)>,
<APPLE_PINMUX(48, 1)>,
<APPLE_PINMUX(49, 1)>;
};
pcie_pins: pcie-pins {
pinmux = <APPLE_PINMUX(150, 1)>,
<APPLE_PINMUX(151, 1)>,
<APPLE_PINMUX(32, 1)>;
};
};
spmi: spmi@23d0d9300 {
compatible = "apple,t8103-spmi", "apple,spmi";
reg = <0x2 0x3d0d9300 0x0 0x100>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 343 IRQ_TYPE_LEVEL_HIGH>;
#address-cells = <2>;
#size-cells = <0>;
status = "disabled";
};
pinctrl_nub: pinctrl@23d1f0000 {
compatible = "apple,t8103-pinctrl", "apple,pinctrl";
reg = <0x2 0x3d1f0000 0x0 0x4000>;
power-domains = <&ps_nub_gpio>;
gpio-controller;
#gpio-cells = <2>;
gpio-ranges = <&pinctrl_nub 0 0 23>;
apple,npins = <23>;
interrupt-controller;
#interrupt-cells = <2>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 330 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 331 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 332 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 333 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 334 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 335 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 336 IRQ_TYPE_LEVEL_HIGH>;
};
pmgr_mini: power-management@23d280000 {
compatible = "apple,t8103-pmgr", "apple,pmgr", "syscon", "simple-mfd";
#address-cells = <1>;
#size-cells = <1>;
reg = <0x2 0x3d280000 0 0x4000>;
};
wdt: watchdog@23d2b0000 {
compatible = "apple,t8103-wdt", "apple,wdt";
reg = <0x2 0x3d2b0000 0x0 0x4000>;
clocks = <&clkref>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 338 IRQ_TYPE_LEVEL_HIGH>;
};
pinctrl_smc: pinctrl@23e820000 {
compatible = "apple,t8103-pinctrl", "apple,pinctrl";
reg = <0x2 0x3e820000 0x0 0x4000>;
gpio-controller;
#gpio-cells = <2>;
gpio-ranges = <&pinctrl_smc 0 0 16>;
apple,npins = <16>;
interrupt-controller;
#interrupt-cells = <2>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 391 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 392 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 393 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 394 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 395 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 396 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 397 IRQ_TYPE_LEVEL_HIGH>;
};
smc_mbox: mbox@23e408000 {
compatible = "apple,t8103-asc-mailbox", "apple,asc-mailbox-v4";
reg = <0x2 0x3e408000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 400 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 401 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 402 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 403 IRQ_TYPE_LEVEL_HIGH>;
interrupt-names = "send-empty", "send-not-empty",
"recv-empty", "recv-not-empty";
#mbox-cells = <0>;
};
smc: smc@23e050000 {
compatible = "apple,smc";
reg = <0x2 0x3e050000 0x0 0x4000>;
mboxes = <&smc_mbox>;
gpio-controller;
#gpio-cells = <2>;
gpio-13 = <0x00800000>;
};
pinctrl_aop: pinctrl@24a820000 {
compatible = "apple,t8103-pinctrl", "apple,pinctrl";
reg = <0x2 0x4a820000 0x0 0x4000>;
gpio-controller;
#gpio-cells = <2>;
gpio-ranges = <&pinctrl_aop 0 0 42>;
apple,npins = <42>;
interrupt-controller;
#interrupt-cells = <2>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 268 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 269 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 270 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 271 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 272 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 273 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 274 IRQ_TYPE_LEVEL_HIGH>;
};
ans_mbox: mbox@277408000 {
compatible = "apple,t8103-asc-mailbox", "apple,asc-mailbox-v4";
reg = <0x2 0x77408000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 583 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 584 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 585 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 586 IRQ_TYPE_LEVEL_HIGH>;
interrupt-names = "send-empty", "send-not-empty",
"recv-empty", "recv-not-empty";
#mbox-cells = <0>;
power-domains = <&ps_ans2>;
};
sart: sart@27bc50000 {
compatible = "apple,t8103-sart", "apple,sart2";
reg = <0x2 0x7bc50000 0x0 0x10000>;
power-domains = <&ps_ans2>;
};
nvme@27bcc0000 {
compatible = "apple,t8103-nvme-ans2", "apple,nvme-ans2";
reg = <0x2 0x7bcc0000 0x0 0x40000>,
<0x2 0x77400000 0x0 0x4000>;
reg-names = "nvme", "ans";
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 590 IRQ_TYPE_LEVEL_HIGH>;
mboxes = <&ans_mbox>;
apple,sart = <&sart>;
power-domains = <&ps_ans2>;
resets = <&ps_ans2>;
};
dwc3_0: usb@382280000 {
compatible = "apple,t8103-dwc3", "apple,dwc3", "snps,dwc3";
reg = <0x3 0x82280000 0x0 0x100000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 777 IRQ_TYPE_LEVEL_HIGH>;
usb-role-switch;
role-switch-default-mode = "host";
iommus = <&dwc3_0_dart_0 0>, <&dwc3_0_dart_1 1>;
power-domains = <&ps_atc0_usb>;
};
dwc3_0_dart_0: iommu@382f00000 {
compatible = "apple,t8103-dart";
reg = <0x3 0x82f00000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 781 IRQ_TYPE_LEVEL_HIGH>;
#iommu-cells = <1>;
power-domains = <&ps_atc0_usb>;
};
dwc3_0_dart_1: iommu@382f80000 {
compatible = "apple,t8103-dart";
reg = <0x3 0x82f80000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 781 IRQ_TYPE_LEVEL_HIGH>;
#iommu-cells = <1>;
power-domains = <&ps_atc0_usb>;
};
dwc3_1: usb@502280000 {
compatible = "apple,t8103-dwc3", "apple,dwc3", "snps,dwc3";
reg = <0x5 0x02280000 0x0 0x100000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 857 IRQ_TYPE_LEVEL_HIGH>;
usb-role-switch;
role-switch-default-mode = "host";
iommus = <&dwc3_1_dart_0 0>, <&dwc3_1_dart_1 1>;
power-domains = <&ps_atc1_usb>;
};
dwc3_1_dart_0: iommu@502f00000 {
compatible = "apple,t8103-dart";
reg = <0x5 0x02f00000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 861 IRQ_TYPE_LEVEL_HIGH>;
#iommu-cells = <1>;
power-domains = <&ps_atc1_usb>;
};
dwc3_1_dart_1: iommu@502f80000 {
compatible = "apple,t8103-dart";
reg = <0x5 0x02f80000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 861 IRQ_TYPE_LEVEL_HIGH>;
#iommu-cells = <1>;
power-domains = <&ps_atc1_usb>;
};
pcie0_dart_0: dart@681008000 {
compatible = "apple,t8103-dart";
reg = <0x6 0x81008000 0x0 0x4000>;
#iommu-cells = <1>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 696 IRQ_TYPE_LEVEL_HIGH>;
power-domains = <&ps_apcie_gp>;
};
pcie0_dart_1: dart@682008000 {
compatible = "apple,t8103-dart";
reg = <0x6 0x82008000 0x0 0x4000>;
#iommu-cells = <1>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 699 IRQ_TYPE_LEVEL_HIGH>;
power-domains = <&ps_apcie_gp>;
};
pcie0_dart_2: dart@683008000 {
compatible = "apple,t8103-dart";
reg = <0x6 0x83008000 0x0 0x4000>;
#iommu-cells = <1>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 702 IRQ_TYPE_LEVEL_HIGH>;
power-domains = <&ps_apcie_gp>;
};
pcie0: pcie@690000000 {
compatible = "apple,t8103-pcie", "apple,pcie";
device_type = "pci";
reg = <0x6 0x90000000 0x0 0x1000000>,
<0x6 0x80000000 0x0 0x100000>,
<0x6 0x81000000 0x0 0x4000>,
<0x6 0x82000000 0x0 0x4000>,
<0x6 0x83000000 0x0 0x4000>;
reg-names = "config", "rc", "port0", "port1", "port2";
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 695 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 698 IRQ_TYPE_LEVEL_HIGH>,
<AIC_IRQ 701 IRQ_TYPE_LEVEL_HIGH>;
msi-controller;
msi-parent = <&pcie0>;
msi-ranges = <&aic AIC_IRQ 704 IRQ_TYPE_EDGE_RISING 32>;
iommu-map = <0x100 &pcie0_dart_0 1 1>,
<0x200 &pcie0_dart_1 1 1>,
<0x300 &pcie0_dart_2 1 1>;
iommu-map-mask = <0xff00>;
bus-range = <0 3>;
#address-cells = <3>;
#size-cells = <2>;
ranges = <0x43000000 0x6 0xa0000000 0x6 0xa0000000 0x0 0x20000000>,
<0x02000000 0x0 0xc0000000 0x6 0xc0000000 0x0 0x40000000>;
power-domains = <&ps_apcie_gp>;
pinctrl-0 = <&pcie_pins>;
pinctrl-names = "default";
port00: pci@0,0 {
device_type = "pci";
reg = <0x0 0x0 0x0 0x0 0x0>;
reset-gpios = <&pinctrl_ap 152 GPIO_ACTIVE_LOW>;
#address-cells = <3>;
#size-cells = <2>;
ranges;
interrupt-controller;
#interrupt-cells = <1>;
interrupt-map-mask = <0 0 0 7>;
interrupt-map = <0 0 0 1 &port00 0 0 0 0>,
<0 0 0 2 &port00 0 0 0 1>,
<0 0 0 3 &port00 0 0 0 2>,
<0 0 0 4 &port00 0 0 0 3>;
};
port01: pci@1,0 {
device_type = "pci";
reg = <0x800 0x0 0x0 0x0 0x0>;
reset-gpios = <&pinctrl_ap 153 GPIO_ACTIVE_LOW>;
#address-cells = <3>;
#size-cells = <2>;
ranges;
interrupt-controller;
#interrupt-cells = <1>;
interrupt-map-mask = <0 0 0 7>;
interrupt-map = <0 0 0 1 &port01 0 0 0 0>,
<0 0 0 2 &port01 0 0 0 1>,
<0 0 0 3 &port01 0 0 0 2>,
<0 0 0 4 &port01 0 0 0 3>;
};
port02: pci@2,0 {
device_type = "pci";
reg = <0x1000 0x0 0x0 0x0 0x0>;
reset-gpios = <&pinctrl_ap 33 GPIO_ACTIVE_LOW>;
#address-cells = <3>;
#size-cells = <2>;
ranges;
interrupt-controller;
#interrupt-cells = <1>;
interrupt-map-mask = <0 0 0 7>;
interrupt-map = <0 0 0 1 &port02 0 0 0 0>,
<0 0 0 2 &port02 0 0 0 1>,
<0 0 0 3 &port02 0 0 0 2>,
<0 0 0 4 &port02 0 0 0 3>;
};
};
dart_sio: iommu@235004000 {
compatible = "apple,t8103-dart", "apple,dart";
reg = <0x2 0x35004000 0x0 0x4000>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 635 IRQ_TYPE_LEVEL_HIGH>;
#iommu-cells = <1>;
power-domains = <&ps_sio_cpu>;
};
nco_inp: clock-ref {
compatible = "fixed-factor-clock";
clocks = <&clkref>;
#clock-cells = <0>;
clock-mult = <75>;
clock-div = <2>; // 24 MHz * (75/2) = 900 MHz
clock-output-names = "nco_inp";
};
nco: nco@23b044000 {
compatible = "apple,t8103-nco", "apple,nco";
reg = <0x2 0x3b044000 0x0 0x14000>;
clocks = <&nco_inp>;
#clock-cells = <1>;
apple,nchannels = <5>;
};
admac: dma-controller@238200000 {
compatible = "apple,t8103-admac", "apple,admac";
reg = <0x2 0x38200000 0x0 0x34000>;
dma-channels = <12>;
interrupt-parent = <&aic>;
interrupts = <AIC_IRQ 626 IRQ_TYPE_LEVEL_HIGH>;
#dma-cells = <1>;
iommus = <&dart_sio 2>;
power-domains = <&ps_sio_adma>;
};
mca: mca {
compatible = "apple,t8103-mca", "apple,mca";
reg = <0x2 0x38400000 0x0 0x18000>,
<0x2 0x38300000 0x0 0x30000>;
reg-names = "clusters", "switch";
clocks = <&nco 0>, <&nco 1>, <&nco 2>, <&nco 3>;
power-domains = <&ps_mca0>; //, <&ps_mca1>, <&ps_mca2>, <&ps_mca3>, <&ps_mca4>, <&ps_mca5>;
resets = <&ps_mca0>, <&ps_mca1>, <&ps_mca2>, <&ps_mca3>, <&ps_mca4>, <&ps_mca5>;
#sound-dai-cells = <1>;
apple,nclusters = <6>;
apple,mclk-range = <2600000 25000000>;
route {
dmas = <&admac 2>;
dma-names = "tx";
apple,serdes = <1>;
sound-dai = <&mca 0>;
};
route2 {
dmas = <&admac 6>;
dma-names = "tx";
apple,serdes = <3>;
sound-dai = <&mca 2>;
};
};
};
};
#include "t8103-pmgr.dtsi"

View File

@@ -222,6 +222,11 @@ u64 get_tcr(u64 *pips, u64 *pva_bits);
* mmu_setup() - Sets up the mmu page tables as per mem_map
*/
void mmu_setup(void);
/**
* mmu_enable() - Enable the MMU by setting 'M' bit in SCTLR register
*/
void mmu_enable(void);
#endif
#endif /* _ASM_ARMV8_MMU_H_ */

View File

@@ -1,3 +1,5 @@
#include <linux/types.h>
#ifdef CONFIG_GPIO_EXTRA_HEADER
#include <asm/arch/gpio.h>
#endif

View File

@@ -3,12 +3,22 @@ if ARCH_APPLE
config TEXT_BASE
default 0x00000000
config SYS_CONFIG_NAME
default "apple"
config SYS_SOC
default "apple"
config SYS_VENDOR
default "apple"
config SYS_BOARD
string "Board name"
default "mac"
help
This option contains information about board name.
Based on this option board/<CONFIG_SYS_VENDOR>/<CONFIG_SYS_BOARD> will
be used.
Apple silicon based devices are expected to use the generic board name
"mac".
config SYS_MALLOC_LEN
default 0x4000000

View File

@@ -673,6 +673,83 @@ static struct mm_region t6022_mem_map[] = {
}
};
/* Apple M3 */
static struct mm_region t8122_mem_map[] = {
{
/* I/O */
.virt = 0x200000000,
.phys = 0x200000000,
.size = 4UL * SZ_1G,
.attrs = PTE_BLOCK_MEMTYPE(MT_DEVICE_NGNRNE) |
PTE_BLOCK_NON_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* NVMe */
.virt = 0x300000000,
.phys = 0x300000000,
.size = SZ_1G,
.attrs = PTE_BLOCK_MEMTYPE(MT_DEVICE_NGNRNE) |
PTE_BLOCK_NON_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* PCIE */
.virt = 0x580000000,
.phys = 0x580000000,
.size = SZ_512M,
.attrs = PTE_BLOCK_MEMTYPE(MT_DEVICE_NGNRNE) |
PTE_BLOCK_NON_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* PCIE */
.virt = 0x5a0000000,
.phys = 0x5a0000000,
.size = SZ_512M,
.attrs = PTE_BLOCK_MEMTYPE(MT_DEVICE_NGNRE) |
PTE_BLOCK_INNER_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* PCIE */
.virt = 0x5c0000000,
.phys = 0x5c0000000,
.size = SZ_1G,
.attrs = PTE_BLOCK_MEMTYPE(MT_DEVICE_NGNRE) |
PTE_BLOCK_INNER_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* I/O ATC0 */
.virt = 0x700000000,
.phys = 0x700000000,
.size = SZ_1G,
.attrs = PTE_BLOCK_MEMTYPE(MT_DEVICE_NGNRNE) |
PTE_BLOCK_NON_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* I/O ATC1 */
.virt = 0xb00000000,
.phys = 0xb00000000,
.size = SZ_1G,
.attrs = PTE_BLOCK_MEMTYPE(MT_DEVICE_NGNRNE) |
PTE_BLOCK_NON_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* RAM */
.virt = 0x10000000000,
.phys = 0x10000000000,
.size = 8UL * SZ_1G,
.attrs = PTE_BLOCK_MEMTYPE(MT_NORMAL) |
PTE_BLOCK_INNER_SHARE
}, {
/* Framebuffer */
.attrs = PTE_BLOCK_MEMTYPE(MT_NORMAL_NC) |
PTE_BLOCK_INNER_SHARE |
PTE_BLOCK_PXN | PTE_BLOCK_UXN
}, {
/* List terminator */
0,
}
};
struct mm_region *mem_map;
int board_init(void)
@@ -720,6 +797,8 @@ void build_mem_map(void)
mem_map = t6020_mem_map;
else if (of_machine_is_compatible("apple,t6022"))
mem_map = t6022_mem_map;
else if (of_machine_is_compatible("apple,t8122"))
mem_map = t8122_mem_map;
else
panic("Unsupported SoC\n");

View File

@@ -11,6 +11,7 @@
#include <asm/io.h>
#include <asm/arch/rtkit.h>
#include <linux/iopoll.h>
#include <linux/sizes.h>
/* ASC registers */
#define REG_CPU_CTRL 0x0044

View File

@@ -78,7 +78,6 @@ choice
config TARGET_AT91SAM9260EK
bool "Atmel at91sam9260 reference board"
select AT91SAM9260
select BOARD_EARLY_INIT_F
config TARGET_GURNARD
bool "Support gurnard"
@@ -96,7 +95,6 @@ config TARGET_GURNARD
config TARGET_AT91SAM9261EK
bool "Atmel at91sam9261 reference board"
select AT91SAM9261
select BOARD_EARLY_INIT_F
config TARGET_PM9261
bool "Ronetix pm9261 board"
@@ -105,7 +103,6 @@ config TARGET_PM9261
config TARGET_AT91SAM9263EK
bool "Atmel at91sam9263 reference board"
select AT91SAM9263
select BOARD_EARLY_INIT_F
config TARGET_USB_A9263
bool "Caloa USB A9260 board"
@@ -119,7 +116,6 @@ config TARGET_PM9263
config TARGET_AT91SAM9M10G45EK
bool "Atmel AT91SAM9M10G45-EK board"
select AT91SAM9M10G45
select BOARD_EARLY_INIT_F
select SUPPORT_SPL
config TARGET_PM9G45
@@ -129,18 +125,15 @@ config TARGET_PM9G45
config TARGET_AT91SAM9N12EK
bool "Atmel AT91SAM9N12-EK board"
select AT91SAM9N12
select BOARD_EARLY_INIT_F
select SUPPORT_SPL
config TARGET_AT91SAM9RLEK
bool "Atmel at91sam9rl reference board"
select AT91SAM9RL
select BOARD_EARLY_INIT_F
config TARGET_AT91SAM9X5EK
bool "Atmel AT91SAM9X5-EK board"
select AT91SAM9X5
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select SUPPORT_SPL
@@ -154,31 +147,26 @@ config TARGET_GARDENA_SMART_GATEWAY_AT91SAM
config TARGET_SAM9X60EK
bool "SAM9X60-EK board"
select SAM9X60
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
config TARGET_SAM9X60_CURIOSITY
bool "SAM9X60 CURIOSITY board"
select SAM9X60
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
config TARGET_SAM9X75_CURIOSITY
bool "SAM9X75 CURIOSITY board"
select SAM9X7
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
imply OF_UPSTREAM
config TARGET_SAMA5D2_PTC_EK
bool "SAMA5D2 PTC EK board"
select BOARD_EARLY_INIT_F
select SAMA5D2
select BOARD_LATE_INIT
config TARGET_SAMA5D2_XPLAINED
bool "SAMA5D2 Xplained board"
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select SAMA5D2
select SUPPORT_SPL
@@ -186,7 +174,6 @@ config TARGET_SAMA5D2_XPLAINED
config TARGET_SAMA5D27_SOM1_EK
bool "SAMA5D27 SOM1 EK board"
select SAMA5D2
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select CPU_V7A
select SUPPORT_SPL
@@ -201,7 +188,6 @@ config TARGET_SAMA5D27_SOM1_EK
config TARGET_SAMA5D27_WLSOM1_EK
bool "SAMA5D27 WLSOM1 EK board"
select SAMA5D2
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select CPU_V7A
select SUPPORT_SPL
@@ -228,7 +214,6 @@ config TARGET_SAMA5D2_ICP
bool "SAMA5D2 Industrial Connectivity Platform (ICP)"
select SAMA5D2
select SUPPORT_SPL
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
help
The SAMA5D2 ICP embeds SAMA5D27 rev. C SoC, together with
@@ -248,28 +233,24 @@ config TARGET_SAMA5D29_CURIOSITY
config TARGET_SAMA5D3_XPLAINED
bool "SAMA5D3 Xplained board"
select BOARD_EARLY_INIT_F
select SAMA5D3
select SUPPORT_SPL
select BOARD_LATE_INIT
config TARGET_SAMA5D3XEK
bool "SAMA5D3X-EK board"
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select SAMA5D3
select SUPPORT_SPL
config TARGET_SAMA5D4_XPLAINED
bool "SAMA5D4 Xplained board"
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select SAMA5D4
select SUPPORT_SPL
config TARGET_SAMA5D4EK
bool "SAMA5D4 Evaluation Kit"
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
select SAMA5D4
select SUPPORT_SPL
@@ -291,7 +272,6 @@ config TARGET_CORVUS
config TARGET_SAMA7G5EK
bool "SAMA7G5 EK board"
select SAMA7G5
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
config TARGET_SAMA7G54_CURIOSITY
@@ -307,7 +287,6 @@ config TARGET_SAMA7G54_CURIOSITY
config TARGET_SAMA7D65_CURIOSITY
bool "SAMA7D65 CURIOSITY board"
select SAMA7D65
select BOARD_EARLY_INIT_F
select BOARD_LATE_INIT
imply OF_UPSTREAM

View File

@@ -132,7 +132,8 @@ void board_init_f(ulong dummy)
timer_init();
board_early_init_f();
if (IS_ENABLED(CONFIG_BOARD_EARLY_INIT_F))
board_early_init_f();
at91_mem_init();

View File

@@ -294,6 +294,7 @@ void enable_caches(void)
__func__, ret);
}
mmu_enable();
icache_enable();
dcache_enable();
}

View File

@@ -126,4 +126,14 @@ struct rom_extended_boot_data {
u32 get_boot_device(void);
const char *get_reset_reason(void);
#define writel_verify(val, addr) \
do { \
u32 readback; \
writel(val, addr); \
readback = readl(addr); \
if (readback != val) \
printf("writel_verify failed: addr=0x%p, expected=0x%x, got=0x%x\n", \
(void *)(addr), (val), readback); \
} while (0)
#endif /* _ASM_ARCH_HARDWARE_H_ */

View File

@@ -40,6 +40,15 @@
#define NB_THREADMAP_BIT1 BIT(1)
#define NB_THREADMAP_BIT2 BIT(2)
/*
* RAT mapping for errata ID: i2437
*/
#define RAT_ERRATA_2437_BASE_REGION0 0x40f90000
#define RAT_ERRATA_2437_IN_ADDR 0xc0000000
#define RAT_ERRATA_2437_OUT_ADDR_U 0x0000004d
#define RAT_ERRATA_2437_OUT_ADDR_L 0x21000000
#define RAT_ERRATA_2437_CTRL 0x80000010
struct fwl_data cbass_hc_cfg0_fwls[] = {
{ "PCIE0_CFG", 2577, 7 },
{ "EMMC8SS0_CFG", 2579, 4 },
@@ -346,6 +355,36 @@ void board_init_f(ulong dummy)
if (ret)
printf("AVS init failed: %d\n", ret);
}
if (IS_ENABLED(CONFIG_CPU_V7R)) {
/*
* Errata ID i2437: SE Clock-Gating Turning Off Too Early
*
* A hardware bug is present in the C7120 Streaming Engine top level
* clock gating logic that can lead to the C7120 CPU hanging.
* Workaround: The DSP_<COREID>_DEBUG_CLKEN_OVERRIDE fields of the
* COMPUTE_CLUSTER_CFG_WRAP_0_CC_CNTRL register (where COREID is the
* name of the specific C7120 core) must be enabled before power-up
* of the C7120 core to override all clock-gating.
*/
/* Setup RAT mapping */
debug("Errata i2437: Use RAT for COMPUTE_CLUSTER_CFG_WRAP_0_CC_CNTRL register\n");
writel_verify(RAT_ERRATA_2437_IN_ADDR, RAT_ERRATA_2437_BASE_REGION0 + 0x24);
writel_verify(RAT_ERRATA_2437_OUT_ADDR_L, RAT_ERRATA_2437_BASE_REGION0 + 0x28);
writel_verify(RAT_ERRATA_2437_OUT_ADDR_U, RAT_ERRATA_2437_BASE_REGION0 + 0x2c);
writel_verify(RAT_ERRATA_2437_CTRL, RAT_ERRATA_2437_BASE_REGION0 + 0x20);
/* Enable DSP_X_DEBUG_CLKEN_OVERRIDE for C71x cores */
writel_verify(0x300, RAT_ERRATA_2437_IN_ADDR + 0x200);
/* Clear RAT mapping */
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x20);
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x24);
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x28);
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x2c);
}
}
#endif

View File

@@ -45,6 +45,15 @@
#define NB_THREADMAP_BIT1 BIT(1)
#define NB_THREADMAP_BIT2 BIT(2)
/*
* RAT mapping for errata ID: i2437
*/
#define RAT_ERRATA_2437_BASE_REGION0 0x40f90000
#define RAT_ERRATA_2437_IN_ADDR 0xc0000000
#define RAT_ERRATA_2437_OUT_ADDR_U 0x0000004d
#define RAT_ERRATA_2437_OUT_ADDR_L 0x21000000
#define RAT_ERRATA_2437_CTRL 0x80000010
struct fwl_data infra_cbass0_fwls[] = {
{ "PSC0", 5, 1 },
{ "PLL_CTRL0", 6, 1 },
@@ -322,6 +331,36 @@ void board_init_f(ulong dummy)
setup_navss_nb();
setup_qos();
if (IS_ENABLED(CONFIG_CPU_V7R)) {
/*
* Errata ID i2437 SE Clock-Gating Turning Off Too Early
*
* A hardware bug is present in the C7120 Streaming Engine top level
* clock gating logic that can lead to the C7120 CPU hanging.
* Workaround: The DSP_<COREID>_DEBUG_CLKEN_OVERRIDE fields of the
* COMPUTE_CLUSTER_CFG_WRAP_0_CC_CNTRL register (where COREID is the
* name of the specific C7120 core) must be enabled before power-up
* of the C7120 core to override all clock-gating.
*/
/* Setup RAT mapping */
debug("Errata i2437: Use RAT for COMPUTE_CLUSTER_CFG_WRAP_0_CC_CNTRL register\n");
writel_verify(RAT_ERRATA_2437_IN_ADDR, RAT_ERRATA_2437_BASE_REGION0 + 0x24);
writel_verify(RAT_ERRATA_2437_OUT_ADDR_L, RAT_ERRATA_2437_BASE_REGION0 + 0x28);
writel_verify(RAT_ERRATA_2437_OUT_ADDR_U, RAT_ERRATA_2437_BASE_REGION0 + 0x2c);
writel_verify(RAT_ERRATA_2437_CTRL, RAT_ERRATA_2437_BASE_REGION0 + 0x20);
/* Enable DSP_X_DEBUG_CLKEN_OVERRIDE for C71x cores */
writel_verify(0xF00, RAT_ERRATA_2437_IN_ADDR + 0x200);
/* Clear RAT mapping */
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x20);
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x24);
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x28);
writel_verify(0, RAT_ERRATA_2437_BASE_REGION0 + 0x2c);
}
}
u32 spl_mmc_boot_mode(struct mmc *mmc, const u32 boot_device)

View File

@@ -195,7 +195,6 @@ config SYS_BOARD
be used.
config SYS_CONFIG_NAME
default "mt7622" if TARGET_MT7622
default "mt7623" if TARGET_MT7623
default "mt7629" if TARGET_MT7629
default "mt7981" if TARGET_MT7981

View File

@@ -1,15 +1,19 @@
if ARCH_RENESAS
# Renesas ARM SoCs R-Car Gen3/Gen4 (64bit)
config TMU_TIMER
bool
# Renesas ARM SoCs R-Car Gen3/Gen4/Gen5 (64bit Cortex-A / 32bit Cortex-M/R)
config RCAR_64
bool
select ARM64
select CPU_V8M if RCAR_64_RSIP
select ARM64 if !RCAR_64_RSIP
select CMD_CACHE
select OF_BOARD_SETUP
select OF_BOARD_SETUP if !RCAR_64_RSIP
select PHY
select PINCONF
select PINCTRL
select POSITION_INDEPENDENT
select POSITION_INDEPENDENT if !RCAR_64_RSIP
imply CMD_FS_UUID
imply CMD_GPT
imply CMD_MMC_SWRITE if MMC

Some files were not shown because too many files have changed in this diff Show More