From nobody Sun Nov 24 01:41:01 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=1728142275; cv=none; d=zohomail.com; s=zohoarc; b=juYz+lB8L8mhWUn0OOerW4iwiH4bFUrT8RSgj9+oAR/jQ630crPEsCIQyF8J5b29sk9l49yidET06dN5GoPqDWbQqa/1ntGDdcc3kW+G5AVaH0Bz13ac0rcQS0DFi2aRNZUuu61M8z04tFbYDQNWexxHqONtQWgRRdldpHVW+XY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1728142275; h=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=MP+WvwE/XecW9wPOVCpjk+gA5jxWiH/v3HQ4ejXK7hQ=; b=Mvff9Lg32l7+r0iOl7XKPZT01x051OGP4tnfTxqhhRPZAmHTNW9FCSkr9CVGtexKh50rPrg4cXt2PrJlL4KODPztT2zLGcvMxrcC5akipBtz9DLGdbed+SzxR3WNGUWFiAXYKist5/MAq5vLjURLftn5QHg5N3e3ipZrK4krM5A= 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 172814227575050.161618016180455; Sat, 5 Oct 2024 08:31:15 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sx6fX-00024d-HD; Sat, 05 Oct 2024 11:26:07 -0400 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 1sx6fT-00021j-PC for qemu-devel@nongnu.org; Sat, 05 Oct 2024 11:26:03 -0400 Received: from mail-pl1-x62e.google.com ([2607:f8b0:4864:20::62e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sx6fS-0002Mm-3D for qemu-devel@nongnu.org; Sat, 05 Oct 2024 11:26:03 -0400 Received: by mail-pl1-x62e.google.com with SMTP id d9443c01a7336-20b90984971so32650785ad.3 for ; Sat, 05 Oct 2024 08:26:01 -0700 (PDT) Received: from stoup.. (174-21-81-121.tukw.qwest.net. [174.21.81.121]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-20c1396948dsm14351765ad.225.2024.10.05.08.25.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 05 Oct 2024 08:26:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1728141960; x=1728746760; 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=MP+WvwE/XecW9wPOVCpjk+gA5jxWiH/v3HQ4ejXK7hQ=; b=PD9InbelSTBbSyJQhO2yBhjfv6quspqR+hcKBK8xNJQh7SiQ5x16zJul91E/KMn9cE apbtsmFnpLKw+Zqk5SH3KnM/hQ5ZjCC4g/kG0TmnPrM1Pz+yJZ4bVfI3Nvuk/qyO8vfw LbWJ5JIZlCGbGadT0U+n2G932knz+XmtjrxxPrkGrlGZlwbV/oprBYlljocBZ72nxjbt asqgeWZQAsewI4FVTIIZ6F8ZGgQlw82xqN3yuQ/u2IZLV0oJIso7CdsXUnjIUL4WX+RQ gYikTvGLG/FiXCwhPQGnQIWifKFHplP8fQw6OXJDoL2dyUuCoGnot+uLmk5d7n2xz1+g umJg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728141960; x=1728746760; 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=MP+WvwE/XecW9wPOVCpjk+gA5jxWiH/v3HQ4ejXK7hQ=; b=jx8+nV4E59yswRl++f81Niahqc/nLKnexx83Kx262BNAyHRSs3kvpWKie0x+RmFgkO h7eVxlkebUDrqLSey2TDecSnJeuVuOQHbIxAdEkIDcLdvr+LWB2dgk3L6M66EQn8kmSe TmCtuSsFg1/d+vgnk6NGbHmwbysx4L4qby24r+LZzqYlLA/00O7okgfz+fgJYRx2iY+E xwuD7lEI3eSA8r4yKPImd92pQMHJuzb7dRyrLqNXHEcHP/WWVJz6LpYl61sjMZ0PQ9Qt sKP2AMArFrKarTOa4DXwGKYG8BjKsxGh5OC9kQnlswHTqEpr4LIKAX8NbQwnpCyT1xsu hWlg== X-Gm-Message-State: AOJu0YyG1Z1MaqttcY9VoTT1+LujbUuCVqwWEeDRGzq/ncufCeboB3cT FUZEZZt+6GLcDDtwxsldHoLYakD/SDIADvN2LdPwtuOPfSer4YarX9JRAApwpIJwnFr0kUhnfJ8 U X-Google-Smtp-Source: AGHT+IESYzC42ts/+MgAFBURTMzI6DPqe+lqay1qM2V34nvaOe/CY71VOZQTw0rCb6RzMXOSgxY+yw== X-Received: by 2002:a17:902:db02:b0:20b:ba72:37c with SMTP id d9443c01a7336-20bfea542c6mr100209775ad.48.1728141960541; Sat, 05 Oct 2024 08:26:00 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: deller@kernel.org, peter.maydell@linaro.org, alex.bennee@linaro.org, linux-parisc@vger.kernel.org, qemu-arm@nongnu.org Subject: [PATCH 08/20] target/hppa: Add MemOp argument to hppa_get_physical_address Date: Sat, 5 Oct 2024 08:25:39 -0700 Message-ID: <20241005152551.307923-9-richard.henderson@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20241005152551.307923-1-richard.henderson@linaro.org> References: <20241005152551.307923-1-richard.henderson@linaro.org> MIME-Version: 1.0 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::62e; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x62e.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 autolearn=unavailable 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: 1728142276244116600 Content-Type: text/plain; charset="utf-8" Just add the argument, unused at this point. Zero is the safe do-nothing value for all callers. Signed-off-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- target/hppa/cpu.h | 2 +- target/hppa/int_helper.c | 2 +- target/hppa/mem_helper.c | 9 +++++---- target/hppa/op_helper.c | 2 +- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/target/hppa/cpu.h b/target/hppa/cpu.h index f4e051f176..526855f982 100644 --- a/target/hppa/cpu.h +++ b/target/hppa/cpu.h @@ -369,7 +369,7 @@ bool hppa_cpu_tlb_fill(CPUState *cs, vaddr address, int= size, void hppa_cpu_do_interrupt(CPUState *cpu); bool hppa_cpu_exec_interrupt(CPUState *cpu, int int_req); int hppa_get_physical_address(CPUHPPAState *env, vaddr addr, int mmu_idx, - int type, hwaddr *pphys, int *pprot); + int type, MemOp mop, hwaddr *pphys, int *ppr= ot); void hppa_cpu_do_transaction_failed(CPUState *cs, hwaddr physaddr, vaddr addr, unsigned size, MMUAccessType access_type, diff --git a/target/hppa/int_helper.c b/target/hppa/int_helper.c index 391f32f27d..58695def82 100644 --- a/target/hppa/int_helper.c +++ b/target/hppa/int_helper.c @@ -167,7 +167,7 @@ void hppa_cpu_do_interrupt(CPUState *cs) =20 vaddr =3D hppa_form_gva_psw(old_psw, env->iasq_f, vadd= r); t =3D hppa_get_physical_address(env, vaddr, MMU_KERNEL= _IDX, - 0, &paddr, &prot); + 0, 0, &paddr, &prot); if (t >=3D 0) { /* We can't re-load the instruction. */ env->cr[CR_IIR] =3D 0; diff --git a/target/hppa/mem_helper.c b/target/hppa/mem_helper.c index b984f730aa..a386c80fa4 100644 --- a/target/hppa/mem_helper.c +++ b/target/hppa/mem_helper.c @@ -197,7 +197,7 @@ static int match_prot_id64(CPUHPPAState *env, uint32_t = access_id) } =20 int hppa_get_physical_address(CPUHPPAState *env, vaddr addr, int mmu_idx, - int type, hwaddr *pphys, int *pprot) + int type, MemOp mop, hwaddr *pphys, int *ppr= ot) { hwaddr phys; int prot, r_prot, w_prot, x_prot, priv; @@ -340,7 +340,7 @@ hwaddr hppa_cpu_get_phys_page_debug(CPUState *cs, vaddr= addr) mmu_idx =3D (cpu->env.psw & PSW_D ? MMU_KERNEL_IDX : cpu->env.psw & PSW_W ? MMU_ABS_W_IDX : MMU_ABS_IDX); =20 - excp =3D hppa_get_physical_address(&cpu->env, addr, mmu_idx, 0, + excp =3D hppa_get_physical_address(&cpu->env, addr, mmu_idx, 0, 0, &phys, &prot); =20 /* Since we're translating for debugging, the only error that is a @@ -438,7 +438,8 @@ bool hppa_cpu_tlb_fill(CPUState *cs, vaddr addr, int si= ze, break; } =20 - excp =3D hppa_get_physical_address(env, addr, mmu_idx, a_prot, &phys, = &prot); + excp =3D hppa_get_physical_address(env, addr, mmu_idx, a_prot, 0, + &phys, &prot); if (unlikely(excp >=3D 0)) { if (probe) { return false; @@ -678,7 +679,7 @@ target_ulong HELPER(lpa)(CPUHPPAState *env, target_ulon= g addr) hwaddr phys; int prot, excp; =20 - excp =3D hppa_get_physical_address(env, addr, MMU_KERNEL_IDX, 0, + excp =3D hppa_get_physical_address(env, addr, MMU_KERNEL_IDX, 0, 0, &phys, &prot); if (excp >=3D 0) { if (excp =3D=3D EXCP_DTLB_MISS) { diff --git a/target/hppa/op_helper.c b/target/hppa/op_helper.c index 7f79196fff..744325969f 100644 --- a/target/hppa/op_helper.c +++ b/target/hppa/op_helper.c @@ -334,7 +334,7 @@ target_ulong HELPER(probe)(CPUHPPAState *env, target_ul= ong addr, } =20 mmu_idx =3D PRIV_P_TO_MMU_IDX(level, env->psw & PSW_P); - excp =3D hppa_get_physical_address(env, addr, mmu_idx, 0, &phys, &prot= ); + excp =3D hppa_get_physical_address(env, addr, mmu_idx, 0, 0, &phys, &p= rot); if (excp >=3D 0) { cpu_restore_state(env_cpu(env), GETPC()); hppa_set_ior_and_isr(env, addr, MMU_IDX_MMU_DISABLED(mmu_idx)); --=20 2.43.0