From nobody Wed Nov 27 10:45:35 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=1699896857; cv=none; d=zohomail.com; s=zohoarc; b=NBMTW0fSJ3JFGpP9vLjCSr3xyNlc4Pk6DU14UKbCEm5h/PjUYbhXXnLtIfHkELgiJboMRvn7c3B82FOaKcNP3X3YIprZTVU6xH1ah7iWymGzsTtKbwStvlJ5fQhZhjDw2boC1NPlq8dTe57+X4ingcjtKRW9ElaosVJLXgpj90w= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1699896857; h=Content-Transfer-Encoding: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:Cc; bh=lo0lQlUWSBjMt9Vl8JT1SFLp9AI2+HeOXlIlVWGHESw=; b=DswFkr1CKqXGV3E8Z0VxChvSNb/xAznSlAljK9gF5BJ0NF9nvCfarLDkmebMAPeYChg6lglC9x12/11eyocU8CswWXMpfJDu8cIuy77m9dBnL6HFKip2f/MjJmjglwZkqRTLTYemoof1tlUX4Gk3FOriQntAyEnS6lpmNej4rJ0= 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 1699896857389369.97087707941114; Mon, 13 Nov 2023 09:34:17 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r2anp-0001Sj-Pz; Mon, 13 Nov 2023 12:32:49 -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 1r2ann-0001SE-Fh for qemu-devel@nongnu.org; Mon, 13 Nov 2023 12:32:47 -0500 Received: from mail-pl1-x636.google.com ([2607:f8b0:4864:20::636]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r2anj-0000v3-Q5 for qemu-devel@nongnu.org; Mon, 13 Nov 2023 12:32:47 -0500 Received: by mail-pl1-x636.google.com with SMTP id d9443c01a7336-1cc938f9612so28898165ad.1 for ; Mon, 13 Nov 2023 09:32:43 -0800 (PST) Received: from stoup.. ([71.212.149.95]) by smtp.gmail.com with ESMTPSA id e6-20020a170902d38600b001c731b62403sm4271910pld.218.2023.11.13.09.32.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Nov 2023 09:32:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1699896761; x=1700501561; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=lo0lQlUWSBjMt9Vl8JT1SFLp9AI2+HeOXlIlVWGHESw=; b=ieR7ZysYVpogFKfFx/fUMlikQ2yy9HgJ7G4B800slT2knetGrikwZ+Q+rT2OSx/pYY a9xfQDmJUEp/rPjX0Ux0iQVfWOL0mRiQexMzzeFpQhyIKn1b0Dt8dkmOo4tYHZQtUFCC JmSvDM0yBNmvVCcFlX06Hlbhp1aMhT7ZNFTO8XvJpBs4WcnIgzssUldqcL74lwO1sKze dF0WUWV7yOFKmRhFtPodS9uiED9b/c/ZVLadtwT7irBFnAyNsgGskUd10pacA7OB8XnV tKOJtb58QHef190H44JIYh5Q5QVU4GAK8p9tJXBrDNOzS5hhaQJ7g/+Qxs4OuBDPQXgS Rn7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699896761; x=1700501561; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=lo0lQlUWSBjMt9Vl8JT1SFLp9AI2+HeOXlIlVWGHESw=; b=DmL8uDiJC6Tied3nQ8cVZd7o05rzzsfILSH0Ojzq4bHgdW4/uEesYiIouourN1PJz/ QWzZDXijk0InGPMd6kO9zzn8BcaMSncJyd7U0nZg71U5T3wQFHfKjX6ehMJH+M4/fhKS LRFyXZH0ttVRK5mqjy0Dfqr2eU24Z/tO74+emmwtMUe6j0oMutuEFPLXYxSRu5oghiGL qe3pv+/eImRI80HtQXJCuq3VtjGPfOfF08sjbpYO8cIFGn4L0cdJ20sBTlpP7SH8RYhF g3CtA61r3W4/6Wbpwz1PjqrTkJ6dpoIid2phc9s9InwF2YEcOTvvdC1GZF27S1xafd6i 6q+g== X-Gm-Message-State: AOJu0Yw+wyBh0sQKzX6tJd8L1bLYAxHk27WmgkB4l5NCn4u0EpW0BAK+ EyRdySeHviYunVafZ6suztacnPuDXriGxBJyzY8= X-Google-Smtp-Source: AGHT+IHpAyrs/W0P68TiJcV3VNIxJxkIzzJHbPWNG9shmpCdqOTZ6pDZfv8qP/+zaN1kw1q4dZDeXA== X-Received: by 2002:a17:902:8201:b0:1ce:a0b:7314 with SMTP id x1-20020a170902820100b001ce0a0b7314mr215816pln.61.1699896761208; Mon, 13 Nov 2023 09:32:41 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 03/12] target/hppa: Use PRIV_P_TO_MMU_IDX in helper_probe Date: Mon, 13 Nov 2023 09:32:28 -0800 Message-Id: <20231113173237.48233-4-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231113173237.48233-1-richard.henderson@linaro.org> References: <20231113173237.48233-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::636; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x636.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: 1699896857933100001 Content-Type: text/plain; charset="utf-8" Direct privilege level to mmu_idx mapping has been false for some time. Provide the correct value to hppa_get_physical_address. Fixes: fa824d99f9b ("target/hppa: Switch to use MMU indices 11-15") Signed-off-by: Richard Henderson --- target/hppa/op_helper.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/target/hppa/op_helper.c b/target/hppa/op_helper.c index a0e31c0c25..7f607c3afd 100644 --- a/target/hppa/op_helper.c +++ b/target/hppa/op_helper.c @@ -338,7 +338,7 @@ target_ulong HELPER(probe)(CPUHPPAState *env, target_ul= ong addr, #ifdef CONFIG_USER_ONLY return page_check_range(addr, 1, want); #else - int prot, excp; + int prot, excp, mmu_idx; hwaddr phys; =20 trace_hppa_tlb_probe(addr, level, want); @@ -347,7 +347,8 @@ target_ulong HELPER(probe)(CPUHPPAState *env, target_ul= ong addr, return 0; } =20 - excp =3D hppa_get_physical_address(env, addr, level, 0, &phys, + 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, NULL); if (excp >=3D 0) { if (env->psw & PSW_Q) { --=20 2.34.1