From patchwork Wed Jan 27 22:42:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 12051147 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.5 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9105AC433DB for ; Wed, 27 Jan 2021 22:44:32 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 2F79D64DD8 for ; Wed, 27 Jan 2021 22:44:31 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2F79D64DD8 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=amsat.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:58118 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l4tY7-0007pZ-3r for qemu-devel@archiver.kernel.org; Wed, 27 Jan 2021 17:44:31 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:57650) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l4tWp-0006VR-MO for qemu-devel@nongnu.org; Wed, 27 Jan 2021 17:43:11 -0500 Received: from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f]:35756) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1l4tWo-0001eq-8z for qemu-devel@nongnu.org; Wed, 27 Jan 2021 17:43:11 -0500 Received: by mail-wm1-x32f.google.com with SMTP id e15so3003550wme.0 for ; Wed, 27 Jan 2021 14:43:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=hsf6YslG+iiwGWWyzTzUT651ZdNva63Lvir9YoamAx4=; b=K8EQn8GTmUm9OhKOy8D8hABbFns8fRdgboTQVFsPW8omlNRQD/s3q5hL3vAgV5CVid l/v+79k8vQpxYwkkNRYAidgKt9h7YbbLkQa7p/qbtcafQ33ZpQ53koAU6rvieSCbf/d2 fRWtX9BWwYelWexOS6FgW1rRz2d8Bl2kxTXeyEnXizIl1oWJLPH8W5JbTvBFqvTnQgRP bOJ1pLhYHMFfJUqeTQWzuIiX9kGssWnTc6DiqfUYjDxqycRol0xQNC/xw8ecRA9ON+h0 OGa+72Ih9SdA3Ip8+NTIYHoEb/gpaBO88EZlZ9dR2nzOLiQeEMtCyB+tNcEdAVnenJeH pkBQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=hsf6YslG+iiwGWWyzTzUT651ZdNva63Lvir9YoamAx4=; b=e2xAFHY5GrBoA0liM9IeYG8WLqu0Fd6Xp1oN4S2nXo59QtXS761OITPtRkTKN2zDrl PJGvX86df1+Zq/wM6l9Me8lWlKVXxCHRt3vjqpfiBJXeZCV3Ziw7RCECze+BayT8nOGd rxGkQE5m2yyvJjC7tzeI57667SMU7noluS4zcaoo7bEgjU/lgpYtyEfMOhIf9yz5lZqd MutJqlFujuelHkt4aRfESn8bBpcx9YmUQZ/OQCBhDrf+HrMU0nb9S6ffDNZ8uJMWUDaC brweXIgOAW9RbJT9OF5kOelzNJfZFCJprbCx93YIjbW2z00U3SpMenQ+EqSsJQ0CL3r5 uTVw== X-Gm-Message-State: AOAM532gKrAy9hkVUnRNaUhDpdIdh/EJYZ6Gw7vx1J3Gh3RFAnoR1kI9 +FOZxToJHrchnatAIBu+WckBde42iJk= X-Google-Smtp-Source: ABdhPJxefUx5HtYSGlomhi3A2311yHC3rNT8NTLgzr2dvatp6hP23xr0pW5S1FKBRXURA0y+/rhZgg== X-Received: by 2002:a1c:df08:: with SMTP id w8mr5797209wmg.81.1611787388638; Wed, 27 Jan 2021 14:43:08 -0800 (PST) Received: from localhost.localdomain (13.red-83-57-169.dynamicip.rima-tde.net. [83.57.169.13]) by smtp.gmail.com with ESMTPSA id q9sm4331552wme.18.2021.01.27.14.43.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Jan 2021 14:43:08 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH 2/3] target/tricore: Pass MMUAccessType to get_physical_address() Date: Wed, 27 Jan 2021 23:42:54 +0100 Message-Id: <20210127224255.3505711-3-f4bug@amsat.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20210127224255.3505711-1-f4bug@amsat.org> References: <20210127224255.3505711-1-f4bug@amsat.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32f; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wm1-x32f.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no 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: Bastian Koppelmann , Richard Henderson , =?utf-8?q?Philippe_Mathie?= =?utf-8?q?u-Daud=C3=A9?= , Joe Komlodi , David Brenken , Andreas Konopik Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" 'int access_type' and ACCESS_INT are unused, drop them. Provide the mmu_idx argument to match other targets. 'int rw' is actually the MMUAccessType, rename it. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Bastian Koppelmann --- target/tricore/helper.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/target/tricore/helper.c b/target/tricore/helper.c index 81171db833b..c5e997f3215 100644 --- a/target/tricore/helper.c +++ b/target/tricore/helper.c @@ -33,7 +33,7 @@ enum { #if defined(CONFIG_SOFTMMU) static int get_physical_address(CPUTriCoreState *env, hwaddr *physical, int *prot, target_ulong address, - int rw, int access_type) + MMUAccessType access_type, int mmu_idx) { int ret = TLBRET_MATCH; @@ -72,13 +72,11 @@ bool tricore_cpu_tlb_fill(CPUState *cs, vaddr address, int size, CPUTriCoreState *env = &cpu->env; hwaddr physical; int prot; - int access_type; int ret = 0; rw &= 1; - access_type = ACCESS_INT; ret = get_physical_address(env, &physical, &prot, - address, rw, access_type); + address, rw, mmu_idx); qemu_log_mask(CPU_LOG_MMU, "%s address=" TARGET_FMT_lx " ret %d physical " TARGET_FMT_plx " prot %d\n",