Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp1013587lqo; Fri, 17 May 2024 08:14:39 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVHoztf09Z+KPwKlnGnJVen6NdXYKHxybi4qxb8oCZp1l1LpDPrHHRge0fftRib2tVGiBEsA4y4C6fof6hnT4TgJ9R+9K4DXB315BaVgQ== X-Google-Smtp-Source: AGHT+IHfQgf1Zm6UW4vIv6Gz4p3kB3P+B9qYxCpKplwPlbXRzZAuh6lk/smL6tCxTF7Pm0Cz3VM0 X-Received: by 2002:a17:902:b48d:b0:1e4:ccf6:209f with SMTP id d9443c01a7336-1ef43d2e29emr211161905ad.28.1715958878808; Fri, 17 May 2024 08:14:38 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715958878; cv=pass; d=google.com; s=arc-20160816; b=LfU0IlzGjgxUlVcRlIn+J9wSCyKyd8X3pDruTBEq/Kbo8IgFEKr6p/sbFdQLsMtxxK wkYQoltEh8YH4ZZ9RhYZWq8n/5AeCHAM1KqqV402W6gT4nFie4oBtqRLqFGv/uUOkl12 QtpJ9ZPfWuOLYP8RpLKV5lDCTlNeLMcrtJUWQGKe2mPIpasw6s33IVO+hKrS7X7PrjvJ WAtVaciYu5OC+yVSG8rm2FcLBrgu00Qdot+HghXaPYzTV3iKgcC/rBYFL13Sh97V1403 jRuNB5KGfSGC6xrbiqDGREFGXJyOtwbUMj7WyJ1awNL10si2MB1AV99/7TpTxfaqKD1o 0yPQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=bxwJ7AJVWOOJH5g1C7ONAzDxOLE31aJ/GSXI4iM+BBI=; fh=vNToJYDwn8a8WjUn9nUs2IneRGhPE2/S/58ULDaopbU=; b=dWVracr0tuDfs6OVlarR8OPFJ2C/HcQaN+c40yKi/QPj61axsYp3l35PQlMeKCeYQ0 eIXyS5iNq0s22OIpnmSU4onceutsfZGXf4d3n6G+KAM4hON4QgVZzJQwJPsIfAG43rZz yRsq8jdptvvsYxcYEVUeAq9R2HuUpFPdm/3UWLSeATUIJVub1ulZCzLR4cGcTm7QI6be QV8YQjr2FZ6o1ylr1PBMa2+kT05neh+fb/PhlKpdGvN6W+wWByNXYrnvWZ4cHXoOf1Mk /xm54n8gDwAsQ7srxrXv/YyFHgwuUBIHsdkfqe1YQo3/3olEnhX1s0CjOY1CGSqPemcD 98zA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@rivosinc-com.20230601.gappssmtp.com header.s=20230601 header.b="Qrawe+/6"; arc=pass (i=1 spf=pass spfdomain=rivosinc.com dkim=pass dkdomain=rivosinc-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-182243-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-182243-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id d9443c01a7336-1ef0bad59c7si177268965ad.137.2024.05.17.08.14.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 08:14:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-182243-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@rivosinc-com.20230601.gappssmtp.com header.s=20230601 header.b="Qrawe+/6"; arc=pass (i=1 spf=pass spfdomain=rivosinc.com dkim=pass dkdomain=rivosinc-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-182243-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-182243-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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 41045B24903 for ; Fri, 17 May 2024 14:55:28 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A888A745D5; Fri, 17 May 2024 14:53:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=rivosinc-com.20230601.gappssmtp.com header.i=@rivosinc-com.20230601.gappssmtp.com header.b="Qrawe+/6" Received: from mail-wr1-f49.google.com (mail-wr1-f49.google.com [209.85.221.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DDB3B71756 for ; Fri, 17 May 2024 14:53:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.49 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715957606; cv=none; b=Xf4SRRbtHClGBScK/TPrfeiu05MeXbZylCB63TID0h1Kav4vk7Ph7ZqqHSNCoCqMnTjwk8Iwr9jG2KvWYbA4cN16/y/nbB3FLtCYBjug4Gjn9PkGM1TGPlLyc6urUPjJKB89szhXTJM1h3WJaDjbzKg/km+lIkIf69OOxL50gho= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715957606; c=relaxed/simple; bh=Pm3PTmjoqA7Tnqx632wXkGWqZM/Iv8ukmTO2nSQRuVo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=VO7mV7oUXE28CZYxJegP5iqTsg+A0z8oMDqM5OrDKauTVgukf5g7ajUtBnsGMA7HfWKFCLsfASIpHhBUFtT95ASwadybRdc6MAW2Q0lZ+YMuN1Cj/xYfrHl44Gw01LOG/1RhqF2abcV7TETPP8goNWvaswVqY1Jb+seeuwQzXP8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=rivosinc.com; spf=pass smtp.mailfrom=rivosinc.com; dkim=pass (2048-bit key) header.d=rivosinc-com.20230601.gappssmtp.com header.i=@rivosinc-com.20230601.gappssmtp.com header.b=Qrawe+/6; arc=none smtp.client-ip=209.85.221.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-wr1-f49.google.com with SMTP id ffacd0b85a97d-34cba0d9a3eso26921f8f.1 for ; Fri, 17 May 2024 07:53:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1715957603; x=1716562403; 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=bxwJ7AJVWOOJH5g1C7ONAzDxOLE31aJ/GSXI4iM+BBI=; b=Qrawe+/66RoxEDSzHWhvJrp8Bp6u1wDod3M4n5h8DILb0p3fdGaP5ttf+hUHr18IXC VdP2Yk9b3SFycogAt4Bs8mLhWBNGHYhDEdl7KYWoCypC2RYIp3q63UIvad6WCURLUiuQ lf0of2cLU+wMFoPSRlD7qRYex23bGFJ3dwp9F82tW5gFCEdgrVkwj1sqck+p0S6LoOz6 UcRb1nePvXNf+vbc1tVq/pDGnw8mHK+MdlGsMaB0VWvCrCAmieoJ1phKmcgrB53nuUBv VZt3pLkDZDN+UXHblULircaGolGEcJMtJldjLhGlJ5Vsk9eI9D/pKAReySpqjPPQ3dVw uo8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715957603; x=1716562403; 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=bxwJ7AJVWOOJH5g1C7ONAzDxOLE31aJ/GSXI4iM+BBI=; b=HClbwOhtFxOPG9hYgv0ipvTRboMjum+sKKHFtEh6wjc/SASE3Hngq40TwTA3tw6Lw+ nDvhv+eX/4+DFhyyZ4TbOY/BXcLODj95gy0xeweMFWI7G48DDFtLH4X+8fAzAFf4w/x2 3K05id3HmG/vtaZV4Th8PErsTJ0WAQQSDNKoh7Erbg+iYQEp9w+bClwg88uQT2d6S38y QAdK3o3VzwA5wsIJgLke6vbbp9/ytAAKlVxyzeEUgZqlRSv7hj/s5Jo2G/kv9C+ndu+x Jl37x+5Mn3Wux1zOsNiSTFUBJvCXJQV+7U/tFk0qsbwZ8jeFH/So3A4Xj1fR0Z11tn5o NHKQ== X-Forwarded-Encrypted: i=1; AJvYcCXyBCL6UAZyqb5ujg4qKIfB6G6EGQ4CjWR7Cw8DyNNroB1pYkqYapDwZWB/DulYlmuXZ/enZ3auEbFqEmoC0wKKv0PU/YOxqzFoWcnR X-Gm-Message-State: AOJu0YzGZ0tFb4j8KxPqgHdC7kwiVIPx26TnvlGTmcB6dA1zncRsIiNN mhrqENarddVDsS0dEVJ6VpXLS3XXSM5mKmmPEbO/ZkHlCn4ksRuzKnzJY3ViRx8= X-Received: by 2002:a05:600c:511c:b0:420:29dd:84e2 with SMTP id 5b1f17b1804b1-42029dd87camr37914505e9.2.1715957603384; Fri, 17 May 2024 07:53:23 -0700 (PDT) Received: from carbon-x1.. ([2a01:e0a:999:a3a0:46f0:3724:aa77:c1f8]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-41fccce9431sm301723695e9.28.2024.05.17.07.53.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 07:53:22 -0700 (PDT) From: =?UTF-8?q?Cl=C3=A9ment=20L=C3=A9ger?= To: Jonathan Corbet , Paul Walmsley , Palmer Dabbelt , Albert Ou , Conor Dooley , Rob Herring , Krzysztof Kozlowski , Anup Patel , Shuah Khan Cc: =?UTF-8?q?Cl=C3=A9ment=20L=C3=A9ger?= , Atish Patra , linux-doc@vger.kernel.org, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, kvm@vger.kernel.org, kvm-riscv@lists.infradead.org, linux-kselftest@vger.kernel.org, Conor Dooley Subject: [PATCH v5 06/16] dt-bindings: riscv: add Zca, Zcf, Zcd and Zcb ISA extension description Date: Fri, 17 May 2024 16:52:46 +0200 Message-ID: <20240517145302.971019-7-cleger@rivosinc.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240517145302.971019-1-cleger@rivosinc.com> References: <20240517145302.971019-1-cleger@rivosinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add description for Zca, Zcf, Zcd and Zcb extensions which are part the Zc* standard extensions for code size reduction. Additional validation rules are added since Zcb depends on Zca, Zcf, depends on Zca and F, Zcd depends on Zca and D and finally, Zcf can not be present on rv64. Signed-off-by: Clément Léger Reviewed-by: Conor Dooley --- .../devicetree/bindings/riscv/extensions.yaml | 78 +++++++++++++++++++ 1 file changed, 78 insertions(+) diff --git a/Documentation/devicetree/bindings/riscv/extensions.yaml b/Documentation/devicetree/bindings/riscv/extensions.yaml index b9100addeb90..39084c58d4e4 100644 --- a/Documentation/devicetree/bindings/riscv/extensions.yaml +++ b/Documentation/devicetree/bindings/riscv/extensions.yaml @@ -220,6 +220,38 @@ properties: instructions as ratified at commit 6d33919 ("Merge pull request #158 from hirooih/clmul-fix-loop-end-condition") of riscv-bitmanip. + - const: zca + description: | + The Zca extension part of Zc* standard extensions for code size + reduction, as ratified in commit 8be3419c1c0 ("Zcf doesn't exist on + RV64 as it contains no instructions") of riscv-code-size-reduction, + merged in the riscv-isa-manual by commit dbc79cf28a2 ("Initial seed + of zc.adoc to src tree."). + + - const: zcb + description: | + The Zcb extension part of Zc* standard extensions for code size + reduction, as ratified in commit 8be3419c1c0 ("Zcf doesn't exist on + RV64 as it contains no instructions") of riscv-code-size-reduction, + merged in the riscv-isa-manual by commit dbc79cf28a2 ("Initial seed + of zc.adoc to src tree."). + + - const: zcd + description: | + The Zcd extension part of Zc* standard extensions for code size + reduction, as ratified in commit 8be3419c1c0 ("Zcf doesn't exist on + RV64 as it contains no instructions") of riscv-code-size-reduction, + merged in the riscv-isa-manual by commit dbc79cf28a2 ("Initial seed + of zc.adoc to src tree."). + + - const: zcf + description: | + The Zcf extension part of Zc* standard extensions for code size + reduction, as ratified in commit 8be3419c1c0 ("Zcf doesn't exist on + RV64 as it contains no instructions") of riscv-code-size-reduction, + merged in the riscv-isa-manual by commit dbc79cf28a2 ("Initial seed + of zc.adoc to src tree."). + - const: zfa description: The standard Zfa extension for additional floating point @@ -499,5 +531,51 @@ properties: The T-HEAD specific 0.7.1 vector implementation as written in https://github.com/T-head-Semi/thead-extension-spec/blob/95358cb2cca9489361c61d335e03d3134b14133f/xtheadvector.adoc. + allOf: + # Zcb depends on Zca + - if: + contains: + const: zcb + then: + contains: + const: zca + # Zcd depends on Zca and D + - if: + contains: + const: zcd + then: + allOf: + - contains: + const: zca + - contains: + const: d + # Zcf depends on Zca and F + - if: + contains: + const: zcf + then: + allOf: + - contains: + const: zca + - contains: + const: f + +allOf: + # Zcf extension does not exist on rv64 + - if: + properties: + riscv,isa-extensions: + contains: + const: zcf + riscv,isa-base: + contains: + const: rv64i + then: + properties: + riscv,isa-extensions: + not: + contains: + const: zcf + additionalProperties: true ... -- 2.43.0