summaryrefslogtreecommitdiff
path: root/arch
AgeCommit message (Collapse)Author
2023-03-30arm64: dts: imx8mp: Add FEC RMII pin mux on i.MX8MP DHCOMMarek Vasut
The i.MX8MP DHCOM SoM may come with either external RGMII PHY or LAN8740Ai RMII PHY on the SoM attached to FEC MAC. Add pin mux settings for both options, so that DT overlay can override these settings on SoM variant with the LAN8740Ai PHY. Signed-off-by: Marek Vasut <[email protected]>
2023-03-30arm64: dts: imx8mp: Add EQoS RMII pin mux on i.MX8MP DHCOMMarek Vasut
The i.MX8MP DHCOM SoM may come with either KSZ9131RNXI RGMII PHY or LAN8740Ai RMII PHY on the SoM attached to EQoS MAC. Add pin mux settings for both options, so that DT overlay can override these settings on SoM variant with the LAN8740Ai PHY. Signed-off-by: Marek Vasut <[email protected]>
2023-03-30arm64: dts: imx8mp: Adjust EQoS PHY address on i.MX8MP DHCOMMarek Vasut
The current variant of the SoM has LAN8740Ai PHY connected to EQoS strapped to MDIO address 0 , adjust the MDIO address to match the hardware. Signed-off-by: Marek Vasut <[email protected]>
2023-03-30arm: mvebu: Define all options for AXP BOOT_FROM_* macrosPali Rohár
Definitions are according to the MV78460 Hardware Specifications. Signed-off-by: Pali Rohár <[email protected]> Tested-by: Tony Dinh <[email protected]> Tested-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: Define all BOOTROM_ERR_MODE_* macrosPali Rohár
A385 BootROM fills into bits [31:28] of register 0x182d0 tracing value, which represents in which state BootROM currently is. BootROM fills one of the possible values: 0x2 (CPU initialization), 0x3 (UART detection), 0x6 (UART booting), 0x8 (PCI Express booting), 0x9 (parallel or SPI NOR booting), 0xA (parallel or SPI NAND booting), 0xB (SATA booting) and 0xE (SD / eMMC booting). Meaning of these values matches TRACE_* macros from Marvell soc_spec.h file: https://github.com/MarvellEmbeddedProcessors/u-boot-marvell/blob/u-boot-2013.01-armada-18.06/tools/marvell/doimage_mv/soc_spec.h Signed-off-by: Pali Rohár <[email protected]> Tested-by: Tony Dinh <[email protected]> Tested-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: Define all options for A38x BOOT_FROM_* macrosPali Rohár
Disassembling A385 BootROM binary reveal how BootROM interprets strapping pins for Boot Device Mode. All possible options are: 0x00..0x07 -> Parallel NOR 0x08..0x15 -> Parallel NAND 0x16..0x17 -> Parallel NOR 0x18..0x25 -> Parallel NAND 0x26..0x27 -> SPI NAND 0x28..0x29 -> UART xmodem 0x2a..0x2b -> SATA 0x2c..0x2d -> PCI Express 0x2e..0x2f -> Parallel NOR 0x30..0x31 -> SD / eMMC 0x32..0x39 -> SPI NOR 0x3a..0x3c -> Parallel NOR 0x3d..0x3e -> UART debug console 0x3f -> Invalid Note that Boot Device Mode Options in A38x Hardware Specifications is incomplete. Signed-off-by: Pali Rohár <[email protected]> Tested-by: Tony Dinh <[email protected]> Tested-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: Convert BOOT_FROM_* constants to function macrosPali Rohár
This allows to merge BOOT_FROM_MMC and BOOT_FROM_MMC_ALT constants to one macro. And also allows to extend other BOOT_FROM_* macros for other variants. Signed-off-by: Pali Rohár <[email protected]> Tested-by: Tony Dinh <[email protected]> Tested-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: Remove A38x BOOT_FROM_SATA 0x22 constantPali Rohár
A385 BootROM treats strapping configuration 0x22 as SPI-NAND. So remove incorrect definition 0x22 as SATA. SATA on A385 has configuration 0x2A. Signed-off-by: Pali Rohár <[email protected]> Tested-by: Tony Dinh <[email protected]> Tested-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: Remove A38x BOOT_FROM_UART_ALT 0x3f constantPali Rohár
A385 BootROM treats strapping configuration 0x3f as invalid. When booting fails (e.g. because of invalid configuration) then BootROM fallbacks to UART booting. Detecting BootROM fallback to UART booting is implemented in U-Boot since commit 2fd4284051e3 ("ARM: mach-mvebu: handle fall-back to UART boot"). So there is no need to define BOOT_FROM_UART_ALT constant and special handling for it anymore, remove it. This change effectively revers commit f3a88e2ca17a ("arm: mvebu: fix boot from UART on ClearFog Base"). Signed-off-by: Pali Rohár <[email protected]> Tested-by: Tony Dinh <[email protected]> Tested-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: Cleanup get_boot_device() codePali Rohár
Show correct information in debug() output and use correct names for variables. No functional change. Signed-off-by: Pali Rohár <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: clearfog: Detect MMC vs SDHC and fixup fdtMartin Rowe
[upstream of vendor commit 19a96f7c40a8fc1d0a6546ac2418d966e5840a99] The Clearfog devices have only one SDHC device. This is either eMMC if it is populated on the SOM or SDHC if not. The Linux device tree assumes the SDHC case. Detect if the device is an eMMC and fixup the device-tree so it will be detected by Linux. Ported from vendor repo at https://github.com/SolidRun/u-boot Signed-off-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30arm: mvebu: clearfog: Fix MMC detectionMartin Rowe
A388 Clearfog MMC is either SD Card or eMMC with different behaviour for both. Setting the device to non-removable in the u-boot.dtsi allows both to correctly detect the device. Signed-off-by: Martin Rowe <[email protected]> Reviewed-by: Stefan Roese <[email protected]>
2023-03-30imx: spl_imx_romapi: Get and print boot stageYe Li
Get and print boot stage through ROM API in SPL Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29pico-imx6: Pass the mmc alias to fix boot regressionFabio Estevam
Originally, the mmc aliases node was present in imx6qdl-pico.dtsi. After the sync with Linux in commit d0399a46e7cd ("imx6dl/imx6qdl: synchronise device trees with linux"), the aliases node is gone as the upstream version does not have it. This causes a boot regression in which the eMMC card cannot be found anymore. Fix it by passing the alias node in the u-boot.dtsi file to restore the original behaviour where the eMMC (esdhc3) was mapped to mmc0. Fixes: d0399a46e7cd ("imx6dl/imx6qdl: synchronise device trees with linux") Signed-off-by: Fabio Estevam <[email protected]>
2023-03-29imx: ele_ahab: Remove OEM Secure World Closed printYe Li
The OEM Secure World Closed is not a valid lifecycle on iMX8ULP/iMX9. So remove it from lifecycle print. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: ele_ahab: confirm lifecycle before closing the partYe Li
Before moving the lifecycle to OEM closed, confirm the lifecycle is OEM open, otherwise cancel to move forward the lifecycle. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29misc: sentinel: s400_api: Use new command request definitionsYe Li
Remove legacy command definitions, change to use new ELE_xxx command request. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: ahab: Move imx9 and imx8ulp AHAB support togetherYe Li
Use common file ele_ahab.c for i.MX9 and iMX8ULP AHAB support, since both of them use same sentinel ELE APIs Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx93: ahab: Get and decode AHAB eventsYe Li
For ahab_status command, support to get and decode AHAB events Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29misc: sentinel: s400_api: Add get_events APIYe Li
Add get_events API to retrieve any singular events that has occurred since the FW has started from sentinel Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx8ulp_evk: Change to use DDR driverYe Li
Remove the DDR initialization codes from board and enable the iMX8ULP DDR driver. Signed-off-by: Ye Li <[email protected]>
2023-03-29imx: sentinel: Update S400 API get info message structureYe Li
From Sentinel FW v0.0.9-9df0f503, the response message of get info API is changed to add OEM SRK and some states (IMEM, CSAL, TRNG). With old structure, we get failure from sentinel due to the buffer size can't fit with new response message. So update the API structure to fix the issue. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Update clocks to meet max rate restrictionsYe Li
Update PLL3/PLL4 PFD and USDHC clocks to meet maximum frequency restrictions. Detail clock rate changes in the patch: PLL3 PFD2: 389M -> 324M PLL3 PFD3: 336M -> 389M PLL3 PFD3: DIV1 336M -> 389M (OD), 194M (ND/LD) PLL3 PFD3: DIV2 336M -> 194M (OD), 97M (ND/LD) PLL4 PFD0: 792M -> 594M PLL4 PFD2: 792M -> 316.8M NIC_AP: 96M (ND) -> 192M, 48M (LD) -> 96M NIC_LPAV: 198 (ND) -> 192M, 99M (LD) -> 96M USDHC0: PLL3 PFD3 DIV1, 389M (OD), 194M (ND/LD) USDHC1: PLL3 PFD3 DIV2, 194M (OD), 97M (ND/LD) USDHC2: PLL3 PFD3 DIV2, 194M (OD), 97M (ND/LD) Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Configure XRDC PDAC and MSC for DBD owner=S400 onlyYe Li
This patch is used to support DBD owner fuse changed to S400 only. The XRDC PDAC2 for LPAV pbridge5 and MSC1/2/3 for GPIO and LPAV are not configured by S400 default setting. So these PDAC and MSC are invalid, only DBD owner can access the corresponding resources. We have to configure necessary PDAC and MSC for SPL before DDR initialization. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: upower: make code cleanerPeng Fan
To clean the upower codes by aligning codes format, check err_code and add detail bits list for the memory magic number Reviewed-by: Ye Li <[email protected]> Signed-off-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: upower: replace magic number with macroPeng Fan
The swton indicates the logic switch, magic number 0xfff80 is hard to understand, so use macro. Some board design may not have MIPI_CSI voltage input connected per data sheet. In that case, the upower power on API may dead loop mu to wait response, however there is no response. So remove MIPI_CSI here, let linux power domain driver to runtime enable the power domain. Reviewed-by: Ye Li <[email protected]> Signed-off-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Clear dividers in PLL3DIV_PFD registersYe Li
At present, in cgc1_pll3_init we don't set the pll3pfd div values, just use the default 0. But on A1 part, ROM will set PLL3 pfd1div2 to 1 and pfd2div1 to 3. This finally causes some clocks' rate decreased, for example USDHC. So clear the PLL3DIV_PFD dividers to get correct rate. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Reconfigure MRC3 for SRAM0 accessYe Li
Some space in SRAM0 will be protected by S400 to allow RX SecPriv mode access only for boot purpose. Since SW will reuse the SRAM0 as SCMI buffer and SPL container loading buffer, need to reconfigure MRC3. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: configure XRDC for DRAM access from S400Ye Li
Need to add DRAM access permission for S400, as S400 needs to access it When SPL calls image authentication Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Adjust handshake to sync TRDC and XRDC completionYe Li
To fit the DBD_EN fused part, we re-design the TRDC and XRDC assignment. M33 will be the TRDC owner and needs to configure TRDC. A35 is the XRDC owner, ATF will configure XRDC. The handshake between U-boot and M33 image is used to sync TRDC and XRDC configuration completion. Once the handshake is done, A35 and M33 can access the allowed resources in others domain. The handshake is needed when M33 is booted or DBD_EN fused, because both cases will enable the TRDC. If handshake is timeout, the boot will hang. We use SIM GPR0 to pass the info from SPL to u-boot, because before the handshake, u-boot can't access SEC SIM and FSB. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Jacky Bai <[email protected]>
2023-03-29imx: imx8ulp: Remove the TRDC configure from A35Ye Li
As M33 is responsible for TRDC configuration, the settings for A35 nonsecure world access and DMA0 access are moved to M33 image. So remove the codes to release TRDC and configure it. Just keep the configurations for reference. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Jacky Bai <[email protected]>
2023-03-29imx: imx8ulp: Set XRDC MRC4/5 for access DDR from APDYe Li
iMX8ULP A1 S400 ROM removes the setting for MRC4/5. So we have to set them in SPL to allow access to DDR from A35 and APD PER masters Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Limit the eMMC ROM API workaround to A0.1 partYe Li
Since A1 ROM has fixed the ROM API eMMC issue, we should only use the workaround for A0.1 part. Add a SOC revision check. Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Get chip revision from SentinelYe Li
In both SPL and u-boot, after probing the S400 MU, get the chip revision, lifecycle and UID from Sentinel. Update get_cpu_rev to use the chip revision not hard coded it for A0 Signed-off-by: Ye Li <[email protected]> Reviewed-by: Peng Fan <[email protected]>
2023-03-29imx: imx8ulp: Fix MU device probe failureYe Li
Since latest DTS has added multiple MU nodes, using compatible string to find the device node is not proper. It finds the first node with the compatible string matched even the node is disabled. Signed-off-by: Ye Li <[email protected]>
2023-03-29mpc83xx: Remove CONFIG_SYS_GPIO{1/2}_PRELIM and relatedChristophe Leroy
Last use of CONFIG_SYS_GPIO1_PRELIM was removed by commit fae2ea5951 ("ppc: Remove MPC8349EMDS board and ARCH_MPC8349 support"). Last use of CONFIG_SYS_GPIO2_PRELIM was removed even before by commit 6843862342 ("ppc: Remove caddy2 / vme8349 boards") Those two items were removed from whitelist by commit 8cca60a2cb ("Kconfig: Remove some symbols from the whitelist") Signed-off-by: Christophe Leroy <[email protected]> Fixes: fae2ea5951 ("ppc: Remove MPC8349EMDS board and ARCH_MPC8349 support")
2023-03-29mpc83xx: Remove stale CONFIG_SYS_LBLAWBAR{4/5/6/7}_PRELIMChristophe Leroy
Last (incorrect) use of those CONFIG items was removed by commit 9fd9abedcc ("TQM834x: remove defines causing gcc4.4 warnings") Those items are invalid and should have been removed at the same time because lblaw[] has only 4 elements. And they were removed from the whitelist by commit 9c5df7a2a9 ("mpc83xx: Migrate LBLAW_* to Kconfig") Signed-off-by: Christophe Leroy <[email protected]> Fixes: 9fd9abedcc ("TQM834x: remove defines causing gcc4.4 warnings")
2023-03-29arm: mach-k3: introduce generic board detction kconfig optionChristian Gmeiner
For non TI boards it is not possible to enable the do_board_detect() call as TI_I2C_BOARD_DETECT is defined in board/ti/common/Kconfig. I want to use do_board_detect() to dectect boards and properties based on some SPI communication with a FPGA. Signed-off-by: Christian Gmeiner <[email protected]> Reviewed-by: Tom Rini <[email protected]>
2023-03-29iot2050: Add support for configuring M.2 connectorJan Kiszka
The M.2 slots of the related IOT2050 variant need to be configured according to the plugged cards. This tries to detect the card using the M.2 configuration pins of the B-key slot. If that fails, a U-Boot environment variable can be set to configure manually. This variable is write-permitted also in secure boot mode as it is not able to undermine the integrity of the booted system. The configuration is then applied to mux the serdes and to fix up the device tree passed to or loaded by the bootloader. The fix-ups are coming from device tree overlays that are embedded into the firmware image and there also integrity protected. The OS remains free to load a device tree to which they do not apply: U-Boot will not fail to boot in that case. Based on original patch by Chao Zeng. Signed-off-by: Jan Kiszka <[email protected]>
2023-03-29arm: dts: iot2050: Add support for M.2 variantchao zeng
Add support for the M.2 board based on the iot2050 advanced board. The board has two m.2 connectors, one is B-keyed, the other E-keyed. The B-key slot can connect 5G/SSD devices, and E-key can be used for WIFI/BT devices. This variant is covered by PG2 firmware image. Signed-off-by: chao zeng <[email protected]> [Jan: align DT to kernel, polish wording] Signed-off-by: Jan Kiszka <[email protected]>
2023-03-29arm: dts: iot2050: Optionally embed OTP programming data into imageJan Kiszka
Use external blob otpcmd.bin to replace the 0xff filled OTP programming command block to create a firmware image that provisions the OTP on first boot. This otpcmd.bin is generated from the customer keys using steps described in the meta-iot2050 integration layer for the device. Based on original patch by Baocheng Su. Signed-off-by: Jan Kiszka <[email protected]>
2023-03-29arm: dts: iot2050: Allow verifying U-Boot proper by SPLJan Kiszka
Add hashes and configuration signature stubs to prepare verified boot of main U-Boot by SPL. Signed-off-by: Jan Kiszka <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2023-03-29iot2050: Update firmware layoutJan Kiszka
The latest version of the binary-only firmware parts come in a combined form of FSBL and sysfw containers. This implies some layout changes to the generated firmware image but also makes handling of artifacts much simpler (4 files less). The env locations will not change, just the space reserved for U-Boot will shrink from 4 to 3 MB - still plenty of space left in practice. Adjust configuration and documentation accordingly. Along this change, add a new reservation for update commands of the user-controlled OTP part. A specific userspace tool will fill it, and the FSBL will evaluate it during boot. This reservation will use 64K of the former sysfw section. Signed-off-by: Jan Kiszka <[email protected]>
2023-03-29arm: dts: iot2050: Use the auto generator nodes for fdtSu Baocheng
Refactor according to the entry `fit: Entry containing a FIT` of document tools/binman/README.entries. As the generator uses the device tree name for the config description, board_fit_config_name_match requires a small adjustment as well. Signed-off-by: Su Baocheng <[email protected]> [Jan: re-add now required CONFIG_OF_LIST, update config matching] Signed-off-by: Jan Kiszka <[email protected]> Reviewed-by: Simon Glass <[email protected]>
2023-03-29board: siemens: iot2050: Split the build for PG1 and PG2Su Baocheng
Due to different signature keys, the PG1 and the PG2 boards can no longer use the same FSBL (tiboot3). This makes it impossible anyway to maintaine a single flash.bin for both variants, so we can also split the build. A new target is added to indicates the build is for PG1 vs. PG2 boards. Hence now the variants have separated defconfig files. The runtime board_is_sr1() check does make no sense anymore, so remove it and replace with build time check. Documentation is updated accordingly. New binary artifacts are already available via meta-iot2050. Signed-off-by: Su Baocheng <[email protected]> [Jan: refactor config option into targets, tweak some wordings] Signed-off-by: Jan Kiszka <[email protected]>
2023-03-28imx6sx-udoo-neo-basic: Introduce the u-boot.dtsiFabio Estevam
After the conversion to DM_SERIAL in commit 01f372d8d62b ("udoo_neo: Select DM_SERIAL and drop iomux board level init") the SPL log is gone and the U-Boot proper log becomes incomplete: Core: 80 devices, 18 uclasses, devicetree: separate MMC: FSL_SDHC: 1, FSL_SDHC: 2 Loading Environment from MMC... OK In: serial@2020000 Out: serial@2020000 Err: serial@2020000 Net: eth0: ethernet@2188000 Hit any key to stop autoboot: 0 Introduce the u-boot.dtsi file that passes the u-boot,dm-pre-reloc properties to the relevant nodes so that UART can be used early in SPL. With this change, the complete SPL and U-Boot messages are seen again. Signed-off-by: Fabio Estevam <[email protected]>
2023-03-27Revert "rockchip: Fix early use of bootph props"Tom Rini
While this change is correct for v2023.04 it is not correct for next (where this is right now) nor post-v2023.04. This reverts commit 8653e5d3b745925fced5fa6897c92f4a46ec2757. Signed-off-by: Tom Rini <[email protected]>
2023-03-27Merge branch 'master' into nextTom Rini
2023-03-27rockchip: Use BOOTSTD_DEFAULTS if not DISTRO_DEFAULTSTom Rini
When we do not enable DISTRO_DEFAULTS (generally, to get distro_bootcmd) we instea do want to imply BOOTSTD_DEFAULTS so that when using bootstd the general distro boot functionality will still work. Signed-off-by: Tom Rini <[email protected]>
2023-03-27rockchip: Disable DISTRO_DEFAULTS for rk3399 boardsSimon Glass
These board have moved to standard boot but the old 'distro_bootcmd' command is still active. Disable DISTRO_DEFAULTS to fix this. Signed-off-by: Simon Glass <[email protected]> Tested-by: Vagrant Cascadian <[email protected]>