Received: by 2002:ab2:60d1:0:b0:1f7:5705:b850 with SMTP id i17csp406430lqm; Wed, 1 May 2024 04:37:45 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV/CxnTVNdl5+OIzPyUs/KkJN8ien0zyHTCagunxCIUYcox4Xa3jdkTmG+pxLC2v9P9qCRPqAfExkDGAB7uahBibcxd7W50fIHlvmatvQ== X-Google-Smtp-Source: AGHT+IH3VI6Qs39Pcx0zuxg1bkBFukkfq2YXvAlZYoqlg6ZWJfhcOBU8CdE2fBm0B3islGgW6uUm X-Received: by 2002:a17:906:6953:b0:a51:f463:cfee with SMTP id c19-20020a170906695300b00a51f463cfeemr1708102ejs.72.1714563465583; Wed, 01 May 2024 04:37:45 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714563465; cv=pass; d=google.com; s=arc-20160816; b=sIS1kP0IXwSj6aJ2vujY4PRR2PTp1BFjB4J+o4sj9RBCm0r5rqU2UrNRRHAr1qh4kP iSjapk9WUGAdtNUFcWjVB2X5tZ5kU0Tlegd0238uYxzq2WO/Q++huYR5hrDOYxD/k3/3 R2nPaF54Pr6UogNF5YskzpziUfKagQvN0nN54w2yPn9ROzByBgYdz6yE3IqL7Dje/RKY ypt1yErkR0Ilioel1mYnVnLCut9DFmCFrrvd76ttKpAc6R+EXzfBEaajS6IkPFiVGYys G6cm6oLbJjKVSIpzobWkuJ7d1BFfVnREV9Z105If5JmFbBHlHSGiCz9p8s2iPXYnn9f+ PLgQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=DJc8rFaAcB5JvuljMxsElRpMzHrVs09Jvch6Acp19kY=; fh=mBwwpQbay9vhzTgPULjjDn+LkmwbaBeNVRczdYQ/Av4=; b=k5y6yc0tzX4Nw54747Xs+7eAP/yQccsSwtIAZBoCNZRIYFKjzSpoG3yYfOYFlj5n4H TD/kWv7r4A/xiWRPMOzGKw8VxrPcBi0vxzVWVCex/N4Ihs0SF44NHCwMBOU5D4RxSvIe fsKYwBZOyCGh/HYJt8dZ8ft5tIiqUAK8u19GQUeYqGaly2WQBZh5tb9Glcru65m3PNsK Zim0zXIgWMudYApO2xcyCjUOCHQLLOEdF5KmK4Xt6leOuRQsROdyYNliPi9XDhrCYk5D +YQ32q4qppLSLvuYzns5x1jggK/PA3+B2Y8rSo6h4r5msrVp4tH1EJUl6Jhr7K04M4ZW BNvQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=beA3KVgr; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-165194-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-165194-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id gf5-20020a170906e20500b00a519ff0c0a1si16543624ejb.513.2024.05.01.04.37.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 May 2024 04:37:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-165194-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=beA3KVgr; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-165194-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-165194-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 1E1E01F24109 for ; Wed, 1 May 2024 11:37:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 71DCA7FBD3; Wed, 1 May 2024 11:37:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="beA3KVgr" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8937983CDF; Wed, 1 May 2024 11:37:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714563441; cv=none; b=XQN0VuqoV3Py/vnRkUKuv5y+LQre031YlqGIRhhBatRrSLYb5BETMC5+cECZDGV0qGQcZBQsGiIPMldfCHJghAyxIbthV2vSGQSTf6A+wz6jA1XWLeNaRw8kVWIwUjXhoJZEsiHIQ/KllfagfYpKVB1QbStDuyyDu+e0FnmZ7TE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714563441; c=relaxed/simple; bh=MP62atQMR9QZoG0+ZlmS5Hnq2cah7KkCkJlRp2jaF4I=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=I4UMUTh7RZZz7tqbAqFcCqwzVPLC2IzmVg1SF6qXDa2go3OhOizeMkyrZY3tfWj5XDBNEb1gN/w1uHsQb5gQhqlTZyojH2zSGncMspCZV9ZzsTz4WfLn+4VRo7EQSNKXeoaRejE5x8Oa0Oa9C/+nCImwkHmbVFwrS5yMuceaRhU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=beA3KVgr; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7EDF8C32789; Wed, 1 May 2024 11:37:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1714563441; bh=MP62atQMR9QZoG0+ZlmS5Hnq2cah7KkCkJlRp2jaF4I=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=beA3KVgrsWenCerL/qvg7nGJ1js6iXuqGs3AptzAocKB/boxOcYGnp3XkmaF/2oAO oX/IKgwc3iepDK0HUg4Io2c4i03pdfDpZgk1kcov4Ai/aBxurHiyiAX6HmVvpU/2SO NUgp2LZev45f9DvID3VJ/ctqV7scYd+UBaa9jEA43ipsr+v4I9z5uvqE1vmo0LXCpJ qbaaeWs//uQyrcYV7j53qJtIC7z+cFGAY0qdpMGpg3dAbcmAZGjn0tM0K556QYzqkQ 0hJcGqFhq9jdyXi0dahmnkLEGQ+9rxMrR1yFQRySAqIuiMalxkuwm595dFktELebK8 aVetVR6dPCr+Q== Date: Wed, 1 May 2024 12:37:14 +0100 From: Conor Dooley To: Charlie Jenkins Cc: Rob Herring , Krzysztof Kozlowski , Paul Walmsley , Palmer Dabbelt , Albert Ou , Guo Ren , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Conor Dooley , Evan Green , =?iso-8859-1?Q?Cl=E9ment_L=E9ger?= , Jonathan Corbet , Shuah Khan , linux-riscv@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-doc@vger.kernel.org, linux-kselftest@vger.kernel.org Subject: Re: [PATCH v4 07/16] riscv: cpufeature: Extract common elements from extension checking Message-ID: <20240501-probable-unfunded-746ef6ae1853@spud> References: <20240426-dev-charlie-support_thead_vector_6_9-v4-0-b692f3c516ec@rivosinc.com> <20240426-dev-charlie-support_thead_vector_6_9-v4-7-b692f3c516ec@rivosinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="4cVAmCcvx4abtooG" Content-Disposition: inline In-Reply-To: <20240426-dev-charlie-support_thead_vector_6_9-v4-7-b692f3c516ec@rivosinc.com> --4cVAmCcvx4abtooG Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Apr 26, 2024 at 02:29:21PM -0700, Charlie Jenkins wrote: > The __riscv_has_extension_likely() and __riscv_has_extension_unlikely() > functions from the vendor_extensions.h can be used to simplify the > standard extension checking code as well. Migrate those functions to > cpufeature.h and reorganize the code in the file to use the functions. >=20 > Signed-off-by: Charlie Jenkins > --- > arch/riscv/include/asm/cpufeature.h | 78 +++++++++++++++++-------= ------ > arch/riscv/include/asm/vendor_extensions.h | 28 ----------- > 2 files changed, 44 insertions(+), 62 deletions(-) >=20 > diff --git a/arch/riscv/include/asm/cpufeature.h b/arch/riscv/include/asm= /cpufeature.h > index fedd479ccfd1..17896ec9ec11 100644 > --- a/arch/riscv/include/asm/cpufeature.h > +++ b/arch/riscv/include/asm/cpufeature.h > @@ -98,59 +98,66 @@ extern bool riscv_isa_fallback; > =20 > unsigned long riscv_isa_extension_base(const unsigned long *isa_bitmap); > =20 > +#define EXT_ALL_VENDORS 0 It's not really "all vendors", it's standard. Otherwise, this seems all grand to me, Reviewed-by: Conor Dooley Cheers, Conor. --4cVAmCcvx4abtooG Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZjIpagAKCRB4tDGHoIJi 0nqbAQDotPME6y45R4f68eXuCnbyY4XAOyDUzD3fL8AW4YgGDAD/VCUttdmY/5WW rxMqmWx1QCw9yGME4Abt8BHVFnG4ZgI= =cdZM -----END PGP SIGNATURE----- --4cVAmCcvx4abtooG--