From patchwork Mon Aug 9 15:10:21 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Heidelberg X-Patchwork-Id: 12426779 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D8E33C4338F for ; Mon, 9 Aug 2021 15:13:36 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4AA6260EBB for ; Mon, 9 Aug 2021 15:13:36 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 4AA6260EBB Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=ixit.cz Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=hFfaTPMobdyRyvsod0aB7DTXpsDFZLsjdFvr/FCsfzs=; b=yfKzqM77JXaNh4 LOl7Br68GHCiwBhVc7OYbkUC2hPf9kaNkX1Vbdu5jwjxALJTeN+kCVjn4BXfLUt1hr6P0iCCLPvPj fnzBiJgcQUiFizQoncNyoGar2M0lz52hnq+FBJh2CUjqYAziX4Wlt9Z055ijD4fTigkch88PzR7Jc 5MXx6okOUlN63oivlM6wPkgtLKneO3rbnhdZKeUx3WBtDNvBQIh2CyHJ1MJaz98EHmovp6fL9u3go CSlLuQE79ir5A4Rg+gDOoB6yemsNg7Ns0tg7fZDCkzCUuoEzGCf0ScEVkGo6RBkVkrCToe7TjtpFp xxjZz5YBqID7QRuXo3qA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mD6wM-0015IH-Pb; Mon, 09 Aug 2021 15:11:46 +0000 Received: from ixit.cz ([94.230.151.217]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mD6wI-0015G8-Ks for linux-arm-kernel@lists.infradead.org; Mon, 09 Aug 2021 15:11:44 +0000 Received: from newone.lan (ixit.cz [94.230.151.217]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ixit.cz (Postfix) with ESMTPSA id 6D7E42029F; Mon, 9 Aug 2021 17:11:33 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ixit.cz; s=dkim; t=1628521893; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=CE/q2k0CXcFqki/0w/v8nTUHmyve9NcEEIsPdG27/08=; b=Dv28xUMtH040WCqUk51/cLGYzuBhwxh6JmipTtrrh22I/rJLJDvqu5ckX6Rhu2ecjyoQpL AqvfD94oirI0pliblFdjLyNwooMZPasaR9F1D1mIIXOTcNlxHMq++DUKY9kgA2VRujp3Yw qr8RoUFoyeAEJMjIliWPUA49lObeTfk= From: David Heidelberg To: Arnd Bergmann , Jon Medhurst , Russell King , Ard Biesheuvel , Marc Zyngier , Nicolas Pitre Cc: David Heidelberg , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH] ARM: atags_to_fdt: don't warn about stack size Date: Mon, 9 Aug 2021 17:10:21 +0200 Message-Id: <20210809151021.5137-1-david@ixit.cz> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-Spam: Yes X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210809_081142_891306_F47D1156 X-CRM114-Status: GOOD ( 13.66 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.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 disabling the warning flag for this file. Tested on Nexus 7 2012 builds. Original Author: Arnd Bergmann Reference: https://lore.kernel.org/lkml/8232115.18ykgQ6J5T@wuerfel/ Cc: Arnd Bergmann Cc: Nicolas Pitre Cc: Russell King Cc: Ard Biesheuvel Cc: Marc Zyngier Cc: linux-kernel@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: David Heidelberg Acked-by: Nicolas Pitre Acked-by: Arnd Bergmann Acked-by: Arnd Bergmann --- arch/arm/boot/compressed/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/boot/compressed/Makefile b/arch/arm/boot/compressed/Makefile index 9d91ae1091b0..91265e7ff672 100644 --- a/arch/arm/boot/compressed/Makefile +++ b/arch/arm/boot/compressed/Makefile @@ -85,6 +85,8 @@ compress-$(CONFIG_KERNEL_LZ4) = lz4 libfdt_objs := fdt_rw.o fdt_ro.o fdt_wip.o fdt.o ifeq ($(CONFIG_ARM_ATAG_DTB_COMPAT),y) +CFLAGS_REMOVE_atags_to_fdt.o += -Wframe-larger-than=${CONFIG_FRAME_WARN} +CFLAGS_atags_to_fdt.o += -Wframe-larger-than=1280 OBJS += $(libfdt_objs) atags_to_fdt.o endif ifeq ($(CONFIG_USE_OF),y)