From nobody Mon Nov 23 04:36:05 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; 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; dmarc=fail(p=none dis=none) header.from=zte.com.cn Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1792984471249318.0783685828824; Sun, 25 Oct 2026 20:14:31 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xLB9i-0004OD-18; Sun, 25 Oct 2026 23:13:50 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xLB9f-0004NM-2d; Sun, 25 Oct 2026 23:13:47 -0400 Received: from mxhk.zte.com.cn ([160.30.148.34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xLB9c-0006K1-5W; Sun, 25 Oct 2026 23:13:46 -0400 Received: from mse-fl2.zte.com.cn (unknown [10.5.228.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mxhk.zte.com.cn (FangMail) with ESMTPS id 4jCdxY2dz7z5B0x1; Mon, 26 Oct 2026 11:13:37 +0800 (CST) Received: from szxlzmapp02.zte.com.cn ([10.5.231.79]) by mse-fl2.zte.com.cn with SMTP id 69Q3DPGo083166; Mon, 26 Oct 2026 11:13:25 +0800 (+08) (envelope-from wang.yechao255@zte.com.cn) Received: from localhost.localdomain (unknown [10.234.74.162]) by smtp (Zmail) with SMTP; Mon, 26 Oct 2026 11:13:26 +0800 X-Zmail-TransId: 3e816adec555027-03bfa X-Zmail-LocalSMTP: 1 X-ZMAIL-USEORIGINALEMLTOOUTBOUND: 1 X-Zmail-RealSender: wang.yechao255@zte.com.cn From: Wang Yechao To: Palmer Dabbelt , Alistair Francis Cc: Weiwei Li , Daniel Henrique Barboza , Liu Zhiwei , Chao Liu , qemu-riscv@nongnu.org, qemu-devel@nongnu.org, Wang Yechao Subject: [PATCH v2] target/riscv: Remove unused MMU_USER_IDX macro Date: Mon, 26 Oct 2026 11:11:40 +0800 Message-ID: <20261026031144.631964-1-wang.yechao255@zte.com.cn> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-MAIL: mse-fl2.zte.com.cn 69Q3DPGo083166 X-TLS: YES X-ENVELOPE-SENDER: wang.yechao255@zte.com.cn X-SOURCE-IP: 10.5.228.133 unknown Mon, 26 Oct 2026 11:13:37 +0800 X-CLEAN: YES X-Fangmail-Anti-Spam-Filtered: true X-Fangmail-MID-QID: 6ADEC561.000/4jCdxY2dz7z5B0x1 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=lists1p.gnu.org; Received-SPF: pass client-ip=160.30.148.34; envelope-from=wang.yechao255@zte.com.cn; helo=mxhk.zte.com.cn 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, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development 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-ZM-MESSAGEID: 1792984473678158500 Content-Type: text/plain; charset="utf-8" MMU_USER_IDX is not used anywhere in the tree. Its value is also incorrect: it is defined as 3, while the user-mode MMU index is MMUIdx_U(0), as defined in target/riscv/internals.h. Since the macro is both unused and wrong, remove it rather than fix its value. Signed-off-by: yechao-w Reviewed-by: Daniel Henrique Barboza Reviewed-by: Alistair Francis --- Changes in v2: - Adjust the patch descriptions and rebased on riscv-to-apply.next. - Link to v1: https://lore.kernel.org/qemu-devel/20260107161336108RbvgIEJ1p= ww_fKZtMreFp@zte.com.cn/ target/riscv/cpu.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/target/riscv/cpu.h b/target/riscv/cpu.h index b65d631994..df7477fc5f 100644 --- a/target/riscv/cpu.h +++ b/target/riscv/cpu.h @@ -180,8 +180,6 @@ extern RISCVCPUImpliedExtsRule *riscv_multi_ext_implied= _rules[]; =20 #define RISCV_IMPLIED_EXTS_RULE_END -1 =20 -#define MMU_USER_IDX 3 - #if !defined(CONFIG_USER_ONLY) #include "tcg/pmp.h" #endif --=20 2.27.0