From patchwork Mon Nov 12 02:35:19 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 996246 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42tZrZ10Lfz9s0t for ; Mon, 12 Nov 2018 13:46:06 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="FA91h4yJ"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 42tZrY60SjzF3Qt for ; Mon, 12 Nov 2018 13:46:05 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="FA91h4yJ"; dkim-atps=neutral X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=softfail (mailfrom) smtp.mailfrom=socionext.com (client-ip=210.131.2.75; helo=conuserg-08.nifty.com; envelope-from=yamada.masahiro@socionext.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="FA91h4yJ"; dkim-atps=neutral Received: from conuserg-08.nifty.com (conuserg-08.nifty.com [210.131.2.75]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 42tZgL32GbzDrcN for ; Mon, 12 Nov 2018 13:38:06 +1100 (AEDT) Received: from pug.e01.socionext.com (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-08.nifty.com with ESMTP id wAC2ZqVT015801; Mon, 12 Nov 2018 11:35:53 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-08.nifty.com wAC2ZqVT015801 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1541990154; bh=QWXSE7/OQHBlT44+TGlqxkRhZ97JeJizcyopsk4jHsY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FA91h4yJOyJENTGNyr75p88tfVsNiDXhOMInZzw3/rfJHw3x2OV/RH4xPefEqEaYm MMbVZ+9LlRjnCfqRP6SZkAN3jWbpeIXY6mVbMysyQb3V2luFgTIZ9a6ZyOohJ7S5gb qacupi+SvN7TZKLquE9qfBWONdhDg17n4E29ZLrf/D7cJpcXkmR1eGBVhM1hyDt2o+ AjH8sy8Ce37kZUPq3C5aveDOJEd97a9B7WcuQ6e51EK3Y5PTKwKDoWRuyPYQYqv0f3 7v76VVz5fBrTNXvRcFY2nZjdizkP7wsi05HlCt2KDNMb4o2YrD7ksjhX6SlUH5fBiF fBwr7zq78p25A== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: Ingo Molnar , Thomas Gleixner , x86@kernel.org Subject: [PATCH 1/2] um: remove -fno-unit-at-a-time workaround for pre-4.0 GCC Date: Mon, 12 Nov 2018 11:35:19 +0900 Message-Id: <1541990120-9643-2-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1541990120-9643-1-git-send-email-yamada.masahiro@socionext.com> References: <1541990120-9643-1-git-send-email-yamada.masahiro@socionext.com> X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-kernel@vger.kernel.org, Masahiro Yamada , Borislav Petkov , "H. Peter Anvin" , Richard Weinberger , linuxppc-dev@lists.ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Commit cafa0010cd51 ("Raise the minimum required gcc version to 4.6") bumped the minimum GCC version to 4.6 for all architectures. '$(call cc-option,-fno-unit-at-a-time)' is now dead code since '$(cc-version) -lt 0400' is always false. Signed-off-by: Masahiro Yamada Acked-by: Richard Weinberger --- arch/x86/Makefile.um | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/arch/x86/Makefile.um b/arch/x86/Makefile.um index 91085a0..577976b 100644 --- a/arch/x86/Makefile.um +++ b/arch/x86/Makefile.um @@ -26,12 +26,8 @@ cflags-y += $(call cc-option,-mpreferred-stack-boundary=2) # an unresolved reference. cflags-y += -ffreestanding -# Disable unit-at-a-time mode on pre-gcc-4.0 compilers, it makes gcc use -# a lot more stack due to the lack of sharing of stacklots. Also, gcc -# 4.3.0 needs -funit-at-a-time for extern inline functions. -KBUILD_CFLAGS += $(shell if [ $(cc-version) -lt 0400 ] ; then \ - echo $(call cc-option,-fno-unit-at-a-time); \ - else echo $(call cc-option,-funit-at-a-time); fi ;) +# gcc 4.3.0 needs -funit-at-a-time for extern inline functions. +KBUILD_CFLAGS += $(call cc-option,-funit-at-a-time) KBUILD_CFLAGS += $(cflags-y) From patchwork Mon Nov 12 02:35:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 996245 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42tZny6LbMz9s7h for ; Mon, 12 Nov 2018 13:43:50 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="fzvuX3Br"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 42tZny4stRzDrWQ for ; Mon, 12 Nov 2018 13:43:50 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="fzvuX3Br"; dkim-atps=neutral X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=softfail (mailfrom) smtp.mailfrom=socionext.com (client-ip=210.131.2.75; helo=conuserg-08.nifty.com; envelope-from=yamada.masahiro@socionext.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="fzvuX3Br"; dkim-atps=neutral Received: from conuserg-08.nifty.com (conuserg-08.nifty.com [210.131.2.75]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 42tZg36XpXzF3Mm for ; Mon, 12 Nov 2018 13:37:51 +1100 (AEDT) Received: from pug.e01.socionext.com (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-08.nifty.com with ESMTP id wAC2ZqVU015801; Mon, 12 Nov 2018 11:35:54 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-08.nifty.com wAC2ZqVU015801 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1541990155; bh=D/YvA7fG3eU8iQ4XCYgoVJjQnd4bdw8V+EnSjh78kh0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=fzvuX3Bra8KLE9Rh3REv55KBUmUCE7oTRkQlfJ2ZyFZNyr7uLINHuLHxFSk6lrTLi kNcg3yxZAGvaNt0UVlG3Uh3HecmArW8QmgBJQ7/ejCUUxxKYkSuKrZaf2x81bFmg6S zv5ZN0s2WmCLfl35TvG2Hm306NwOHWGmgQf8yVI322xsSpwFnND2PCH4zaRiySqtNg pQpYzKR+8/H96J13EPQpu64My7ZB7DU6tyHT69MFLHIUyqAaK5NGt4F+eimsAjlTdd ArY3H7djdnoflh2KtFzqQ5ApxLN0HslLF5dVNNS3u+LRZ/HUDQXjGpieEYxt0cE3oo BP0FjJUpn4nCA== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: Ingo Molnar , Thomas Gleixner , x86@kernel.org Subject: [PATCH 2/2] x86, powerpc: remove -funit-at-a-time compiler option entirely Date: Mon, 12 Nov 2018 11:35:20 +0900 Message-Id: <1541990120-9643-3-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1541990120-9643-1-git-send-email-yamada.masahiro@socionext.com> References: <1541990120-9643-1-git-send-email-yamada.masahiro@socionext.com> X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-kernel@vger.kernel.org, Masahiro Yamada , Borislav Petkov , "H. Peter Anvin" , Paul Mackerras , Richard Weinberger , linuxppc-dev@lists.ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" GCC 4.6 manual says: -funit-at-a-time This option is left for compatibility reasons. -funit-at-a-time has no effect, while -fno-unit-at-a-time implies -fno-toplevel-reorder and -fno-section-anchors. Enabled by default. Signed-off-by: Masahiro Yamada Acked-by: Ingo Molnar Acked-by: Michael Ellerman --- arch/powerpc/Makefile | 4 ---- arch/x86/Makefile | 4 ---- arch/x86/Makefile.um | 5 ----- 3 files changed, 13 deletions(-) diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile index 8a2ce14..854199c 100644 --- a/arch/powerpc/Makefile +++ b/arch/powerpc/Makefile @@ -228,10 +228,6 @@ KBUILD_CFLAGS += $(call cc-option,-mno-vsx) KBUILD_CFLAGS += $(call cc-option,-mno-spe) KBUILD_CFLAGS += $(call cc-option,-mspe=no) -# Enable unit-at-a-time mode when possible. It shrinks the -# kernel considerably. -KBUILD_CFLAGS += $(call cc-option,-funit-at-a-time) - # FIXME: the module load should be taught about the additional relocs # generated by this. # revert to pre-gcc-4.4 behaviour of .eh_frame diff --git a/arch/x86/Makefile b/arch/x86/Makefile index 88398fd..3508049 100644 --- a/arch/x86/Makefile +++ b/arch/x86/Makefile @@ -130,10 +130,6 @@ else KBUILD_CFLAGS += -mno-red-zone KBUILD_CFLAGS += -mcmodel=kernel - - # -funit-at-a-time shrinks the kernel .text considerably - # unfortunately it makes reading oopses harder. - KBUILD_CFLAGS += $(call cc-option,-funit-at-a-time) endif ifdef CONFIG_X86_X32 diff --git a/arch/x86/Makefile.um b/arch/x86/Makefile.um index 577976b..1db7913 100644 --- a/arch/x86/Makefile.um +++ b/arch/x86/Makefile.um @@ -26,9 +26,6 @@ cflags-y += $(call cc-option,-mpreferred-stack-boundary=2) # an unresolved reference. cflags-y += -ffreestanding -# gcc 4.3.0 needs -funit-at-a-time for extern inline functions. -KBUILD_CFLAGS += $(call cc-option,-funit-at-a-time) - KBUILD_CFLAGS += $(cflags-y) else @@ -50,6 +47,4 @@ ELF_FORMAT := elf64-x86-64 LINK-$(CONFIG_LD_SCRIPT_DYN) += -Wl,-rpath,/lib64 LINK-y += -m64 -# Do unit-at-a-time unconditionally on x86_64, following the host -KBUILD_CFLAGS += $(call cc-option,-funit-at-a-time) endif