From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 78CA1C4332F for ; Sat, 24 Dec 2022 01:15:46 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 7E61C854BD; Sat, 24 Dec 2022 02:15:44 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=ti.com header.i=@ti.com header.b="U9IpeWS1"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id C4C5C854C3; Sat, 24 Dec 2022 02:15:43 +0100 (CET) Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 0912B851DF for ; Sat, 24 Dec 2022 02:15:40 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=bb@ti.com Received: from lelv0265.itg.ti.com ([10.180.67.224]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id 2BO1FdwA074418; Fri, 23 Dec 2022 19:15:39 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1671844539; bh=3GuVLltnaDg/w3xmyIWGCxS5+fAkPE9yzuarR9hjT5o=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=U9IpeWS1/XHSih9Kn6Q0DuDIxViadoF8S+EIZ6/YT5/bf/KRpDU0VK+YbSJoLhug7 H33TxwS+rihIVaiZCAElfMikms2LtXvCxgyY8ZMZbk2VWaYhWhA45+HWnGwxVikPI4 686tfX9y2vQt0VFy9cb15c8VuLvfFTIeoX+wTatA= Received: from DLEE115.ent.ti.com (dlee115.ent.ti.com [157.170.170.26]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 2BO1FcLR000480 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 23 Dec 2022 19:15:39 -0600 Received: from DLEE103.ent.ti.com (157.170.170.33) by DLEE115.ent.ti.com (157.170.170.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16; Fri, 23 Dec 2022 19:15:38 -0600 Received: from fllv0039.itg.ti.com (10.64.41.19) by DLEE103.ent.ti.com (157.170.170.33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16 via Frontend Transport; Fri, 23 Dec 2022 19:15:38 -0600 Received: from localhost (ileaxei01-snat.itg.ti.com [10.180.69.5]) by fllv0039.itg.ti.com (8.15.2/8.15.2) with ESMTP id 2BO1Fcls088871; Fri, 23 Dec 2022 19:15:38 -0600 From: Bryan Brattlof To: Tom Rini , Vignesh Raghavendra , Andrew Davis , Judith Mendez , Kamlesh Gurudasani CC: UBoot Mailing List , Bryan Brattlof Subject: [PATCH 1/5] configs: restrict am62ax wakup SPL size Date: Fri, 23 Dec 2022 19:15:21 -0600 Message-ID: <20221224011525.4696-2-bb@ti.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20221224011525.4696-1-bb@ti.com> References: <20221224011525.4696-1-bb@ti.com> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1605; i=bb@ti.com; h=from:subject; bh=n7ohZHPYUsE/Ix7np5p9fHKcyaim3Ro7vTxcicB1JHY=; b=owNCWmg5MUFZJlNZnKflQwAAZf////Zfpv1uvPbjC5u/eHW/uXr27/2H32q/T7/P0/Z623+wARtq oYoAGgBoaPUDQAZDTTI0A0A9QAAHpA0GIaaA0yAAGmnpNAPUNDR6jQNP1J7VENBo0eiaADRoyAND1A 0GJk0YmgGgBoNAyGhoMCZPUHqNGhhGhoBtQ2poyNNGjQgHpqBo00GjI0YQ0DJppiZGQBpkBoBgmRky NAMJkwgGQDJkYRoNADRkaAAA1JW49wcgAMxBCh4tUI4Rg2U6Lzs1YoZYioprFnZ+ejAeqNzvih0hik 3SmPzyGUtXVJE3TiKERYy6l04WejNWx7bBa4vZP84rZoumHLtkTHg3WWwg4FwpDJnAtdjSTwS8JJwk 4vUX7GmQkSx8WhGez+s7M9TqlZyjwTy7TpagomOSp6xJNiDkhM3Jy9P7vawXLRraGNJGkhbrQAzCHT FQvuS/PUWx+/JHuD427h4WYiYcLBR98h3ge/S4fHSo5G5RHZTENZoclBSnGfRkvB/rhi2k4Iyc5ITn GtpkUzzKAwXIBdatE4MJ/4qRIgyNb6798OA+jsZsonHwvwXWiXBdqAPukZL9pqXHWQ+ArTnRhxtgMG otpYe6utA4v/Bth3VmdKWi/vSn+Au4MdK47htNEBuaowmLR6cWxCH5M/Az40Va/4u5IpwoSE5T8qGA X-Developer-Key: i=bb@ti.com; a=openpgp; fpr=D3D177E40A38DF4D1853FEEF41B90D5D71D56CE0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean In its current form, the am62a's wakeup SPL is fairly small, however this will not remain as more boot modes are eventually added. To protect us from overflowing our ~256k of HSM SRAM, add limits and check during the wakeup SPL build. Signed-off-by: Bryan Brattlof --- configs/am62ax_evm_r5_defconfig | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/configs/am62ax_evm_r5_defconfig b/configs/am62ax_evm_r5_defconfig index 59d5f4f80eb8d..bfffb8eef77d8 100644 --- a/configs/am62ax_evm_r5_defconfig +++ b/configs/am62ax_evm_r5_defconfig @@ -13,7 +13,9 @@ CONFIG_SPL_TEXT_BASE=0x43c00000 CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_STACK_R_ADDR=0x82000000 -CONFIG_SPL_SIZE_LIMIT=0x40000 +CONFIG_SPL_SYS_MALLOC_F_LEN=0x7145 +CONFIG_SPL_SIZE_LIMIT=0x3A7F0 +CONFIG_SPL_SIZE_LIMIT_PROVIDE_STACK=0x3500 CONFIG_SPL_FS_FAT=y CONFIG_SPL_LIBDISK_SUPPORT=y CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y @@ -22,11 +24,14 @@ CONFIG_SPL_LOAD_FIT=y CONFIG_SPL_LOAD_FIT_ADDRESS=0x80080000 CONFIG_SPL_FIT_IMAGE_POST_PROCESS=y # CONFIG_DISPLAY_CPUINFO is not set -CONFIG_SPL_MAX_SIZE=0x58000 +CONFIG_SPL_SIZE_LIMIT_SUBTRACT_GD=y +CONFIG_SPL_SIZE_LIMIT_SUBTRACT_MALLOC=y +CONFIG_SPL_MAX_SIZE=0x3B000 CONFIG_SPL_PAD_TO=0x0 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y -CONFIG_SPL_BSS_START_ADDR=0x43c37800 -CONFIG_SPL_BSS_MAX_SIZE=0x5000 +CONFIG_SPL_BSS_START_ADDR=0x43c3b000 +CONFIG_SPL_BSS_MAX_SIZE=0x3000 +CONFIG_SPL_SYS_REPORT_STACK_F_USAGE=y CONFIG_SPL_SYS_MALLOC_SIMPLE=y CONFIG_SPL_STACK_R=y CONFIG_SPL_SEPARATE_BSS=y -- 2.39.0