From nobody Fri Nov 1 07:21:17 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1708128146; cv=none; d=zohomail.com; s=zohoarc; b=lTX8b/VahuykX72vW5bf2YlvcZSa0pM11VL+AEGoNy8grPnhh5jUdwCOeTZnuBGMv9u/EMkjDnFJfo1hqLe6/fOqCgMgxU2Z0HnKdDX2XZAy6912IFKBoVnJ4b0oKJnnXWwOTRehstYQvNhnt+8JLh3JbPVOM3WADougeJKCHX8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1708128146; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=s0Fg3oLZqQjSAYBkitbDfSo4mh2A3osvSIf7Yp2p+8E=; b=A9KYPGC6I/yITrXe9Ly5AlnunH5hZgpPmCVeUltPi2y0a4ycLN4uUjDUU/w3Y2kfKlGEKN0aqV/24SrRKNydtqz6WztXZ2lkFyJ6+nM3FmdUIhddBDzY6uqLlv2kWy0jLsdjzplB5vTF3jitmyrDyDa07bUjj+cp+wdxO4ZlZM0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1708128146191714.4622580183336; Fri, 16 Feb 2024 16:02:26 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rb89S-0003LO-Nz; Fri, 16 Feb 2024 19:01:54 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rb89Q-0003Kz-A1 for qemu-devel@nongnu.org; Fri, 16 Feb 2024 19:01:52 -0500 Received: from mail-pf1-x430.google.com ([2607:f8b0:4864:20::430]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rb89L-0007uz-RP for qemu-devel@nongnu.org; Fri, 16 Feb 2024 19:01:49 -0500 Received: by mail-pf1-x430.google.com with SMTP id d2e1a72fcca58-6e0f5934813so2090114b3a.2 for ; Fri, 16 Feb 2024 16:01:47 -0800 (PST) Received: from atishp.ba.rivosinc.com ([64.71.180.162]) by smtp.gmail.com with ESMTPSA id p13-20020a635b0d000000b005d66caee3d0sm464015pgb.22.2024.02.16.16.01.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Feb 2024 16:01:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20230601.gappssmtp.com; s=20230601; t=1708128106; x=1708732906; darn=nongnu.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=s0Fg3oLZqQjSAYBkitbDfSo4mh2A3osvSIf7Yp2p+8E=; b=zTpMKDqAA1Vx+VuphOoxZfI4mRSQTpJGvdy96VsE5yT+iSK8i77AQiUXG0MeoJV8PT hxZdN9rAhb/HIc0YeE0BHFf8n9chrFf/XYDl7dVyQkLixn9+Pkj5CZPTKaMG2bV2XZLr sPKCtousO3tC2Az0Fovqwfn8tVexYD1d7GA6so47vRtzaZ4RPe1pYZBUNrYxV4KSGcN0 9Ew9SEszOacePRvJY/3CYZP8v6u/hiCQiIqct/n6AW9RqA0FuqtGEcj/pnlg4mYXakCX XvB1A5JkwVroKIjLqSBHjYdANUMKtyi7kJr5mWau44v5oBsPogUFB6rhokHWlL0zlRv4 s13Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708128106; x=1708732906; 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=s0Fg3oLZqQjSAYBkitbDfSo4mh2A3osvSIf7Yp2p+8E=; b=jURUbSdwaHVa647wUo+g4zIC6miHgUN3ZYE00wbFP3/x4vdasaHm8yrGYleVuS0sHa CvS2iK8vZEdMUbX4p6mV4KrUTXD+xqgaaaVywfkPz5O5iNbzy6r1NyKix6KOPK3eEqGY hU3EvyOcqLTlhYiMQQTbAwnZjPRZBRyD7Oo7KocmlrgBWTe/gcufSfhNEtTBMXuVE388 NPjCa/9sAD4zNPM7Dr5op6ilTwGXqW6RfhXnpQBlHxrgjgQwqYvi+TOkidsrWDskUnQa WmktqVizwyGSmz4enPX1drOXychRnlycTPCn8sTqjjgI52QhVTjxFHsCUA21O6tH1o+R Hk/g== X-Gm-Message-State: AOJu0Yw39bHuCZqYgyAvCHSi2aOqHgZpuarI4bEBRxe31P1zGZcTyKHd Dy71z7KaNQDpeAozK+N7KES1lztB/KUSqOcpv9cYZ8i42GSV7a/MYEhwnHMzEFuBuC+F5G+9GlQ s X-Google-Smtp-Source: AGHT+IGzADrYzPcNY3RqO3T1kyg8JFD4ffQbnJcozK4J7bG3yILjNQEKPD03Q9l72mQkHWAJLjCfPg== X-Received: by 2002:aa7:860c:0:b0:6e1:1c:1125 with SMTP id p12-20020aa7860c000000b006e1001c1125mr6005694pfn.14.1708128105678; Fri, 16 Feb 2024 16:01:45 -0800 (PST) From: Atish Patra To: qemu-devel@nongnu.org Cc: Atish Patra , Alistair Francis , Bin Meng , Daniel Henrique Barboza , Liu Zhiwei , Palmer Dabbelt , qemu-riscv@nongnu.org, Weiwei Li , kaiwenxue1@gmail.com Subject: [PATCH RFC 1/8] target/riscv: Add properties for Indirect CSR Access extension Date: Fri, 16 Feb 2024 16:01:27 -0800 Message-Id: <20240217000134.3634191-2-atishp@rivosinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240217000134.3634191-1-atishp@rivosinc.com> References: <20240217000134.3634191-1-atishp@rivosinc.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2607:f8b0:4864:20::430; envelope-from=atishp@rivosinc.com; helo=mail-pf1-x430.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @rivosinc-com.20230601.gappssmtp.com) X-ZM-MESSAGEID: 1708128148670100005 Content-Type: text/plain; charset="utf-8" From: Kaiwen Xue This adds the properties for sxcsrind. Definitions of new registers and implementations will come with future patches. Signed-off-by: Atish Patra Signed-off-by: Kaiwen Xue --- target/riscv/cpu.c | 4 ++++ target/riscv/cpu_cfg.h | 2 ++ 2 files changed, 6 insertions(+) diff --git a/target/riscv/cpu.c b/target/riscv/cpu.c index 8af99ed2f6de..ff7c6c7c380e 100644 --- a/target/riscv/cpu.c +++ b/target/riscv/cpu.c @@ -152,10 +152,12 @@ const RISCVIsaExtData isa_edata_arr[] =3D { ISA_EXT_DATA_ENTRY(zhinxmin, PRIV_VERSION_1_12_0, ext_zhinxmin), ISA_EXT_DATA_ENTRY(smaia, PRIV_VERSION_1_12_0, ext_smaia), ISA_EXT_DATA_ENTRY(smcntrpmf, PRIV_VERSION_1_12_0, ext_smcntrpmf), + ISA_EXT_DATA_ENTRY(smcsrind, PRIV_VERSION_1_12_0, ext_smcsrind), ISA_EXT_DATA_ENTRY(smepmp, PRIV_VERSION_1_12_0, ext_smepmp), ISA_EXT_DATA_ENTRY(smstateen, PRIV_VERSION_1_12_0, ext_smstateen), ISA_EXT_DATA_ENTRY(ssaia, PRIV_VERSION_1_12_0, ext_ssaia), ISA_EXT_DATA_ENTRY(sscofpmf, PRIV_VERSION_1_12_0, ext_sscofpmf), + ISA_EXT_DATA_ENTRY(sscsrind, PRIV_VERSION_1_12_0, ext_sscsrind), ISA_EXT_DATA_ENTRY(sstc, PRIV_VERSION_1_12_0, ext_sstc), ISA_EXT_DATA_ENTRY(svadu, PRIV_VERSION_1_12_0, ext_svadu), ISA_EXT_DATA_ENTRY(svinval, PRIV_VERSION_1_12_0, ext_svinval), @@ -1348,6 +1350,8 @@ const RISCVCPUMultiExtConfig riscv_cpu_extensions[] = =3D { /* Defaults for standard extensions */ MULTI_EXT_CFG_BOOL("sscofpmf", ext_sscofpmf, false), MULTI_EXT_CFG_BOOL("smcntrpmf", ext_smcntrpmf, false), + MULTI_EXT_CFG_BOOL("smcsrind", ext_smcsrind, false), + MULTI_EXT_CFG_BOOL("sscsrind", ext_sscsrind, false), MULTI_EXT_CFG_BOOL("zifencei", ext_zifencei, true), MULTI_EXT_CFG_BOOL("zicsr", ext_zicsr, true), MULTI_EXT_CFG_BOOL("zihintntl", ext_zihintntl, true), diff --git a/target/riscv/cpu_cfg.h b/target/riscv/cpu_cfg.h index eabbecb8f962..b9086464752e 100644 --- a/target/riscv/cpu_cfg.h +++ b/target/riscv/cpu_cfg.h @@ -74,6 +74,8 @@ struct RISCVCPUConfig { bool ext_smstateen; bool ext_sstc; bool ext_smcntrpmf; + bool ext_smcsrind; + bool ext_sscsrind; bool ext_svadu; bool ext_svinval; bool ext_svnapot; --=20 2.34.1