From patchwork Fri Jun 28 09:37:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yong-Xuan Wang X-Patchwork-Id: 1953859 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=g2euENXG; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=sifive.com header.i=@sifive.com header.a=rsa-sha256 header.s=google header.b=CEBrhzmc; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=kvm-riscv-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4W9Vjy055Vz20X6 for ; Fri, 28 Jun 2024 19:38:30 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=JKnDvCWwJ6pdHMw+1BNHAkK7W1QpTrwtkR+w2YcogKE=; b=g2euENXGRcugRD U6u4tblosffaLX7q+iBOqHzOTCKRaBMYcEtOnamONuStSfHG03E02eFaHp/5BnEVM1o5cHgVYDpMR DfS1QN1msFyty8fzIxKbsDsz3K8lRZqcgZU5h31ngJFQhpcW6OBT4T9LXh74zLTPVA1FldYmUeqKZ G1c6Ham3ZtG2E2qAdinudQsdw8H9RqmuVgZwCu+IE5sXe053/j/quLKkeWj9gMZMiOJDMqRUdGYII FEFD9rAVjp8VvP2NRc+66T8FT6IcsHVIpu5yxr3HbAQhKgZsdL0ZoQ06CPo2Zi/ZsHXYDZOOyr5m1 0ubHc6TcxuBCJ+Q71T+Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sN83o-0000000DHgw-3Coo; Fri, 28 Jun 2024 09:38:28 +0000 Received: from mail-pg1-x535.google.com ([2607:f8b0:4864:20::535]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sN83U-0000000DHU2-0QxF for kvm-riscv@lists.infradead.org; Fri, 28 Jun 2024 09:38:10 +0000 Received: by mail-pg1-x535.google.com with SMTP id 41be03b00d2f7-6c5bcb8e8edso306147a12.2 for ; Fri, 28 Jun 2024 02:38:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; t=1719567487; x=1720172287; darn=lists.infradead.org; h=references:in-reply-to:message-id:date:subject:cc:to:from:from:to :cc:subject:date:message-id:reply-to; bh=YA0dWEkzXvI8/KpPhKTDAN4RTMFwdU95qGVE5ffUQFc=; b=CEBrhzmchGogQSicM+Cst/0YsC5g7/0w1IbxK7+F3mxfhbYIU9Qv14r2xLOb0OcUNN 2wTc9JP9VsSCW8kb/kawNspB9lLhAIT5SK7gpLtAFDVluzXENy6sL/dG/kfnbVoUpOz+ SOsTYXu5x5qPu81nCzLLp7MmmOKKe6cE47/HcRBCFlrHfFBMvPz2eGpOJrS/28C+Yt9C Bm1GZSDci5+wTw5VUQLjAr8OyQSvVu8k5JDVrg9aJJixghuPx9rW6u/bMg+RZw9C2sSc yE5wuuLroHO2UQI+e8Hxl36NL+lnOTu9BA69eEkeshkEj0u9L8cwxEaQA871v86E7h9t KN/A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1719567487; x=1720172287; h=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=YA0dWEkzXvI8/KpPhKTDAN4RTMFwdU95qGVE5ffUQFc=; b=isUgRX3S4Z5jVEaPQGR7OVYMRh6+n3rckqSNbb4l6Mkxvk9G1SJ+2SE9mNwbbvNmFL Bkmq9+hQgBS2wk9YM6wLcnTpp/aCC0W4gCgCsBEjQ3ljXSqgKwcRvKG3xJA0tlcOPDcp 2RhnTi1C1a11xqjlBM1X5/ANSxgnnAanCK4tnCggej357nDO7SvVdHR1bnQMOOBMZIfz zYA4X91ECrIM8aBKIy8smdfyUFcFA1d1xJSIemO5sVaiON0NmCCB58C1MhifqRgm8z/g W6zp63FhIbPLpZtc/lQe490S9Zmx4qLi874YCF8q00RgL8VZy8W5hha4EgPpX+Pxp4/O MJXA== X-Forwarded-Encrypted: i=1; AJvYcCWHa9KECZXgrj2LuNyTgZpDcfET1uXcjd5aGoO4sY+tErMq4iVaBHztSmgdlouL19mQhrcQqaZ6WBOq1aM42+6mFMAG8OQuZ+t/oluvyA== X-Gm-Message-State: AOJu0Yyixw0vxEx2jDqDcKvkF6WCfgUifaskka4vg/XbqDFqZ7IHNzfo ieDuUk+w92gbC/+0CPj0XUJOBlIlSSaxUVCsv/qiQ9k1dPlPyrTX9QUX7kX9ilQ= X-Google-Smtp-Source: AGHT+IEr7EQCj6dcAAmXxE9nTudy+Q1tr3NBQMPkn5K3OhDpK9au3cIf3F6kgtczs2qpjnr6GuG+cA== X-Received: by 2002:a05:6a20:6a90:b0:1bd:91aa:79a0 with SMTP id adf61e73a8af0-1bd91aa7a7dmr7189755637.12.1719567486974; Fri, 28 Jun 2024 02:38:06 -0700 (PDT) Received: from hsinchu26.internal.sifive.com (59-124-168-89.hinet-ip.hinet.net. [59.124.168.89]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1fac10c6c8dsm11087155ad.26.2024.06.28.02.38.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Jun 2024 02:38:06 -0700 (PDT) From: Yong-Xuan Wang To: linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, kvm-riscv@lists.infradead.org, kvm@vger.kernel.org Cc: greentime.hu@sifive.com, vincent.chen@sifive.com, Yong-Xuan Wang , Conor Dooley , Rob Herring , Krzysztof Kozlowski , Paul Walmsley , Palmer Dabbelt , Albert Ou , devicetree@vger.kernel.org Subject: [PATCH v6 2/4] dt-bindings: riscv: Add Svade and Svadu Entries Date: Fri, 28 Jun 2024 17:37:06 +0800 Message-Id: <20240628093711.11716-3-yongxuan.wang@sifive.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20240628093711.11716-1-yongxuan.wang@sifive.com> References: <20240628093711.11716-1-yongxuan.wang@sifive.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240628_023808_360094_8AA3D774 X-CRM114-Status: GOOD ( 11.81 ) X-Spam-Score: -0.2 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Add entries for the Svade and Svadu extensions to the riscv,isa-extensions property. Signed-off-by: Yong-Xuan Wang --- .../devicetree/bindings/riscv/extensions.yaml | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) Content analysis details: (-0.2 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2607:f8b0:4864:20:0:0:0:535 listed in] [list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain X-BeenThere: kvm-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "kvm-riscv" Errors-To: kvm-riscv-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Add entries for the Svade and Svadu extensions to the riscv,isa-extensions property. Signed-off-by: Yong-Xuan Wang --- .../devicetree/bindings/riscv/extensions.yaml | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/Documentation/devicetree/bindings/riscv/extensions.yaml b/Documentation/devicetree/bindings/riscv/extensions.yaml index 468c646247aa..c3d053ce7783 100644 --- a/Documentation/devicetree/bindings/riscv/extensions.yaml +++ b/Documentation/devicetree/bindings/riscv/extensions.yaml @@ -153,6 +153,34 @@ properties: ratified at commit 3f9ed34 ("Add ability to manually trigger workflow. (#2)") of riscv-time-compare. + - const: svade + description: | + The standard Svade supervisor-level extension for SW-managed PTE A/D + bit updates as ratified in the 20240213 version of the privileged + ISA specification. + + Both Svade and Svadu extensions control the hardware behavior when + the PTE A/D bits need to be set. The default behavior for the four + possible combinations of these extensions in the device tree are: + 1) Neither Svade nor Svadu present in DT => It is technically + unknown whether the platform uses Svade or Svadu. Supervisor may + assume Svade to be present and enabled or it can discover based + on mvendorid, marchid, and mimpid. + 2) Only Svade present in DT => Supervisor must assume Svade to be + always enabled. (Obvious) + 3) Only Svadu present in DT => Supervisor must assume Svadu to be + always enabled. (Obvious) + 4) Both Svade and Svadu present in DT => Supervisor must assume + Svadu turned-off at boot time. To use Svadu, supervisor must + explicitly enable it using the SBI FWFT extension. + + - const: svadu + description: | + The standard Svadu supervisor-level extension for hardware updating + of PTE A/D bits as ratified at commit c1abccf ("Merge pull request + #25 from ved-rivos/ratified") of riscv-svadu. Please refer to Svade + dt-binding description for more details. + - const: svinval description: The standard Svinval supervisor-level extension for fine-grained