Received: by 2002:a89:48b:0:b0:1f5:f2ab:c469 with SMTP id a11csp454640lqd; Wed, 24 Apr 2024 07:24:20 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXFl3WFSybVfvkT+Ui5qAY5dFFs/KnqfAYVxHV5L+vMNI5VDWG/p6ybBl8uj++bIfIN2IVDyYrzeBK4d8v8otRr5a+a65tK3oy1TbsF+w== X-Google-Smtp-Source: AGHT+IFl9cWq+035hV0rNBSMgxarOvl5y52l4E58XkJ61ZecFZFrW8Wi9WzomGhPZTi46pHZVZxk X-Received: by 2002:a17:903:1110:b0:1e4:3386:349f with SMTP id n16-20020a170903111000b001e43386349fmr2728986plh.51.1713968659946; Wed, 24 Apr 2024 07:24:19 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713968659; cv=pass; d=google.com; s=arc-20160816; b=MhNbFe53+t0fgFWa4rsfuYz9ywrWuX4hEbZFOIzBOb349kt+7X/t+rTh+e6M7kb1e1 Qi6F5nDnOoHzYG9kfj9+Kt7fwuO4WlI3Pc5uU2kUF5dIvQRaSMj3pVs8xyExV0QLBqqC Qp4HTFZPcJKpbVbLafeFVqYxs7BIroUWLWZJ6e2fwu7H1DPs4cDy2iJaVzOLotPrlLi/ IB3qMFDotSKLwj1m8Iwvri3MEL/hBWvgiq8KEtsloGtiAEZnbBQWwTPImSs+62vl9oqo VnxCKB9/Z/VBtQeO7WityJelfKJsyXOyEiCpsZkCd59uV93H2KQUnIj86jkbmkz9Cn9t xFnw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=EJhDyyPHKVTNIWSpGOpmxo2v9mPcsPD83AhAnFDIUR8=; fh=GgrBnc7ORkY+J/1GISwRDdwfqWq3J4mCa9qstoRY4lo=; b=uFU/3+u6jY4YPlS5dcDMAtSzbh5YCBpekvhlqaZLWwL8rB7myPQarij5BpUXPzkXwN tgJsjRfpCn/mKlTbA40YFFnoYGcUW+bjlIYvTE9GjKJBva5EgGnCFcrfZVb5xz2LfFYA 5A7PBNuo/2RzQ/dm9UhqZTIFoaqE9Su5J8WVBM6352qmkz8YbDUg8S17nhPbAcKb1NBW wG+M5BXbFxU3dHAh+1whbTfdcxThfAzB66OA5x3vYdymNrVy0wgyXh7kfuRhPijPXVH8 S6HmGOgLzcKeUL97vvJzrUjcwgx1t+JQfgMKs9C0r2KR52blIGFdgF0hGpSiuZXFnWCy FFtA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=ghiti.fr); spf=pass (google.com: domain of linux-kernel+bounces-157067-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-157067-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id q4-20020a17090311c400b001e89487bdb0si11346883plh.377.2024.04.24.07.24.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Apr 2024 07:24:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-157067-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=ghiti.fr); spf=pass (google.com: domain of linux-kernel+bounces-157067-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-157067-linux.lists.archive=gmail.com@vger.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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 5B428284798 for ; Wed, 24 Apr 2024 14:22:26 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1A7EB15ECD5; Wed, 24 Apr 2024 14:22:13 +0000 (UTC) Received: from relay9-d.mail.gandi.net (relay9-d.mail.gandi.net [217.70.183.199]) (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 2E78B15ECCB; Wed, 24 Apr 2024 14:22:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.199 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713968532; cv=none; b=VbmSvt8fuAdSwYyS7wC3aKMAbSEIBE1SfB4fWYHYBLMImj9Zjb2Cfrudd4pxA8G9u/+kPnRRLEMslXgOsDj6w7vghDn/pKzmUvafTT7Lb90I7d9nqwgdY/1z0AQuKxIeYRkBo5jbkjpHOjCI1SCdm9hPpiYg5AZ3T78QBggOk2U= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713968532; c=relaxed/simple; bh=bKd7H00rDt0Or6kdVYu+lE7iFOzMdHEuVtRzVbC9rds=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=cz842Sd9IiINssqBB0lEvRCLC12pfAhBf8LKf2EFuqw9vrItBcCrsT8jPegCgc/alKVP4KWQlol0GasJWRED9fOZGpEL+6w4RhASbH+Ntten1mwGrf7dMtldjg4MWp/3KNjElw9TmAkYYkM8Qn7wASTO95wnquv9xijmYcIWUCU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ghiti.fr; spf=pass smtp.mailfrom=ghiti.fr; arc=none smtp.client-ip=217.70.183.199 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ghiti.fr Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ghiti.fr Received: by mail.gandi.net (Postfix) with ESMTPSA id 2E576FF809; Wed, 24 Apr 2024 14:22:02 +0000 (UTC) Message-ID: <6c624361-a968-498b-a9fb-ea2aaec70ce8@ghiti.fr> Date: Wed, 24 Apr 2024 16:22:02 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 06/17] riscv: Fix extension subset checking Content-Language: en-US To: Charlie Jenkins , Conor Dooley , 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 , =?UTF-8?B?Q2zDqW1lbnQgTMOpZ2Vy?= , Jonathan Corbet , Shuah Khan Cc: 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 References: <20240420-dev-charlie-support_thead_vector_6_9-v3-0-67cff4271d1d@rivosinc.com> <20240420-dev-charlie-support_thead_vector_6_9-v3-6-67cff4271d1d@rivosinc.com> From: Alexandre Ghiti In-Reply-To: <20240420-dev-charlie-support_thead_vector_6_9-v3-6-67cff4271d1d@rivosinc.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-GND-Sasl: alex@ghiti.fr Hi Charlie, On 21/04/2024 03:04, 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. > > Signed-off-by: Charlie Jenkins > Reviewed-by: Conor Dooley > Fixes: 0d8295ed975b ("riscv: add ISA extension parsing for scalar crypto") > --- > arch/riscv/kernel/cpufeature.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/riscv/kernel/cpufeature.c b/arch/riscv/kernel/cpufeature.c > index 48874aac4871..b537731cadef 100644 > --- a/arch/riscv/kernel/cpufeature.c > +++ b/arch/riscv/kernel/cpufeature.c > @@ -609,7 +609,7 @@ static int __init riscv_fill_hwcap_from_ext_list(unsigned long *isa2hwcap) > > if (ext->subset_ext_size) { > for (int j = 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); > } > } > I think this should go into -fixes, let's check with Palmer if he wants to take this patch only or if you should send the patch on its own. You can add: Reviewed-by: Alexandre Ghiti Thanks, Alex