1
0
Fork 0
mirror of https://github.com/u-boot/u-boot.git synced 2025-04-29 01:14:45 +00:00
Commit graph

10692 commits

Author SHA1 Message Date
Simon Glass
4acbd003d3 sandbox: Update sandbox_vpl to select sha1 and sha256
These algorithms are used in VPL, so enable them.

Signed-off-by: Simon Glass <sjg@chromium.org>
2025-02-03 16:00:42 -06:00
Tom Rini
2beaa34252 configs/am62x_r5_usbdfu.config: More completely disable MMC
As this fragment turns off MMC in both SPL and full U-Boot, we can turn
the whole symbol off rather than just the MMC driver.

Signed-off-by: Tom Rini <trini@konsulko.com>
2025-01-31 11:05:02 -06:00
Tom Rini
a582e48533 STM32 MPU:
- Remove dt-bindings headers available in dts/upstream
 - Fixes for stm32prog
 - Enable CONFIG_SYS_64BIT_LBA for STM32MP15/13/25 defconfigs
 - Add upport of ck_usbo_48m in pre-reloc stage for STM32MP13
 - Clean env_get_location() for STM32MP1
 - Fix board_get_usable_ram_top() to fix infinite loop in cache
   management for STM32MP2.
 - Fix ck_flexgen_08 frequency for STM32MP2
 
 STM32 MCU:
 - Tune CYCLIC_MAX_CPU_TIME_US to avoid cyclic warning for STM32F469-Disco
 - Tune CYCLIC_MAX_CPU_TIME_US to avoid cyclic warning for STM32F769-Disco
 -----BEGIN PGP SIGNATURE-----
 
 iQJQBAABCgA6FiEEXyrViUccKBz9c35Jysd4L3sz/6YFAmecl/gcHHBhdHJpY2Uu
 Y2hvdGFyZEBmb3NzLnN0LmNvbQAKCRDKx3gvezP/pns8D/oCH3arsB5lw1Mb6iMV
 bP5J8gVUQzCSGlm45XHd0I0VDZoVuxfCvzTPSmQaAajix8B92brpIq+nA59pm6rD
 hu4pyuBt+KpE7amiqw+KCiGqucHcWHpWCf5kLBgkyejXjpaNWCR9Z660NNpT4Aop
 LFi0KEhMlU2VYacDBRnc6zquFaYXOkmdbifFy1df3Dq+bCttB7MzBYcu4tjqHhjQ
 V3Q3Sp0oLJr5nTLzTP0QIOMyUPKOT/Mc1YkYCDYYpLdko1y4msn6p90sCNB/HVos
 3GjwaGxH3inaz6pljASXrWIDyIl7OiGamKsijs/51Tnpp4DkG+yfwceji9MF+B7a
 bRrSB4vqZ1a4gNWOnOnVlFA0+LdMuvMEv0qH25HvVKOTTnrgxfc+M2ITs6MxPRyu
 7DiDiWxMeAovdYcMJEcwFuSOgelqOfVGO1sJF4VqoIaYzEpVW7qotq2fXwMgsO+z
 iwCiTT7wCLllV9+HAW0UF7zfzQSOyZ1AFBetCMy43UOJsK2v86D//vB2WObbGwZb
 vBIXtZ5+KwZDUrNvpGDrz+hKhfVMZFCEDzNvd79NX6VUICRgEk7Bwz/Rl+3QBS9Y
 LVn7q8GPGh7qVYWATj/7d8udCK/nsKb3YSwTGtvPCVjtv1RJSW1UKd9vUmgLAuJM
 Mva68ypnWwUOcSdEPwOstOJGXg==
 =sq48
 -----END PGP SIGNATURE-----

Merge tag 'u-boot-stm32-20250131' of https://source.denx.de/u-boot/custodians/u-boot-stm

STM32 MPU:
- Remove dt-bindings headers available in dts/upstream
- Fixes for stm32prog
- Enable CONFIG_SYS_64BIT_LBA for STM32MP15/13/25 defconfigs
- Add upport of ck_usbo_48m in pre-reloc stage for STM32MP13
- Clean env_get_location() for STM32MP1
- Fix board_get_usable_ram_top() to fix infinite loop in cache
  management for STM32MP2.
- Fix ck_flexgen_08 frequency for STM32MP2

STM32 MCU:
- Tune CYCLIC_MAX_CPU_TIME_US to avoid cyclic warning for STM32F469-Disco
- Tune CYCLIC_MAX_CPU_TIME_US to avoid cyclic warning for STM32F769-Disco
2025-01-31 08:32:11 -06:00
Patrice Chotard
2a903b0141 configs: stm32f469-disco: Set CYCLIC_MAX_CPU_TIME_US to 50000 for stm32f469-disco
Updating the framebuffer takes quite a long time on this slow patform,
set CYCLIC_MAX_CPU_TIME_US to 50000 for stm32f469-disco to avoid
following cyclic warning:

"cyclic function video_init took too long: 46784us vs 5000us max"

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2025-01-31 10:13:10 +01:00
Patrice Chotard
c1bb2b62b0 configs: stm32f769-disco: Set CYCLIC_MAX_CPU_TIME_US to 8000 for stm32f769-disco
Updating the framebuffer takes quite a long time on this slow patform,
set CYCLIC_MAX_CPU_TIME_US to 8000 for stm32f769-disco to avoid
following cyclic warning:

"cyclic function video_init took too long: 7280us vs 5000us max"

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2025-01-31 10:13:10 +01:00
Patrice Chotard
f05e4ec4a4 configs: stm32mp25: enable CONFIG_SYS_64BIT_LBA
In arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c, in init_device(),
in case of RAW_IMAGE, part->size = block_dev->lba * block_dev->blksz.

  _ part->size is declared as u64.
  _ block_dev->lba is declared as lbaint_t which is uint64_t
    if CONFIG_SYS_64BIT_LBA is enable, otherwise ulong.
  _ block_dev->blksz is declared as unsigned long.

For example, in case block_dev->lba = 0x1dacc00, block_dev->blksz = 0x200
then part->size 0x5980000 which is incorrect as both are declared as ulong.

To fix this overflow issue, enable CONFIG_SYS_64BIT_LBA, block_dev->lba is
then declared as uint64_t and part->size get the correct value 0x3b5980000.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2025-01-31 10:13:10 +01:00
Patrice Chotard
1ddd8e5d9b configs: stm32mp15: enable CONFIG_SYS_64BIT_LBA
In arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c, in init_device(),
in case of RAW_IMAGE, part->size = block_dev->lba * block_dev->blksz.

  _ part->size is declared as u64.
  _ block_dev->lba is declared as lbaint_t which is uint64_t
    if CONFIG_SYS_64BIT_LBA is enable, otherwise ulong.
  _ block_dev->blksz is declared as unsigned long.

For example, in case block_dev->lba = 0x1dacc00, block_dev->blksz = 0x200
then part->size 0x5980000 which is incorrect as both are declared as ulong.

To fix this overflow issue, enable CONFIG_SYS_64BIT_LBA, block_dev->lba is
then declared as uint64_t and part->size get the correct value 0x3b5980000.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2025-01-31 10:13:10 +01:00
Patrice Chotard
d429595f4d configs: stm32mp13: enable CONFIG_SYS_64BIT_LBA
In arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c, in init_device(),
in case of RAW_IMAGE, part->size = block_dev->lba * block_dev->blksz.

  _ part->size is declared as u64.
  _ block_dev->lba is declared as lbaint_t which is uint64_t
    if CONFIG_SYS_64BIT_LBA is enable, otherwise ulong.
  _ block_dev->blksz is declared as unsigned long.

For example, in case block_dev->lba = 0x1dacc00, block_dev->blksz = 0x200
then part->size 0x5980000 which is incorrect as both are declared as ulong.

To fix this overflow issue, enable CONFIG_SYS_64BIT_LBA, block_dev->lba is
then declared as uint64_t and part->size get the correct value 0x3b5980000.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
2025-01-31 10:13:10 +01:00
Tom Rini
ac3eeb1542 Merge patch series "Add support for MediaTek MT7987 SoC"
Weijie Gao <weijie.gao@mediatek.com> says:

This patch series add support for MediaTek MT7987 SoC with its reference
boards and related drivers.

This patch series add basic boot support on eMMC/SD/SPI-NOR/SPI-NAND for these
boards. The clock, pinctrl drivers and the SoC initializaton code are also
included.

Link: https://lore.kernel.org/r/cover.1737621362.git.weijie.gao@mediatek.com
2025-01-30 14:35:30 -06:00
Weijie Gao
c80a3fb961 board: mediatek: add MT7987 reference boards
This patch adds general board files based on MT7987 SoC.

MT7987 uses one mmc controller for booting from both SD and eMMC, and the
pins of mmc controller are also shared with one spi controller.
So three configs are need for these boot types:

1. mt7987_rfb_defconfig - SPI-NOR (spi2) and SPI-NAND (spi0)
2. mt7987_emmc_rfb_defconfig - eMMC + SPI-NOR (spi2)
3. mt7987_sd_rfb_defconfig - SD + SPI-NOR (spi2)

Note: spi2 also supports booting from SPI-NAND, but not the default option.

Signed-off-by: Sam Shih <sam.shih@mediatek.com>
Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
2025-01-30 14:35:14 -06:00
Marek Vasut
4cf712a3be net: miiphybb: configs: Drop CONFIG_BITBANGMII_MULTI
It seems that every remaining system which enables BITBANGMII also
enables BITBANGMII_MULTI . Remove the BITBANGMII_MULTI symbol and
assume it is always enabled. This allows removal of a bit of legacy
code. No functional change intended.

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Paul Barker <paul.barker.ct@bp.renesas.com>
2025-01-29 22:52:23 +01:00
Tom Rini
021baf7b08 We have use cases where a previous stage boot loader doesn't have any
TPM drivers. Instead of extending the hardware PCRs it produces an
 EventLog that U-Boot later replays on the hardware.
 
 The only real example we have is TF-A, which produces the EventLog using
 hashing algorithms created at compile time. This creates a problem to the
 TPM since measurements need to extend all active PCR banks. Up to now
 we were exiting refusing the extend measurements.
 
 TPMs can be instructed to change their active PCR banks, as long as the
 device resets immediately after a reconfiguration. This PR is adding
 that functionality. U-Boot can now scan the currently active TPM PCR
 banks, the ones it was compiled to support and the ones present in an
 EventLog. It the reconfigures the TPM on the fly with the correct algorithms.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEgWII69YpahbL5iK5gS8AYozs+qIFAmeYhMUACgkQgS8AYozs
 +qIzfxAAv0vngk2MycOWsQY1Mch0799o+QPN+J4avl52duLSCmiFUpoXOQCiRZSG
 5SpjqygrWXOL6T0EUMVjv8qaGJTZY5uY296G8zt+Nboq08XRMb76kV3vl/9XQ9oh
 lsF44QcoSpWM+NCfQ00yWsmy1FQZg5soQMU1liW8qJH1yUuDZP7WGDG2N2Kng5ag
 MW38SWXVM8+RiA1UeuaQtVvH5BfL/kotsG4U2LZwp6k4eJttzbUQylF09K/h+4Qf
 8nIwl6TQ7j59DRA2r7WHVmxFpYf+BOzf7wnLbAKKP9/QlEEo8+K8GabrNqcm/dx+
 Bav6dzZUzAJ024ocvouanQmjJfj2WnqryfRNJrU3ggt2j6JXkjNW9xHXdBZoKRBj
 WNTXMUIxe1t+5jD9KXyAg/C7FE1EaJDZu0JfK0xeXHvnnYbL6eYHyRkZCA6MZ95O
 ZCvDXv9x7zhZkUj9VY5kFvmWbemjX33CHMToIafu7fZtsCe6oIrISzMW4T3/74pS
 y6142Ceoy7qxYCkBgTzt5UTj4pTS2ZYaiqZXUTftFtmaNt56lcFWqaTR7Fz1U8CV
 1K8I3wKs8Fs5P326Y9fJ/kHfhHFTaVVDxWIhxK5Mg+vAIPeNECDybYH4q0FzAf1K
 h9ni39KC629MpMB2drYmYCtrzGk4nSyAwha1vSS9twltFi4Rgmo=
 =jn1D
 -----END PGP SIGNATURE-----

Merge tag 'tpm-master-28012025' of https://source.denx.de/u-boot/custodians/u-boot-tpm

CI: https://source.denx.de/u-boot/custodians/u-boot-tpm/-/pipelines/24375

We have use cases where a previous stage boot loader doesn't have any
TPM drivers. Instead of extending the hardware PCRs it produces an
EventLog that U-Boot later replays on the hardware.

The only real example we have is TF-A, which produces the EventLog using
hashing algorithms created at compile time. This creates a problem to the
TPM since measurements need to extend all active PCR banks. Up to now
we were exiting refusing the extend measurements.

TPMs can be instructed to change their active PCR banks, as long as the
device resets immediately after a reconfiguration. This PR is adding
that functionality. U-Boot can now scan the currently active TPM PCR
banks, the ones it was compiled to support and the ones present in an
EventLog. It the reconfigures the TPM on the fly with the correct algorithms.
2025-01-29 08:12:21 -06:00
Tom Rini
ecbd635367 configs: use syntax CONFIG_FOO=n in tools-only_defconfig again
As explained in commit c2cd7bd3ec ("configs: use syntax CONFIG_FOO=n
in tools-only_defconfig") we need to not use the "# CONFIG_FOO is not
set" syntax here in order to work correctly on OSes where cpp comes
ffrom LLVM.

Fixes: 867e16ae05 ("configs: Resync with savedefconfig")
Signed-off-by: Tom Rini <trini@konsulko.com>
2025-01-29 08:08:52 -06:00
Duje Mihanović
5983f0ff61 board: samsung: add initial support for coreprimevelte board
Samsung Galaxy Core Prime VE LTE is an entry-level PXA1908-based
smartphone. It has 1GB of DRAM, 8GB eMMC and USB connectivity.

Signed-off-by: Duje Mihanović <duje.mihanovic@skole.hr>
Reviewed-by: Stefan Roese <sr@denx.de>
2025-01-28 09:08:44 +01:00
Ben Schneider
e344dc4b11 configs: mvebu_espressobin_ultra-88f3720_defconfig: enable full bootflow functionality
This appliance has multiple devices from which it can boot. Enable full
bootflow functionality so users can choose a non-default boot device.

Signed-off-by: Ben Schneider <ben@bens.haus>
Reviewed-by: Stefan Roese <sr@denx.de>
2025-01-28 09:08:44 +01:00
Tony Dinh
116d1d0047 arm: kirkwood: Enable bootstd and other modernization for OpenRD boards
Enable bootstd for OpenRD boards
Update defconfigs to the latest u-boot requirements
Remove JFFS2 support. See JFFS2 Vulnerability[1].
Move default envs to text-base environment

[1] https://lore.kernel.org/u-boot/20241114233005.GN3600562@bill-the-cat/T/#m2fc25da1d2c019bc3cd8676991fdd64b8a21aa9b

Signed-off-by: Tony Dinh <mibodhi@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
2025-01-28 09:08:44 +01:00
Raymond Mao
b8eaa52612 board: qemu-arm: select TPM_PCR_ALLOCATE
Enable PCR allocate and system reboot when algorithms don't match
among the values from TPM device, U-Boot support and evenlog.

Signed-off-by: Raymond Mao <raymond.mao@linaro.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
2025-01-28 08:58:41 +02:00
Tom Rini
0e198ff1a9 configs: Resync with savedefconfig
Resync all defconfig files using qconfig.py

Signed-off-by: Tom Rini <trini@konsulko.com>
2025-01-24 16:35:58 -06:00
Tom Rini
a9813506c4 Merge patch series "Add bitbang feature for npcm8xx and driver"
Michael Chang <zhang971090220@gmail.com> says:

I am resubmitting the patch titled "Add bitbang feature for npcm8xx
and driver" for review and inclusion in the upstream project.

Driver didn't support bitbang feature.
Add bb_miiphy_bus function for driver and open feature for npcm8xx

the log is as below:
-------------------------------------------------
U-Boot 2024.10-g30b9cdaf2df5-dirty (Jan 09 2025 - 00:57:37 +0000)

CPU-0: NPCM845 A1 @ Model: Nuvoton npcm845 Development Board (Device Tree)
DRAM:  1 GiB
RNG: NPCM RNG module bind OK
OTP: NPCM OTP module bind OK
AES: NPCM AES module bind OK
SHA: NPCM SHA module bind OK
I/TC: Reserved shared memory is enabled
I/TC: Dynamic shared memory is enabled
I/TC: Normal World virtualization support is disabled
I/TC: Asynchronous notifications are disabled
Core:  649 devices, 28 uclasses, devicetree: separate
WDT:   Not starting watchdog@901c
MMC:   sdhci@f0842000: 0
Loading Environment from SPIFlash... SF:
Detected w25q512jvq with page size 256 Bytes, erase size 64 KiB,
total 64 MiB
OK
In:    serial@0
Out:   serial@0
Err:   serial@0
Net:   eth0: eth@f0802000, eth1: eth@f0804000, eth3: eth@f0808000
Hit any key to stop autoboot:  0
U-Boot>
U-Boot>
U-Boot>setenv ipaddr 192.168.16.3
U-Boot>ping 192.168.16.12
eth@f0802000 Waiting for PHY auto negotiation to complete
......... TIMEOUT !
Could not initialize PHY eth@f0802000
eth@f0804000 Waiting for PHY auto negotiation to complete
......... TIMEOUT !
Could not initialize PHY eth@f0804000
Speed: 100, full duplex
Using eth@f0808000 device
host 192.168.16.12 is alive

Link: https://lore.kernel.org/r/20250117104540.1580343-1-zhang971090220@gmail.com
2025-01-23 18:51:26 -06:00
Michael Chang
a78ab77063 ARM: configs: nuvoton: add bitbang feature for npcm8xx.
Enable bitbang and multiple bitbang feature for npcm8xx platform.

Signed-off-by: Jim Liu <JJLIU0@nuvoton.com>
Signed-off-by: Michael Chang <zhang971090220@gmail.com>
2025-01-23 18:51:26 -06:00
Daniel Schultz
a416d9e680 configs: phycore_am64x_a53_defconfig: Fix environment
Enable ENV_OVERWRITE to allow environment variables to be
overwritten within the board code. This is required to add
MAC addresses during SOM detection.

Additionally, set ENV_IS_NOWHERE for boot sources other than MMC.

Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
Reviewed-by: Wadim Egorov <w.egorov@phytec.de>
2025-01-23 12:11:50 -06:00
Daniel Schultz
18674f7cdb configs: phycore_am64x_a53_defconfig: Enable GPIO command
Enable the GPIO command to allow access to the GPIO pins.

Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
Reviewed-by: Wadim Egorov <w.egorov@phytec.de>
2025-01-23 12:11:50 -06:00
Daniel Schultz
3a1e127fbf configs: phycore_am64x_a53_defconfig: Fix GPIO controllers
The phyBOARD-Electra does not include a PCA953x I2C GPIO multiplexer.
Remove this configuration as it is a remnant from another
defconfig, and enable CONFIG_DA8XX_GPIO for the DA8XX DaVinci GPIO
controller instead.

Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
Reviewed-by: Wadim Egorov <w.egorov@phytec.de>
2025-01-23 12:11:50 -06:00
Daniel Schultz
d87a706b9b configs: phycore_am62x_r5_defconfig: Increase SPL Malloc Pool
Increase the malloc pool size for the SPL by additional 4kB from
0x7000 to 0x8000.

This fixes following error message:
  ...
  alloc space exhausted ptr 7028 limit 7000
  DRAM init failed: -12

Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
2025-01-23 12:11:50 -06:00
Tom Rini
8352727e33 Merge patch series "Cumulative fixes and updates for MediaTek platform"
Weijie Gao <weijie.gao@mediatek.com> says:

This patch series contains fixes and updates for MediaTek platform,
including drivers, board and arch files.

Link: https://lore.kernel.org/r/cover.1737104723.git.weijie.gao@mediatek.com
2025-01-23 12:11:50 -06:00
Weijie Gao
c7a3761ddf configs: mt7988: move image load address to 0x44000000
This patch sets mt7988 image load address to 0x44000000 to support loading
larger images.

Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
2025-01-23 12:11:49 -06:00
Weijie Gao
7958b41b8c configs: mt7629: move image load address to 0x42000000
Update the image load address to ensure it matches the mt7629 NOR
controller's DMA alignment requirements.

Signed-off-by: Sam Shih <sam.shih@mediatek.com>
Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
2025-01-23 12:11:49 -06:00
Tom Rini
e67cbd7aba Merge branch 'master' of https://source.denx.de/u-boot/custodians/u-boot-sunxi
Following the move of the H616 family to OF_UPSTREAM in the last cycle,
now some older SoCs with identical DTs follow the lead: the F1C100s, A10,
A10s, A13. The remaining SoCs suffer from that IRQ cells incompatiblity,
breaking support for Linux < v5.13, so I am holding their move back still.

Otherwise we get proper support for the PinePhone v1.2, and PSTORE support
for all revisions of that device.

This is rounded up by a PMIC related fix for some A80 boards, and two
cleanup patches that are preparations for two new SoCs families, being
worked on as we speak. But they have to wait for the next cycle.

Gitlab CI passed, and I booted that briefly on some boards.
2025-01-23 08:16:15 -06:00
Tom Rini
a3b71cc6f5 Merge patch series "upl: Prerequite patches for updated spec"
Simon Glass <sjg@chromium.org> says:

The current UPL spec[1] has been tidied up and improved over the last
year, since U-Boot's original UPL support was written.

This series includes some prerequisite patches needed for the real UPL
patches. It is split from [2]

[1] https://github.com/UniversalPayload/spec/tree/3f1450d
[2] https://patchwork.ozlabs.org/project/uboot/list/?series=438574&state=*

Link: https://lore.kernel.org/r/20250111000029.245022-1-sjg@chromium.org
2025-01-22 17:08:47 -06:00
Simon Glass
d5bc5c6cb0 x86: emulation: Enable bloblist
Add bloblist support so that tables can be generated and placed in a
bloblist, then passed to a payload using UPL

Signed-off-by: Simon Glass <sjg@chromium.org>
2025-01-22 17:08:23 -06:00
Simon Glass
44e39ff6ac x86: Show an error if video fails
If video is enabled we expect it to work. Avoid silent failure by adding
a panic if things go wrong.

Expand the SPL malloc-area for qemu-x86_64 to avoid a panic.

Signed-off-by: Simon Glass <sjg@chromium.org>
2025-01-22 17:08:23 -06:00
Simon Glass
d56c761ca2 x86: Create more space for SPL with qemu-x86_64
The space here is quite tight and there is plenty of room in the ROM.
Move SPL earlier to allow for expansion.

Signed-off-by: Simon Glass <sjg@chromium.org>
2025-01-22 17:08:23 -06:00
Simon Glass
53d5a22163 emulation: Use bloblist to hold tables
QEMU can have its own internal ACPI and SMBIOS tables. At present U-Boot
copies out the SMBIOS tables but points directly to the ACPI ones.

The ACPI tables are not aligned on a 4KB boundary, which means that UPL
cannot use them directly, since it uses a reserved-memory node for the
tables and that it assumed (by EDK2) to be 4KB-aligned.

On x86, QEMU provides the tables in a mapped memory region and U-Boot
makes use of these directly, thus making it difficult to use any common
code.

Adjust the logic to fit within the existing table-generation code. Use a
bloblist always and ensure that the ACPI tables is placed in an aligned
region. Set a size of 8K for QEMU. This does not actually put all the
tables in one place, for QEMU, since it currently adds a pointer to the
tables in QFW.

On ARM, enable bloblist so that SMBIOS tables can be added to the
bloblist.

Signed-off-by: Simon Glass <sjg@chromium.org>
2025-01-22 17:08:23 -06:00
Andre Przywara
73cbb3baa6 sunxi: switch Allwinner A10s/A13 boards to OF_UPSTREAM
In contrast to some other Allwinner SoCs, there is no difference between
the DTs for the Allwinner A10s/A13 SoCs (sun5i) between the U-Boot and the
Linux kernel repository.

Remove the old copies of the A10s/A13 related .dts and .dtsi files, and
switch most of sun5i boards over to use OF_UPSTREAM.

There are two boards for which we don't have DTs in the kernel tree.
Keep those two .dts files in the legacy U-Boot DT directory, and let
their defconfig opt out of OF_UPSTREAM.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Acked-by: Sumit Garg <sumit.garg@linaro.org>
2025-01-22 22:49:15 +00:00
Andre Przywara
08d65024e0 sunxi: switch Allwinner A10 boards to OF_UPSTREAM
In contrast to some other Allwinner SoCs, there is no difference between
the DTs for the Allwinner A10 SoCs (sun4i) between the U-Boot and the
Linux kernel repository.

Remove the old copies of the A10 related .dts and .dtsi files, and switch
most of sun4i boards over to use OF_UPSTREAM.

There are two boards for which we don't have DTs in the kernel tree.
Keep those two .dts files in the legacy U-Boot DT directory, and let
their defconfig opt out of OF_UPSTREAM.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Acked-by: Sumit Garg <sumit.garg@linaro.org>
2025-01-22 22:49:10 +00:00
Andre Przywara
dc2dd2de0f suniv: switch Allwinner F1Cx00 boards to OF_UPSTREAM
In contrast to some other Allwinner SoCs, there is no difference between
the DTs for the Allwinner F1C100/F1C200 SoCs (sunvi) between the U-Boot
and the Linux kernel repository.

Remove the old copies of the F1Cx00 related .dts and .dtsi files, and
switch the whole suniv SoC over to use OF_UPSTREAM.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com>
2025-01-22 22:44:34 +00:00
Andrey Skvortsov
a4fc1e3e27 sunxi: pinephone: detect existed magnetometer and fixup dtb
In newer 1.2 PinePhone board revisions LIS3MDL magnetometer was replaced by
AF8133J. They use the same PB1 pin in different modes.

LIS3MDL uses it as an gpio input to handle interrupt.
AF8133J uses it as an gpio output as a reset signal.

It wasn't possible at runtime to enable both device tree
nodes and detect supported sensor at probe time.

AF8133J has reset pin (PB1) connected to the SoC. By default AF8133J
is in a reset state and don't respond to probe request on I2C
bus. Extra code would be needed to handle reset signal. Therefore this
code uses LIS3MDL magnetometer instead of AF8133J.

Introducing new dts 1.2b with AF8133J sensor would require probing in
SPL. That would lead to pulling in into SPL I2C controller driver,
RSB controller driver, introducing new AXP803 driver to power-up
sensors for probe. It's working, but SPL is pretty size-constrained on
A64 and doesn't have much space. Therefore fdt fixup is done in U-Boot
proper without introducing new board revision and new dts.

Signed-off-by: Andrey Skvortsov <andrej.skvortzov@gmail.com>
Link: https://lore.kernel.org/all/20240908214718.36316-1-andrej.skvortzov@gmail.com/
Link: https://lists.denx.de/pipermail/u-boot/2024-February/545700.html
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
[Andre: fix formatting]
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2025-01-22 22:44:34 +00:00
Andrey Skvortsov
bd03d35fae sunxi: defconfig: Add pstore support for pinephone
pstore will allow users to catch kernel crashes and report them to
developers. Modern (Android) phones have pstore usually enabled to get
information about kernel crash, since it's the simplest way to get
kernel backtrace on mobile device without serial console. Usually it's
enabled by default in distribution kernels like Debian.

CONFIG_PSTORE=y
CONFIG_PSTORE_RAM=m

systemd has service that automatically handles pstore and saves them
in /var/lib/pstore for later usage.

In general any DRAM address, that isn't overwritten during a boot is
suitable for pstore.

Range from 0x40000000 - 0x50000000 is heavily used by u-boot for
internal use and to load kernel, fdt, fdto, scripts, pxefile and ramdisk
later in the boot process. Ramdisk start address is 0x4FF00000,
initramfs for kernel with some hacking features and debug info enabled
can take more than 100Mb and final address will be around 0x58000000.
Address 0x61000000 will most likely not overlap with that.

Signed-off-by: Andrey Skvortsov <andrej.skvortzov@gmail.com>
Reviewed-by: Andre Przywara <andre.przywara@arm.com>
2025-01-22 22:44:34 +00:00
Andre Przywara
9d87d5082d sunxi: H616: DRAM: rename Kconfig parameters to be more generic
The H616 DRAM controller requires some board specific parameters, which
we declare in Kconfig, let each board specify in their defconfig, and
then use in the DRAM init code.

Other DRAM controllers now require a very similar, if not identical
parameter set, with so far the same parameter names used.

To help keep the Kconfig file at bay, rename the existing parameter
names to drop the H616_ part in there, to make them more naturally
reusable for other SoCs.

No functional change, just a rename.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com>
2025-01-22 22:44:34 +00:00
Simon Glass
864106f3c4 bloblist: Make BLOBLIST_ALLOC the default
We want to encourage people to use an allocated bloblist since it is
more flexible than a fixed one. Make this the default, being sure not to
change existing users.

The unit tests require BLOBLIST_FIXED so add a dependency in the
Makefile to avoid build errors.

All sandbox builds require BLOBLIST_FIXED so make that the default for
sandbox.

Signed-off-by: Simon Glass <sjg@chromium.org>
2025-01-22 15:58:03 -06:00
Neil Armstrong
ed7ba0c114
configs: qcom_defconfig: enable RNG driver and command
Enable the MSM RNG driver by default with the associated
command, this will fill KASLR seed when booting Linux.

Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20241125-topic-sm8x50-rng-v1-2-52b72821c3e9@linaro.org
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2025-01-22 16:43:53 +01:00
Neil Armstrong
8376161a03
qcom_defconfig: enable X1E80100 pinctrl driver
Enable the X1E80100 pinctrl driver in the Qualcomm defconfig.

Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Tested-by: Caleb Connolly <caleb.connolly@linaro.org> # Yoga Slim 7x
Reviewed-by: Caleb Connolly <caleb.connolly@linaro.org>
Link: https://lore.kernel.org/r/20241115-topic-x1e80100-pinctrl-v1-2-35f984226e47@linaro.org
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2025-01-22 16:35:03 +01:00
Neil Armstrong
743bcd5553
qcom_defconfig: enable X1E80100 clock driver
Enable the X1E80100 clock driver in the Qualcomm defconfig.

Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20241118-topic-x1e80100-clk-v1-2-8841e87ad81f@linaro.org
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2025-01-22 16:34:26 +01:00
Varadarajan Narayanan
58bf7db9a5
configs: add qcs9100_defconfig
Introduce a defconfig for the Ride R3 and other QCS9100 boards with a
dedicated uefi partition. These can replace EDK2 entirely with U-Boot.

Signed-off-by: Varadarajan Narayanan <quic_varada@quicinc.com>
Reviewed-by: Sumit Garg <sumit.garg@linaro.org>
Link: https://lore.kernel.org/r/20250110050817.3819282-7-quic_varada@quicinc.com
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2025-01-22 16:26:52 +01:00
Varadarajan Narayanan
ea3d9be203
qcom_defconfig: enable SA8775P clock driver
Enable the SA8775P clock driver in the Qualcomm defconfig.

Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Varadarajan Narayanan <quic_varada@quicinc.com>
Link: https://lore.kernel.org/r/20250110050817.3819282-6-quic_varada@quicinc.com
Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
2025-01-22 16:26:51 +01:00
Tom Rini
82d262ae16 Merge patch series "MediaTek MT7629 OF_UPSTREAM migration (v2)"
Weijie Gao <weijie.gao@mediatek.com> says:

This patch series migrates MediaTek MT7629 to OF_UPSTREAM

Changes in v2:
* Remove mt7629-rfb.dtb from arch/arm/dts/Makefile
* Add wdt-reboot node to make reset command work

Link: https://lore.kernel.org/r/cover.1736851116.git.weijie.gao@mediatek.com
2025-01-21 09:29:05 -06:00
Tom Rini
ca7881e789 Merge patch series "Broadcom bcmbca dts updates"
david regan <dregan@broadcom.com> says:

Updates for Broadcom bcmbca devices,
make use of OF_UPSTREAM which uses Linux dts,
update bcmbca dts to current nand node naming convention,
enable basic nand functionality for bcmbca devices.

Link: https://lore.kernel.org/r/20250114045425.148801-1-dregan@broadcom.com
2025-01-21 09:29:05 -06:00
Patrick Rudolph
4fd503bb8e sbp1: Add support for IBM SBP1 board
Add defconfig & devicetree for IBM SBP1 board BMC based on AST2600 SoC.

Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Signed-off-by: Naresh Solanki <naresh.solanki@9elements.com>
2025-01-21 09:29:05 -06:00
Sam Shih
9bc0c7e8ab board: mediatek: mt7629: Migrate to OF_UPSTREAM
Move differences in DT files between upstream Linux DT and U-Boot DT to
mt7629-rfb-u-boot.dtsi.
Remove old copies of mt7629-related clock bindings, .dts, and .dtsi files.
Update defconfig to switch the whole mt7629 SoC to use OF_UPSTREAM.

Signed-off-by: Sam Shih <sam.shih@mediatek.com>
Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
2025-01-21 09:28:43 -06:00
david regan
65fcf33a3f arm: dts: Enable basic nand functionality for bcmbca devices
Enable rudimentary nand read/write capability.

Changes in v2:
- New patch in series added enabling of nand functionality

Signed-off-by: david regan <dregan@broadcom.com>
Reviewed-by: William Zhang <william.zhang@broadcom.com>
Reviewed-by: Anand Gore <anand.gore@broadcom.com>
2025-01-21 09:28:05 -06:00