Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

st bsp update to stm32mp-r2 #6

Open
wants to merge 1 commit into
base: scarthgap
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion recipes-bsp/trusted-firmware-a/tf-a-stm32mp-common.inc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ LIC_FILES_CHKSUM = "file://license.rst;md5=1dd070c98a281d18d9eefd938729b031"

SRC_URI = "git://github.com/STMicroelectronics/arm-trusted-firmware;protocol=https;branch=${SRCBRANCH}"
SRCBRANCH = "v2.8-stm32mp"
SRCREV = "61924c04caa485af6d4be4663b4977f6ac226ca0"
SRCREV = "1568486ae9e1c15c0add1bc80e6fe225fa90714a"

DEPENDS += "dtc-native openssl-native"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 912ba711f3d740c0797edc1de9d1ee2d9b907f6e Mon Sep 17 00:00:00 2001
From 1616438ea56412aa7948701ebd8516d1438b8d13 Mon Sep 17 00:00:00 2001
From: Ayoub Zaki <[email protected]>
Date: Wed, 27 Dec 2023 15:05:24 +0700
Subject: [PATCH 1/4] add signature nodes to dts files
Expand All @@ -10,7 +10,7 @@ Signed-off-by: Ayoub Zaki <[email protected]>
2 files changed, 16 insertions(+)

diff --git a/arch/arm/dts/stm32mp157c-dk2.dts b/arch/arm/dts/stm32mp157c-dk2.dts
index 41d01a769c2..21c450a7719 100644
index 55126617bf..ae2bbeb130 100644
--- a/arch/arm/dts/stm32mp157c-dk2.dts
+++ b/arch/arm/dts/stm32mp157c-dk2.dts
@@ -18,6 +18,14 @@
Expand All @@ -29,7 +29,7 @@ index 41d01a769c2..21c450a7719 100644
ethernet0 = &ethernet0;
serial3 = &usart2;
diff --git a/arch/arm/dts/stm32mp157f-dk2.dts b/arch/arm/dts/stm32mp157f-dk2.dts
index c07a360f687..552f4edb6ee 100644
index f18aa8c35f..cd93eed192 100644
--- a/arch/arm/dts/stm32mp157f-dk2.dts
+++ b/arch/arm/dts/stm32mp157f-dk2.dts
@@ -18,6 +18,14 @@
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
From 0c4a60782d0863240e0ed579e107c5ffd1e5aac5 Mon Sep 17 00:00:00 2001
From a92099b60b60d201f6a419de0a61968967718d1e Mon Sep 17 00:00:00 2001
From: Ayoub Zaki <[email protected]>
Date: Wed, 27 Dec 2023 15:06:02 +0700
Date: Wed, 31 Jul 2024 17:49:33 +0200
Subject: [PATCH 2/4] shift kernel load address

Signed-off-by: Ayoub Zaki <[email protected]>
Expand All @@ -9,18 +9,18 @@ Signed-off-by: Ayoub Zaki <[email protected]>
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/configs/stm32mp15_common.h b/include/configs/stm32mp15_common.h
index bd8e16bc1b9..ecd00327c29 100644
index 50a989332d..55ad90c54d 100644
--- a/include/configs/stm32mp15_common.h
+++ b/include/configs/stm32mp15_common.h
@@ -123,7 +123,7 @@
@@ -114,7 +114,7 @@
* 1M fdt, 1M script, 1M pxe and 1M for overlay
* and the ramdisk at the end.
*/
-#define __KERNEL_ADDR_R __stringify(0xc2000000)
+#define __KERNEL_ADDR_R __stringify(0xc8000000)
#define __FDT_ADDR_R __stringify(0xc4000000)
#define __SCRIPT_ADDR_R __stringify(0xc4100000)
#define __PXEFILE_ADDR_R __stringify(0xc4200000)
#define __FDT_ADDR_R __stringify(0xc6000000)
#define __SCRIPT_ADDR_R __stringify(0xc6100000)
#define __PXEFILE_ADDR_R __stringify(0xc6200000)
--
2.34.1

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
From 100981de9788ee6a854685ce39c6043963076d18 Mon Sep 17 00:00:00 2001
From d63dbde80546af992b6dfde0eadc3f3cf7e80187 Mon Sep 17 00:00:00 2001
From: Ayoub Zaki <[email protected]>
Date: Wed, 27 Dec 2023 15:07:18 +0700
Date: Wed, 31 Jul 2024 17:50:34 +0200
Subject: [PATCH 3/4] rework CONFIG_EXTRA_ENV_SETTINGS

Signed-off-by: Ayoub Zaki <[email protected]>
Expand All @@ -9,10 +9,10 @@ Signed-off-by: Ayoub Zaki <[email protected]>
1 file changed, 29 insertions(+), 13 deletions(-)

diff --git a/include/configs/stm32mp15_st_common.h b/include/configs/stm32mp15_st_common.h
index e9bfbc482ef..3218118d8df 100644
index 7b0ed0a121..39c97b13e0 100644
--- a/include/configs/stm32mp15_st_common.h
+++ b/include/configs/stm32mp15_st_common.h
@@ -28,21 +28,24 @@
@@ -28,28 +28,44 @@
* for nor boot, distro boot on SD card = mmc0 ONLY !
*/
#define ST_STM32MP1_BOOTCMD "bootcmd_stm32mp=" \
Expand Down Expand Up @@ -49,8 +49,7 @@ index e9bfbc482ef..3218118d8df 100644
#undef CONFIG_EXTRA_ENV_SETTINGS
#define CONFIG_EXTRA_ENV_SETTINGS \
STM32MP_MEM_LAYOUT \
@@ -50,7 +53,20 @@
STM32MP_PARTS_DEFAULT \
ST_STM32MP1_BOOTCMD \
BOOTENV \
STM32MP_EXTRA \
- STM32MP_BOARD_EXTRA_ENV
Expand Down
Original file line number Diff line number Diff line change
@@ -1,27 +1,26 @@
From 52a49165ed1c44a42fee1d9ba393044ada5e8e8b Mon Sep 17 00:00:00 2001
From 93c29bdf97040789b477575dbbbfdeefd239d50a Mon Sep 17 00:00:00 2001
From: Ayoub Zaki <[email protected]>
Date: Wed, 27 Dec 2023 15:07:36 +0700
Subject: [PATCH 4/4] rework stm32mp15x defconfig
Date: Wed, 31 Jul 2024 17:55:07 +0200
Subject: [PATCH] rework stm32mp15x defconfig

Signed-off-by: Ayoub Zaki <[email protected]>
---
configs/stm32mp15_defconfig | 26 ++++++++++++++++----------
1 file changed, 16 insertions(+), 10 deletions(-)

diff --git a/configs/stm32mp15_defconfig b/configs/stm32mp15_defconfig
index be25aaa7885..5908a573b2d 100644
index 5f3fbac002..03c1e59040 100644
--- a/configs/stm32mp15_defconfig
+++ b/configs/stm32mp15_defconfig
@@ -2,14 +2,15 @@ CONFIG_ARM=y
@@ -2,14 +2,14 @@ CONFIG_ARM=y
CONFIG_ARCH_STM32MP=y
CONFIG_TFABOOT=y
CONFIG_SYS_MALLOC_F_LEN=0x80000
-CONFIG_ENV_OFFSET=0x900000
CONFIG_ENV_SECT_SIZE=0x40000
+CONFIG_ENV_OFFSET=0x280000
CONFIG_ENV_SECT_SIZE=0x40000
CONFIG_DEFAULT_DEVICE_TREE="stm32mp157c-ev1"
CONFIG_SYS_PROMPT="STM32MP> "
+CONFIG_BOOTCOUNT_BOOTLIMIT=3
CONFIG_DDR_CACHEABLE_SIZE=0x8000000
CONFIG_CMD_STM32KEY=y
CONFIG_TARGET_ST_STM32MP15X=y
Expand All @@ -30,15 +29,7 @@ index be25aaa7885..5908a573b2d 100644
CONFIG_CMD_STM32PROG=y
# CONFIG_ARMV7_NONSEC is not set
CONFIG_SYS_LOAD_ADDR=0xc2000000
@@ -43,6 +44,7 @@ CONFIG_CMD_USB=y
CONFIG_CMD_USB_MASS_STORAGE=y
CONFIG_SYS_DISABLE_AUTOLOAD=y
CONFIG_CMD_BMP=y
+CONFIG_CMD_BOOTCOUNT=y
CONFIG_CMD_CACHE=y
CONFIG_CMD_EFIDEBUG=y
CONFIG_CMD_TIME=y
@@ -54,19 +56,14 @@ CONFIG_CMD_EXT4_WRITE=y
@@ -60,17 +60,10 @@ CONFIG_CMD_EXT4_WRITE=y
CONFIG_CMD_LOG=y
CONFIG_CMD_UBI=y
CONFIG_OF_LIVE=y
Expand All @@ -54,25 +45,15 @@ index be25aaa7885..5908a573b2d 100644
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
-CONFIG_SYS_MMC_ENV_DEV=-1
-CONFIG_ENV_MMC_USE_DT=y
+# CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG is not set
CONFIG_TFTP_TSIZE=y
CONFIG_STM32_ADC=y
+CONFIG_BOOTCOUNT_LIMIT=y
CONFIG_CLK_SCMI=y
CONFIG_SET_DFU_ALT_INFO=y
CONFIG_USB_FUNCTION_FASTBOOT=y
@@ -164,6 +161,7 @@ CONFIG_BMP_16BPP=y
CONFIG_BMP_24BPP=y
CONFIG_BMP_32BPP=y
CONFIG_WDT=y
@@ -187,3 +180,16 @@ CONFIG_FWU_MULTI_BANK_UPDATE=y
CONFIG_FWU_MDATA_V2=y
# CONFIG_TOOLS_MKEFICAPSULE is not set
# CONFIG_TOOLS_MKFWUMDATA is not set
+CONFIG_BOOTCOUNT_LIMIT=y
+CONFIG_WDT_STM32MP=y
CONFIG_WDT_ARM_SMC=y
CONFIG_WDT_STM32MP=y
# CONFIG_BINMAN_FDT is not set
@@ -174,3 +169,11 @@ CONFIG_ERRNO_STR=y
# CONFIG_LMB_USE_MAX_REGIONS is not set
CONFIG_LMB_MEMORY_REGIONS=2
CONFIG_LMB_RESERVED_REGIONS=16
+CONFIG_VIDEO_LOGO=y
+CONFIG_SPLASH_SCREEN=y
+CONFIG_SPLASH_SCREEN_ALIGN=y
Expand All @@ -81,10 +62,8 @@ index be25aaa7885..5908a573b2d 100644
+CONFIG_ECDSA=y
+CONFIG_ECDSA_VERIFY=y
+CONFIG_OF_CONTROL=y
+CONFIG_ENV_WRITEABLE_LIST=y
+CONFIG_ENV_FLAGS_LIST_DEFAULT="active_system:dw"
+CONFIG_ENV_FLAGS_LIST_STATIC="active_system:dw"

+# CONFIG_ENV_WRITEABLE_LIST=y
+# CONFIG_ENV_FLAGS_LIST_DEFAULT="active_system:dw"
+# CONFIG_ENV_FLAGS_LIST_STATIC="active_system:dw"
--
2.34.1

2 changes: 1 addition & 1 deletion recipes-bsp/u-boot/u-boot-stm32_2022.10.bb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ DEPENDS += "bc-native dtc-native u-boot-tools-native"
DEPENDS += "python3-setuptools-native"

SRCBRANCH = "v2022.10-stm32mp"
SRCREV = "2c7a6accfa78d34c402fa262bb53f0b952198882"
SRCREV = "262bcb6906d46aa2265be284b0b625eb2e0b674e"

SRC_URI = "git://github.com/STMicroelectronics/u-boot.git;protocol=https;branch=${SRCBRANCH} \
file://0001-add-signature-nodes-to-dts-files.patch \
Expand Down
46 changes: 45 additions & 1 deletion recipes-kernel/linux/linux-stm32/defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -211,16 +211,60 @@ CONFIG_REGULATOR_STM32_PWR=y
CONFIG_REGULATOR_STPMIC1=y
CONFIG_REGULATOR_VCTRL=y
CONFIG_DRM=y
CONFIG_DRM_MIPI_DSI=y
CONFIG_DRM_KMS_HELPER=y
CONFIG_DRM_FBDEV_EMULATION=y
CONFIG_DRM_DP_AUX_BUS=y
CONFIG_DRM_DISPLAY_HELPER=y
CONFIG_DRM_DISPLAY_DP_HELPER=y
CONFIG_DRM_DISPLAY_HDMI_HELPER=y
CONFIG_DRM_GEM_DMA_HELPER=y
CONFIG_DRM_GEM_SHMEM_HELPER=y
CONFIG_DRM_EXYNOS_FIMD=y
CONFIG_DRM_EXYNOS_MIXER=y
CONFIG_DRM_EXYNOS_DPI=y
CONFIG_DRM_EXYNOS_DSI=y
CONFIG_DRM_EXYNOS_DP=y
CONFIG_DRM_EXYNOS_HDMI=y
CONFIG_DRM_RCAR_USE_LVDS=y
CONFIG_DRM_RCAR_USE_MIPI_DSI=y
CONFIG_DRM_STM=y
CONFIG_DRM_STM_DSI=y
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANEL_SIMPLE=y
CONFIG_DRM_PANEL_EDP=y
CONFIG_DRM_PANEL_ORISETECH_OTM8009A=y
CONFIG_DRM_BRIDGE=y
CONFIG_DRM_PANEL_BRIDGE=y
CONFIG_DRM_DISPLAY_CONNECTOR=y
CONFIG_DRM_SII902X=y
CONFIG_DRM_I2C_ADV7511=y
CONFIG_DRM_I2C_ADV7511_AUDIO=y
CONFIG_DRM_I2C_ADV7511_CEC=y
CONFIG_DRM_DW_MIPI_DSI=y
CONFIG_DRM_ETNAVIV_THERMAL=y
CONFIG_DRM_SIMPLEDRM=y
CONFIG_DRM_LEGACY=y
CONFIG_DRM_PANEL_ORIENTATION_QUIRKS=y
CONFIG_DRM_NOMODESET=y
CONFIG_FB=y
CONFIG_FB_SIMPLE=y
CONFIG_FB_CMDLINE=y
CONFIG_FB_NOTIFY=y
CONFIG_FB_CFB_FILLRECT=y
CONFIG_FB_CFB_COPYAREA=y
CONFIG_FB_CFB_IMAGEBLIT=y
CONFIG_FB_SYS_FILLRECT=y
CONFIG_FB_SYS_COPYAREA=y
CONFIG_FB_SYS_IMAGEBLIT=y
CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA=y
CONFIG_FB_SYS_FOPS=y
CONFIG_FB_DEFERRED_IO=y
CONFIG_FB_MODE_HELPERS=y
CONFIG_BACKLIGHT_CLASS_DEVICE=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_BACKLIGHT_GPIO=y
CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=y
CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y
CONFIG_LOGO=y
CONFIG_USB_CONN_GPIO=y
Expand Down
6 changes: 3 additions & 3 deletions recipes-kernel/linux/linux-stm32_6.1.bb
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
require linux-stm32.inc

LINUX_VERSION = "6.1.28"
LINUX_VERSION = "6.1.82"
SRCBRANCH = "v6.1-stm32mp"
SRCREV = "7928f69738d2e57ee2a0dba6e9e680a3bf75ded9"
SRCREV = "7084443b1f4255944dc48190b3e95127e692dc2a"

LIC_FILES_CHKSUM = "file://${S}/COPYING;md5=6bc538ed5bd9a7fc9398086aedcd7e46"

SRC_URI += "file://defconfig"
SRC_URI += "https://cdn.kernel.org/pub/linux/kernel/projects/rt/6.1/older/patch-6.1.28-rt10.patch.gz;sha256sum=e3686855cd31a6856d40ea3601422e5ebb073d4733263c1f1e7d506a84dcd6c6"
SRC_URI += "https://cdn.kernel.org/pub/linux/kernel/projects/rt/6.1/older/patch-6.1.82-rt27.patch.gz;sha256sum=5381b4f6da5f13aa285bd980c8af695366bc3e330aa377ea0e01699270c8696f"
SRC_URI += "${@bb.utils.contains('MACHINE_FEATURES', 'rt', 'file://rt-preempt.cfg', '', d)}"
5 changes: 3 additions & 2 deletions recipes-security/optee/optee-os-stm32mp_3.19.0.bb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ SRC_URI = "git://github.com/STMicroelectronics/optee_os.git;protocol=ssh;branch=
SRC_URI += "file://0001-ta-pkcs11-fix-ecc-generation-and-ecc-import.patch"
SRC_URI += "file://0002-ta-pkcs11-rsa-public-key-import-calculate-CKA_MODULUS_BITS.patch"
SRCBRANCH = "3.19.0-stm32mp"
SRCREV = "d0159bbfa266dcb0e12c01712e258b86e4d67f51"
SRCREV = "43089782f25c57968bea4e2794fb82101d31227c"

S = "${WORKDIR}/git"

Expand Down Expand Up @@ -36,7 +36,8 @@ EXTRA_OEMAKE += "CROSS_COMPILE_core=${HOST_PREFIX}"
EXTRA_OEMAKE += "CROSS_COMPILE_ta_arm64=${HOST_PREFIX}"
EXTRA_OEMAKE += "${@bb.utils.contains('TUNE_FEATURES', 'aarch64', 'CFG_ARM64_core=y ta-targets=ta_arm64', 'CFG_ARM32_core=y CROSS_COMPILE_ta_arm32=${HOST_PREFIX}', d)}"
EXTRA_OEMAKE += "NOWERROR=1"
EXTRA_OEMAKE += "CFG_WITH_PAGER=y CFG_STM32MP1_OPTEE_IN_SYSRAM=1"
EXTRA_OEMAKE += "CFG_STM32MP_PROFILE=secure_and_system_services"
EXTRA_OEMAKE += "CFG_WITH_PAGER=y CFG_STM32MP1_OPTEE_IN_SYSRAM=y"
EXTRA_OEMAKE += "CFG_WITH_USER_TA=y"
EXTRA_OEMAKE += "CFG_IN_TREE_EARLY_TAS+=trusted_keys/f04a0fe7-1f5d-4b9b-abf7-619b85b4ce8c"
EXTRA_OEMAKE += "CFG_IN_TREE_EARLY_TAS+=pkcs11/fd02c9da-306c-48c7-a49c-bbd827ae86ee"
Expand Down