From patchwork Tue Mar 27 02:25:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steven Seeger X-Patchwork-Id: 891312 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=flightsystems.net Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 409FJB6P36z9s0v for ; Tue, 27 Mar 2018 13:26:34 +1100 (AEDT) Received: from localhost ([::1]:59996 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f0eJk-00026t-Bm for incoming@patchwork.ozlabs.org; Mon, 26 Mar 2018 22:26:32 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52868) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f0eJE-00026c-He for qemu-devel@nongnu.org; Mon, 26 Mar 2018 22:26:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f0eJB-0005AE-9O for qemu-devel@nongnu.org; Mon, 26 Mar 2018 22:26:00 -0400 Received: from p3plsmtpa09-04.prod.phx3.secureserver.net ([173.201.193.233]:47661) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1f0eJB-00058T-2w for qemu-devel@nongnu.org; Mon, 26 Mar 2018 22:25:57 -0400 Received: from wirbelwind.localnet ([204.197.155.4]) by :SMTPAUTH: with SMTP id 0eJ6fpigDhKYo0eJ6fb6mU; Mon, 26 Mar 2018 19:25:54 -0700 From: Steven Seeger To: qemu-devel@nongnu.org Date: Mon, 26 Mar 2018 22:25:24 -0400 Message-ID: <3978804.GGRd8R3pmO@wirbelwind> Organization: Embedded Flight Systems, Inc. MIME-Version: 1.0 X-CMAE-Envelope: MS4wfMqKnsed3NoyOsSWK4E/+UMV5eE6JQfeIdLmAwHIXg6X5kNHRSgxHi4OMgGKi90HGfHzJLanQHTyqT5ZZpiBSWkbSXsYzHHkdqQw6mCyp++5KL4c3kcT 9b5BQESm5xvvYUV5WSx8fZh5zJ1pmmY74Vliv7thvdj9ASMW/tVfqprthX+z3xtH8KOZ5msrXY+kBIINMwg1goAOEBCnG/1x9JADz9VJBBKd3Lx4zDzYfAif X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 173.201.193.233 Subject: [Qemu-devel] [PATCH 01/02] leon3: change the handling for ASI_LEON_NOCACHE to be aware of if the MMU is enabled or not X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: steven.seeger@flightsystems.net Cc: peter.maydell@linaro.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" From f512606776e20dc603b8ea3faaeb103667de3178 Mon Sep 17 00:00:00 2001 From: Steven Seeger Date: Sun, 25 Mar 2018 17:58:21 -0400 Subject: [PATCH 1/6] leon3: change the handling for ASI_LEON_NOCACHE to be aware of if the MMU is enabled or not Signed-off-by: Steven Seeger --- target/sparc/translate.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) type = GET_ASI_DIRECT; @@ -2131,7 +2134,6 @@ static DisasASI get_asi(DisasContext *dc, int insn, TCGMemOp memop) break; case ASI_M_BYPASS: /* MMU passthrough */ case ASI_LEON_BYPASS: /* LEON MMU passthrough */ - case ASI_LEON_NOCACHE: mem_idx = MMU_PHYS_IDX; type = GET_ASI_DIRECT; break; diff --git a/target/sparc/translate.c b/target/sparc/translate.c index f55ec28665..ab8d0a0c72 100644 --- a/target/sparc/translate.c +++ b/target/sparc/translate.c @@ -2121,6 +2121,9 @@ static DisasASI get_asi(DisasContext *dc, int insn, TCGMemOp memop) || (asi == ASI_USERDATA && (dc->def->features & CPU_FEATURE_CASA))) { switch (asi) { + case ASI_LEON_NOCACHE: /* force cache miss */ + type = GET_ASI_DIRECT; + break; case ASI_USERDATA: /* User data access */ mem_idx = MMU_USER_IDX;