Commit Graph

9 Commits

Author SHA1 Message Date
Grzegorz Szymaszek
b8c492068b board/stm32mp157: remove hardcoded device tree names from post-image.sh
The post-image.sh script is used in several STM32MP157-based board
configs. It had hardcoded device tree file names for the supported
boards which were used for matching the expected TF-A binary name.
Replace this mechanism with a pair of grep and sed that build the TF-A
binary name from the device tree file name. For example, if
BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES contained
DTB_FILE_NAME=stm32mp157c-dk2.dtb, the appropriate TF-A file would be
named tf-a-stm32mp157c-dk2.stm32.

Since the Bash Here Strings are removed with this change, I took the
opportunity to remove the only other non-POSIX command, "local", and
then I was able to change the shebang to plain /bin/sh, with -eu for
simpler error handling.

Signed-off-by: Grzegorz Szymaszek <gszymaszek@short.pl>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2023-09-30 21:15:45 +02:00
Dario Binacchi
f187fad22d configs/stm32f4xx_defconfig: off network utils from busybox
Kernel is built without network support, so network utils are useless.
This has a positive impact on the size of busybox and xipImage, making
them smaller.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Reviewed-by: Giulio Benetti <giulio.benetti@benettiegineering.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2023-07-28 23:00:38 +02:00
Dario Binacchi
58e7ac21b1 configs/stm32f4xx_defconfig: remove BR2_PACKAGE_IFUPDOWN_SCRIPTS
Kernel is built without network support. It is useless to compile the
package and then remove it from rootfs.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2023-05-13 19:58:22 +02:00
Thomas Petazzoni
97fc9b2a7f board/*/genimage.cfg: use partition-table-type = "gpt"
The gpt = "true" form is deprecated in genimage, use
partition-table-type = "gpt" instead.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2022-07-23 15:36:21 +02:00
Sergey Matyukevich
3e70251d36 board/stmicroelectronics/common/stm32mp157: fix U-Boot corruption on the first boot
The stm32mp157 images successfully boot only once. Subsequent boot
attempts fail to reach U-Boot. The root cause turns out to be in U-Boot
corruption during the first boot. The stm32mp1 U-Boot stores its
environment at the end of GPT partition named 'ssbl' since v2020.10-rc2.
However Buildroot genimage template for stm32mp157 boards creates 'ssbl'
partition w/o extra space for U-Boot primary and redundant environments.
This patch explicitly specifies 'ssbl' partition size that should be
enough for both u-boot.stm32 image (~1M) and both environments (16K).

Signed-off-by: Sergey Matyukevich <geomatsi@gmail.com>
Tested-by: Pierre-Jean Texier <texier.pj2@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2021-07-15 21:59:15 +02:00
Peter Korsgaard
2107f7a75b configs/avenger96_defconfig: add support for Arrow Avenger96 board
Very similar to the other stm32mp157-based boards, except that we use the
multi_v7 defconfig for ease of maintenance.

Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2021-02-08 16:25:00 +01:00
Shlomi Vaknin
4d15114713 configs/stm32mp157*: switch to use TF-A based configurations
This commit changes the stm32mp1 configurations to use the TF-A ->
U-Boot boot flow (called "trusted boot flow" by ST) instead of the
U-Boot SPL -> U-Boot boot flow. ST recommands this trusted boot, and
it's also the only one that allows to use the STM32 Cube Programmer
for reflashing devices.

As part of this, the genimage configuration file is now generated, as
it contains some file names that depend on the platform. Removing
partition-type from genimage.cfg is mandatory, since it would cause a
hybrid MBR partition table to be created, which itself would prevent
ATF from finding the ssbl parition.

Signed-off-by: Shlomi Vaknin <shlomi.39sd@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-10-13 23:04:03 +02:00
Bartosz Bilas
092b112f48 board/stmicroelectronics/stm32f4xx: move post-build script into common directory
Let's clean up "boards/stmicroelectronics" directory a bit
to have everything in particular directories.

Signed-off-by: Bartosz Bilas <b.bilas@grinn-global.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-03-21 15:27:17 +01:00
Bartosz Bilas
7f82e0933a configs/stm32mp157: use common genimage config file for stm32mp157 boards
It will be useful for the upcoming introducing stm32mp157a dk2 board.

Signed-off-by: Bartosz Bilas <b.bilas@grinn-global.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2020-03-21 15:27:17 +01:00