From patchwork Fri May 10 15:19:38 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 163888 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:142:0:0:0:0 with SMTP id j2csp2539742ilr; Fri, 10 May 2019 08:43:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqzIoazX+FcrgqRVa3sEA7IOErIjfklnESE51vEImcofAJJX4VVnfmndj7InXOuiHaVd0DXS X-Received: by 2002:a50:e611:: with SMTP id y17mr8323508edm.222.1557503012076; Fri, 10 May 2019 08:43:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557503012; cv=none; d=google.com; s=arc-20160816; b=Q+pzEgebKbjOlVlgNAnSJyutultrgJcC/XVmwM47iHYB+q+g7jTLlTiiRuTID759I+ ytAd2R4jEhkGnphB7Ufl09kMM507PavVEI0iHZKZn8i4+Hlfop/s0OyNpuL9wTCzVPDG HPf/7bWTSKRJekqOK1Sa/PXddnRa9201CXx45/RaulccJeZCiaYBRWSTcJzmbSviJ/hR kNsA9jyr91jygKJHE4ktRFe2yxHi1t6uQOgW5EnEZgOfRLu/fCsFIdt9re9ZZRNV0TNY ZQ4LP0rAJJ2Usl8pXtRxQP0xOP0jM/W91wz1Slmm/3Wi7CeQ6NldJ5lCh2tixt5VDsS2 R3UQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=s4MN+agLoZqxLhzSptzqanZ4wwu5I/aQQC+BedaVD0U=; b=GOQxfjx2zVxyRV4/3CBkUqQN41HmwIEPHK7xcMLPSq5THXkeXvrzXBBreA6UqcZdtg HYx1/O6kJOOzXb89IJpAktWXxYt9C0GK5DEPC6pMIQE8SZFgOpH7rswC0XWK/QNhjCwM v4/LflhM4vJwFLhlKri3LeHNOMqJfOta8pPBqeriJCvJCEVtvZu9UWJXqEKCU/T403P7 5ag+IkP1YxRo+IMNoxtllLJ9yaiKFkARltFLT9jRwxce7wPwOzN4oBOpHL5GeqQXnvLr HVkk16pfvubkiYSGnmCecj77zpoDMaEfeaGExMtBgfj0Xz4jx2fL1ctU6Rh9kulmMV5q Sl2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=zgg8PjH4; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l44si1431341edb.410.2019.05.10.08.43.31 for (version=TLS1 cipher=AES128-SHA bits=128/128); Fri, 10 May 2019 08:43:32 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=zgg8PjH4; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([127.0.0.1]:45325 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hP7gJ-00050m-48 for patch@linaro.org; Fri, 10 May 2019 11:43:31 -0400 Received: from eggs.gnu.org ([209.51.188.92]:56342) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hP7Jn-0007no-CW for qemu-devel@nongnu.org; Fri, 10 May 2019 11:20:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hP7Jm-0000FO-Cu for qemu-devel@nongnu.org; Fri, 10 May 2019 11:20:15 -0400 Received: from mail-pg1-x534.google.com ([2607:f8b0:4864:20::534]:41597) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hP7Jm-0000Er-7a for qemu-devel@nongnu.org; Fri, 10 May 2019 11:20:14 -0400 Received: by mail-pg1-x534.google.com with SMTP id z3so3175228pgp.8 for ; Fri, 10 May 2019 08:20:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=s4MN+agLoZqxLhzSptzqanZ4wwu5I/aQQC+BedaVD0U=; b=zgg8PjH4YnENq5WLwCWpzZ+Nr3n7SoYjq2Tf9O+KHz4AQpUpOW4bykeeVfmHJEpYHb LLOLoUNZCJVdbVJ5JC9DJy6PQ1OQRe1DFhX3HMxM2tAIQ0PQNReB7c6wpni4wZFITqym kCmtC5qnsHa41DftzqZl0JABtEO20wxr/BeLLLCuQUtDIVPwIXLEAcpo3y03Ldu6wtdW uIia4tTkmrTI7OeKtauk+Man9Zo18O7m4m6S1eYmr8rYnCBkBdobx1wGwqtohI5AX71t KOEkZzpXR5GFcJoXdAuIXTTl28JGlDEsrUTIk29+m1yYlcITUJfwUnPrXdpRbmHSdmvx bFnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=s4MN+agLoZqxLhzSptzqanZ4wwu5I/aQQC+BedaVD0U=; b=uoMpDwuW8t1rc99MkLxne4WH/YxOrKSmHJPR7c3O90HjsDNmqp4oAV1dn/vzOxvQl4 jeRLgWcSvrmc+YE7ajEQ4dxzV573q8FVFUBMCc0xaVfAOq46b+s6/VL5gUK103+inNfk HY4kJ2+FqVMZTKU1BFXqPLoiO1NtcYY6VwbjS/3bW6+PohRhzDU+DXg3J2cJrnn70QPn WUCkVX3VTHWPF6w03DPnrW15lO8QXsQEzgmadYkkFR+Z85paIkRgvPhEfXgoladdhSrv qbVYZTg8sZKLGb/XU+D8oWQGvpar+McWHwd6OGCq9cGF5JTJk532D8qsBrYIM8PIbXo3 Q/Pg== X-Gm-Message-State: APjAAAWVV09ZylIW1u575SchUmY9iGMv+ahgWx2ocjGE//uf4lUdlqAB c4YoZp+fPD4i9vh31BHHotAF8JWyDMg= X-Received: by 2002:aa7:8453:: with SMTP id r19mr15042988pfn.44.1557501612868; Fri, 10 May 2019 08:20:12 -0700 (PDT) Received: from localhost.localdomain (97-113-13-231.tukw.qwest.net. [97.113.13.231]) by smtp.gmail.com with ESMTPSA id 19sm5920517pgz.24.2019.05.10.08.20.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 10 May 2019 08:20:12 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Date: Fri, 10 May 2019 08:19:38 -0700 Message-Id: <20190510151944.22981-22-richard.henderson@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190510151944.22981-1-richard.henderson@linaro.org> References: <20190510151944.22981-1-richard.henderson@linaro.org> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::534 Subject: [Qemu-devel] [PULL 21/27] target/tilegx: Convert to CPUClass::tlb_fill 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: , Cc: peter.maydell@linaro.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/tilegx/cpu.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) -- 2.17.1 diff --git a/target/tilegx/cpu.c b/target/tilegx/cpu.c index b9d37105fa..b209c55387 100644 --- a/target/tilegx/cpu.c +++ b/target/tilegx/cpu.c @@ -25,6 +25,7 @@ #include "hw/qdev-properties.h" #include "linux-user/syscall_defs.h" #include "qemu/qemu-print.h" +#include "exec/exec-all.h" static void tilegx_cpu_dump_state(CPUState *cs, FILE *f, int flags) { @@ -111,8 +112,9 @@ static void tilegx_cpu_do_interrupt(CPUState *cs) cs->exception_index = -1; } -static int tilegx_cpu_handle_mmu_fault(CPUState *cs, vaddr address, int size, - int rw, int mmu_idx) +static bool tilegx_cpu_tlb_fill(CPUState *cs, vaddr address, int size, + MMUAccessType access_type, int mmu_idx, + bool probe, uintptr_t retaddr) { TileGXCPU *cpu = TILEGX_CPU(cs); @@ -122,7 +124,7 @@ static int tilegx_cpu_handle_mmu_fault(CPUState *cs, vaddr address, int size, cpu->env.signo = TARGET_SIGSEGV; cpu->env.sigcode = 0; - return 1; + cpu_loop_exit_restore(cs, retaddr); } static bool tilegx_cpu_exec_interrupt(CPUState *cs, int interrupt_request) @@ -152,7 +154,7 @@ static void tilegx_cpu_class_init(ObjectClass *oc, void *data) cc->cpu_exec_interrupt = tilegx_cpu_exec_interrupt; cc->dump_state = tilegx_cpu_dump_state; cc->set_pc = tilegx_cpu_set_pc; - cc->handle_mmu_fault = tilegx_cpu_handle_mmu_fault; + cc->tlb_fill = tilegx_cpu_tlb_fill; cc->gdb_num_core_regs = 0; cc->tcg_initialize = tilegx_tcg_init; }