From patchwork Sun Nov 14 17:31:19 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 1554923 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=libero.it header.i=@libero.it header.a=rsa-sha256 header.s=s2021 header.b=n7NSTwfT; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4HsfWy23NPz9sWJ for ; Mon, 15 Nov 2021 04:31:58 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id E4F2440266; Sun, 14 Nov 2021 17:31:55 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 4Drn4icJI9Mc; Sun, 14 Nov 2021 17:31:55 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id 1267640205; Sun, 14 Nov 2021 17:31:54 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 50D021BF2BA for ; Sun, 14 Nov 2021 17:31:48 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 40E1140205 for ; Sun, 14 Nov 2021 17:31:48 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id KM6BF-h_n3QQ for ; Sun, 14 Nov 2021 17:31:47 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0 Received: from libero.it (smtp-16.italiaonline.it [213.209.10.16]) by smtp4.osuosl.org (Postfix) with ESMTPS id E922740204 for ; Sun, 14 Nov 2021 17:31:46 +0000 (UTC) Received: from passgat-Modern-14-A10M.homenet.telecomitalia.it ([79.24.99.64]) by smtp-16.iol.local with ESMTPA id mJLpm8CKm7VizmJLzmVOoi; Sun, 14 Nov 2021 18:31:44 +0100 x-libjamoibt: 1601 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=libero.it; s=s2021; t=1636911104; bh=LfBoQXXmc/hwYFWj/Kc32uq13Z1X5EUvofulfvRGQ8c=; h=From; b=n7NSTwfTPq6eYLKAYTyOq6E0sdGOFqTR7W7XlOhhrIobYmhIER3nzpxcCPaLh+dAR U5f8j3HWyHZ1qzTifddZQLSZ+z574dNw7sYKsibjNA9rkiP0O8a8EI/YUSPWJtSbsj EkoIGPCo9Ztc3RZ3jQ13OWSVSuuiWdbXnRMkE1XvXoJoVRMdjq37RqnYcTwGFLY/5g PJmQG5X00Q3jW++VqgcqbVkGWY367lAzA5TIuHQJi47MzQT/K9scMI1KXvOH7JA7PX dlcfHnqnNEbHWGMyFor+oUFBJSrBkU6r79cIuef3ubHIOXzOgo9Nudgj8hetgT1aiT OnlizED0313Pg== X-CNFS-Analysis: v=2.4 cv=ftYZ2H0f c=1 sm=1 tr=0 ts=61914800 cx=a_exe a=8X6arsqDvdvtpvHbdcPR/Q==:117 a=8X6arsqDvdvtpvHbdcPR/Q==:17 a=pGLkceISAAAA:8 a=x06lECoZNFyqQeWrCsUA:9 To: buildroot@buildroot.org Date: Sun, 14 Nov 2021 18:31:19 +0100 Message-Id: <20211114173122.16612-2-dariobin@libero.it> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211114173122.16612-1-dariobin@libero.it> References: <20211114173122.16612-1-dariobin@libero.it> X-CMAE-Envelope: MS4xfAT7VzN2LomipVYy4F34i/VPnp3rNmBgWWoR3ILj9Y9xio735xvxYasQP/KSFDZ/SYTDCb96ODCXv6gkNGLZbAGS37Z8DA6wMujG5NfJT8+Gputpebe7 UIRBRQ/jvTIq6kgGpYK8bigHagBZ7o4BD5G+DaRC8K+0qXR/Sm4fFNI38X9C3dmE+NWc8A8RfwfuqsnENDMOOHn6ZmenJeDwY3rMrj3NxNzKvDuzz3ROf2/j MXwtOBQIl2DsRlxZerDgUseSLE0gzMbB5hsqWbLJ46PyPrLL5Chhc1bw5j5fjfvs3ILlk27M68nwFT4RTPNU9Xel3Ryk6SnT+c7xPFD/lUTc+rwEIQZPpECG 4011DOga Subject: [Buildroot] [v2, 1/4] configs/stm32f469_xip_disco: fix kernel bootup X-BeenThere: buildroot@buildroot.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Dario Binacchi via buildroot From: Dario Binacchi Reply-To: Dario Binacchi Cc: Lee Jones , Christophe Priouzeau , Dario Binacchi MIME-Version: 1.0 Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Testing this configuration on the stm32f469-disco board failed. Removing the changes on the DRAM I got a bootable image. I also changed the kernel load address from 0x8010000 to 0x800C000 to allocate more space to the kernel since 32kB for the device tree is enough. Signed-off-by: Dario Binacchi --- .../stm32f469-disco/flash_xip.sh | 2 +- .../stm32f469-disco/linux-xip.config | 8 +-- ...32f469-i-Update-kernel-start-address.patch | 56 ------------------- ...69i-disco-change-kernel-load-address.patch | 26 +++++++++ ...fault-dram-address-without-remapping.patch | 38 ------------- configs/stm32f469_disco_xip_defconfig | 1 + 6 files changed, 32 insertions(+), 99 deletions(-) mode change 100644 => 100755 board/stmicroelectronics/stm32f469-disco/flash_xip.sh delete mode 100644 board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469-i-Update-kernel-start-address.patch create mode 100644 board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch delete mode 100644 board/stmicroelectronics/stm32f469-disco/patches/linux/0001-Use-default-dram-address-without-remapping.patch diff --git a/board/stmicroelectronics/stm32f469-disco/flash_xip.sh b/board/stmicroelectronics/stm32f469-disco/flash_xip.sh old mode 100644 new mode 100755 index b5a067cee5..da27cd327c --- a/board/stmicroelectronics/stm32f469-disco/flash_xip.sh +++ b/board/stmicroelectronics/stm32f469-disco/flash_xip.sh @@ -15,6 +15,6 @@ ${OUTPUT_DIR}/host/bin/openocd -f board/stm32f469discovery.cfg \ -c "flash info 0" \ -c "flash write_image erase ${OUTPUT_DIR}/images/stm32f469i-disco.bin 0x08000000" \ -c "flash write_image erase ${OUTPUT_DIR}/images/stm32f469-disco.dtb 0x08004000" \ - -c "flash write_image erase ${OUTPUT_DIR}/images/xipImage 0x08010000" \ + -c "flash write_image erase ${OUTPUT_DIR}/images/xipImage 0x0800C000" \ -c "reset run" \ -c "shutdown" diff --git a/board/stmicroelectronics/stm32f469-disco/linux-xip.config b/board/stmicroelectronics/stm32f469-disco/linux-xip.config index 2d0ce59b31..01a94eb9d1 100644 --- a/board/stmicroelectronics/stm32f469-disco/linux-xip.config +++ b/board/stmicroelectronics/stm32f469-disco/linux-xip.config @@ -18,7 +18,7 @@ CONFIG_CC_OPTIMIZE_FOR_SIZE=y # CONFIG_MULTIUSER is not set # CONFIG_SYSFS_SYSCALL is not set # CONFIG_FHANDLE is not set -# CONFIG_POSIX_TIMERS is not set +CONFIG_POSIX_TIMERS=y # CONFIG_BUG is not set # CONFIG_BASE_FULL is not set # CONFIG_FUTEX is not set @@ -47,12 +47,12 @@ CONFIG_ARCH_STM32=y CONFIG_CPU_V7M_NUM_IRQ=240 # CONFIG_ARM_DMA_MEM_BUFFERABLE is not set CONFIG_SET_MEM_PARAM=y -CONFIG_DRAM_BASE=0xc0000000 -CONFIG_DRAM_SIZE=0x01000000 +CONFIG_DRAM_BASE=0x00000000 +CONFIG_DRAM_SIZE=0x00800000 CONFIG_HZ_1000=y # CONFIG_ATAGS is not set CONFIG_XIP_KERNEL=y -CONFIG_XIP_PHYS_ADDR=0x08010000 +CONFIG_XIP_PHYS_ADDR=0x0800C000 CONFIG_XIP_DEFLATED_DATA=y # CONFIG_SUSPEND is not set # CONFIG_STACKPROTECTOR is not set diff --git a/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469-i-Update-kernel-start-address.patch b/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469-i-Update-kernel-start-address.patch deleted file mode 100644 index d5d1e5a8ad..0000000000 --- a/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469-i-Update-kernel-start-address.patch +++ /dev/null @@ -1,56 +0,0 @@ -From fe5f3a86d07e378baeeddc1dfecd0686d83aa42f Mon Sep 17 00:00:00 2001 -From: Yauheni Saldatsenka -Date: Sat, 14 Aug 2021 18:54:51 +0300 -Subject: [PATCH] stm32f469-i: Update kernel start address - -As of GNU/Linux v5.12 kernel device tree binary grows above 0x08008000 -and overwrites kernel binary -Therefore this commit moves kernel to the next flash bank - -Signed-off-by: Yauheni Saldatsenka ---- - stm32f469i-disco.c | 7 +++---- - 1 file changed, 3 insertions(+), 4 deletions(-) - -diff --git a/stm32f469i-disco.c b/stm32f469i-disco.c -index 2da1f4b..46fc06a 100644 ---- a/stm32f469i-disco.c -+++ b/stm32f469i-disco.c -@@ -6,6 +6,7 @@ - #include "gpio.h" - #include "mpu.h" - -+#define KERNEL_ADDR 0x08010000 - #define CONFIG_HSE_HZ 8000000 - #define CONFIG_PLL_M 8 - #define CONFIG_PLL_N 360 -@@ -85,7 +86,7 @@ static void fmc_wait_busy(void) - - void start_kernel(void) - { -- void (*kernel)(uint32_t reserved, uint32_t mach, uint32_t dt) = (void (*)(uint32_t, uint32_t, uint32_t))(0x08008000 | 1); -+ void (*kernel)(uint32_t reserved, uint32_t mach, uint32_t dt) = (void (*)(uint32_t, uint32_t, uint32_t))(KERNEL_ADDR | 1); - - kernel(0, ~0UL, 0x08004000); - } -@@ -102,7 +103,7 @@ int main(void) - volatile uint32_t *SYSCFG_MEMRMP = (void *)(SYSCFG_BASE + 0x00); - int i; - -- mpu_config(0x0); -+ mpu_config(0xc0000000); - - if (*FLASH_CR & FLASH_CR_LOCK) { - *FLASH_KEYR = 0x45670123; -@@ -195,8 +196,6 @@ int main(void) - usart_setup(usart_base, 45000000); - usart_putch(usart_base, '.'); - -- *SYSCFG_MEMRMP = 0x4; -- - start_kernel(); - - return 0; --- -2.32.0 - diff --git a/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch b/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch new file mode 100644 index 0000000000..1f8d929bfb --- /dev/null +++ b/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch @@ -0,0 +1,26 @@ +From d87969f72671cab5a88ba6e2418e43d0fa267d6f Mon Sep 17 00:00:00 2001 +From: Dario Binacchi +Date: Sat, 13 Nov 2021 15:46:32 +0100 +Subject: [PATCH] stm32f469i-disco: change kernel load address + +Signed-off-by: Dario Binacchi +--- + stm32f469i-disco.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/stm32f469i-disco.c b/stm32f469i-disco.c +index 2da1f4b..3aacb12 100644 +--- a/stm32f469i-disco.c ++++ b/stm32f469i-disco.c +@@ -85,7 +85,7 @@ static void fmc_wait_busy(void) + + void start_kernel(void) + { +- void (*kernel)(uint32_t reserved, uint32_t mach, uint32_t dt) = (void (*)(uint32_t, uint32_t, uint32_t))(0x08008000 | 1); ++ void (*kernel)(uint32_t reserved, uint32_t mach, uint32_t dt) = (void (*)(uint32_t, uint32_t, uint32_t))(0x0800C000 | 1); + + kernel(0, ~0UL, 0x08004000); + } +-- +2.17.1 + diff --git a/board/stmicroelectronics/stm32f469-disco/patches/linux/0001-Use-default-dram-address-without-remapping.patch b/board/stmicroelectronics/stm32f469-disco/patches/linux/0001-Use-default-dram-address-without-remapping.patch deleted file mode 100644 index 68fe8380a2..0000000000 --- a/board/stmicroelectronics/stm32f469-disco/patches/linux/0001-Use-default-dram-address-without-remapping.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 8ccf9f625d00138d86fb7d70f3efd58a8fb4d7ff Mon Sep 17 00:00:00 2001 -From: Yauheni Saldatsenka -Date: Mon, 23 Aug 2021 02:54:22 +0300 -Subject: [PATCH] Use default dram address without remapping - -Signed-off-by: Yauheni Saldatsenka ---- - arch/arm/boot/dts/stm32f469-disco.dts | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/arch/arm/boot/dts/stm32f469-disco.dts b/arch/arm/boot/dts/stm32f469-disco.dts -index 2e1b3bbbe4b5..06845614a19a 100644 ---- a/arch/arm/boot/dts/stm32f469-disco.dts -+++ b/arch/arm/boot/dts/stm32f469-disco.dts -@@ -60,9 +60,9 @@ chosen { - stdout-path = "serial0:115200n8"; - }; - -- memory@00000000 { -+ memory@c0000000 { - device_type = "memory"; -- reg = <0x00000000 0x1000000>; -+ reg = <0xc0000000 0x1000000>; - }; - - aliases { -@@ -84,7 +84,7 @@ vdd_dsi: vdd-dsi { - }; - - soc { -- dma-ranges = <0xc0000000 0x0 0x10000000>; -+ dma-ranges = <0xc0000000 0xc0000000 0x10000000>; - }; - - leds { --- -2.32.0 - diff --git a/configs/stm32f469_disco_xip_defconfig b/configs/stm32f469_disco_xip_defconfig index 1ceffe4026..e8b2cf3d21 100644 --- a/configs/stm32f469_disco_xip_defconfig +++ b/configs/stm32f469_disco_xip_defconfig @@ -3,6 +3,7 @@ BR2_cortex_m4=y BR2_GLOBAL_PATCH_DIR="board/stmicroelectronics/stm32f469-disco/patches" # BR2_UCLIBC_INSTALL_UTILS is not set BR2_GCC_ENABLE_LTO=y +BR2_ROOTFS_POST_BUILD_SCRIPT="board/stmicroelectronics/common/stm32f4xx/stm32-post-build.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/stmicroelectronics/stm32f469-disco/linux-xip.config" From patchwork Sun Nov 14 17:31:20 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 1554924 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=libero.it header.i=@libero.it header.a=rsa-sha256 header.s=s2021 header.b=AayG48Ci; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4HsfX92dJZz9sWJ for ; Mon, 15 Nov 2021 04:32:09 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id B7F6E80D60; Sun, 14 Nov 2021 17:32:07 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0Ahl-WmYKYrl; Sun, 14 Nov 2021 17:32:06 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id D69ED80D96; Sun, 14 Nov 2021 17:32:05 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 6CF0D1BF2BA for ; Sun, 14 Nov 2021 17:31:49 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 6807360667 for ; Sun, 14 Nov 2021 17:31:49 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp3.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=libero.it Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id eC_3bJigI-Un for ; Sun, 14 Nov 2021 17:31:48 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0 Received: from libero.it (smtp-16.italiaonline.it [213.209.10.16]) by smtp3.osuosl.org (Postfix) with ESMTPS id F0FEB605FD for ; Sun, 14 Nov 2021 17:31:47 +0000 (UTC) Received: from passgat-Modern-14-A10M.homenet.telecomitalia.it ([79.24.99.64]) by smtp-16.iol.local with ESMTPA id mJLpm8CKm7VizmJM1mVOpD; Sun, 14 Nov 2021 18:31:45 +0100 x-libjamoibt: 1601 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=libero.it; s=s2021; t=1636911105; bh=IW9EeQzyBTgchyDfZUTA8vUDs0IKLlvYScnrT0DXJgg=; h=From; b=AayG48CiQUZ2iRgyB6ZObyLWZSNd1FGoYASJIGIKBmTLuHu+QvWmUacGDMzNreQ6C XsjherhHJcroT6eOdBg7giU1yB1bIHnc8zwUCmiY9smEKTGwY4BtQCkGBDXJOCXjbJ x289WiHJH7UhWmpPTseASeg1vUlxaBAbVboB9BzIlB7r8+FJrVy9VlMBaoWXH6N9Xy 4b4jd97ztrSVB2jO8hWvN/bYSJZBhq6LeA94rkk0oBIpvcnxDw7fOOVVx3q2oEtyrF t6RaYK8PyIBTQOMBiKogWtFqPNLzpVbXzzJ7GK4CgqJh8CabjNmF0dS0JQmKCm6Mu5 tgxQ5iW3UpSIQ== X-CNFS-Analysis: v=2.4 cv=ftYZ2H0f c=1 sm=1 tr=0 ts=61914801 cx=a_exe a=8X6arsqDvdvtpvHbdcPR/Q==:117 a=8X6arsqDvdvtpvHbdcPR/Q==:17 a=NEAV23lmAAAA:8 a=TdwfhV22bwzyGTalfRQA:9 To: buildroot@buildroot.org Date: Sun, 14 Nov 2021 18:31:20 +0100 Message-Id: <20211114173122.16612-3-dariobin@libero.it> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211114173122.16612-1-dariobin@libero.it> References: <20211114173122.16612-1-dariobin@libero.it> X-CMAE-Envelope: MS4xfAekS9CODcOlDVVruhXLS7uVOJ0kUnaeCTqk4+5oxMai3i+zOfvFW21IkXgXRCTDedGFQYP4FXkPEB0XBIHPScnIZOvjgdrUTq72uvO5LmOrTooPTOQS Z5waIdSvKKintCWVNdY4u366yvsTUvqJ7vCRw/GkJHDmqinOXF/Z9SiDatBhYub4woAEkAWdFTkdu+g5wEc3CvqytbOMRw55aEabp5YsXIA4PxKr3a7/6e9T Ro+qUXswUwY1lzaOK/YUfr5ht8ExOtmU8qgF8HEkjVfxKBDGbZh+3Dw2aUkxFWGDL/RR9z6Dnf2EE0Bej52l4rgzDf+29Ce1I9C4HkDv+G/tTGTSRTnvvJs3 FFRb/2// Subject: [Buildroot] [v2,2/4] boot/afboot-stm32: upgrade version X-BeenThere: buildroot@buildroot.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Dario Binacchi via buildroot From: Dario Binacchi Reply-To: Dario Binacchi Cc: Lee Jones , Christophe Priouzeau , Dario Binacchi MIME-Version: 1.0 Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Newer versions of the kernel generate device trees that are not storable in a single 16kB sector. In these cases the kernel load address must be changed. The commit 2e499dcff3ef ("Add possibility to use custom kernel load address") adds the possibility to override the default (0x08008000) kernel load address. This also required changes to the stm32f429_disco_defconfig and stm32f469_disco_xip_defconfig configurations. Signed-off-by: Dario Binacchi --- ...69i-disco-change-kernel-load-address.patch | 26 --------------- boot/afboot-stm32/Config.in | 32 +++++++++++++++++++ boot/afboot-stm32/afboot-stm32.hash | 2 +- boot/afboot-stm32/afboot-stm32.mk | 18 ++++++++--- configs/stm32f429_disco_defconfig | 1 + configs/stm32f469_disco_xip_defconfig | 3 +- 6 files changed, 50 insertions(+), 32 deletions(-) delete mode 100644 board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch diff --git a/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch b/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch deleted file mode 100644 index 1f8d929bfb..0000000000 --- a/board/stmicroelectronics/stm32f469-disco/patches/afboot-stm32/0001-stm32f469i-disco-change-kernel-load-address.patch +++ /dev/null @@ -1,26 +0,0 @@ -From d87969f72671cab5a88ba6e2418e43d0fa267d6f Mon Sep 17 00:00:00 2001 -From: Dario Binacchi -Date: Sat, 13 Nov 2021 15:46:32 +0100 -Subject: [PATCH] stm32f469i-disco: change kernel load address - -Signed-off-by: Dario Binacchi ---- - stm32f469i-disco.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/stm32f469i-disco.c b/stm32f469i-disco.c -index 2da1f4b..3aacb12 100644 ---- a/stm32f469i-disco.c -+++ b/stm32f469i-disco.c -@@ -85,7 +85,7 @@ static void fmc_wait_busy(void) - - void start_kernel(void) - { -- void (*kernel)(uint32_t reserved, uint32_t mach, uint32_t dt) = (void (*)(uint32_t, uint32_t, uint32_t))(0x08008000 | 1); -+ void (*kernel)(uint32_t reserved, uint32_t mach, uint32_t dt) = (void (*)(uint32_t, uint32_t, uint32_t))(0x0800C000 | 1); - - kernel(0, ~0UL, 0x08004000); - } --- -2.17.1 - diff --git a/boot/afboot-stm32/Config.in b/boot/afboot-stm32/Config.in index 309b9e0491..71f4c7e382 100644 --- a/boot/afboot-stm32/Config.in +++ b/boot/afboot-stm32/Config.in @@ -5,3 +5,35 @@ config BR2_TARGET_AFBOOT_STM32 afboot-stm32 is a very small bootloader for STM32 platforms https://github.com/mcoquelin-stm32/afboot-stm32 + +if BR2_TARGET_AFBOOT_STM32 + +choice + prompt "Board type" + help + Select the proper stm32 board type. + +config BR2_TARGET_AFBOOT_STM32_F429_DISCO + bool "stm32f429-disco" + +config BR2_TARGET_AFBOOT_STM32_F469_DISCO + bool "stm32f469-disco" + +endchoice + +config BR2_TARGET_AFBOOT_STM32_KERNEL_ADDR + hex "Kernel load address" + default "0x08008000" + help + This is the physical address in your flash memory the kernel will + be linked for and stored to. This address is dependent on your own + flash usage. + +config BR2_TARGET_AFBOOT_STM32_DTB_ADDR + hex "Device-tree load address" + default "0x08004000" + help + This is the physical address in your flash memory the device-tree + will be stored to. This address is dependent on your own flash usage. + +endif diff --git a/boot/afboot-stm32/afboot-stm32.hash b/boot/afboot-stm32/afboot-stm32.hash index 75f47295f6..80b9b6a106 100644 --- a/boot/afboot-stm32/afboot-stm32.hash +++ b/boot/afboot-stm32/afboot-stm32.hash @@ -1,2 +1,2 @@ # Locally calculated -sha256 9b37b661bd3091ceb5d8dc5a56a2dfc02ae9ebc0c63dad3c4289c9d6b3d3ec89 afboot-stm32-0.2.tar.gz +sha256 132f9817e615131856892cbe3df1502cdcd0700a12a48aa6bae8acfd5f093b42 afboot-stm32-3566acd582e5536fb60864281788a30f5527df2d-br1.tar.gz diff --git a/boot/afboot-stm32/afboot-stm32.mk b/boot/afboot-stm32/afboot-stm32.mk index 0fb4735285..80074a3c35 100644 --- a/boot/afboot-stm32/afboot-stm32.mk +++ b/boot/afboot-stm32/afboot-stm32.mk @@ -4,17 +4,27 @@ # ################################################################################ -AFBOOT_STM32_VERSION = 0.2 -AFBOOT_STM32_SITE = $(call github,mcoquelin-stm32,afboot-stm32,v$(AFBOOT_STM32_VERSION)) +AFBOOT_STM32_VERSION = 3566acd582e5536fb60864281788a30f5527df2d +AFBOOT_STM32_SITE = https://github.com/mcoquelin-stm32/afboot-stm32.git +AFBOOT_STM32_SITE_METHOD = git AFBOOT_STM32_INSTALL_IMAGES = YES AFBOOT_STM32_INSTALL_TARGET = NO +ifeq ($(BR2_TARGET_AFBOOT_STM32_F429_DISCO),y) +AFBOOT_STM32_BOARD=stm32f429i-disco +else +AFBOOT_STM32_BOARD=stm32f469i-disco +endif + define AFBOOT_STM32_BUILD_CMDS - $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) CROSS_COMPILE=$(TARGET_CROSS) all + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) CROSS_COMPILE=$(TARGET_CROSS) \ + $(AFBOOT_STM32_BOARD) \ + KERNEL_ADDR=$(BR2_TARGET_AFBOOT_STM32_KERNEL_ADDR) \ + DTB_ADDR=$(BR2_TARGET_AFBOOT_STM32_DTB_ADDR) endef define AFBOOT_STM32_INSTALL_IMAGES_CMDS - $(INSTALL) -m 0755 -t $(BINARIES_DIR) -D $(@D)/stm32*.bin + $(INSTALL) -m 0755 -t $(BINARIES_DIR) -D $(@D)/$(AFBOOT_STM32_BOARD).bin endef $(eval $(generic-package)) diff --git a/configs/stm32f429_disco_defconfig b/configs/stm32f429_disco_defconfig index 2c0641a6c5..4007eb20a5 100644 --- a/configs/stm32f429_disco_defconfig +++ b/configs/stm32f429_disco_defconfig @@ -15,4 +15,5 @@ BR2_PACKAGE_BUSYBOX_CONFIG="package/busybox/busybox-minimal.config" BR2_TARGET_ROOTFS_INITRAMFS=y # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_AFBOOT_STM32=y +BR2_TARGET_AFBOOT_STM32_KERNEL_ADDR=0x0800C000 BR2_PACKAGE_HOST_OPENOCD=y diff --git a/configs/stm32f469_disco_xip_defconfig b/configs/stm32f469_disco_xip_defconfig index e8b2cf3d21..4c49ffcc7a 100644 --- a/configs/stm32f469_disco_xip_defconfig +++ b/configs/stm32f469_disco_xip_defconfig @@ -1,6 +1,5 @@ BR2_arm=y BR2_cortex_m4=y -BR2_GLOBAL_PATCH_DIR="board/stmicroelectronics/stm32f469-disco/patches" # BR2_UCLIBC_INSTALL_UTILS is not set BR2_GCC_ENABLE_LTO=y BR2_ROOTFS_POST_BUILD_SCRIPT="board/stmicroelectronics/common/stm32f4xx/stm32-post-build.sh" @@ -16,4 +15,6 @@ BR2_PACKAGE_BUSYBOX_CONFIG="package/busybox/busybox-minimal.config" BR2_TARGET_ROOTFS_INITRAMFS=y # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_AFBOOT_STM32=y +BR2_TARGET_AFBOOT_STM32_F469_DISCO=y +BR2_TARGET_AFBOOT_STM32_KERNEL_ADDR=0x0800C000 BR2_PACKAGE_HOST_OPENOCD=y From patchwork Sun Nov 14 17:31:21 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 1554925 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=libero.it header.i=@libero.it header.a=rsa-sha256 header.s=s2021 header.b=ZAwCOjdd; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4HsfXQ0yZPz9sWJ for ; Mon, 15 Nov 2021 04:32:22 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id ACA1D40204; Sun, 14 Nov 2021 17:32:19 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0jl-KQaz1erM; Sun, 14 Nov 2021 17:32:18 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id AD41240271; Sun, 14 Nov 2021 17:32:17 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id C584B1BF2BA for ; Sun, 14 Nov 2021 17:31:52 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id C29E380DA3 for ; Sun, 14 Nov 2021 17:31:52 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp1.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=libero.it Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Y7Ah4HKkdhrS for ; Sun, 14 Nov 2021 17:31:52 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0 Received: from libero.it (smtp-16.italiaonline.it [213.209.10.16]) by smtp1.osuosl.org (Postfix) with ESMTPS id 82C7B80D62 for ; Sun, 14 Nov 2021 17:31:50 +0000 (UTC) Received: from passgat-Modern-14-A10M.homenet.telecomitalia.it ([79.24.99.64]) by smtp-16.iol.local with ESMTPA id mJLpm8CKm7VizmJM6mVOqB; Sun, 14 Nov 2021 18:31:50 +0100 x-libjamoibt: 1601 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=libero.it; s=s2021; t=1636911110; bh=1OOcMSi+m9y8Stf8+OJq1s5KzMA3t96cERPVB52079o=; h=From; b=ZAwCOjdd24rOY7XaWZVkQPZCUYNTnOTgY4IVPX4eqKDZlgQzfIRHJJYQatFwI/II6 RiPSAi41BgKt73VlT7ykKPh92075MFrAHa3DXDqfLFJMSGH0XPLUNcuWiPn8vdyLY5 oQ1ijWQL/b1uQLbB+gkwDo9LH96duIgIS37B/azlIdS8LE9b2EGbk6tVx7L8BCw/mT yzBo25InJ9z/q4BiQbLywZ4RrfynGImPN0weq+W6R8T8cqumpRy1iaKL5i3RaKlOv1 frkvhxCiN8nHOX7sWA5gk3RGh3j11hv9XclhYtU3opYHGRoEITJ/cmxUh1CgrD0hFS I1r0E2yGz+6bw== X-CNFS-Analysis: v=2.4 cv=ftYZ2H0f c=1 sm=1 tr=0 ts=61914806 cx=a_exe a=8X6arsqDvdvtpvHbdcPR/Q==:117 a=8X6arsqDvdvtpvHbdcPR/Q==:17 a=uP1ucDPQAAAA:8 a=ORQKomyGMWY2Aaz4Py8A:9 a=9a9ggB8z3XFZH39hjkD6:22 To: buildroot@buildroot.org Date: Sun, 14 Nov 2021 18:31:21 +0100 Message-Id: <20211114173122.16612-4-dariobin@libero.it> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211114173122.16612-1-dariobin@libero.it> References: <20211114173122.16612-1-dariobin@libero.it> X-CMAE-Envelope: MS4xfDqtG/6k204DaiuzuXpBI0Q4sMlBSsKQQO3RlM/fHAu0MohuHwOiP3IO3rvF9p051v8jBDvdPPl6exRK+zVpKL0SPMjotT3Lq92SsbcRRQ2gLFq+h51i gY5fyhjqlplPkDWXriocWRM62zddR5tJKhYh0hgAz8swzsieglAliGSYeBeJ4RXpmS1RFRIWSl/nvyMpq7eJCtLG89HOo61vgw9ChPyI6QL2j3uLyOOyTfVJ Xzd+XZdXb0FkV818ZsJN7vtKDx3nANo9Ccrz0HQcy1ZDDa2tJBpjzXnUWZGsVzh64cEQbYhn1P7Dgz82YiE3mmGjcY1IcL33qWh9jB5pT2zy0+9B5fGLtGco tmC+0gAN Subject: [Buildroot] [v2,3/4] configs/stm32f429_disco: fix kernel bootup X-BeenThere: buildroot@buildroot.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Dario Binacchi via buildroot From: Dario Binacchi Reply-To: Dario Binacchi Cc: Lee Jones , Christophe Priouzeau , Dario Binacchi MIME-Version: 1.0 Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" The kernel generated by the configuration for the STM32f429-discovery board is buggy: Fixes: Unhandled exception: IPSR = 00000006 LR = fffffff1 CPU: 0 PID: 1 Comm: init Not tainted 4.11.0 #2 Hardware name: STM32 (Device Tree Support) task: 9041a000 task.stack: 907c0000 PC is at ret_fast_syscall+0x2/0x4a LR is at tty_ioctl+0x1ad/0x75c pc : [<0800d942>] lr : [<080c2e05>] psr: 4000000b sp : 907c1fa8 ip : 0000001c fp : 905961a2 r10: 00000000 r9 : 907c0000 r8 : 0800dae0 r7 : 00000036 r6 : 905e7e60 r5 : 00000000 r4 : 905e7ebc r3 : 00000000 r2 : 00000000 r1 : 00000000 r0 : 00000000 xPSR: 4000000b CPU: 0 PID: 1 Comm: init Not tainted 4.11.0 #2 Hardware name: STM32 (Device Tree Support) [<0800fbf9>] (unwind_backtrace) from [<0800f05b>] (show_stack+0xb/0xc) [<0800f05b>] (show_stack) from [<0800f553>] (__invalid_entry+0x4b/0x4c) Inspired by commit a3e3d9c198 ("configs/stm32f469_disco_xip_defconfig: alternative defconfig for XIP") I updated the stm32f429_disco_defconfig configuration to use a newer kernel. Current setup kernel + rootfs fits in 1.6MB on-chip flash memory. The kernel has been moved to new flash bank due to growth of dtb size. For better binary size optimization gcc LTO is turned on. Signed-off-by: Dario Binacchi --- .../stm32f429-disco/flash.sh | 2 +- .../stm32f429-disco/linux.config | 120 ++++++++++++++++++ ...sco-don-t-force-init-in-chosen-boota.patch | 32 ----- configs/stm32f429_disco_defconfig | 10 +- 4 files changed, 127 insertions(+), 37 deletions(-) create mode 100644 board/stmicroelectronics/stm32f429-disco/linux.config delete mode 100644 board/stmicroelectronics/stm32f429-disco/patches/linux/0001-ARM-stm32f249-disco-don-t-force-init-in-chosen-boota.patch diff --git a/board/stmicroelectronics/stm32f429-disco/flash.sh b/board/stmicroelectronics/stm32f429-disco/flash.sh index b19e0a6019..3e2bf121d3 100755 --- a/board/stmicroelectronics/stm32f429-disco/flash.sh +++ b/board/stmicroelectronics/stm32f429-disco/flash.sh @@ -21,6 +21,6 @@ ${OUTPUT_DIR}/host/bin/openocd -f board/${BOARD_NAME}.cfg \ -c "flash info 0" \ -c "flash write_image erase ${OUTPUT_DIR}/images/stm32f429i-disco.bin 0x08000000" \ -c "flash write_image erase ${OUTPUT_DIR}/images/stm32f429-disco.dtb 0x08004000" \ - -c "flash write_image erase ${OUTPUT_DIR}/images/xipImage 0x08008000" \ + -c "flash write_image erase ${OUTPUT_DIR}/images/xipImage 0x0800C000" \ -c "reset run" \ -c "shutdown" diff --git a/board/stmicroelectronics/stm32f429-disco/linux.config b/board/stmicroelectronics/stm32f429-disco/linux.config new file mode 100644 index 0000000000..7b5c60f180 --- /dev/null +++ b/board/stmicroelectronics/stm32f429-disco/linux.config @@ -0,0 +1,120 @@ +# CONFIG_LOCALVERSION_AUTO is not set +CONFIG_KERNEL_XZ=y +CONFIG_NO_HZ_IDLE=y +CONFIG_HIGH_RES_TIMERS=y +CONFIG_PREEMPT=y +CONFIG_LOG_BUF_SHIFT=12 +CONFIG_PRINTK_SAFE_LOG_BUF_SHIFT=10 +CONFIG_BLK_DEV_INITRD=y +CONFIG_INITRAMFS_SOURCE="${BR_BINARIES_DIR}/rootfs.cpio" +# CONFIG_RD_GZIP is not set +# CONFIG_RD_BZIP2 is not set +# CONFIG_RD_LZMA is not set +# CONFIG_RD_XZ is not set +# CONFIG_RD_LZO is not set +# CONFIG_RD_LZ4 is not set +# CONFIG_RD_ZSTD is not set +CONFIG_CC_OPTIMIZE_FOR_SIZE=y +# CONFIG_MULTIUSER is not set +# CONFIG_SYSFS_SYSCALL is not set +# CONFIG_FHANDLE is not set +CONFIG_POSIX_TIMERS=y +CONFIG_BUG=y +# CONFIG_BASE_FULL is not set +# CONFIG_FUTEX is not set +# CONFIG_EPOLL is not set +# CONFIG_SIGNALFD is not set +# CONFIG_TIMERFD is not set +# CONFIG_EVENTFD is not set +# CONFIG_AIO is not set +# CONFIG_IO_URING is not set +# CONFIG_ADVISE_SYSCALLS is not set +# CONFIG_MEMBARRIER is not set +# CONFIG_KALLSYMS is not set +CONFIG_KCMP=y +# CONFIG_RSEQ is not set +CONFIG_EMBEDDED=y +# CONFIG_VM_EVENT_COUNTERS is not set +# CONFIG_COMPAT_BRK is not set +CONFIG_SLOB=y +# CONFIG_SLAB_MERGE_DEFAULT is not set +# CONFIG_MMU is not set +CONFIG_ARCH_STM32=y +# CONFIG_MACH_STM32F469 is not set +# CONFIG_MACH_STM32F746 is not set +# CONFIG_MACH_STM32F769 is not set +# CONFIG_MACH_STM32H743 is not set +CONFIG_CPU_V7M_NUM_IRQ=240 +# CONFIG_ARM_DMA_MEM_BUFFERABLE is not set +CONFIG_SET_MEM_PARAM=y +CONFIG_DRAM_BASE=0x90000000 +CONFIG_DRAM_SIZE=0x00800000 +CONFIG_HZ_1000=y +# CONFIG_ATAGS is not set +CONFIG_XIP_KERNEL=y +CONFIG_XIP_PHYS_ADDR=0x0800C000 +CONFIG_XIP_DEFLATED_DATA=y +# CONFIG_SUSPEND is not set +# CONFIG_STACKPROTECTOR is not set +# CONFIG_COMPAT_32BIT_TIME is not set +# CONFIG_GCC_PLUGINS is not set +# CONFIG_BLOCK is not set +CONFIG_BINFMT_FLAT=y +CONFIG_BINFMT_SHARED_FLAT=y +# CONFIG_COREDUMP is not set +CONFIG_DEVTMPFS=y +CONFIG_DEVTMPFS_MOUNT=y +# CONFIG_STANDALONE is not set +# CONFIG_PREVENT_FIRMWARE_BUILD is not set +# CONFIG_FW_LOADER is not set +# CONFIG_ALLOW_DEV_COREDUMP is not set +CONFIG_EEPROM_93CX6=y +# CONFIG_INPUT is not set +# CONFIG_VT is not set +# CONFIG_UNIX98_PTYS is not set +# CONFIG_LEGACY_PTYS is not set +# CONFIG_LDISC_AUTOLOAD is not set +CONFIG_SERIAL_STM32=y +CONFIG_SERIAL_STM32_CONSOLE=y +# CONFIG_DEVMEM is not set +# CONFIG_HWMON is not set +CONFIG_WATCHDOG=y +CONFIG_MFD_STM32_TIMERS=y +# CONFIG_USB_SUPPORT is not set +CONFIG_NEW_LEDS=y +CONFIG_LEDS_CLASS=y +CONFIG_LEDS_GPIO=y +CONFIG_LEDS_TRIGGERS=y +CONFIG_LEDS_TRIGGER_HEARTBEAT=y +CONFIG_RTC_CLASS=y +CONFIG_RTC_DRV_STM32=y +CONFIG_DMADEVICES=y +CONFIG_STM32_DMA=y +CONFIG_STM32_DMAMUX=y +CONFIG_STM32_MDMA=y +CONFIG_SYNC_FILE=y +# CONFIG_VIRTIO_MENU is not set +# CONFIG_VHOST_MENU is not set +CONFIG_IIO=y +CONFIG_IIO_BUFFER=y +CONFIG_IIO_TRIGGERED_BUFFER=y +CONFIG_IIO_STM32_TIMER_TRIGGER=y +# CONFIG_FILE_LOCKING is not set +# CONFIG_DNOTIFY is not set +# CONFIG_INOTIFY_USER is not set +# CONFIG_PROC_SYSCTL is not set +CONFIG_CONFIGFS_FS=y +# CONFIG_MISC_FILESYSTEMS is not set +CONFIG_NLS=y +CONFIG_PRINTK_TIME=y +CONFIG_CONSOLE_LOGLEVEL_DEFAULT=15 +CONFIG_CONSOLE_LOGLEVEL_QUIET=15 +CONFIG_MESSAGE_LOGLEVEL_DEFAULT=7 +# CONFIG_SYMBOLIC_ERRNAME is not set +CONFIG_DEBUG_INFO=y +# CONFIG_SECTION_MISMATCH_WARN_ONLY is not set +CONFIG_DEBUG_FS=y +# CONFIG_DEBUG_MISC is not set +# CONFIG_SCHED_DEBUG is not set +# CONFIG_RCU_TRACE is not set +# CONFIG_RUNTIME_TESTING_MENU is not set diff --git a/board/stmicroelectronics/stm32f429-disco/patches/linux/0001-ARM-stm32f249-disco-don-t-force-init-in-chosen-boota.patch b/board/stmicroelectronics/stm32f429-disco/patches/linux/0001-ARM-stm32f249-disco-don-t-force-init-in-chosen-boota.patch deleted file mode 100644 index d6d5c61aae..0000000000 --- a/board/stmicroelectronics/stm32f429-disco/patches/linux/0001-ARM-stm32f249-disco-don-t-force-init-in-chosen-boota.patch +++ /dev/null @@ -1,32 +0,0 @@ -From ded9afa688184b3240a92c2b8f114c545a09bc3f Mon Sep 17 00:00:00 2001 -From: Thomas Petazzoni -Date: Sat, 12 Mar 2016 23:14:41 +0100 -Subject: [PATCH] ARM: stm32f249-disco: don't force init= in /chosen/bootargs - -There is no reason to override the kernel's default init= value, as -this breaks userspace that assumes the kernel default of /init is -used. Since stm32 is often used with a minimal bootloader -(afboot-stm32) that doesn't provide any mechanism to override the DTB, -we need to adjust the kernel command line in the Device Tree source. - -Signed-off-by: Thomas Petazzoni ---- - arch/arm/boot/dts/stm32f429-disco.dts | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/arch/arm/boot/dts/stm32f429-disco.dts b/arch/arm/boot/dts/stm32f429-disco.dts -index f0b731d..2bae81c 100644 ---- a/arch/arm/boot/dts/stm32f429-disco.dts -+++ b/arch/arm/boot/dts/stm32f429-disco.dts -@@ -53,7 +53,7 @@ - compatible = "st,stm32f429i-disco", "st,stm32f429"; - - chosen { -- bootargs = "root=/dev/ram rdinit=/linuxrc"; -+ bootargs = "root=/dev/ram"; - stdout-path = "serial0:115200n8"; - }; - --- -2.6.4 - diff --git a/configs/stm32f429_disco_defconfig b/configs/stm32f429_disco_defconfig index 4007eb20a5..01b54c02cc 100644 --- a/configs/stm32f429_disco_defconfig +++ b/configs/stm32f429_disco_defconfig @@ -1,12 +1,14 @@ BR2_arm=y BR2_cortex_m4=y -BR2_GLOBAL_PATCH_DIR="board/stmicroelectronics/stm32f429-disco/patches" -BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_11=y +BR2_KERNEL_HEADERS_5_15=y +# BR2_UCLIBC_INSTALL_UTILS is not set +BR2_GCC_ENABLE_LTO=y BR2_ROOTFS_POST_BUILD_SCRIPT="board/stmicroelectronics/common/stm32f4xx/stm32-post-build.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y -BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.11" -BR2_LINUX_KERNEL_DEFCONFIG="stm32" +BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.15" +BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y +BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/stmicroelectronics/stm32f429-disco/linux.config" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="xipImage" BR2_LINUX_KERNEL_DTS_SUPPORT=y From patchwork Sun Nov 14 17:31:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 1554926 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=libero.it header.i=@libero.it header.a=rsa-sha256 header.s=s2021 header.b=H3k1iKn+; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.133; helo=smtp2.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4HsfXf2ZqKz9sWJ for ; Mon, 15 Nov 2021 04:32:33 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 5623840001; Sun, 14 Nov 2021 17:32:31 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id KAhB3uKnpCvO; Sun, 14 Nov 2021 17:32:30 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id 6EF2140156; Sun, 14 Nov 2021 17:32:29 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id ECE4E1BF2BA for ; Sun, 14 Nov 2021 17:31:53 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id DCC1D60667 for ; Sun, 14 Nov 2021 17:31:53 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp3.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=libero.it Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OuSXZ3opP7AG for ; Sun, 14 Nov 2021 17:31:53 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0 Received: from libero.it (smtp-16.italiaonline.it [213.209.10.16]) by smtp3.osuosl.org (Postfix) with ESMTPS id 03ADE605FD for ; Sun, 14 Nov 2021 17:31:52 +0000 (UTC) Received: from passgat-Modern-14-A10M.homenet.telecomitalia.it ([79.24.99.64]) by smtp-16.iol.local with ESMTPA id mJLpm8CKm7VizmJM8mVOqw; Sun, 14 Nov 2021 18:31:52 +0100 x-libjamoibt: 1601 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=libero.it; s=s2021; t=1636911112; bh=yUj3eBjzbRQULusoWNTVFJDOp4Dn3S4eXuQ3ptw+ODQ=; h=From; b=H3k1iKn+DOq/Am7MvB10j9dUpLgKi2KsZjJeZSv9/otbqHwy+Ppbchb1WreFMOIHW Zg/EZZgZqk8CNZn8iaydlM/NuODm/yc/RRq5pJGLAkEyQF7THFNQ/8EkJMfNHj/Xm7 uJmS4TTq2dyDVXWgYzpcKcZNfhafVvwwfDUSqbOsEAGn3MGcC0uWMCrbKVG/8G4hW4 jXbseLz27DhgbwV/B/gIJ0d8Tu7eyMBFZAjgsNR8/SZCO3bANFCQLmaG7M2JBtLmu1 DRuwRFmxmVCU11qOl1EMAG0xVkV1n3v51/HhN8gBhEk3AGpk/aayRp/uFU1FmgEf7T az6emCRUVVx7Q== X-CNFS-Analysis: v=2.4 cv=ftYZ2H0f c=1 sm=1 tr=0 ts=61914808 cx=a_exe a=8X6arsqDvdvtpvHbdcPR/Q==:117 a=8X6arsqDvdvtpvHbdcPR/Q==:17 a=pl1rPjcGXzItbPHqDv8A:9 To: buildroot@buildroot.org Date: Sun, 14 Nov 2021 18:31:22 +0100 Message-Id: <20211114173122.16612-5-dariobin@libero.it> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20211114173122.16612-1-dariobin@libero.it> References: <20211114173122.16612-1-dariobin@libero.it> X-CMAE-Envelope: MS4xfMU9XLH9CiGo38H8tOhmko/dkyIzaKGMTTdtGlslbKrGm6D4mll4y5Lv1p6y1Qki5ZKNjF6pyh381L5CdPrCZWMj67Q4Aqzy/3Q4QyzYylsVrr/qeGHP 6+o7xbuMSmgVMFFz6S0eP5vLifp3FaQZW1sJj5v9Pq/TvTZn6aMWqo11fdWHxgHS/wjRHT50OxDkcCeiFQTgI+0h1/XcMbEhy9/24Law2wXUd02s2dO0sK+U RKwyMe4quV55X4/x/opjtItgyBKiIA1ysx/HYWtn+1j/W0h66NNGzfIdsR0eamWQCt8vW2Aac60a8ctg5s0nPqc8w928RqHsYrXxP/YQho4wk4vdWMubqgiG To3KUP09 Subject: [Buildroot] [v2, 4/4] configs/stm32f4{2|6}9_*_defconfig: rename configurations X-BeenThere: buildroot@buildroot.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Dario Binacchi via buildroot From: Dario Binacchi Reply-To: Dario Binacchi Cc: Lee Jones , Christophe Priouzeau , Dario Binacchi MIME-Version: 1.0 Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" The name of the configurations are now more explicit. As a result, the readme files have also been changed. Signed-off-by: Dario Binacchi --- .../stm32f469-disco/{flash.sh => flash_sd.sh} | 0 .../stm32f469-disco/{linux.fragment => linux-sd.fragment} | 0 board/stmicroelectronics/stm32f469-disco/readme.txt | 4 ++-- board/stmicroelectronics/stm32f469-disco/readme_xip.txt | 2 +- ...tm32f429_disco_defconfig => stm32f429_disco_xip_defconfig} | 0 ...stm32f469_disco_defconfig => stm32f469_disco_sd_defconfig} | 2 +- 6 files changed, 4 insertions(+), 4 deletions(-) rename board/stmicroelectronics/stm32f469-disco/{flash.sh => flash_sd.sh} (100%) rename board/stmicroelectronics/stm32f469-disco/{linux.fragment => linux-sd.fragment} (100%) rename configs/{stm32f429_disco_defconfig => stm32f429_disco_xip_defconfig} (100%) rename configs/{stm32f469_disco_defconfig => stm32f469_disco_sd_defconfig} (97%) diff --git a/board/stmicroelectronics/stm32f469-disco/flash.sh b/board/stmicroelectronics/stm32f469-disco/flash_sd.sh similarity index 100% rename from board/stmicroelectronics/stm32f469-disco/flash.sh rename to board/stmicroelectronics/stm32f469-disco/flash_sd.sh diff --git a/board/stmicroelectronics/stm32f469-disco/linux.fragment b/board/stmicroelectronics/stm32f469-disco/linux-sd.fragment similarity index 100% rename from board/stmicroelectronics/stm32f469-disco/linux.fragment rename to board/stmicroelectronics/stm32f469-disco/linux-sd.fragment diff --git a/board/stmicroelectronics/stm32f469-disco/readme.txt b/board/stmicroelectronics/stm32f469-disco/readme.txt index 4d178b40d6..99d26ccb66 100644 --- a/board/stmicroelectronics/stm32f469-disco/readme.txt +++ b/board/stmicroelectronics/stm32f469-disco/readme.txt @@ -7,13 +7,13 @@ configuration for the STM32F469 Discovery evaluation platform. Building -------- - make stm32f469_disco_defconfig + make stm32f469_disco_sd_defconfig make Flashing -------- - ./board/stmicroelectronics/stm32f469-disco/flash.sh output/ + ./board/stmicroelectronics/stm32f469-disco/flash_sd.sh output/ It will flash the U-boot bootloader. diff --git a/board/stmicroelectronics/stm32f469-disco/readme_xip.txt b/board/stmicroelectronics/stm32f469-disco/readme_xip.txt index 632d221ba1..7c20c2d015 100644 --- a/board/stmicroelectronics/stm32f469-disco/readme_xip.txt +++ b/board/stmicroelectronics/stm32f469-disco/readme_xip.txt @@ -19,6 +19,6 @@ Building Flashing -------- - ./board/stmicroelectronics/stm32f469-disco/flash.sh output/ + ./board/stmicroelectronics/stm32f469-disco/flash_xip.sh output/ It will flash binary to internal flash memory. diff --git a/configs/stm32f429_disco_defconfig b/configs/stm32f429_disco_xip_defconfig similarity index 100% rename from configs/stm32f429_disco_defconfig rename to configs/stm32f429_disco_xip_defconfig diff --git a/configs/stm32f469_disco_defconfig b/configs/stm32f469_disco_sd_defconfig similarity index 97% rename from configs/stm32f469_disco_defconfig rename to configs/stm32f469_disco_sd_defconfig index 438d32150c..5ad4068e5e 100644 --- a/configs/stm32f469_disco_defconfig +++ b/configs/stm32f469_disco_sd_defconfig @@ -8,7 +8,7 @@ BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.14.12" BR2_LINUX_KERNEL_DEFCONFIG="stm32" -BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm/configs/dram_0x00000000.config board/stmicroelectronics/stm32f469-disco/linux.fragment" +BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm/configs/dram_0x00000000.config board/stmicroelectronics/stm32f469-disco/linux-sd.fragment" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="zImage" BR2_LINUX_KERNEL_DTS_SUPPORT=y