From nobody Fri Dec 19 17:15:31 2025 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=mail.uni-paderborn.de ARC-Seal: i=1; a=rsa-sha256; t=1590737104; cv=none; d=zohomail.com; s=zohoarc; b=kr8ptm+85KYQpAE6VJ4pJLoSkWuOhZ/ucA2O02/B3hu/xygTOznerDYgfQsFLfoaYBwt8Yz7qtX2rQfO/VwMpJ42eM7AQRw1uozBWbXXye74VOgIHY5IhgzPlgTJAGoESsSrve5wOMv0qV5mVQEgXjDP5saK1akdxKkxGfjUAu4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1590737104; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=rx0jqlG7DVmqPjDtdv6JC7rI8sWvslCr0TIEyBBtzh0=; b=nyEZqbCcWa4t1DfNIpChL/3nHugr1PNZNZObIHr5+x1B7O/Sj/VG8yvwM0DbhlFv0xSNHDW5J8pys5NR/use1rrgtK4+LsMnU620BfXvhJVWssfYyHByfMA6ty9k7yGa+FC4x67rAgxMNMcYqutnumERvs8/yhPrnEfLhRnc4IY= ARC-Authentication-Results: i=1; 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 header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1590737104036398.58927557688514; Fri, 29 May 2020 00:25:04 -0700 (PDT) Received: from localhost ([::1]:56746 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jeZO2-0006b5-PX for importer@patchew.org; Fri, 29 May 2020 03:25:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:44470) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jeZLJ-0002dL-CT for qemu-devel@nongnu.org; Fri, 29 May 2020 03:22:13 -0400 Received: from doohan.uni-paderborn.de ([2001:638:502:c003::16]:58556) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jeZLH-0000ep-8v for qemu-devel@nongnu.org; Fri, 29 May 2020 03:22:12 -0400 Received: from diego.uni-paderborn.de ([131.234.189.25] helo=localhost.localdomain) by mail.uni-paderborn.de with esmtp (Exim 4.93 doohan) id 1jeZLE-000ReP-J2 for qemu-devel@nongnu.org; Fri, 29 May 2020 09:22:08 +0200 Received: from mail.uni-paderborn.de by diego with queue id 675715-1 for qemu-devel@nongnu.org; Fri, 29 May 2020 07:22:07 GMT X-Envelope-From: From: Bastian Koppelmann To: qemu-devel@nongnu.org Subject: [PATCH v2 4/5] target/tricore: Implement tricore_cpu_get_phys_page_debug Date: Fri, 29 May 2020 09:21:47 +0200 Message-Id: <20200529072148.284037-5-kbastian@mail.uni-paderborn.de> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200529072148.284037-1-kbastian@mail.uni-paderborn.de> References: <20200529072148.284037-1-kbastian@mail.uni-paderborn.de> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-PMX-Version: 6.4.9.2830568, Antispam-Engine: 2.7.2.2107409, Antispam-Data: 2020.5.29.71818, AntiVirus-Engine: 5.74.0, AntiVirus-Data: 2020.5.28.5740003 X-Sophos-SenderHistory: ip=2a02:908:2214:e5bc::95d, fs=6374311, da=78345992, mc=154, sc=3, hc=151, sp=1, fso=6374311, re=0, sd=0, hd=0 X-IMT-Spam-Score: 0.0 () X-IMT-Authenticated-Sender: 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=2001:638:502:c003::16; envelope-from=kbastian@mail.uni-paderborn.de; helo=doohan.uni-paderborn.de X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: kbastian@mail.uni-paderborn.de Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" this also removes tricore_cpu_get_phys_page_attrs_debug() as it was a temporary fix from b190f477e29c7cd03a8fee49c96d27f160e3f5b0. Signed-off-by: Bastian Koppelmann Reviewed-by: Richard Henderson --- target/tricore/cpu.c | 10 +--------- target/tricore/helper.c | 13 +++++++++++++ 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c index 743b404a95..c8c1e9e7d5 100644 --- a/target/tricore/cpu.c +++ b/target/tricore/cpu.c @@ -23,14 +23,6 @@ #include "exec/exec-all.h" #include "qemu/error-report.h" =20 -static hwaddr tricore_cpu_get_phys_page_attrs_debug(CPUState *cpu, vaddr a= ddr, - MemTxAttrs *attrs) -{ - error_report("function cpu_get_phys_page_attrs_debug not " - "implemented, aborting"); - return -1; -} - static inline void set_feature(CPUTriCoreState *env, int feature) { env->features |=3D 1ULL << feature; @@ -161,7 +153,7 @@ static void tricore_cpu_class_init(ObjectClass *c, void= *data) cc->dump_state =3D tricore_cpu_dump_state; cc->set_pc =3D tricore_cpu_set_pc; cc->synchronize_from_tb =3D tricore_cpu_synchronize_from_tb; - cc->get_phys_page_attrs_debug =3D tricore_cpu_get_phys_page_attrs_debu= g; + cc->get_phys_page_debug =3D tricore_cpu_get_phys_page_debug; cc->tcg_initialize =3D tricore_tcg_init; cc->tlb_fill =3D tricore_cpu_tlb_fill; } diff --git a/target/tricore/helper.c b/target/tricore/helper.c index d5db7b2c03..7715293263 100644 --- a/target/tricore/helper.c +++ b/target/tricore/helper.c @@ -42,6 +42,19 @@ static int get_physical_address(CPUTriCoreState *env, hw= addr *physical, =20 return ret; } + +hwaddr tricore_cpu_get_phys_page_debug(CPUState *cs, vaddr addr) +{ + TriCoreCPU *cpu =3D TRICORE_CPU(cs); + hwaddr phys_addr; + int prot; + int mmu_idx =3D cpu_mmu_index(&cpu->env, false); + + if (get_physical_address(&cpu->env, &phys_addr, &prot, addr, 0, mmu_id= x)) { + return -1; + } + return phys_addr; +} #endif =20 /* TODO: Add exeption support*/ --=20 2.26.2