From nobody Tue Nov 26 14:39:23 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; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1706853317; cv=none; d=zohomail.com; s=zohoarc; b=QSo2VHg1gye+80nW01gtwtHhr84DT1wVBt6aQIFAALPfPIrzeNzgwJ6cWnWsNnyT3VZB9Mowl9IwO9FMh+npc75d/EWVjVrMNWIvny8+TB9t2hoLUK/vCvj5FPlhg2dwdiI0X7FYVR+n991uXc/Ls2nZLZ2DaMeqRqeg4FLqbuc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1706853317; h=Content-Type: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=nhzLuFE6ppEoB9HS2thFYeCAmUg0HDDP2UuzU+1BEtw=; b=dogUCGrEUHPg2fCB9vb+8IaLTRrShqWycACK86eddR5/bvVlc9v2a+vOPI425KiVWaPfCQwJCLg5j9TyrIshVd+XaworHZxy23X6o5B6XYpCmf/wiykgB2S3XAPVslV0mgSbIIaxnrAnSkKgNw0xSEhCnHQagnvOlVwvC3OOngM= 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; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1706853317459509.27438391501926; Thu, 1 Feb 2024 21:55:17 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rVmSp-0001X8-9Y; Fri, 02 Feb 2024 00:51:47 -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 1rVmSl-0001Tl-NS for qemu-devel@nongnu.org; Fri, 02 Feb 2024 00:51:43 -0500 Received: from mail-pg1-x52a.google.com ([2607:f8b0:4864:20::52a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rVmSd-0001uS-4x for qemu-devel@nongnu.org; Fri, 02 Feb 2024 00:51:36 -0500 Received: by mail-pg1-x52a.google.com with SMTP id 41be03b00d2f7-5dbcfa0eb5dso1574254a12.3 for ; Thu, 01 Feb 2024 21:51:34 -0800 (PST) Received: from stoup.. ([103.210.27.218]) by smtp.gmail.com with ESMTPSA id h2-20020aa79f42000000b006dab0d72cd0sm715111pfr.214.2024.02.01.21.51.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Feb 2024 21:51:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1706853094; x=1707457894; 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=nhzLuFE6ppEoB9HS2thFYeCAmUg0HDDP2UuzU+1BEtw=; b=YWJwQaqUGG9/Pdi9n/oxDcu9xArWNDKB9jSAE3GpviaybjFCPUPeu+Ota9Ps2u6B5y NVjW+Hy/t6LAy/zG+gsg03aBYl/1XNCthRa6rfVCZjekeOactX7LEmiNt6QwxBlEocaG wlADygSZatgDYGLAKDrw7SE9W5KB+xc9zUVOMPCXkCsO2t9iA3MPxcQYHSF/9ayB8R4M Q9xdclevjE4sIxkZAVDulANYJHy4TRaA/OR3eHOvd1/1FdmQXZlUIGODv+C6q6i3q+kn JodiOmzzO88DOKJTxp4plbx6RnuYhtXnRypexHl53Mq34JNaLZ/es2+OzTiaX1KVrrUQ 7tVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706853094; x=1707457894; 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=nhzLuFE6ppEoB9HS2thFYeCAmUg0HDDP2UuzU+1BEtw=; b=gJemvN/DarsmzHJ8P+8TXEj+4bMug3TBRzPiiujSjJD49Wu7XmlW8roIIWdaGRVZ/z ZDqAdGzVdayeeiKpEaUZ4L/YEkahexa3zm3+uuchiiZw4ZneTEyQqdGmFjpjOjvg/Ulq zXGrnMDDN9Gh72ZqzyvDdCnfIaDKRTVa95Qv87koZrupUtpxuaP07X3itmht4eNdEs48 KMxJ9c2xY73+5VGecE8zQo7n0Qi4XLqPKdOEepemrCpFVjuVkMkXWA6KCqTzT4lIIddR ndE4EQZIE+m1W+K7vfioAIwV65rDCbqs7/OodBEUNNuOp7AvOxZ7A2jNeWb4NAnHg4Zn Iuiw== X-Gm-Message-State: AOJu0YxyLiRKb2rmA6lL6lTwYBAbnaec3/IGun6CPo3MHUlcoe4Sn5+f URoysphe4C4FPN1WBjMrQx8Vsd7GW2cHy0MLMiDxqJ9DZReiyTgb8ZdC3b99JeQUaEgLnB/zlXZ swLI= X-Google-Smtp-Source: AGHT+IEQ5ur0SDJGpEZGK38nwTFwOsuQq5IoG2dpLXJ8pschrEffkAaIJt3U7RahC3AD4AlZSWFgJA== X-Received: by 2002:a05:6a20:c61e:b0:19c:b3ea:27ba with SMTP id gp30-20020a056a20c61e00b0019cb3ea27bamr6570462pzb.52.1706853093781; Thu, 01 Feb 2024 21:51:33 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCWlKY66yzftTQ1Yd01vuQCQGZeRwDkPucpH7hbRPPsDjGVBYMZljz8PJKhNRKYtM6FGx4wL0MWXS/2Z6mfQ5gngog== From: Richard Henderson To: qemu-devel@nongnu.org Cc: Alistair Francis , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 24/57] target/riscv: Populate CPUClass.mmu_index Date: Fri, 2 Feb 2024 15:50:03 +1000 Message-Id: <20240202055036.684176-26-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240202055036.684176-1-richard.henderson@linaro.org> References: <20240202055036.684176-1-richard.henderson@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" 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::52a; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x52a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-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=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: 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 @linaro.org) X-ZM-MESSAGEID: 1706853318901100003 Reviewed-by: Alistair Francis Reviewed-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Richard Henderson --- target/riscv/cpu.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/target/riscv/cpu.c b/target/riscv/cpu.c index 8cbfc7e781..be21fa09c6 100644 --- a/target/riscv/cpu.c +++ b/target/riscv/cpu.c @@ -867,6 +867,11 @@ static bool riscv_cpu_has_work(CPUState *cs) #endif } =20 +static int riscv_cpu_mmu_index(CPUState *cs, bool ifetch) +{ + return riscv_env_mmu_index(cpu_env(cs), ifetch); +} + static void riscv_cpu_reset_hold(Object *obj) { #ifndef CONFIG_USER_ONLY @@ -1810,6 +1815,7 @@ static void riscv_cpu_class_init(ObjectClass *c, void= *data) =20 cc->class_by_name =3D riscv_cpu_class_by_name; cc->has_work =3D riscv_cpu_has_work; + cc->mmu_index =3D riscv_cpu_mmu_index; cc->dump_state =3D riscv_cpu_dump_state; cc->set_pc =3D riscv_cpu_set_pc; cc->get_pc =3D riscv_cpu_get_pc; --=20 2.34.1