Hi Carlo,
On 9/30/26 2:51 PM, Carlo Caione wrote:
Genio 510 and 700 need a way to provision blank eMMC and recover boards
with unusable boot firmware. Add RAM-based fastboot download agents that
can be loaded through the MediaTek BootROM download protocol without
relying on the installed bootloader.
Fastboot in U-Boot proper is preferred when the complete download agent
fits the platform's BootROM payload limit. It provides U-Boot's shell and
boot facilities as well as flashing. The SPL variant offers a smaller
executable payload when including BL31 and U-Boot proper would exceed
that limit. Both require an external DDR loader and run fastboot from
DRAM after DDR initialization.
The two paths start USB fastboot at different stages:
Fastboot in SPL Fastboot in U-Boot proper
--------------- -------------------------
BootROM USB download BootROM USB download
(host -> SRAM) (host -> SRAM)
| |
v v
DDR loader DDR loader
| Initialize DRAM | Initialize DRAM
| Copy SPL to DRAM | Copy SPL + FIT to DRAM
v v
SPL SPL
| USB fastboot <-> host | Load BL31 + U-Boot from RAM
v v
eMMC provisioning BL31
|
v
U-Boot proper
| USB fastboot <-> host
v
eMMC provisioning
This series is based on upstream/next. Generic SPL fastboot V6, applied
to u-boot-dfu-next [1], remains a prerequisite.
Had a glance at this (am not really interested in Mediatek :) ), and the
single question I would have is:
why have SPL_ in the middle of the Kconfig symbol?
Can't you just have
SPL_MTK_BROM_DOWNLOAD_AGENT_FASTBOOT for SPL
MTK_BROM_DOWNLOAD_AGENT_FASTBOOT for proper
so you can use CONFIG_IS_ENABLED(MTK_BROM_DOWNLOAD_AGENT_FASTBOOT)? You
can always use IS_ENABLED(CONFIG_SPL_MTK_BROM_DOWNLOAD_AGENT_FASTBOOT)
if you want to check the symbol for a specific stage.
Cheers,
Quentin