u-boot-brain/arch/arm
Patrick Delaunay 954bd1a923 stm32mp: add the command stm32prog
Add a specific command stm32prog for STM32MP soc family
witch allows to program the boot devices with the tool
STM32CubeProgrammer (http://www.st.com/STM32CubeProg).

This command uses the same UART STM32 protocol than MCU
STM32 with or USB with DFU protocol v1.1 (ithe MCU ST
extension are no supported).

The executed actions are based on a tab separated value file
with a stm32 header, the FlashLayout file
(https://wiki.st.com/stm32mpu/wiki/STM32CubeProgrammer_flashlayout).

This file is parsed by the U-Boot command to:
- initialize the devices
- create the partition table on each device
- initialize the DFU backend to access to not volatile memory
  (NOR/NAND/SD/eMMC) or to virtual device (OTP/PMIC)

Up to STM32PROG_MAX_DEV (5) devices can be updated with a FlashLayout.

The communication between U-Boot and STM32CubeProgrammer is done with
the specific alternate configuration (see "AN5275: USB DFU/USART protocols
used in STM32MP1 Series bootloaders" for details).

The command stm32prog is executed when a boot from USB is detected
(selected with bootpins) and we can program the boot devices with
a simple command (on Windows or Linux):

PC $>  STM32_Programmer_CLI -c port=usb1 -w flaslayout.tsv

1/ the ROM code loads TF-A in embedded RAM (DFU or uart)
2/ TF-A loads flashlayout file and U-Boot in DDR (DFU or uart)
3/ U-Boot executes the stm32prog command (DFU or uart)

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@st.com>
2020-05-14 09:02:12 +02:00
..
cpu imx: imx8qm/qxp: Recover SPL data section for partition reboot 2020-05-10 20:55:20 +02:00
dts board: stm32mp1: reserve memory for OP-TEE in device tree 2020-05-14 09:02:12 +02:00
include imx: imx8qm/qxp: check whether m4 partition booted 2020-05-10 20:55:20 +02:00
lib cmd: cache: Fix non-cached memory cachability 2020-05-07 09:01:42 -04:00
mach-aspeed dm: core: Require users of devres to include the header 2020-02-05 19:33:46 -07:00
mach-at91 common: Move hang() to the same header as panic() 2020-01-24 23:06:49 +05:30
mach-bcm283x rpi4: Update memory map to accommodate scb devices 2020-01-29 18:30:33 +01:00
mach-bcmstb
mach-cortina board: presidio-asic: Add basic G3 engr. development board support 2020-02-07 16:16:01 -05:00
mach-davinci mach-davinci: Hard-code the default SPL_LDSCRIPT path 2020-03-16 18:54:18 -04:00
mach-exynos arm: exynos: Read default MMC device from XOM[7:5] pins 2020-01-28 09:54:05 +09:00
mach-highbank
mach-imx imx8: cpu: check resource owned after sid fail 2020-05-10 20:55:21 +02:00
mach-integrator
mach-k3 arm: K3: Increase default SYSFW image size allocation 2020-05-11 10:16:49 +05:30
mach-keystone common: Move hang() to the same header as panic() 2020-01-24 23:06:49 +05:30
mach-kirkwood common: Move reset_cpu() to the CPU header 2020-01-24 23:06:49 +05:30
mach-mediatek arm: mediatek: remove unused binman config 2020-03-10 17:08:13 -04:00
mach-meson phy: Use _nodev naming convention if non-device clients 2020-05-11 01:30:49 +05:30
mach-mvebu arm: mvebu: correct SPL boot configs for SPI/MMC 2020-04-22 14:28:15 +02:00
mach-omap2 spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-orion5x edminiv2: Move CONFIG_SPL_LDSCRIPT to defconfig 2020-03-16 18:54:18 -04:00
mach-owl arm: add support Actions Semi S700 2020-04-24 16:40:09 -04:00
mach-qemu qemu: don't allow to select 32- and 64-bit 2020-04-24 10:51:32 -04:00
mach-rmobile common: Move some cache and MMU functions out of common.h 2019-12-02 18:23:55 -05:00
mach-rockchip spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-s5pc1xx common: Move some cache and MMU functions out of common.h 2019-12-02 18:23:55 -05:00
mach-snapdragon mach-snapdragon: Fix overwriting last digit of serial number 2020-04-03 11:47:47 -04:00
mach-socfpga arm: socfpga: stratix10: Fix incorrect CLKMGR_S10_PERPLL_BYPASS offset 2020-04-27 09:14:52 +02:00
mach-sti
mach-stm32
mach-stm32mp stm32mp: add the command stm32prog 2020-05-14 09:02:12 +02:00
mach-sunxi sunxi: SPL SPI: Add SPI boot support for the Allwinner H6 SoC 2020-03-18 18:12:04 +05:30
mach-tegra ARM: tegra: Add NVIDIA Jetson Nano Developer Kit support 2020-04-02 14:30:02 -07:00
mach-u8500 board: Add new Samsung "stemmy" board based on ST-Ericsson U8500 2020-01-22 17:47:57 -05:00
mach-uniphier spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-versal arm: asm/cache.c: Introduce arm_reserve_mmu 2020-04-24 15:17:14 -04:00
mach-versatile
mach-zynq ARM: zynq: Do not print message about boot device 2020-04-06 12:52:45 +02:00
mach-zynqmp arm: asm/cache.c: Introduce arm_reserve_mmu 2020-04-24 15:17:14 -04:00
mach-zynqmp-r5 common: Move reset_cpu() to the CPU header 2020-01-24 23:06:49 +05:30
thumb1/include/asm/proc-armv
config.mk
Kconfig arm: juno: enable USB 2020-05-07 09:01:42 -04:00
Kconfig.debug
Makefile arm: Add support for ST-Ericsson U8500 SoC 2020-01-22 17:47:57 -05:00