From patchwork Thu Feb 18 16:26:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 102740 Delivered-To: patch@linaro.org Received: by 10.112.43.199 with SMTP id y7csp682350lbl; Thu, 18 Feb 2016 08:27:48 -0800 (PST) X-Received: by 10.98.73.205 with SMTP id r74mr11496545pfi.118.1455812868514; Thu, 18 Feb 2016 08:27:48 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c10si10181627pat.170.2016.02.18.08.27.48; Thu, 18 Feb 2016 08:27:48 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1946900AbcBRQ1q (ORCPT + 30 others); Thu, 18 Feb 2016 11:27:46 -0500 Received: from mout.kundenserver.de ([212.227.126.133]:52903 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1946877AbcBRQ12 (ORCPT ); Thu, 18 Feb 2016 11:27:28 -0500 Received: from wuerfel.localnet ([78.42.132.4]) by mrelayeu.kundenserver.de (mreue003) with ESMTPSA (Nemesis) id 0LpzzH-1a0fdG2qO7-00ffJs; Thu, 18 Feb 2016 17:26:57 +0100 From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: Nicolas Pitre , Jon Medhurst , Russell King , Ard Biesheuvel , Marc Zyngier , linux-kernel@vger.kernel.org Subject: [PATCH v2] ARM: atags_to_fdt: don't warn about stack size Date: Thu, 18 Feb 2016 17:26:56 +0100 Message-ID: <7301172.5fH67MHlU9@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) In-Reply-To: References: <1455804123-2526139-1-git-send-email-arnd@arndb.de> <1455804123-2526139-6-git-send-email-arnd@arndb.de> MIME-Version: 1.0 X-Provags-ID: V03:K0:mbDACV3FzaOdWPOSj82q5SJSx/QuHscl0L1tIJrqMlnejb5qwvT Wm9zW+FwDh4gycpBkxGn32kzgb3Cdj0hfQ1E37J392B0oOzg6ml/0Tu6WHmRB5hEGtmO4vE yHj5pI2DuS6UzH7ztBKkJVQU3j2RCXPPjRYdI1F3g96vrYvoEv3UmZYL8nlP3tYG1nvP0BM YXi1rZCng7O11ytX264lw== X-UI-Out-Filterresults: notjunk:1; V01:K0:pxLAydFLWos=:nfA78WpCXjqwgk6JNLr726 WX69l978fB1xjTVaMkMbVhFFFV/wQTYEWjGcy082i51ZJ3L294u4sILDRoCoCmooWr/uTCfrT fc0mNE0gQTjeSwU+XqMLy96AZuTUW5s2CYGfaDH6/g3U1XeEvas0B+Grhp3tFPJx4HrQ1n62v 2hZ5JcMwYsQZBou3ASw/v0Cwau6heyZ8u4G+hV6JZEXxFDtqOGlVmgKX45Rd9jYZdMErk5msy IxVgaIbDXyEqo9DSQZyfkrlHWCfmmufuB0VM69eCBKkhs7Jn8pq4/ZlrVatdFr0JQEN1mwOQo 1pFeFZ4PxXOvM2pncxG8ULGsu1aSSUAY8y2vYEKtDHKvv85FEtyHClE/kVvwWIjQ3anSpFS/Z EjVix346NHGSZCiuLH7BxjIdkN7X46nJK7qwZd5LV/KZHA7fJ3mK+O/5MUNuxUFUUBaHgdeyw vKQ8ecXMCU0c/Gdgg5Q5ZcUFbt0aVn0SojJ2KaNv0JUJZk1Wxnyk15h2Haa1c/4ntDcWBR+eA PzzfZZrzJAjlBtguLopyHg555IiBtGzHIXnEJypekzAVKdlkxdcGZg6cLMkadPmy/buiaYqRU uaUwQKshJYjRoDfd1uvTCXumyutTx8RI6h1ZOOD8uwK7Q5Y+eFabZZ3qxTPFncvKxzhQ26DdV RG/Oy/AZeGxk7+QxqkS/McR30XDFq2AxCrsutH1nMtN79hlc0i3UWxQXdB9/CWv6nIxtbi8xV Rrxj0bdhvNJmKzuv Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The merge_fdt_bootargs() function by definition consumes more than 1024 bytes of stack because it has a 1024 byte command line on the stack, meaning that we always get a warning when building this file: arch/arm/boot/compressed/atags_to_fdt.c: In function 'merge_fdt_bootargs': arch/arm/boot/compressed/atags_to_fdt.c:98:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=] However, as this is the decompressor and we know that it has a very shallow call chain, and we do not actually risk overflowing the kernel stack at runtime here. This just shuts up the warning by slightly increasing the limit for this file. Signed-off-by: Arnd Bergmann --- On Thursday 18 February 2016 11:13:52 Nicolas Pitre wrote: > What about setting the warning to 2048 instead? Sure, actually 1280 is more than enough I think. diff --git a/arch/arm/boot/compressed/Makefile b/arch/arm/boot/compressed/Makefile index 7a6a58ef8aaf..2cc63038d6c8 100644 --- a/arch/arm/boot/compressed/Makefile +++ b/arch/arm/boot/compressed/Makefile @@ -85,6 +85,8 @@ $(addprefix $(obj)/,$(libfdt) $(libfdt_hdrs)): $(obj)/%: $(srctree)/scripts/dtc/ $(addprefix $(obj)/,$(libfdt_objs) atags_to_fdt.o): \ $(addprefix $(obj)/,$(libfdt_hdrs)) +CFLAGS_atags_to_fdt.o += -Wframe-larger-than=1280 + ifeq ($(CONFIG_ARM_ATAG_DTB_COMPAT),y) OBJS += $(libfdt_objs) atags_to_fdt.o endif