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 A9955C4332F for ; Sun, 11 Dec 2022 14:15:31 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id C9B3F85369; Sun, 11 Dec 2022 15:15:29 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.b="Wt5Dmwvn"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id CD26685376; Sun, 11 Dec 2022 15:15:27 +0100 (CET) Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) (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 3C8B1852B0 for ; Sun, 11 Dec 2022 15:15:25 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=pali@kernel.org Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id CBF22B80A3A; Sun, 11 Dec 2022 14:15:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6784CC433EF; Sun, 11 Dec 2022 14:15:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1670768123; bh=40IhVtMs2fUuLrYD1fHiGBp00SONCCes9IcVVIngZYM=; h=From:To:Cc:Subject:Date:From; b=Wt5DmwvnXi3WoOxZz/1caehwhxuywimjpI5NxNcONNUQ5NEZ92p1qe1M6GvnxFpJh AQe0TNz2Z0Q+iIyyeE0y51jBqyHHhrdcBGaiHtTajlAeEBsVQytgTMt/+SkKbc28MT oHiK2QDv/J8C28+rpeGtKemAwUpu78m3rjQYH2oAA86VvSB48l9/735Q9eOv5GZTii MfkKJRPPCqrbhl0baStUsLXhvF4kIrNAGtgcsDKCM5FrOICbw7rZeJWc1AIiNoEEaN 88+XvbMhUVjZC4LbiLwsnxIYxxnGKoEi+O37JvJElM4P+9woQfhVKjpzO2o00uaZcO imvVL0q14iF0Q== Received: by pali.im (Postfix) id 8370D872; Sun, 11 Dec 2022 15:15:20 +0100 (CET) From: =?UTF-8?q?Pali=20Roh=C3=A1r?= To: Vagrant Cascadian Cc: u-boot@lists.denx.de Subject: [PATCH u-boot] powerpc/mpc85xx: Improve disabling of SPE instructions Date: Sun, 11 Dec 2022 15:14:59 +0100 Message-Id: <20221211141459.8344-1-pali@kernel.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Specifying -mspe=no also disables usage of SPE instructions. It is documented in "[PATCH,rs6000] make -mno-spe work as expected" email: http://gcc.gnu.org/ml/gcc-patches/2008-04/msg00311.html So replace -mspe=yes by -mspe=no, so make it clear that u-boot has to be compiled without SPE instructions. Linux kernel contains following Makefile code to achieve it: # No SPE instruction when building kernel # (We use all available options to help semi-broken compilers) KBUILD_CFLAGS += $(call cc-option,-mno-spe) KBUILD_CFLAGS += $(call cc-option,-mspe=no) Do same for U-Boot. Signed-off-by: Pali Rohár --- arch/powerpc/cpu/mpc85xx/config.mk | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/cpu/mpc85xx/config.mk b/arch/powerpc/cpu/mpc85xx/config.mk index b6b5d2053aea..482bb90cb120 100644 --- a/arch/powerpc/cpu/mpc85xx/config.mk +++ b/arch/powerpc/cpu/mpc85xx/config.mk @@ -6,11 +6,12 @@ PLATFORM_CPPFLAGS += -msoft-float -mno-string PLATFORM_RELFLAGS += -msingle-pic-base -fno-jump-tables -# -mspe=yes is needed to have -mno-spe accepted by a buggy GCC; +# No SPE instruction when building u-boot +# (We use all available options to help semi-broken compilers) # see "[PATCH,rs6000] make -mno-spe work as expected" on # http://gcc.gnu.org/ml/gcc-patches/2008-04/msg00311.html -PLATFORM_CPPFLAGS += $(call cc-option,-mspe=yes) \ - $(call cc-option,-mno-spe) +PLATFORM_CPPFLAGS += $(call cc-option,-mno-spe) \ + $(call cc-option,-mspe=no) ifdef CONFIG_E6500 PLATFORM_CPPFLAGS += -mcpu=e6500 -- 2.20.1