From nobody Wed Dec 17 00:17:01 2025 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 85018C4167B for ; Fri, 8 Dec 2023 05:55:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1573212AbjLHFzT (ORCPT ); Fri, 8 Dec 2023 00:55:19 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44364 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1573208AbjLHFzF (ORCPT ); Fri, 8 Dec 2023 00:55:05 -0500 Received: from mail-pf1-x42a.google.com (mail-pf1-x42a.google.com [IPv6:2607:f8b0:4864:20::42a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 908E9172D for ; Thu, 7 Dec 2023 21:55:09 -0800 (PST) Received: by mail-pf1-x42a.google.com with SMTP id d2e1a72fcca58-6ce831cbba6so1082184b3a.2 for ; Thu, 07 Dec 2023 21:55:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; t=1702014909; x=1702619709; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=oJ/tAo5hDwQPfRruz9afcRfXvkx00dxKddYKFVNcdvc=; b=eSoaiv3RAbbY2NaBNjD878XjrSAtvRe+3gHiselTxD5LVxCdzAFJf3dY3hr/jLeYk7 PekZeG3b5R+Lmmx9dNz9Wq/CHdjgfDr7R1sQ0s8pz8crm88wE8ASkmflaBxGJfDCU6dJ A0hVT1oPsgguypJ9Id+kQMcPMgmWiwzWKPByYuv14A7eZ4lmnjVsKX+VJ5CXCIh4+2pl EsC8EsynuDG0k8s6zxAhLj6Eogtxp62jGP6/561coWy1rkOTpDRkRuYSCyqPXER73H7P 3rebnT7DlUAm6M8RF/g3LnFxcRZ0QfUS2lVfOHFExBEJN6FzaGhhyKC+3oRfzdy2NNd6 s5gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702014909; x=1702619709; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=oJ/tAo5hDwQPfRruz9afcRfXvkx00dxKddYKFVNcdvc=; b=O4vRRkw1G+j7awv3C/VRlCfwg7xt2sGyITcFdq8ewTIIpXbEZ4jiXVJl4Y0LYBauvp EjOIiDonPDjSxJzjJ6zWWcxZpXOSggaQcIxP+fpcCEBELSwhh+yK/Z3fk8Fck8tAAcgr EovyWi1hnYp5K3tRcO3Eu9rY8LHDMWfJRAsW/RJ9pWJb5S2mfs51pw1B/xvyneR/erqZ UWbb+Up0kphF7APlkTZ7QlADi2V3y9jKql1h7a5HU8/YW/SGGI3qrenbdnMjb/0HOD3m KcOsECmtbUTndN5RHF6sZdfCrz+rIbtIJmDaXz7JhCfTNf+JC6F4Vpjc/EKL9gYztCiF R5MA== X-Gm-Message-State: AOJu0Yyra66cAMkhPitCFwsCo8v9DFIPe7eAU2oxdI1m/diAzrNErrla 4W5Sj5L/mt2n3p8WhUl91fOn/Q== X-Google-Smtp-Source: AGHT+IHgMEmtold3cNsq0/10/gSamuXTn7dqDmNr7pkUJjR3cZZJuyMG6U/Bp0CgIPL33Lkbwgh+tw== X-Received: by 2002:a05:6a20:4282:b0:181:74fe:ba83 with SMTP id o2-20020a056a20428200b0018174feba83mr4264495pzj.40.1702014909013; Thu, 07 Dec 2023 21:55:09 -0800 (PST) Received: from sw06.internal.sifive.com ([4.53.31.132]) by smtp.gmail.com with ESMTPSA id s22-20020a170902989600b001ce5b859a59sm786250plp.305.2023.12.07.21.55.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 21:55:08 -0800 (PST) From: Samuel Holland To: linux-arm-kernel@lists.infradead.org, loongarch@lists.linux.dev, linuxppc-dev@lists.ozlabs.org, x86@kernel.org, linux-riscv@lists.infradead.org, Christoph Hellwig Cc: linux-kernel@vger.kernel.org, amd-gfx@lists.freedesktop.org, linux-arch@vger.kernel.org, Samuel Holland Subject: [RFC PATCH 05/12] lib/raid6: Use CC_FLAGS_FPU for NEON CFLAGS Date: Thu, 7 Dec 2023 21:54:35 -0800 Message-ID: <20231208055501.2916202-6-samuel.holland@sifive.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231208055501.2916202-1-samuel.holland@sifive.com> References: <20231208055501.2916202-1-samuel.holland@sifive.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Now that CC_FLAGS_FPU is exported and can be used anywhere in the source tree, use it instead of duplicating the flags here. Signed-off-by: Samuel Holland Reviewed-by: Christoph Hellwig --- lib/raid6/Makefile | 31 ++++++++----------------------- 1 file changed, 8 insertions(+), 23 deletions(-) diff --git a/lib/raid6/Makefile b/lib/raid6/Makefile index 1c5420ff254e..309fea97efc6 100644 --- a/lib/raid6/Makefile +++ b/lib/raid6/Makefile @@ -33,25 +33,6 @@ CFLAGS_REMOVE_vpermxor8.o +=3D -msoft-float endif endif =20 -# The GCC option -ffreestanding is required in order to compile code conta= ining -# ARM/NEON intrinsics in a non C99-compliant environment (such as the kern= el) -ifeq ($(CONFIG_KERNEL_MODE_NEON),y) -NEON_FLAGS :=3D -ffreestanding -# Enable -NEON_FLAGS +=3D -isystem $(shell $(CC) -print-file-name=3Dinclude) -ifeq ($(ARCH),arm) -NEON_FLAGS +=3D -march=3Darmv7-a -mfloat-abi=3Dsoftfp -mfpu=3Dneon -endif -CFLAGS_recov_neon_inner.o +=3D $(NEON_FLAGS) -ifeq ($(ARCH),arm64) -CFLAGS_REMOVE_recov_neon_inner.o +=3D -mgeneral-regs-only -CFLAGS_REMOVE_neon1.o +=3D -mgeneral-regs-only -CFLAGS_REMOVE_neon2.o +=3D -mgeneral-regs-only -CFLAGS_REMOVE_neon4.o +=3D -mgeneral-regs-only -CFLAGS_REMOVE_neon8.o +=3D -mgeneral-regs-only -endif -endif - quiet_cmd_unroll =3D UNROLL $@ cmd_unroll =3D $(AWK) -v N=3D$* -f $(srctree)/$(src)/unroll.awk < $<= > $@ =20 @@ -75,10 +56,14 @@ targets +=3D vpermxor1.c vpermxor2.c vpermxor4.c vpermx= or8.c $(obj)/vpermxor%.c: $(src)/vpermxor.uc $(src)/unroll.awk FORCE $(call if_changed,unroll) =20 -CFLAGS_neon1.o +=3D $(NEON_FLAGS) -CFLAGS_neon2.o +=3D $(NEON_FLAGS) -CFLAGS_neon4.o +=3D $(NEON_FLAGS) -CFLAGS_neon8.o +=3D $(NEON_FLAGS) +CFLAGS_neon1.o +=3D $(CC_FLAGS_FPU) +CFLAGS_neon2.o +=3D $(CC_FLAGS_FPU) +CFLAGS_neon4.o +=3D $(CC_FLAGS_FPU) +CFLAGS_neon8.o +=3D $(CC_FLAGS_FPU) +CFLAGS_REMOVE_neon1.o +=3D $(CC_FLAGS_NO_FPU) +CFLAGS_REMOVE_neon2.o +=3D $(CC_FLAGS_NO_FPU) +CFLAGS_REMOVE_neon4.o +=3D $(CC_FLAGS_NO_FPU) +CFLAGS_REMOVE_neon8.o +=3D $(CC_FLAGS_NO_FPU) targets +=3D neon1.c neon2.c neon4.c neon8.c $(obj)/neon%.c: $(src)/neon.uc $(src)/unroll.awk FORCE $(call if_changed,unroll) --=20 2.42.0