Received: by 2002:ab2:7041:0:b0:1f4:bcc8:f211 with SMTP id x1csp76266lql; Fri, 12 Apr 2024 04:27:13 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCW0OwdWnn8uYBK3//iyz7Kjq4a68v9EXklRXrfO/DXmT8ggA29oCRJ7/xicuRCEpt62GYHRgBZZOT5zbGhsd52ib9qSfK5GUjhwHLVLBw== X-Google-Smtp-Source: AGHT+IGxP84oOcpGDXN7MZCLFEZdfNiEXIyBGIYNeIrNpRkMuGfDnPBnK6HzGg/O3URbwBO4eny2 X-Received: by 2002:a0c:ab1b:0:b0:699:23a9:4d4 with SMTP id h27-20020a0cab1b000000b0069923a904d4mr2376077qvb.58.1712921233473; Fri, 12 Apr 2024 04:27:13 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712921233; cv=pass; d=google.com; s=arc-20160816; b=xYQaN6VIki7v9JX31YL/NhjcxEDwNYuJHPqWgfonBb2KczTSPqUhKAvkFC6F/DmHsu tnO1TjStsS9+1MiW+qOSAHVGNGSJrVhzHdV9CZ3ltv3QMBFQF6ivSyXXljTKYXHMik0Q ijqvrdR20j2IZS86rJ1FkfyAecCBNSc5udsSCwBPIZvTYXaS1u3TVdCwFSJAEfCJsqE0 ZrzJRGaYrKKYaQOOPvB782rwL7FRfZMbeh1h7bQTQjsn28XQAI45y8Y8mHPkEl3xEtuh oVoAreKj//tGiIPxvaSMVmSLc1bWjfCnT4HwluKJil2Oh0kE47b4iTqX5SgrD3J9UQZ9 KfJQ== 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=qY16YBn2gy9FmzJBQ9nn7FPBkfixM6fTQ9yka8IrW4E=; fh=4jyGPlIgBC+cOBl2betKVRRu896Cfe1VEzAQNc3FCOU=; b=eVQwHX9gdcAbi01CZ7pG+o6H8i8daTsWj7xdcCN84gz86L/Wgb10ibIn1GHQeS/Z7F sdrrdozaoHZEYgR8q+Ff5CATsX0+MNyMRKtIG0ZN2lP1KsN3G8aphXgqBvDbavZ2j3kL QJqkTW5FpN1jCEVg7ugwg9jGD0elEB9W5BetsfQYsYB7OdYeSPpqhRiMnk8RaOTFRX9I RG2hwYYdQjQExtMo6cQc7GInMEJK7DTnNZyhWznUEQqq6SoXvcsqLXMq62qaS0YtEEra vVCfO9PDzYL71ri50h4ZvI1RdsK/5CcPJNmqWK666JtF3wQCFWMf+gc/iSe6eOXA4Ai1 nsjQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=c4Lh99Ue; arc=pass (i=1 spf=pass spfdomain=microchip.com dkim=pass dkdomain=microchip.com dmarc=pass fromdomain=microchip.com); spf=pass (google.com: domain of linux-kernel+bounces-142577-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-142577-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microchip.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id gg15-20020a056214252f00b0069b5f0276ffsi223441qvb.495.2024.04.12.04.27.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Apr 2024 04:27:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-142577-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=c4Lh99Ue; arc=pass (i=1 spf=pass spfdomain=microchip.com dkim=pass dkdomain=microchip.com dmarc=pass fromdomain=microchip.com); spf=pass (google.com: domain of linux-kernel+bounces-142577-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-142577-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microchip.com 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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 95A651C234B1 for ; Fri, 12 Apr 2024 11:26:58 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B9FB854BEA; Fri, 12 Apr 2024 11:26:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=microchip.com header.i=@microchip.com header.b="c4Lh99Ue" Received: from esa.microchip.iphmx.com (esa.microchip.iphmx.com [68.232.153.233]) (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 A03A354918; Fri, 12 Apr 2024 11:26:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=68.232.153.233 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712921202; cv=none; b=F2wRJRVRsS74oHx7d85BaHr/ImjUhO3hVYB1+0n/rRp/Z9twa9jZetyzNMXxN2xAYcYOphPaj+9rlNPvdQCersLbcqtbR9g0qDvnB9gDD+c8sMnoT/FdDR1EL1STsvOUak7JvFEw5q7HlwkXqcBml7oKreRtbNc80Sfvz02Rvog= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712921202; c=relaxed/simple; bh=z+QWmlRkXyiZHeyBdGOBMyt0lCNZkClZvYp8kEJVhsQ=; h=Date:From:To:CC:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=oyjEpVtZbPdbPpKRW1oPa+lwHAbGPYe7KRkuS7QuRexr6tF9WYZRcbj9skc8U/CruEaZALDy4rVt32eFZ4uQMvBOtL45JEkm9cvieN7xgfs3yIT5XoNSk0RuuQtI3kdYeK6FI6AQk14QmlIgVaJolN091O6p8L8BKUIzZwOvvqA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=microchip.com; spf=pass smtp.mailfrom=microchip.com; dkim=pass (2048-bit key) header.d=microchip.com header.i=@microchip.com header.b=c4Lh99Ue; arc=none smtp.client-ip=68.232.153.233 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=microchip.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=microchip.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1712921200; x=1744457200; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=z+QWmlRkXyiZHeyBdGOBMyt0lCNZkClZvYp8kEJVhsQ=; b=c4Lh99UeYj4OVZPo8ToZKnV67HgdkbhLPdqx1NykFNqIIQTax6+JcWzT QCNOXOkr79UwP099CD182TDlD4S4O6up3dmqejjYTuoBAI8FtuzSeFE+g frdXqe2UB8RSRGKR9trxXTzpsPGGh+0iCMF9WgDj+DRFrNRJCnr3yX/Ot lWUu5LKipiztOrbNZ2scUqPcNdO0JCo6SBzZnecivW5AnO9GE/TvxHOaW BEYGgBzLpeL/m6/e9CBhA56U0GtYRh4YABFSRuUrxJqNHElXxx3twNG/1 MgcXGdCBSreVxjoeC4/jBu52WsO9+3oMl38Dvr8g+L+NjshhtiBUuScSD g==; X-CSE-ConnectionGUID: mMLqTC6MQs2jRulaBFM8hA== X-CSE-MsgGUID: cKKh0uYiRwyg+O5MVbf/Iw== X-IronPort-AV: E=Sophos;i="6.07,195,1708412400"; d="asc'?scan'208";a="22708176" X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa1.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 12 Apr 2024 04:26:38 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Fri, 12 Apr 2024 04:26:37 -0700 Received: from wendy (10.10.85.11) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35 via Frontend Transport; Fri, 12 Apr 2024 04:26:33 -0700 Date: Fri, 12 Apr 2024 12:25:42 +0100 From: Conor Dooley To: Charlie Jenkins CC: Conor Dooley , Rob Herring , Krzysztof Kozlowski , Paul Walmsley , Palmer Dabbelt , Albert Ou , Guo Ren , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Evan Green , =?iso-8859-1?Q?Cl=E9ment_L=E9ger?= , Jonathan Corbet , Shuah Khan , , , , Palmer Dabbelt , , , , Subject: Re: [PATCH 05/19] riscv: Fix extension subset checking Message-ID: <20240412-underuse-manliness-56d328666ce9@wendy> References: <20240411-dev-charlie-support_thead_vector_6_9-v1-0-4af9815ec746@rivosinc.com> <20240411-dev-charlie-support_thead_vector_6_9-v1-5-4af9815ec746@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="q4bmFTLuVU/tA/Al" Content-Disposition: inline In-Reply-To: <20240411-dev-charlie-support_thead_vector_6_9-v1-5-4af9815ec746@rivosinc.com> --q4bmFTLuVU/tA/Al Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Apr 11, 2024 at 09:11:11PM -0700, Charlie Jenkins wrote: > This loop is supposed to check if ext->subset_ext_ids[j] is valid, rather > than if ext->subset_ext_ids[i] is valid, before setting the extension > id ext->subset_ext_ids[j] in isainfo->isa. >=20 > Signed-off-by: Charlie Jenkins > Fixes: 0d8295ed975b ("riscv: add ISA extension parsing for scalar crypto") Reviewed-by: Conor Dooley Thanks, Conor. > --- > arch/riscv/kernel/cpufeature.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >=20 > diff --git a/arch/riscv/kernel/cpufeature.c b/arch/riscv/kernel/cpufeatur= e.c > index cd156adbeb66..5eb52d270a9a 100644 > --- a/arch/riscv/kernel/cpufeature.c > +++ b/arch/riscv/kernel/cpufeature.c > @@ -617,7 +617,7 @@ static int __init riscv_fill_hwcap_from_ext_list(unsi= gned long *isa2hwcap) > =20 > if (ext->subset_ext_size) { > for (int j =3D 0; j < ext->subset_ext_size; j++) { > - if (riscv_isa_extension_check(ext->subset_ext_ids[i])) > + if (riscv_isa_extension_check(ext->subset_ext_ids[j])) > set_bit(ext->subset_ext_ids[j], isainfo->isa); > } > } >=20 > --=20 > 2.44.0 >=20 --q4bmFTLuVU/tA/Al Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZhkaNgAKCRB4tDGHoIJi 0jF+AP0aO4m1oyhnqLkpU2nu54aTKQxfBfGaf5fonL4sFryyhgD/dWIvHo6yBxxP Nl1Ow+f7aIxbclA0UIvZgnXGzIHIIgQ= =wY2O -----END PGP SIGNATURE----- --q4bmFTLuVU/tA/Al--