1 /* SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause */
3 * Copyright (C) 2021, STMicroelectronics - All Rights Reserved
5 * Configuration settings for the STMicroelectonics STM32MP15x boards
8 #ifndef __CONFIG_STM32MP15_ST_COMMON_H__
9 #define __CONFIG_STM32MP15_ST_COMMON_H__
11 #include <configs/stm32mp15_common.h>
13 #ifdef CONFIG_EXTRA_ENV_SETTINGS
15 * default bootcmd for stm32mp1 STMicroelectronics boards:
16 * for serial/usb: execute the stm32prog command
17 * for mmc boot (eMMC, SD card), distro boot on the same mmc device
18 * for nand or spi-nand boot, distro boot with ubifs on UBI partition
19 * for nor boot, distro boot on SD card = mmc0 ONLY !
21 #define ST_STM32MP1_BOOTCMD "bootcmd_stm32mp=" \
22 "echo \"Boot over ${boot_device}${boot_instance}!\";" \
23 "if test ${boot_device} = serial || test ${boot_device} = usb;" \
24 "then stm32prog ${boot_device} ${boot_instance}; " \
27 "if test ${boot_device} = mmc;" \
28 "then env set boot_targets \"mmc${boot_instance}\"; fi;" \
29 "if test ${boot_device} = nand ||" \
30 " test ${boot_device} = spi-nand ;" \
31 "then env set boot_targets ubifs0; fi;" \
32 "if test ${boot_device} = nor;" \
33 "then env set boot_targets mmc0; fi;" \
34 "run distro_bootcmd;" \
37 #undef CONFIG_EXTRA_ENV_SETTINGS
38 #define CONFIG_EXTRA_ENV_SETTINGS \
41 STM32MP_PARTS_DEFAULT \