From nobody Sun Nov 24 11:34:05 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=1723562797; cv=none; d=zohomail.com; s=zohoarc; b=Ay7GL4TYJeMVJ3/rQ9asmeepDi5WNgPUk4RrNiqQS0AbMEXj5D5XxxFnMw/ljsanZFXqoFkTLL3jYr9s6vOq+SVUOjzQDw23jJIvg5TbjWCrlPinUNUkAHVjhHdKAPQbfYLt6KdX4aBLvkzvAsUncnxErrtWCX+xHK0kSrM+pyQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1723562797; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=cR8DL4fFh9wwc7+M9JHjarbbrgOTCmPyE0fl6m12ljw=; b=mcvOjkba/BHq6ZUrRyOA0gFkMl/W8ClLLB7iI/+NXXKddUouD3Z/jyN1IidIifhvTMfY4GPl+PYxs4j2QjId9ptfMxlSP6Wrb8xfXC/weLKU+v/Y+yocOkuo4XjUlTEh16w9lNXcn7cyiJsWT9131XANE7tjj8SGE+eYInoB/U0= 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 1723562797387381.8240302047402; Tue, 13 Aug 2024 08:26:37 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sdtPk-0002D2-W6; Tue, 13 Aug 2024 11:26:26 -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 1sdtPe-0001uF-UX for qemu-devel@nongnu.org; Tue, 13 Aug 2024 11:26:19 -0400 Received: from mail-wr1-x435.google.com ([2a00:1450:4864:20::435]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sdtPd-0005hi-1P for qemu-devel@nongnu.org; Tue, 13 Aug 2024 11:26:18 -0400 Received: by mail-wr1-x435.google.com with SMTP id ffacd0b85a97d-368584f9e36so2773470f8f.2 for ; Tue, 13 Aug 2024 08:26:15 -0700 (PDT) Received: from localhost.localdomain (80.red-88-28-4.dynamicip.rima-tde.net. [88.28.4.80]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-36e4c36bcbasm10649361f8f.18.2024.08.13.08.26.12 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 13 Aug 2024 08:26:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723562774; x=1724167574; darn=nongnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=cR8DL4fFh9wwc7+M9JHjarbbrgOTCmPyE0fl6m12ljw=; b=T26+Sdu/Je2BUPFZmvi7nrdvBipLZyWTUHDxMnxE+A0H3ywT5lUwVfmM15NqLhFbhu DuYKOqTxxD+9llE3FyCP8mk4aYnf9Y3jufJjdbSth4JjN6jxhHfEoKKyGpTF233s0Srx z2oMxlYm6HPPKqA3ek0Lg6dZoxhnqr0mvRJDm1QuNV29qDWppiVc1UtohSIzAvQ1X8uq Hy6sVpFPlA2mIV2/T+PnNLnD/ygSDJyuwiD4AgAZpWkYKsX1zCbpe2Ze8XOriIBvseP2 yQmadiowva2PnOy2ePk6eBMFd/PSjwDm/xteTbv/CDl6fPiVdnruD3EGIfxHZOYAxy5E s5iA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723562774; x=1724167574; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=cR8DL4fFh9wwc7+M9JHjarbbrgOTCmPyE0fl6m12ljw=; b=ksHpL+lQlme3CcVRiNPxZ2p3aD15GuL0iOdmQwJAxzRk33tHKs2gqottuiyKhD+zIX Wi9j0a3u0P4OkJfSeEGSnArVLPqWfmrtrzeMQRK3UUO6ie8oRoOiKsuSecJ9GG1iZJME kWYP0Tfonza+SrF/FGEuuzTwaZKR8REIusgkUu5x16kJjpeobkrN+y0bpIdxeWeUy2ky edlumDNrEV1jOKevAtnYDR+KsklzRJ4hikHzIHmWgT6IupT0Qapvk1A0ErnlgLbcfTVh BLY3+pWZyDAKZ2y2VOviNulX8S5vzs6MNx/aBgv4q1v6vLbk0nXZOefIDfK1Vqa6id4s fO8A== X-Gm-Message-State: AOJu0YwOgPqndeg41e3fZxbWzFO1x3fvsV0aAYj69vJYgPTAUvyaeZmL O3KJoqnkXbci5HO9tVoysvGU/SdmJeFV3by7EouVBfG5XgV+8/MYw/yCKDYivpB6v/FAAaBuHOg Z/rM= X-Google-Smtp-Source: AGHT+IEwq/XIEpRxiRf6HpQeQZwTpeBSAaMjS84//ESorvACUWefTPRH+FR7n9Gw2o4BAX1JqMSTlQ== X-Received: by 2002:adf:a451:0:b0:36b:bcef:b393 with SMTP id ffacd0b85a97d-3716cd256b6mr2712357f8f.57.1723562773910; Tue, 13 Aug 2024 08:26:13 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Aleksandar Rikalo , Aurelien Jarno , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Jiaxun Yang , Richard Henderson Subject: [PATCH-for-9.1?] target/mips: Load PTE as DATA Date: Tue, 13 Aug 2024 17:26:10 +0200 Message-ID: <20240813152610.97883-1-philmd@linaro.org> X-Mailer: git-send-email 2.45.2 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" 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=2a00:1450:4864:20::435; envelope-from=philmd@linaro.org; helo=mail-wr1-x435.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: 1723562799436116600 PTE is not CODE so load it as normal DATA access. Fixes: 074cfcb4da ("Implement hardware page table walker for MIPS32") Suggested-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- Based-on: <20240813135313.96519-1-philmd@linaro.org> --- target/mips/tcg/sysemu/tlb_helper.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/mips/tcg/sysemu/tlb_helper.c b/target/mips/tcg/sysemu/t= lb_helper.c index 5bff4cb72f..7050ea78df 100644 --- a/target/mips/tcg/sysemu/tlb_helper.c +++ b/target/mips/tcg/sysemu/tlb_helper.c @@ -603,9 +603,9 @@ static bool get_pte(CPUMIPSState *env, uint64_t vaddr, = MemOp op, =20 oi =3D make_memop_idx(op | MO_TE, ptw_mmu_idx); if (op =3D=3D MO_64) { - *pte =3D cpu_ldq_code_mmu(env, vaddr, oi, 0); + *pte =3D cpu_ldq_mmu(env, vaddr, oi, 0); } else { - *pte =3D cpu_ldl_code_mmu(env, vaddr, oi, 0); + *pte =3D cpu_ldl_mmu(env, vaddr, oi, 0); } =20 return true; --=20 2.45.2