From patchwork Mon Jan 29 23:30:27 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 767491 Delivered-To: patch@linaro.org Received: by 2002:adf:ee41:0:b0:33a:e5bd:fedd with SMTP id w1csp1127961wro; Mon, 29 Jan 2024 15:39:53 -0800 (PST) X-Google-Smtp-Source: AGHT+IFqk2PAXwZjPXVhL+6bs9xeaLgvw1Laq2wAQWlJ40ODY9RgDuQrFwMasNOhSfeN5Ve1OR+R X-Received: by 2002:a05:622a:449:b0:42a:6ce0:68c7 with SMTP id o9-20020a05622a044900b0042a6ce068c7mr8437680qtx.100.1706571592958; Mon, 29 Jan 2024 15:39:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1706571592; cv=none; d=google.com; s=arc-20160816; b=MDJnmn5AEqGHd5t/Hb9dUzSXOh6CsRVu6q+ZBCjOWCpg12zeD+t0ElxXdyQ/GLv2r8 CQrzpIgC/tf+YQ7jUiJMoCneGqOQj7qRzL6kyR4ceo4MNW3ag36kQ6nKrsO//st0j6DU Xl+GYC7TWyzprpZLEg9rwFrqkTO2drOMnygyvs67wMy+jLJ5KJWE22QBeRu/tg0PhRJj osBINbc1PZ4shwRRY+5Pq9l9obrqw3B9qMcMaNEVDAj+LB1d08zIBf5ps8YliMnO2sud SNCNYQZvvcl0HemgCARV3iGrIaM48VJM/7FHqNdv9Nl4XfvMVlshmzSnw3Cd56RpKE1b 7sqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=p6rIUVmiCr2QYJOV/5BC5dQis1VA2kzsAKeuwEUc9C4=; fh=d3q967Ss27yOZEBNWb7WV1pwIIYORDjfLhLmomzC17w=; b=z4RsbA22ijSNP5dxVRcKmIyzMoWRtwIt0S9kyAt09wgoSn9GHc2GRMkwZlrSaZqNCY jRscKgckrc++ASIAC0FkzRnXzIrFMA7lFjCZyiZLDQq+OVH1Ii45qAqYOkObgNR15I9j wwxaE+vOHC2YtTRGYNfX71yqIuta5Y9K8VbPpsrdcZ8wg/VKlK8dP4axf7DLPR3e6Exb YeT2WDWxbIBNJxcI99lestTtFuNQgPoQcJkfuH0QI/Bhg3hfPxTdaB3srNDKFrkAC4aj /5b9QA2ua+XpfJ86VZU1V0RaCSv61J08SJ0BUFHsId3FvOnjbAc4fr+1Itn8qVCn9sZJ D/uA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZfNd6T1j; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id o13-20020ac87c4d000000b0042ab4f896dasi360175qtv.469.2024.01.29.15.39.52 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 29 Jan 2024 15:39:52 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZfNd6T1j; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rUb6D-0005qU-Hp; Mon, 29 Jan 2024 18:31:33 -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 1rUb69-0005ll-V8 for qemu-devel@nongnu.org; Mon, 29 Jan 2024 18:31:30 -0500 Received: from mail-pl1-x62d.google.com ([2607:f8b0:4864:20::62d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rUb68-000561-Bj for qemu-devel@nongnu.org; Mon, 29 Jan 2024 18:31:29 -0500 Received: by mail-pl1-x62d.google.com with SMTP id d9443c01a7336-1d8ef972451so6312775ad.2 for ; Mon, 29 Jan 2024 15:31:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1706571087; x=1707175887; 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=p6rIUVmiCr2QYJOV/5BC5dQis1VA2kzsAKeuwEUc9C4=; b=ZfNd6T1jpdTRlXn2WntN3L60w9JklpPPdWBlBjCm5L94DcfjHABBKp26Tz5yMBpJlP 6AoXAwvq7B+3NoBPjGotAvp2AzijY55j7YS3QBxOoLUNdpRj7n7kDu0Qe+fG0yal94eC I2Ar1AKANkYVcA83C6qSY638WwhbkHrnrHt5JyBsHd4eS0ktFqmJsaHOS864lT1mjMlp 58Bbj+f+GVT972zKG4P/7BJbvRpJlLAHwe2zU7XYaDIY+1fp7O3spRypSoE0BblnnSk4 inyE4K1MRYOpUimuZ6vOXfq+R+Vh2dtzTZpmLZGH0FICgA6R0TRB4TJ/O4NXC2Cns8X5 UbZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706571087; x=1707175887; 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=p6rIUVmiCr2QYJOV/5BC5dQis1VA2kzsAKeuwEUc9C4=; b=Rirh/Hvval5lo8ETXGFJ8VCfARGNyCttQHVoV+VVe7stwYglhK5RetMkL4g+ql07Br aJ2iOs/eryNoDkR7Qapv5AirPTe9yhM9VT9A8Q1Mbz0PzhZuhrHuui3/3dmr9dzpprM1 y3+n+s0wBFplEA1AOHSDTnAo5dZaCK8ZHOQFzxXYiWlyl8DycWruzRQROyiAa3ao5ggG 0xBTR5WXC0fakWaokAvGt9QCYs/xoown8q5PiuQ9Q9lP6r1BjK/dqwdaQu+ahnjiCpV+ q20lTCLVdyQthnp4gUEIrw/VguS3hhfYyGWs1VUkPlqfubl7pso6OpfZEDWatoQWiJDj oGOw== X-Gm-Message-State: AOJu0YxTtUxfqFvLEbXQVrr9gzl5zE6bol2jQfhyP4/ALARqTKAnEZaf /vrGWUDWSe3Ob2jimQC+PrlOJEts+D3Escl5Nlk87eWnpUgmGkicbGa9iRGft/3gC+YA0rK+mBE ur/g= X-Received: by 2002:a17:902:d4d0:b0:1d3:45c8:bc0f with SMTP id o16-20020a170902d4d000b001d345c8bc0fmr4325004plg.46.1706571087108; Mon, 29 Jan 2024 15:31:27 -0800 (PST) Received: from stoup.. ([103.210.27.218]) by smtp.gmail.com with ESMTPSA id l6-20020a170902eb0600b001d8dbb867b1sm2710591plb.179.2024.01.29.15.31.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Jan 2024 15:31:26 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: philmd@linaro.org, anjo@rev.ng Subject: [PATCH 17/33] target/mips: Populate CPUClass.mmu_index Date: Tue, 30 Jan 2024 09:30:27 +1000 Message-Id: <20240129233043.34558-18-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240129233043.34558-1-richard.henderson@linaro.org> References: <20240129233043.34558-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62d; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x62d.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson --- target/mips/cpu.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/target/mips/cpu.c b/target/mips/cpu.c index df544ab39b..d644adbc77 100644 --- a/target/mips/cpu.c +++ b/target/mips/cpu.c @@ -182,6 +182,11 @@ static bool mips_cpu_has_work(CPUState *cs) return has_work; } +static int mips_cpu_mmu_index(CPUState *cs, bool ifunc) +{ + return mips_env_mmu_index(cpu_env(cs)); +} + #include "cpu-defs.c.inc" static void mips_cpu_reset_hold(Object *obj) @@ -579,6 +584,7 @@ static void mips_cpu_class_init(ObjectClass *c, void *data) cc->class_by_name = mips_cpu_class_by_name; cc->has_work = mips_cpu_has_work; + cc->mmu_index = mips_cpu_mmu_index; cc->dump_state = mips_cpu_dump_state; cc->set_pc = mips_cpu_set_pc; cc->get_pc = mips_cpu_get_pc;