]> Git Repo - J-u-boot.git/log
J-u-boot.git
2 months agoMerge tag 'u-boot-imx-next-20241126' of https://gitlab.denx.de/u-boot/custodians...
Tom Rini [Tue, 26 Nov 2024 16:49:44 +0000 (10:49 -0600)]
Merge tag 'u-boot-imx-next-20241126' of https://gitlab.denx.de/u-boot/custodians/u-boot-imx into next

CI: https://source.denx.de/u-boot/custodians/u-boot-imx/-/pipelines/23563

- Make Siemens i.MX8 Capricorn board to boot U-Boot mainline again.
- Add support for phycore-imx93 2GB LPDDR4X variant.
- Add phycore-imx8mm EEPROM detection initialisation.

2 months agoboard: phytec: phycore-imx8mm: Add EEPROM detection initialisation
Yunus Bas [Fri, 22 Nov 2024 10:29:38 +0000 (11:29 +0100)]
board: phytec: phycore-imx8mm: Add EEPROM detection initialisation

Add EEPROM detection initialisation for phyCORE-i.MX8MM.

Signed-off-by: Yunus Bas <[email protected]>
2 months agoboard: phytec: imx93: Add phyCORE-i.MX 93 support for all SOM variants
Christoph Stoidner [Wed, 20 Nov 2024 16:31:43 +0000 (17:31 +0100)]
board: phytec: imx93: Add phyCORE-i.MX 93 support for all SOM variants

The phyCORE-i.MX 93 is available in various variants (e.g. different ram
sizes, eMMC HS400 yes/no). Enable hardware introspection for the
imx93-phyboard-segin_defconfig, so that during startup the SOM module
variant can be detected, and the hardware can be configured accordingly.
The resulting SPL and u-boot binary shall able to boot each
phyCORE-i.MX 93 module variant on each carrier board. Finally rename
imx93-phyboard-segin_defconfig to imx93-phycore_defconfig, to highlight
its SOM scope.

Signed-off-by: Christoph Stoidner <[email protected]>
Reviewed-by: Wadim Egorov <[email protected]>
Reviewed-by: Yannic Moog <[email protected]>
2 months agoboard: phytec: imx93: Add eeprom-based hardware introspection
Christoph Stoidner [Wed, 20 Nov 2024 16:31:42 +0000 (17:31 +0100)]
board: phytec: imx93: Add eeprom-based hardware introspection

The phyCORE-i.MX 93 is available in various variants. Relevant variant
options for the spl/u-boot are:
- with or without HS400 support for the eMMC
- with 1GB ram chip, or 2GB ram chip

The phyCORE's eeprom contains all information about the existing variant
options. Add evaluation of the eeprom data to the spl/u-boot to
enable/disable HS400 and to select the appropriate ram configuration at
startup.

Signed-off-by: Christoph Stoidner <[email protected]>
Reviewed-by: Wadim Egorov <[email protected]>
Reviewed-by: Yannic Moog <[email protected]>
Tested-by: Primoz Fiser <[email protected]>
2 months agoboard: phytec: phycore-imx93: Add 2GB LPDDR4X RAM timings
Christoph Stoidner [Wed, 20 Nov 2024 16:31:41 +0000 (17:31 +0100)]
board: phytec: phycore-imx93: Add 2GB LPDDR4X RAM timings

The phyCORE-i.MX 93 is available with a 1GB ram chip or a 2GB ram chip.
Add the ram timings for the 2GB chip, in form of a diff compared
to the existing LPDDR4X 1GB timings. With that, the SPL can select the
appropriate timings at startup.
Update also the 1GB ram timings with new version of the DDR Tool.

Signed-off-by: Christoph Stoidner <[email protected]>
Tested-by: Primoz Fiser <[email protected]>
2 months agosiemens: capricorn: update maintainers
Enrico Leto [Sat, 23 Nov 2024 16:53:04 +0000 (17:53 +0100)]
siemens: capricorn: update maintainers

update MAINTAINERS file, add some more board maintainers.

Signed-off-by: Enrico Leto <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
Reviewed-by: Alexander Sverdlin <[email protected]>
2 months agosiemens: add ddr signal integrity test
Enrico Leto [Sat, 23 Nov 2024 16:53:03 +0000 (17:53 +0100)]
siemens: add ddr signal integrity test

The signal integrity test generates pattern on DDR lines
for certification. The signals must be as fast as possible
and unidirectional.

The test is required from our HW team. The available
u-boot memory test doesn't full fill the our requirements.

The test is planed to be used in all new siemens boards.

Signed-off-by: Enrico Leto <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: add ddr full memory test
Enrico Leto [Sat, 23 Nov 2024 16:53:02 +0000 (17:53 +0100)]
siemens: add ddr full memory test

Add siemens specific memory test. Enable it through Kconfig option
SPL_CMT. The test is required from our HW team. It runs over
temperature during many days:
* must run indefinitively through the *whole* DDR area,
  so we cannot use linux memtest for example.
* must write/read/check all values

Signed-off-by: Enrico Leto <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: capricorn: get module name from eeprom
Enrico Leto [Sat, 23 Nov 2024 16:53:01 +0000 (17:53 +0100)]
siemens: capricorn: get module name from eeprom

The eeprom contains the information on which module
we are running, so read it from the eeprom and print
it on the console.

Signed-off-by: Enrico Leto <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: capricorn: get ram size from system controller
Enrico Leto [Sat, 23 Nov 2024 16:53:00 +0000 (17:53 +0100)]
siemens: capricorn: get ram size from system controller

Get the memory region information from system controller to reduce the
number of platform specific headers. We were aligned on NXP mek board
implementation. This need at least 1 header per memory configuration.

Signed-off-by: Enrico Leto <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: capricorn: add HW version information to boot log
Alessandro Zini [Sat, 23 Nov 2024 16:52:59 +0000 (17:52 +0100)]
siemens: capricorn: add HW version information to boot log

Add the HW version read directly from EEPROM.

EEPROM chip data structure is now in a .h file common to draco
and capricorn.

Therefore move out the definitions in draco board to siemens
common place.

From: Alessandro Zini <[email protected]>
Signed-off-by: Alessandro Zini <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: capricorn: small board updates
Heiko Schocher [Sat, 23 Nov 2024 16:52:58 +0000 (17:52 +0100)]
siemens: capricorn: small board updates

with newest SCFW build_info() works now, so call it
from checkboard() now.

As we only use uart2 as console, do not init uart0.

Signed-off-by: Heiko Schocher <[email protected]>
Reviewed-by: Alexander Sverdlin <[email protected]>
2 months agosiemens: imx8-capricorn.dtsi: add wdt device
Heiko Schocher [Sat, 23 Nov 2024 16:52:57 +0000 (17:52 +0100)]
siemens: imx8-capricorn.dtsi: add wdt device

add wdt device

Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: capricorn: sync spl code with 8qxp-mek
Heiko Schocher [Sat, 23 Nov 2024 16:52:56 +0000 (17:52 +0100)]
siemens: capricorn: sync spl code with 8qxp-mek

sync spl code with 8qxp-mek board.

Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: configs/capricorn_cxg3_defconfig: updates
Heiko Schocher [Sat, 23 Nov 2024 16:52:55 +0000 (17:52 +0100)]
siemens: configs/capricorn_cxg3_defconfig: updates

make savedefconfig and add SCU_WDT and fix environment
offsets, as since silicon c0 the boot container takes place
at offset 0 and so the u-boot-env must be moved outside of
the boot container area.

Signed-off-by: Heiko Schocher <[email protected]>
Reviewed-by: Alexander Sverdlin <[email protected]>
2 months agosiemens: imximage.cfg: sync image names
Heiko Schocher [Sat, 23 Nov 2024 16:52:54 +0000 (17:52 +0100)]
siemens: imximage.cfg: sync image names

sync the image names in imximage.cfg with
the ones used in arch/arm/dts/imx8qxp-u-boot.dtsi

Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: imximage.cfg: correct comment
Heiko Schocher [Sat, 23 Nov 2024 16:52:53 +0000 (17:52 +0100)]
siemens: imximage.cfg: correct comment

fix wrong comment.

Signed-off-by: Heiko Schocher <[email protected]>
Reviewed-by: Alexander Sverdlin <[email protected]>
2 months agosiemens: capricorn: use DCD_SKIP entry
Heiko Schocher [Sat, 23 Nov 2024 16:52:52 +0000 (17:52 +0100)]
siemens: capricorn: use DCD_SKIP entry

Boards which use DCD data in SCFW can drop SPL.

We tried in our mainline rework to use this approach
too as other imx8qxp boards do in mainline. But we
failed ... it was a hard way to understand the
reason!

We cannot use DCD image in container as the SCFW
from siemens, does the RAM init on boot itself!

Siemens SCFW reads the RAM config from i2c eeprom and
dependent on this settings, initializes the RAM.

Adding DCD data to the bootcontainer will result in
hang of the SCFW, also DCD data in container image is
static which do not fit our needs.

So we must drop DCD data image, and this has the side
effect that we need SPL, as the task which loads the images
from the container only loads the images to addresses,
and if executed bit is set, starts them.

As now RAM is not initialized from it, and there is no
option to "wait until SCFW has setup RAM",  we can only
load SPL into internal RAM at this point, as than SPL
and SCFW boot parallel.

The SPL itself then uses the SCU API to communicate
with the SCFW and it seems that SCFW only responds to
this API requests when RAM setup is already done by the
SCFW, which has a side-effect of a "sync" for the RAM
setup is done by SCFW!

We checked if SPL is always save in accessing RAM for
loading images to it! For tests, we added in our RAM
init part in the SCFW long delays (10 seconds and more)
as we thought there is such a sync missing, and we can
break the board through delaying RAM setup... but we
did not managed to fail booting U-Boot from SPL!

Signed-off-by: Heiko Schocher <[email protected]>
2 months agosiemens: imx8qxp-capricorn-u-boot.dtsi: fix boot
Heiko Schocher [Sat, 23 Nov 2024 16:52:51 +0000 (17:52 +0100)]
siemens: imx8qxp-capricorn-u-boot.dtsi: fix boot

current generated flash.bin image does not longer
boot on cxg3 board.

Rename bootph-pre-ram to bootph-all so flash.bin
boots again!

Add u-boot specific change (add bootph-all property)
in A35_0 node to imx8qxp-capricorn-u-boot.dtsi

Signed-off-by: Heiko Schocher <[email protected]>
Reviewed-by: Alexander Sverdlin <[email protected]>
2 months agosiemens: capricorn: move to cxg3 reference project with deneb board
Enrico Leto [Sat, 23 Nov 2024 16:52:50 +0000 (17:52 +0100)]
siemens: capricorn: move to cxg3 reference project with deneb board

We have many HW with capricorn i.MX8X boards. The difference in u-boot is
at all by the display of the LEDs.

* put upstream a reference project & board for DT and defconfig
* use the capricorn prefix outside the board/siemens/capricorn folder

Signed-off-by: Enrico Leto <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
2 months agoimx8qxp: Fix build when using SPL
Heiko Schocher [Sat, 23 Nov 2024 16:52:49 +0000 (17:52 +0100)]
imx8qxp: Fix build when using SPL

imx8qxp based boards which use SPL drop error when
calling make all:
"""
Writing image to './flash.bin'
   Node '/binman/imx-boot/spl': GetData: size 0x0
       Node '/binman/imx-boot': GetPaddedDataForEntry: size 0x0
       Node '/binman/imx-boot': GetData: 1 entries, total size 0x0
       Node '/binman/imx-boot': GetPaddedDataForEntry: size 0x0
Wrote 0x0 bytes
Image 'imx-boot' is missing external blobs and is non-functional: spl

/binman/imx-boot/spl (spl.bin):
   Missing blob

Some images are invalid
"""

Guard creation of flash.bin with CONFIG_XPL_BUILD option.

Signed-off-by: Heiko Schocher <[email protected]>
Fixes: c9713c155127 ("imx8-u-boot: Fix SPL guard option")
2 months agoimx: imx_cntr_image.sh: prevent warning for missing spl
Heiko Schocher [Sat, 23 Nov 2024 16:52:48 +0000 (17:52 +0100)]
imx: imx_cntr_image.sh: prevent warning for missing spl

when building U-Boot on imx8qxp and the board port uses
SPL, U-boot build shows

WARNING '.../spl/u-boot-spl.bin' not found, resulting binary is not-functional

This is because U-Boot binary is build first and Makefile
calls script imx_cntr_image.sh which checks if files
exists... but of course as spl is not yet build the
file `spl/u-boot-spl.bin` does not exist yet, so prevent
this warning.

Signed-off-by: Heiko Schocher <[email protected]>
2 months agotools: imx8image: Improve error message
Heiko Schocher [Sat, 23 Nov 2024 16:52:47 +0000 (17:52 +0100)]
tools: imx8image: Improve error message

Improve error message "header tag mismatched"
Add filename to error message to see, which file
is wrong.

Signed-off-by: Heiko Schocher <[email protected]>
Reviewed-by: Alexander Sverdlin <[email protected]>
2 months agonet: fec_mxc: fix probing for imx8qxp
Heiko Schocher [Sat, 23 Nov 2024 16:52:46 +0000 (17:52 +0100)]
net: fec_mxc: fix probing for imx8qxp

probing on capricorn board (imx8qxp based) brings:

Can't find FEC0 clk rate: -19

Cause is that when probing fec_mxc driver, fec_mii_setspeed()
is called which calls fec_get_clk_rate().

fec_mii_setspeed() calls fec_get_clk_rate with NULL pointer
for udev and so as in IMX8QXP case CLK_CCF is enabled
udev gets searched with:

uclass_get_device_by_seq(UCLASS_ETH, idx, &dev);

but we do not have yet a UCLASS_ETH ! as we just probing it!

Prevent this by passing udev to fec_get_clk_rate()

Signed-off-by: Heiko Schocher <[email protected]>
2 months agowdt: imx8qxp: add option to control external PMIC wdt via IMX8 SCU
Heiko Schocher [Sat, 23 Nov 2024 16:52:45 +0000 (17:52 +0100)]
wdt: imx8qxp: add option to control external PMIC wdt via IMX8 SCU

Driver for a PMIC watchdog timer controlled via Siemens SCU firmware
extensions. Only useful on some Siemens i.MX8-based platforms as
special SCFW is needed which provides the needed SCU API.

Signed-off-by: Andrej Valek <[email protected]>
Signed-off-by: Heiko Schocher <[email protected]>
Reviewed-by: Alexander Sverdlin <[email protected]>
Reviewed-by: Stefan Roese <[email protected]>
2 months agoMerge tag 'v2025.01-rc3' into next
Tom Rini [Mon, 25 Nov 2024 23:23:49 +0000 (17:23 -0600)]
Merge tag 'v2025.01-rc3' into next

Prepare v2025.01-rc3

2 months agoPrepare v2025.01-rc3
Tom Rini [Mon, 25 Nov 2024 22:58:57 +0000 (16:58 -0600)]
Prepare v2025.01-rc3

Signed-off-by: Tom Rini <[email protected]>
2 months agoMerge branch 'master-asix' of https://source.denx.de/u-boot/custodians/u-boot-usb
Tom Rini [Mon, 25 Nov 2024 21:32:16 +0000 (15:32 -0600)]
Merge branch 'master-asix' of https://source.denx.de/u-boot/custodians/u-boot-usb

- Fix two issues with the asix88179 driver

2 months agospi: Fix missed rename from SPI_ADVANCE to SPI_STACKED_PARALLEL
Dominik Wernberger [Mon, 25 Nov 2024 21:21:52 +0000 (22:21 +0100)]
spi: Fix missed rename from SPI_ADVANCE to SPI_STACKED_PARALLEL

Fix missed rename from SPI_ADVANCE to SPI_STACKED_PARALLEL. This fixes
an issue encountered while testing the Zynq-7000 QSPI parallel Flash
implementation.

Fixes: f896aa656774 ("mtd: spi-nor: Rename SPI_ADVANCE to SPI_STACKED_PARALLEL")
Reviewed-by: Venkatesh Yadav Abbarapu <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
Signed-off-by: Dominik Wernberger <[email protected]>
2 months agoMerge https://source.denx.de/u-boot/custodians/u-boot-usb
Tom Rini [Mon, 25 Nov 2024 18:37:46 +0000 (12:37 -0600)]
Merge https://source.denx.de/u-boot/custodians/u-boot-usb

- Support for Microchip USB5744 hub

2 months agoast2600: spl: Use readl for reading mmio
Joel Stanley [Mon, 18 Nov 2024 02:12:56 +0000 (12:42 +1030)]
ast2600: spl: Use readl for reading mmio

u-boot was crashing in qemu as the modeled hardware enforced overly
strict memory reads.

While this code will work on existing hardware, fix to avoid future issues.

Fixes: 12770d0df0e8 ("ast2600: spl: Add boot mode detection")
Link: https://gitlab.com/qemu-project/qemu/-/issues/2636
Signed-off-by: Joel Stanley <[email protected]>
2 months agomtd: Drop superfluous const qualifier
Andy Shevchenko [Mon, 21 Oct 2024 14:20:40 +0000 (17:20 +0300)]
mtd: Drop superfluous const qualifier

The compiler will ignore it anyway:

  include/linux/mtd/mtd.h:342:15: warning: type qualifiers ignored on function return type [-Wignored-qualifiers]

Signed-off-by: Andy Shevchenko <[email protected]>
Reviewed-by: Simon Glass <[email protected]>
2 months agoeth: asix88179: packet drop when receiving large fragmented packets
Khoa Hoang [Fri, 8 Nov 2024 05:51:36 +0000 (21:51 -0800)]
eth: asix88179: packet drop when receiving large fragmented packets

The ASIX 88179A drops packets when receiving fragmented packets larger
than the MTU size due to an insufficient URB buffer size. This change
synchronizes the URB buffer size with the configuration used in the
Linux kernel, resolving the packet drop issue.

To reproduce the issue, set the following configuration:
    CONFIG_IP_DEFRAG=y
    CONFIG_TFTP_BLOCKSIZE=16352

Then, run the `tftp` command. It will fail with a timeout error:

    U-Boot> tftp zero.bin
    Using ax88179_eth device
    TFTP from server 10.0.0.196; our IP address is 10.0.0.18
    Filename 'zero.bin'
    Load address: 0x10000000
    Loading: T T T T T T T T T T T
    Retry count exceeded; starting again

Signed-off-by: Khoa Hoang <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
2 months agoeth: asix88179: Fix ASIX AX88179A PHY hang
Khoa Hoang [Fri, 8 Nov 2024 05:51:35 +0000 (21:51 -0800)]
eth: asix88179: Fix ASIX AX88179A PHY hang

The ASIX AX88179A locks up when the ADVERTISE_NPAGE bit is set in the
MII_ADVERTISE register, suggesting that this feature may be broken or
unsupported on this chip. In the Linux kernel, this bit is not set,
and enabling it also causes the PHY to lock up and stay in a
link-down state.

Additionally, the AX88179 and AX88179A variants do not appear to
support the ADVERTISE_LPACK bit, as setting it consistently reads
back as 0.

This patch removes the ADVERTISE_NPAGE and ADVERTISE_LPACK bits from
the MII_ADVERTISE register configuration. It also resets the PHY
before modifying the MII_ADVERTISE register, then restarts
auto-negotiation, following the same flow used in the U-Boot asix.c
driver.

Signed-off-by: Khoa Hoang <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
2 months agousb: onboard-hub: Bail out if peer hub is already probed
Venkatesh Yadav Abbarapu [Mon, 25 Nov 2024 04:12:02 +0000 (09:42 +0530)]
usb: onboard-hub: Bail out if peer hub is already probed

The .bind function is implemented to bind the correct
"half" of the hub that the driver wants to bind,
and returning -ENODEV for the other "half".

Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
2 months agousb: onboard-hub: Add i2c initialization for usb5744 hub
Venkatesh Yadav Abbarapu [Mon, 25 Nov 2024 04:12:01 +0000 (09:42 +0530)]
usb: onboard-hub: Add i2c initialization for usb5744 hub

Add i2c initialization hook and set usb5744 platform
data with function having required i2c initialization sequence.

Apart from the USB command attach, prevent the hub from suspend.
when the “USB Attach with SMBUS (0xAA56)” command is issued to the hub,
the hub is getting enumerated and then it puts in a suspend mode.
This causes the hub to NAK any SMBUS access made by the SMBUS Master
during this period and not able to see the hub's slave address while
running the "i2c probe" command.

Prevent the MCU from the putting the HUB in suspend mode through register
write. The BYPASS_UDC_SUSPEND bit (Bit 3) of the RuntimeFlags2 register at
address 0x411D controls this aspect of the hub. The BYPASS_UDC_SUSPEND
bit in register 0x411Dh must be set to ensure that the MCU is always
enabled and ready to respond to SMBus runtime commands. This register
needs to be written before the USB attach command is issued.
The byte sequence is as follows:
Slave addr: 0x2d           00 00 05 00 01 41 1D 08
Slave addr: 0x2d           99 37 00
Slave addr: 0x2d           AA 56 00

Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
2 months agousb: onboard-hub: add support for Microchip USB5744
Venkatesh Yadav Abbarapu [Mon, 25 Nov 2024 04:12:00 +0000 (09:42 +0530)]
usb: onboard-hub: add support for Microchip USB5744

Add support for the Microchip USB5744 USB3.0 and USB2.0 Hub.
The usb5744 driver trigger hub reset signal after soft reset.
The usb5744 hub need to reset after the phy initialization,
which toggles the gpio.

Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
2 months agousb: onboard-hub: Fix the return values of regulator APIs
Venkatesh Yadav Abbarapu [Mon, 25 Nov 2024 04:11:59 +0000 (09:41 +0530)]
usb: onboard-hub: Fix the return values of regulator APIs

Don't error out if there is no vdd regulator supply, as these are
optional properties.

Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
2 months agousb: onboard-hub: Add reset-gpio support
Venkatesh Yadav Abbarapu [Mon, 25 Nov 2024 04:11:58 +0000 (09:41 +0530)]
usb: onboard-hub: Add reset-gpio support

As part of the reset, sets the direction of the pin to output before
toggling the pin. Delay of millisecond is added in between low and
high to meet the setup and hold time requirement of the reset.
Update the usb2514 hub_data with the reset delay and power on
delay values.

Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Reviewed-by: Marek Vasut <[email protected]>
2 months agoMerge patch series "Fix device removal order for Apple dart iommu"
Tom Rini [Sun, 24 Nov 2024 21:41:32 +0000 (15:41 -0600)]
Merge patch series "Fix device removal order for Apple dart iommu"

Janne Grunau <[email protected]> says:

Starting with v2024.10 dev_iommu_dma_unmap calls during device removal
trigger a NULL pointer dereference in the Apple dart iommu driver. The
iommu device is removed before its user. The sparsely used DM_FLAG_VITAL
flag is intended to describe this dependency. Add it to the driver.

Adding this flag is unfortunately not enough since the boot routines
except the arm one simply remove all drivers. Add and use a new function
which calls
    dm_remove_devioce_flags(DM_REMOVE_ACTIVE_ALL | DM_REMOVE_NON_VITAL);
    dm_remove_devices_flags(DM_REMOVE_ACTIVE_ALL);
to ensure this order dependency is head consistently.

Link: https://lore.kernel.org/r/[email protected]
2 months agodm: Add dm_remove_devices_active() for ordered device removal
Janne Grunau [Sat, 23 Nov 2024 21:44:05 +0000 (22:44 +0100)]
dm: Add dm_remove_devices_active() for ordered device removal

This replaces dm_remove_devices_flags() calls in all boot
implementations to ensure non vital devices are consistently removed
first. All boot implementation except arch/arm/lib/bootm.c currently
just call dm_remove_devices_flags(DM_REMOVE_ACTIVE_ALL). This can result
in crashes when dependencies between devices exists. The driver model's
design document describes DM_FLAG_VITAL as "indicates that the device is
'vital' to the operation of other devices". Device removal at boot
should follow this.

Instead of adding dm_remove_devices_flags() with (DM_REMOVE_ACTIVE_ALL |
DM_REMOVE_NON_VITAL) everywhere add dm_remove_devices_active() which
does this.

Fixes a NULL pointer deref in the apple dart IOMMU driver during EFI
boot. The xhci-pci (driver which depends on the IOMMU to work) removes
its mapping on removal. This explodes when the IOMMU device was removed
first.

dm_remove_devices_flags() is kept since it is used for testing of
device_remove() calls in dm.

Signed-off-by: Janne Grunau <[email protected]>
2 months agoiommu: apple: Mark device with DM_FLAG_VITAL
Janne Grunau [Sat, 23 Nov 2024 21:44:04 +0000 (22:44 +0100)]
iommu: apple: Mark device with DM_FLAG_VITAL

Avoids NULL pointer dereferences in apple_dart_unmap when the iommu
device is removed before its user. U-boot's device model does not track
dependencies between devices.
Observed on a M1 Ultra Mac Studio with v2024.10.

Acked-by: Mark Kettenis <[email protected]>
Signed-off-by: Janne Grunau <[email protected]>
2 months agoMerge tag 'efi-2025-01-rc3' of https://source.denx.de/u-boot/custodians/u-boot-efi
Tom Rini [Sun, 24 Nov 2024 15:37:32 +0000 (09:37 -0600)]
Merge tag 'efi-2025-01-rc3' of https://source.denx.de/u-boot/custodians/u-boot-efi

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

- Documentation:
  - Document wget syntax enhancements with lwIP network stack
  - Move README.kconfig to HTML documentation
  - Remove redundant README.TPL
- UEFI:
  - Simplify efi_tcg2_hash_log_extend_event()
  - Allow EFI_LOADER_BOUNCE_BUFFER on all architectures
  - Correctly unmap and free memory on errors
- Other:
 - Enable EFI_LOADER_BOUNCE_BUFFER on StarFive VisionFive 2

2 months agolmb: Correctly unmap and free memory on errors
Ilias Apalodimas [Sun, 24 Nov 2024 09:00:03 +0000 (11:00 +0200)]
lmb: Correctly unmap and free memory on errors

We never free and unmap the memory on errors and we never unmap it when
freeing it. The latter won't cause any problems even on sandbox, but for
consistency always use unmap_sysmem()

Fixes: commit 22f2c9ed9f53 ("efi: memory: use the lmb API's for allocating and freeing memory")
Reviewed-by: Heinrich Schuchardt <[email protected]>
Signed-off-by: Ilias Apalodimas <[email protected]>
2 months agoMerge tag 'u-boot-imx-master-20241123' of https://gitlab.denx.de/u-boot/custodians...
Tom Rini [Sun, 24 Nov 2024 03:14:15 +0000 (21:14 -0600)]
Merge tag 'u-boot-imx-master-20241123' of https://gitlab.denx.de/u-boot/custodians/u-boot-imx

CI: https://source.denx.de/u-boot/custodians/u-boot-imx/-/pipelines/23523

- Fix a imx8mn clock driver regression where the 32kHz clock can not be
  found in SPL.

2 months agoconfigs: JH7110: enable EFI_LOADER_BOUNCE_BUFFER
Heinrich Schuchardt [Thu, 21 Nov 2024 14:25:22 +0000 (15:25 +0100)]
configs: JH7110: enable EFI_LOADER_BOUNCE_BUFFER

Our MMC driver for JH7110 boards only supports reading to the low 4 GiB of
memory. Booting boards with more memory requires EFI_LOADER_BOUNCE_BUFFER.

Reported-by: E Shattow <[email protected]>
Signed-off-by: Heinrich Schuchardt <[email protected]>
Tested-by: Loic Devulder <[email protected]>
2 months agoefi_loader: allow EFI_LOADER_BOUNCE_BUFFER on all architectures
Heinrich Schuchardt [Thu, 21 Nov 2024 14:25:21 +0000 (15:25 +0100)]
efi_loader: allow EFI_LOADER_BOUNCE_BUFFER on all architectures

Commit 775f7657ba58 ("Kconfig: clean up the efi configuration status")
by mistake revoked commit dcd1b63b7072 ("efi_loader: allow
EFI_LOADER_BOUNCE_BUFFER on all architectures").

Fixes: 775f7657ba58 ("Kconfig: clean up the efi configuration status")
Signed-off-by: Heinrich Schuchardt <[email protected]>
Tested-by: Loic Devulder <[email protected]>
2 months agodoc: cmd: wget: document lwIP syntax
Jerome Forissier [Mon, 18 Nov 2024 09:18:01 +0000 (10:18 +0100)]
doc: cmd: wget: document lwIP syntax

The lwIP version of wget supports a different syntax with a URL,
in addition to the legacy syntax. Document that.

While we're at it, fix a couple of minor issues in the legacy
syntax:
- hostIPaddr can be a DNS name if CONFIG_CMD_DNS is enabled
- path is mandatory

Signed-off-by: Jerome Forissier <[email protected]>
Reviewed-by: Simon Glass <[email protected]>
Reviewed-by: Heinrich Schuchardt <[email protected]>
2 months agodoc: remove README.TPL
Heinrich Schuchardt [Mon, 11 Nov 2024 09:16:21 +0000 (10:16 +0100)]
doc: remove README.TPL

doc/develop/spl.rst describes SPL, TPL, VPL.
Remove the outdated README.TPL document.

Signed-off-by: Heinrich Schuchardt <[email protected]>
2 months agodoc: move README.kconfig to HTML documentation
Heinrich Schuchardt [Mon, 11 Nov 2024 09:05:39 +0000 (10:05 +0100)]
doc: move README.kconfig to HTML documentation

* format according to Sphinx style
* add link to Linux Kconfig documentation
* sort table alphabetically in 'Conversion from boards.cfg to Kconfig'

Signed-off-by: Heinrich Schuchardt <[email protected]>
2 months agoefi_loader: simplify efi_tcg2_hash_log_extend_event()
Heinrich Schuchardt [Tue, 5 Nov 2024 04:20:45 +0000 (05:20 +0100)]
efi_loader: simplify efi_tcg2_hash_log_extend_event()

The value of variable nt is never used. Just use NULL when calling
efi_check_pe().

The API function is not expected to write to the console. Such output might
have unwanted side effects on the screen layout of an EFI application.

Leave error handling to the caller.

Signed-off-by: Heinrich Schuchardt <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
2 months agoarm64: dts: imx8mn: Include 32kHz oscillator clock in SPL DTs
Marek Vasut [Fri, 22 Nov 2024 01:58:12 +0000 (02:58 +0100)]
arm64: dts: imx8mn: Include 32kHz oscillator clock in SPL DTs

Since 50cdd3f74af3 ("clk: imx: clk-imx8mn Fix nand and spi clock parent"),
drivers/clk/imx/clk-imx8mn.c clk_get_by_name(dev, "osc_24m", &osc_24m_clk)
fails with error -22 EINVAL in SPL. This is because clk_get_by_name() in the
end calls fdtdec_parse_phandle_with_args(), which iterates over all phandles
in clock-controller@30380000 { clocks = <&osc_32k>, <&osc_24m>, ... } node
'clocks' property in an attempt to find the "osc_24m" clock, but fails to
resolve the &osc_32k phandle and returns with -EINVAL.

Include the osc_32k clock in SPL DTs as a low risk fix for v2025.01 release.
This way, fdtdec_parse_phandle_with_args() can resolve both the osc_32k and
following osc_24m phandle and successfully look up the osc_24m clock.

Fixes: 50cdd3f74af3 ("clk: imx: clk-imx8mn Fix nand and spi clock parent")
Signed-off-by: Marek Vasut <[email protected]>
Tested-by: Adam Ford <[email protected]> #imx8mn-beacon
2 months agoMerge branch '2024-11-22-assorted-fixes'
Tom Rini [Fri, 22 Nov 2024 20:43:17 +0000 (14:43 -0600)]
Merge branch '2024-11-22-assorted-fixes'

- Assorted additional lwIP fixes
- Assorted test fixes
- Assorted other localized fixes

2 months agocmd: improve description of the cdp command
Heinrich Schuchardt [Mon, 11 Nov 2024 09:50:35 +0000 (10:50 +0100)]
cmd: improve description of the cdp command

Users might not know what 'CDP' refers to. Provide basic information.

Signed-off-by: Heinrich Schuchardt <[email protected]>
2 months agotest: unit test for hextoull()
Heinrich Schuchardt [Wed, 13 Nov 2024 21:15:12 +0000 (22:15 +0100)]
test: unit test for hextoull()

Provide a unit test for the hextoull() function.

Signed-off-by: Heinrich Schuchardt <[email protected]>
Reviewed-by: Simon Glass <[email protected]>
2 months agonet: lwip: dhcp: support arguments for TFTP file download
Jerome Forissier [Thu, 14 Nov 2024 17:20:07 +0000 (18:20 +0100)]
net: lwip: dhcp: support arguments for TFTP file download

The dhcp command is supposed to have the following syntax as per
"help dhcp":

  dhcp [loadAddress] [[hostIPaddr:]bootfilename]

In other words, any arguments should be passed to an implicit
tftpboot command after the DHCP exchange has occurred.

Add the missing code to the lwIP version of do_dhcp().

Signed-off-by: Jerome Forissier <[email protected]>
2 months agonet: lwip: provide entropy to MBed TLS in one go
Ilias Apalodimas [Thu, 14 Nov 2024 14:29:15 +0000 (16:29 +0200)]
net: lwip: provide entropy to MBed TLS in one go

We currently provide entropy to mbedTLS using 8b chunks.
Take into account the 'len' parameter passed by MBed TLS to the entropy
gathering function instead. Note that the current code works because len
is always 128 (defined at compile time), therefore mbedtls_hardware_poll()
is called repeatedly and the buffer is filled correctly. But passing 'len'
to dm_rng_read() is both better and simpler.

Reviewed-by: Jerome Forissier <[email protected]>
Suggested-by: Simon Glass <[email protected]>
Signed-off-by: Ilias Apalodimas <[email protected]>
Reviewed-by: Simon Glass <[email protected]>
2 months agonet: lwip: wget: update help string
Jerome Forissier [Thu, 14 Nov 2024 14:20:40 +0000 (15:20 +0100)]
net: lwip: wget: update help string

The lwIP version of wget also supports the legacy syntax. Document it in
the help string.

Signed-off-by: Jerome Forissier <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
2 months agonet: lwip: fix get_udev_ipv4_info()
Jerome Forissier [Mon, 18 Nov 2024 14:31:25 +0000 (15:31 +0100)]
net: lwip: fix get_udev_ipv4_info()

The local variables ipstr, maskstr and gwstr in static function
get_udev_ipv4_info() cannot be pointers to read-only data, since
they may be written to in case the device index is > 0. Therefore
make them char arrays allocated on the stack.

Reported-by: Ilias Apalodimas <[email protected]>
Reported-by: Adriano Cordova <[email protected]>
Link: https://lists.denx.de/pipermail/u-boot/2024-November/572066.html
Signed-off-by: Jerome Forissier <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
2 months agoarm64: dts: ti: k3-j7200: Fix OSPI boot
Udit Kumar [Tue, 19 Nov 2024 10:07:20 +0000 (15:37 +0530)]
arm64: dts: ti: k3-j7200: Fix OSPI boot

OSPI boot is broken due to missing bootph property
in pin mux of OSPI.
So add bootph to fix OSPI boot.

Signed-off-by: Udit Kumar <[email protected]>
2 months agoboard: armltd: Make myself maintainer for total compute
Ben Horgan [Tue, 19 Nov 2024 17:25:58 +0000 (17:25 +0000)]
board: armltd: Make myself maintainer for total compute

The previous maintainer is no longer involved in total compute.

Signed-off-by: Ben Horgan <[email protected]>
Reviewed-by: Peter Robinson <[email protected]>
Reviewed-by: Leo Yan <[email protected]>
2 months agoRevert "test: Update time tests to use unit-test asserts"
Tom Rini [Tue, 19 Nov 2024 14:05:26 +0000 (08:05 -0600)]
Revert "test: Update time tests to use unit-test asserts"

While at the base level, this conversion looks equivalent, we now see
both of these tests failing (due to exceeding their allowed margin for
being too slow) in Azure with a very high frequency.

This reverts commit 88db4fc5fec20429881896740df61d402b4b1f66.

Signed-off-by: Tom Rini <[email protected]>
Tested-by: Andrew Goodbody <[email protected]>
Reviewed-by: Simon Glass <[email protected]>
2 months agonet: lwip: fix dhcp_loop()
Jerome Forissier [Fri, 22 Nov 2024 12:35:29 +0000 (13:35 +0100)]
net: lwip: fix dhcp_loop()

The local variables ipstr, maskstr and gwstr in static function
dhcp_loop() cannot be pointers to read-only data, since they may be
written to in case the device index is > 0. Therefore make them char
arrays allocated on the stack.

Reported-by: Ilias Apalodimas <[email protected]>
Signed-off-by: Jerome Forissier <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
2 months agotest: boot: Set DM|SCAN_FDT flags for bootmeth_{cros,android}
Mattijs Korpershoek [Fri, 22 Nov 2024 14:11:34 +0000 (15:11 +0100)]
test: boot: Set DM|SCAN_FDT flags for bootmeth_{cros,android}

We make fewer calls to dm_test_restore() since
commit fbdac8155c89 ("test: Expand implementation of ut_list_has_dm_tests()")

Because of this some valid test combinations are now broken:

$ ./test/py/test.py --bd sandbox --build -k test_ut
$ ./test/py/test.py --bd sandbox --build -k "bootflow_android or bootflow_cros"

Shows:

  Expected '  2  cros         ready   mmc          4 mmc5.bootdev.part_4       ',
  got '  2  cros         ready   mmc          2 mmc5.bootdev.part_2       '

Here prep_mmc_bootdev() is called twice and it will bind bootmeth_cros twice.

Since bootmeth_cros is bound twice, 'bootflow scan' will find 2x the
expected bootflows.

Before
commit fbdac8155c89 ("test: Expand implementation of ut_list_has_dm_tests()")
this did not happen because a cleanup was called each time.

Add UTF_DM and UTF_SCAN_FDT flags to both tests to make sure that the
bootmeths are unbound after the test finishes.

Fixes: fbdac8155c89 ("test: Expand implementation of ut_list_has_dm_tests()")
Signed-off-by: Mattijs Korpershoek <[email protected]>
2 months agoMerge branch 'qcom-main' of https://source.denx.de/u-boot/custodians/u-boot-snapdragon
Tom Rini [Wed, 20 Nov 2024 17:55:24 +0000 (11:55 -0600)]
Merge branch 'qcom-main' of https://source.denx.de/u-boot/custodians/u-boot-snapdragon

CI: https://source.denx.de/u-boot/custodians/u-boot-snapdragon/-/pipelines/23474

- UFS support is enabled for SC7280 and SM8150 platforms.
- Qualcomm dt-bindings headers are all dropped in favour of
  dts/upstream.
- The SMMU driver now correctly handles stream ID 0 and is disabled in
  EL2.
- Initial support for capsule updates (using the new dynamic UUIDs) is
  added for the RB3 Gen 2 board alongside a new SCSI backend for DFU.
- CONFIG_PINCONF is enabled in qcom_defconfig.
- The vqmmc supply is now enabled for sdcard support on boards that need
  it.
- A quirk is added for reading GPIOs on the PM8550 PMIC

2 months agotreewide: remove Qualcomm dt-binding headers that are available upstream
Caleb Connolly [Wed, 13 Nov 2024 04:33:32 +0000 (05:33 +0100)]
treewide: remove Qualcomm dt-binding headers that are available upstream

Some dt-binding headers mask the upstream ones which can lead to build
failures, or worse: super weird bugs, if they get out of sync.

Remove these headers so our devicetree and binding headers will both be
in sync with upstream.

Reviewed-by: Sumit Garg <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agoiommu: qcom-smmu: handle running in el2
Caleb Connolly [Wed, 13 Nov 2024 05:09:24 +0000 (06:09 +0100)]
iommu: qcom-smmu: handle running in el2

We only need to configure the SMMU when running in EL1. In EL2 the
hypervisor isn't running so peripherals can just do DMA as they wish.

Reviewed-by: Neil Armstrong <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agoiommu: qcom-smmu: allow SID 0
Caleb Connolly [Wed, 13 Nov 2024 05:00:56 +0000 (06:00 +0100)]
iommu: qcom-smmu: allow SID 0

It turns out this is a very real stream ID. Who woulda thought?

Drop the 0 check on the SID, there's no reason for it to be there in the first
place.

Reviewed-by: Neil Armstrong <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agoqcom_defconfig: enable capsule update support
Caleb Connolly [Sat, 12 Oct 2024 13:57:20 +0000 (15:57 +0200)]
qcom_defconfig: enable capsule update support

Enable all the necessary options for capsule updates to work, as well as
a few additional EFI features.

Capsule updates themselves are only enabled for the RB3 Gen 2, since the
exact details on where to flash U-Boot (or how to handle multiple boot
methods) has not been finalised for other boards.

Reviewed-by: Neil Armstrong <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agomach-snapdragon: implement capsule update support
Caleb Connolly [Sat, 12 Oct 2024 13:57:19 +0000 (15:57 +0200)]
mach-snapdragon: implement capsule update support

Qualcomm boards flash U-Boot a variety of partitions, implement support
for determining which slot U-Boot is running from, finding the correct
partition for that slot and configuring the appropriate DFU string.

Initially, we only support the RB3 Gen 2 where U-Boot is flashed to the
UEFI partition, and ignore handling of slots. In the future we will
additionally support booting U-Boot from other partitions (e.g. boot)
and correct handling for A/B.

Reviewed-by: Neil Armstrong <[email protected]>
Acked-by: Ilias Apalodimas <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agodisk: expose partition type flags
Caleb Connolly [Sat, 12 Oct 2024 13:57:18 +0000 (15:57 +0200)]
disk: expose partition type flags

GPT partition tables include two bytes worth of vendor defined
attributes, per partition. ChromeOS and Qualcomm both use these (with
different encoding!) to handle A/B slot switching with a retry counter.

Expose these via the disk_partition struct so that they can be parsed by
the relevant board code.

This will be used on Qualcomm boards to determine which slot we're
booting on so that we can flash capsule updates to the correct one.

Reviewed-by: Ilias Apalodimas <[email protected]>
Reviewed-by: Mattijs Korpershoek <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agodfu: add scsi backend
Caleb Connolly [Sat, 12 Oct 2024 13:57:17 +0000 (15:57 +0200)]
dfu: add scsi backend

This is extremely similar to the MMC backend, but there are some notable
differences.

Works with a DFU string like

    scsi 4=u-boot-bin part 11

Where "4" is the SCSI dev number (sequential LUN across all SCSI devices)
and "11" is the partition number.

Reviewed-by: Mattijs Korpershoek <[email protected]>
Acked-by: Mattijs Korpershoek <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agophy: qcom: Add SM8150 to QMP UFS PHY driver
Julius Lehmann [Wed, 2 Oct 2024 18:52:17 +0000 (20:52 +0200)]
phy: qcom: Add SM8150 to QMP UFS PHY driver

Copy PHY tables over from Linux to support SM8150

Reviewed-by: Neil Armstrong <[email protected]>
2 months agophy: qcom: ufs: add sc7280
Caleb Connolly [Sat, 12 Oct 2024 13:22:05 +0000 (15:22 +0200)]
phy: qcom: ufs: add sc7280

Add configuration for the SC7280, copied from Linux 6.11

Reviewed-by: Neil Armstrong <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agoqcom_defconfig: enable UFS Qualcomm controller and PHY drivers
Neil Armstrong [Mon, 14 Oct 2024 07:00:26 +0000 (09:00 +0200)]
qcom_defconfig: enable UFS Qualcomm controller and PHY drivers

Now the Qualcomm controller and PHY drivers were accepted,
enable then in the qcom_defconfig file.

Signed-off-by: Neil Armstrong <[email protected]>
Reviewed-by: Caleb Connolly <[email protected]>
2 months agodt-bindings: remove phy/phy-qcom-qmp.h in favor of dts/upstream
Neil Armstrong [Wed, 16 Oct 2024 07:37:20 +0000 (09:37 +0200)]
dt-bindings: remove phy/phy-qcom-qmp.h in favor of dts/upstream

The upstream version has new defines use to build DT, drop
it in favor of the dts/upstream more recent one.

Signed-off-by: Neil Armstrong <[email protected]>
Reviewed-by: Sumit Garg <[email protected]>
Reviewed-by: Caleb Connolly <[email protected]>
2 months agophy: qcom: ufs: drop unused ufsphy_v2_regs_layout
Neil Armstrong [Wed, 16 Oct 2024 07:43:56 +0000 (09:43 +0200)]
phy: qcom: ufs: drop unused ufsphy_v2_regs_layout

The ufsphy_v2_regs_layout is not used, drop it and fix:
phy-qcom-qmp-ufs.c:87:27: warning: ‘ufsphy_v2_regs_layout’ defined but not used [-Wunused-const-variable=]

Signed-off-by: Neil Armstrong <[email protected]>
Reviewed-by: Caleb Connolly <[email protected]>
2 months agogpio: qcom_pmic: add again the quirk to skip GPIO configuration on PM8550
Neil Armstrong [Wed, 16 Oct 2024 09:16:18 +0000 (11:16 +0200)]
gpio: qcom_pmic: add again the quirk to skip GPIO configuration on PM8550

The qcom_pmic code is broken for new PMICs and should be fixed,
without the QUIRK the code is broken and the GPIOs don't work
anymore on SM8550 and SM8650 platforms.

Partially revert the revert and only add the quirk on the PM8550
PMIC, making the buttons and MMC detect gpio work again.

Signed-off-by: Neil Armstrong <[email protected]>
Reviewed-by: Caleb Connolly <[email protected]>
2 months agommc: msm_sdhci: enable vqmmc at probe if available
Neil Armstrong [Wed, 16 Oct 2024 09:17:16 +0000 (11:17 +0200)]
mmc: msm_sdhci: enable vqmmc at probe if available

On earlier platforms, the vqmmc regulator was enabled by the
previous bootloader, but on the newest (SM8650) it's not
and we need vqmmc to be enabled in order to have the card
to respond.

Signed-off-by: Neil Armstrong <[email protected]>
Reviewed-by: Jaehoon Chung <[email protected]>
Reviewed-by: Caleb Connolly <[email protected]>
2 months agomach-snapdragon: configure logging
Caleb Connolly [Wed, 13 Nov 2024 05:04:17 +0000 (06:04 +0100)]
mach-snapdragon: configure logging

Set LOG_CATEGORY and pr_fmt. Also fix the time.h include.

Reviewed-by: Neil Armstrong <[email protected]>
Signed-off-by: Caleb Connolly <[email protected]>
2 months agoARM: mach-snapdragon: configure a larger default SYS_MALLOC_LEN for fastboot
Neil Armstrong [Wed, 16 Oct 2024 09:25:32 +0000 (11:25 +0200)]
ARM: mach-snapdragon: configure a larger default SYS_MALLOC_LEN for fastboot

Fastboot is very hungry when it flashes larges chunks, and 8MiB
is way too small, allocate a much bigger size like other platforms
using Fastboot.

Signed-off-by: Neil Armstrong <[email protected]>
Tested-by: Caleb Connolly <[email protected]> # rb1
Reviewed-by: Caleb Connolly <[email protected]>
2 months agoqcom_defconfig: enable PINCONF
Neil Armstrong [Thu, 17 Oct 2024 08:04:54 +0000 (10:04 +0200)]
qcom_defconfig: enable PINCONF

The SM8550 and SM8650 SoCs requires PINCONF to properly
setup SDC pins in order to function correctly.

Signed-off-by: Neil Armstrong <[email protected]>
Reviewed-by: Caleb Connolly <[email protected]>
2 months agoMerge tag 'xilinx-for-v2025.01-rc3-v2' of https://source.denx.de/u-boot/custodians...
Tom Rini [Tue, 19 Nov 2024 18:58:05 +0000 (12:58 -0600)]
Merge tag 'xilinx-for-v2025.01-rc3-v2' of https://source.denx.de/u-boot/custodians/u-boot-microblaze

AMD/Xilinx changes for v2025.01-rc3:

- microblaze:
  - Disable JFFS2
- fpga:
  - pass compatible flag to fpga_load()
- zynqmp:
  - SOM RTC fix
  - SC(system controller) PMW polarity fix
  - Fix ram_top calculation with introducing XILINX_MINI
  - Fix RPU release command
- versal:
  - Enable capsule update
  - Enable soft reset and Micron octal flashes
- xilinx:
  - Align Kconfig regarding SPI_STACKED_PARALLEL
- bootcount:
  - Add new zynqmp driver

2 months agoMerge patch series "buildman: Add initial support for config fragments"
Tom Rini [Tue, 19 Nov 2024 16:04:57 +0000 (10:04 -0600)]
Merge patch series "buildman: Add initial support for config fragments"

Simon Glass <[email protected]> says:

This series updates buildman to process #include lines in defconfig
files. With this, it is no-longer necessary to duplicate lines certain
lines from the include-file in the defconfig, e.g. CONFIG_ARM and
CONFIG_SOC_...

Link: https://lore.kernel.org/r/[email protected]
2 months agobuildman: Support a tilde to represent the home directory
Simon Glass [Fri, 8 Nov 2024 15:23:48 +0000 (08:23 -0700)]
buildman: Support a tilde to represent the home directory

It is convenient to use ~ to represent the home directory in the
settings file. Add support for this.

Signed-off-by: Simon Glass <[email protected]>
2 months agobuildman: Correct logic for adding a toolchain
Simon Glass [Fri, 8 Nov 2024 15:23:47 +0000 (08:23 -0700)]
buildman: Correct logic for adding a toolchain

If the toolchain is bad, it should not be added. Correct the logic for
this.

Signed-off-by: Simon Glass <[email protected]>
2 months agobuildman: Document the toolchain-prefix section
Simon Glass [Fri, 8 Nov 2024 15:23:46 +0000 (08:23 -0700)]
buildman: Document the toolchain-prefix section

This is mentioned in examples but should have its own mention in the
'settings' documentation. Add it.

Signed-off-by: Simon Glass <[email protected]>
2 months agobuildman: Correct the indentation in the setting-up section
Simon Glass [Fri, 8 Nov 2024 15:23:45 +0000 (08:23 -0700)]
buildman: Correct the indentation in the setting-up section

The example settings file should be indented so that it shows correctly
in the output. Fix it.

Signed-off-by: Simon Glass <[email protected]>
2 months agobuildman: Support #include files in defconfigs
Simon Glass [Fri, 8 Nov 2024 15:23:44 +0000 (08:23 -0700)]
buildman: Support #include files in defconfigs

This is used by some boards in U-Boot and is a convenient way to deal
with common settings where using a Kconfig files is not desirable.

Detect #include files and process them as if they were part of the
original file.

Signed-off-by: Simon Glass <[email protected]>
Fixes: https://source.denx.de/u-boot/custodians/u-boot-dm/-/issues/30
2 months agobuildman: Set up the tout library
Simon Glass [Fri, 8 Nov 2024 15:23:43 +0000 (08:23 -0700)]
buildman: Set up the tout library

Use this to control info and debugging messages. Enable them if -v is
given.

Signed-off-by: Simon Glass <[email protected]>
2 months agobuildman: Add a lower-level test for KconfigScanner
Simon Glass [Fri, 8 Nov 2024 15:23:42 +0000 (08:23 -0700)]
buildman: Add a lower-level test for KconfigScanner

This code is tested by test_scan_defconfigs() but it is useful to have
some specific tests for the KconfigScanner's operation in U-Boot. Add
a test which checks that the values are obtained correctly.

Signed-off-by: Simon Glass <[email protected]>
2 months agoxilinx: Introduce XILINX_MINI configuration
Michal Simek [Fri, 15 Nov 2024 14:31:02 +0000 (15:31 +0100)]
xilinx: Introduce XILINX_MINI configuration

There is no common symbol which mini configurations are using and recent
get_mem_top() changes adding 1.3kB without having a way to remove it.
That's why introduce new symbol which can be used for removing features
which are not requested by these configurations.

Signed-off-by: Michal Simek <[email protected]>
Link: https://lore.kernel.org/r/aa27b72e17057fa8cbdd92a2bbb863a31c8c1226.1731681053.git.michal.simek@amd.com
2 months agomicroblaze: Disable JFFS2 support
Michal Simek [Fri, 15 Nov 2024 08:38:55 +0000 (09:38 +0100)]
microblaze: Disable JFFS2 support

JFFS2 is not maintained for quite a long time and none should be using it.
Please use other filesystems for flashes like UBIFS instead.

Also remove jffs to MTD map but MTD map is for example that's why it won't
affect anything.

Signed-off-by: Michal Simek <[email protected]>
Link: https://lore.kernel.org/r/a8239acee8886229fdbff66142c46d522e3fe851.1731659933.git.michal.simek@amd.com
2 months agoarm64: zynqmp: Set default RTC device at start
Michal Simek [Tue, 12 Nov 2024 13:58:48 +0000 (14:58 +0100)]
arm64: zynqmp: Set default RTC device at start

For RTC to start to operate there is a need to call the driver. The simple
way to do it is to set default RTC instance which will call the probe and
do basic initialization.

Signed-off-by: Michal Simek <[email protected]>
Link: https://lore.kernel.org/r/01155f1555dbd42adc618906629f5fb45754d5a4.1731419926.git.michal.simek@amd.com
2 months agoarm64: versal: Enable soft reset support for xspi flashes
Venkatesh Yadav Abbarapu [Thu, 14 Nov 2024 04:26:41 +0000 (09:56 +0530)]
arm64: versal: Enable soft reset support for xspi flashes

Activate the xSPI Software Reset support, which will be
utilized to transition from octal DTR mode to legacy
mode during shutdown and boot (if enabled).

Signed-off-by: T Karthik Reddy <[email protected]>
Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Michal Simek <[email protected]>
2 months agoarm64: versal: Enable defconfig for Micron octal flashes
Venkatesh Yadav Abbarapu [Thu, 14 Nov 2024 05:10:47 +0000 (10:40 +0530)]
arm64: versal: Enable defconfig for Micron octal flashes

The Micron MT35 series octal flashes can be activated
through the configuration option CONFIG_SPI_FLASH_MT35XU.
To ensure their detection, enable this option in the
default defconfig for octal flashes.

Signed-off-by: Tejas Bhumkar <[email protected]>
Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Michal Simek <[email protected]>
2 months agospi: cadence_qspi: Fix OSPI boot issue
Venkatesh Yadav Abbarapu [Thu, 14 Nov 2024 06:20:45 +0000 (11:50 +0530)]
spi: cadence_qspi: Fix OSPI boot issue

Moving the hw_reset function from the controller driver to
the NOR framework has caused the OSPI reset not to be triggered
in the Cadence driver's probe function. As a result, reading the
flash ID during SPI calibration is incorrect, and the
CQSPI_REG_RD_DATA_CAPTURE is set with an invalid value.This makes
it unable to read the flash ID properly.
To solve this problem, it's suggested to skip SPI calibration and
instead retrieve the read_delay directly from the device tree.

Skipping SPI calibration doesn't bring harm since there's no need
for the flash golden values stored during SPI calibration.
Instead, they are now read during the spi_nor_read_id call in the
NOR framework.

Signed-off-by: Tejas Bhumkar <[email protected]>
Signed-off-by: Venkatesh Yadav Abbarapu <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Michal Simek <[email protected]>
2 months agotest: cmd/hash: check return value of ut_check_console_line
Heinrich Schuchardt [Sat, 16 Nov 2024 20:08:22 +0000 (21:08 +0100)]
test: cmd/hash: check return value of ut_check_console_line

ut_check_console_line() does include an assert.
Pass the result to ut_assertok().

Addresses-Coverity-ID:  514958 Error handling issues
Fixes: 7dfafcd65ef3 ("test: unit test for hash command")
Signed-off-by: Heinrich Schuchardt <[email protected]>
2 months agoKconfig: describe NET, NO_NET, LWIP_DEBUG and LWIP_ASSERT
Jerome Forissier [Tue, 12 Nov 2024 15:44:29 +0000 (16:44 +0100)]
Kconfig: describe NET, NO_NET, LWIP_DEBUG and LWIP_ASSERT

Some Kconfig symbols introduced in commit 8cb330355bd5 ("net: introduce
alternative implementation as net/lwip/") need a full description. The
NET symbol needs one, too.

Signed-off-by: Jerome Forissier <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
2 months agonet: lwip/wget: correct SERVER_NAME_SIZE
Heinrich Schuchardt [Fri, 8 Nov 2024 17:45:26 +0000 (18:45 +0100)]
net: lwip/wget: correct SERVER_NAME_SIZE

The maximum length of a domain name is 253 as defined in RFC 1035.
So SERVER_NAME_SIZE should be 254 including NUL.

Fixes: 3c656c928bd7 ("net: lwip: add wget command")
Signed-off-by: Heinrich Schuchardt <[email protected]>
Reviewed-by: Jerome Forissier <[email protected]>
Reviewed-by: Ilias Apalodimas <[email protected]>
This page took 0.085314 seconds and 4 git commands to generate.