From patchwork Mon Oct 24 11:31:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 10194 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp641899wru; Mon, 24 Oct 2022 13:36:49 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6GV15Xf1dq3ykZx87ZCDsCLWSQtsW7puU/DhdlncWujDn5Lu7FJ80zyGQRXOvTG2gyCX6V X-Received: by 2002:a17:906:4fc3:b0:72e:eab4:d9d7 with SMTP id i3-20020a1709064fc300b0072eeab4d9d7mr29130085ejw.599.1666643809209; Mon, 24 Oct 2022 13:36:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666643809; cv=none; d=google.com; s=arc-20160816; b=y9+/28oIF2Yi9RMe2Khw2BDbT7ZMqMaU9lU/G7yDDyfUFNgA0NbFlehwxVe2CYTAiu y+O+sK+aGk9nS8CeO2LmtKmKx/12UYbLLN6/RscLqpfVNsAWreoKYJ565NMcRO31hETT +zms6e1ua3FiR9hVdrOGmn21kdEP9weXKdEcw2hLyWRCuPpalfFdZ2ZPdmJAUmBPtgg/ CuEL7kU1yWC3ZZOKjkjDK4Qt2R/2AMCalSLus3cHvumOQp8ikqXnOn6Y9MX9YADZOi82 wMXPt+bkUJ11mA4MGZY+AmasFcolPNIsuA8klhB6opDZMn6aBPywouaAqwRvIYsSq37N mUxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=uggJet0Komhaiy1sc5ND+HudRlIewWcl9B7Jcz0ntT4=; b=sW+ySNT6kzcEEVxmPHd4ojfimsmXpwdPgEE7M7VuXqmv28A1d0hPT5RVnMvjOE4Odp iCY+OHQ46fiQ1Rff7RJnIeOsE4jJG7ZHN9W1+npOV4fD+T17uVO89aCHSJ2i4qvzQXte axM8qDHhBCQFAGGTxiNCz5em0RGTtCIJfYWeY3eggVmAE935I+sNWesSg69TpuZvgZQM owlWok6mD1VCBYkM6FWO/oqDH/n4f61n+MQVO/x7TsQ0BfWDxYvZbiZLRG12dc/6Z9/s RYBtqri6T76Bt/DJ4+hgWNcJ/BzEtUXOqKOyJdbMUHHBYxyam8pFzIqguUtNPLATvuve jGng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=ntqyWUT6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ds1-20020a170907724100b00787abcb1ce0si663246ejc.679.2022.10.24.13.36.09; Mon, 24 Oct 2022 13:36:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=ntqyWUT6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231699AbiJXUXf (ORCPT + 99 others); Mon, 24 Oct 2022 16:23:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45600 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234129AbiJXUWy (ORCPT ); Mon, 24 Oct 2022 16:22:54 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C6CCFB2DA9; Mon, 24 Oct 2022 11:38:38 -0700 (PDT) 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 0572FB815E9; Mon, 24 Oct 2022 12:12:21 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 51EF5C433D6; Mon, 24 Oct 2022 12:12:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666613539; bh=BVsRkkI+Jwqv+WohuOIvxh7su6MF9Z/mPphzuwKvqyI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ntqyWUT6loksrc7pc2BJAt2TC6gEOyuNOsPdOn3jHgTICFK0vEEFx9YcPL3Hq2RXJ 7/wb7TWJGv1NoJf7EQyeOtwcSIKOWu+/4bQx4nmwSdJmZ9S91UUI66f0A8lz4j7ON0 edQHQB3rSbo78iWHaIvYTU82otFBePdNTIwDxHYM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Nicholas Piggin , Segher Boessenkool , Michael Ellerman , Sasha Levin Subject: [PATCH 5.4 175/255] powerpc/64s: Fix GENERIC_CPU build flags for PPC970 / G5 Date: Mon, 24 Oct 2022 13:31:25 +0200 Message-Id: <20221024113008.637861914@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221024113002.471093005@linuxfoundation.org> References: <20221024113002.471093005@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747602698569157415?= X-GMAIL-MSGID: =?utf-8?q?1747602698569157415?= From: Nicholas Piggin [ Upstream commit 58ec7f06b74e0d6e76c4110afce367c8b5f0837d ] Big-endian GENERIC_CPU supports 970, but builds with -mcpu=power5. POWER5 is ISA v2.02 whereas 970 is v2.01 plus Altivec. 2.02 added the popcntb instruction which a compiler might use. Use -mcpu=power4. Fixes: 471d7ff8b51b ("powerpc/64s: Remove POWER4 support") Signed-off-by: Nicholas Piggin Reviewed-by: Segher Boessenkool Signed-off-by: Michael Ellerman Link: https://lore.kernel.org/r/20220921014103.587954-1-npiggin@gmail.com Signed-off-by: Sasha Levin --- arch/powerpc/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile index eedd114a017c..95183a717eb6 100644 --- a/arch/powerpc/Makefile +++ b/arch/powerpc/Makefile @@ -155,7 +155,7 @@ CFLAGS-$(CONFIG_GENERIC_CPU) += -mcpu=power8 CFLAGS-$(CONFIG_GENERIC_CPU) += $(call cc-option,-mtune=power9,-mtune=power8) else CFLAGS-$(CONFIG_GENERIC_CPU) += $(call cc-option,-mtune=power7,$(call cc-option,-mtune=power5)) -CFLAGS-$(CONFIG_GENERIC_CPU) += $(call cc-option,-mcpu=power5,-mcpu=power4) +CFLAGS-$(CONFIG_GENERIC_CPU) += -mcpu=power4 endif else ifdef CONFIG_PPC_BOOK3E_64 CFLAGS-$(CONFIG_GENERIC_CPU) += -mcpu=powerpc64