Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp5992089ybc; Wed, 27 Nov 2019 13:03:09 -0800 (PST) X-Google-Smtp-Source: APXvYqxb43pqkNfAOH6MeGWt1wyClYvCcvXGmuQEclI3OpMfDfq/3pJ+9AXmnUsCUAIfnBEKqiwz X-Received: by 2002:aa7:d9cf:: with SMTP id v15mr8359270eds.182.1574888589817; Wed, 27 Nov 2019 13:03:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574888589; cv=none; d=google.com; s=arc-20160816; b=QI/6qCkpwkDv526OU7BFXbSS3mou2IvSyjyTCq0rgJlB1kCLzOuAe4UDYWHwiLQLtF 08MYMnFVBHHA8vk2LiTOk1i4OWdq7DBgSXjOIuTUx38zoeHyNVy53ucQYjhlOhmRVitn /kPQ2pz07/RmG9uxTmmaO0ox7HF+8wQP8H/w8igDG93jJTnC1nAXcCaSyglCW0WK+oSl B1pRm8ZI3W7hxo5fZCIBwx7hZTXTISCRIThDKS5dOlOxpfsHxqtspxn2MBWKgl6djrqA QhUXQuETD1u6dJ9qaTKK2uYw0HOLekKnbraWcMhwPwBT6D9T2h+jXa22iO3Lt5dAZxuA /rOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Gb7coRBSB/H0dD3lzrlODgehlowbwQauj3Jkst49lvM=; b=wOVLwnCTyDOz00/iKuu6+g1E26I5lDxlyRtS4k5qA5HiBLM1Hfz2vitg6qQKSUNG75 cILYLJIIwc0eE65TIV1w2dVONniH701oqFVpXZcrMK145uHvn6BEbo2uKk6Hqa7KVAgy w3z7U+/POehNSVepua9m+RuUTUOMpi1vOG9DhTVCb9OGr05pr9UuVhJA0GA7nDu/pVNu mSHepTafvX9IoyAwkX8n8ej8qh6SL8fEPVRldMfJmi9qtn3HDlsbYKTo8IARzCL65GMn Pt+qd1/T0MyFBcSKD7FGR5RJX0Ml/W/0XszMQGyhksmchywW3k2SLIWFCZSIjEPi4Ozq 45+g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=xZz7WJVX; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q23si10592867ejn.236.2019.11.27.13.02.40; Wed, 27 Nov 2019 13:03:09 -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; dkim=pass header.i=@kernel.org header.s=default header.b=xZz7WJVX; 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 S1731779AbfK0VBq (ORCPT + 99 others); Wed, 27 Nov 2019 16:01:46 -0500 Received: from mail.kernel.org ([198.145.29.99]:54092 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731741AbfK0VBm (ORCPT ); Wed, 27 Nov 2019 16:01:42 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DA08A2158C; Wed, 27 Nov 2019 21:01:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574888502; bh=mjEAf4IZiaoy69szyp+z+zduvvrVkJ634Pi2kNlx0nY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=xZz7WJVXDS2bU0v7Sv8a0XSH7ngT2HGYxaZtko+VPeoQfbPoZKRwj3p+3gAbd5B9g q1WxZXKpXfjgUGCjkjj7ltjZHiWEa90PM6Mm/0wzAVFpo7o5YsZj47m72RXEnA3fV5 EmfkMtl6tNIsF8pgtW5hBS3hgDrWllD9q4l+e6HI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Joel Stanley , Michael Ellerman , Sasha Levin Subject: [PATCH 4.19 160/306] powerpc/xmon: Relax frame size for clang Date: Wed, 27 Nov 2019 21:30:10 +0100 Message-Id: <20191127203127.204172470@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191127203114.766709977@linuxfoundation.org> References: <20191127203114.766709977@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Joel Stanley [ Upstream commit 9c87156cce5a63735d1218f0096a65c50a7a32aa ] When building with clang (8 trunk, 7.0 release) the frame size limit is hit: arch/powerpc/xmon/xmon.c:452:12: warning: stack frame size of 2576 bytes in function 'xmon_core' [-Wframe-larger-than=] Some investigation by Naveen indicates this is due to clang saving the addresses to printf format strings on the stack. While this issue is investigated, bump up the frame size limit for xmon when building with clang. Link: https://github.com/ClangBuiltLinux/linux/issues/252 Signed-off-by: Joel Stanley Signed-off-by: Michael Ellerman Signed-off-by: Sasha Levin --- arch/powerpc/xmon/Makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/powerpc/xmon/Makefile b/arch/powerpc/xmon/Makefile index 9d7d8e6d705c4..9ba44e190e5e4 100644 --- a/arch/powerpc/xmon/Makefile +++ b/arch/powerpc/xmon/Makefile @@ -13,6 +13,12 @@ UBSAN_SANITIZE := n ORIG_CFLAGS := $(KBUILD_CFLAGS) KBUILD_CFLAGS = $(subst $(CC_FLAGS_FTRACE),,$(ORIG_CFLAGS)) +ifdef CONFIG_CC_IS_CLANG +# clang stores addresses on the stack causing the frame size to blow +# out. See https://github.com/ClangBuiltLinux/linux/issues/252 +KBUILD_CFLAGS += -Wframe-larger-than=4096 +endif + ccflags-$(CONFIG_PPC64) := $(NO_MINIMAL_TOC) obj-y += xmon.o nonstdio.o spr_access.o -- 2.20.1