From patchwork Fri Apr 15 14:23:49 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 611002 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3qmg541Fqgz9t6S for ; Sat, 16 Apr 2016 00:33:28 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b=jpLwMofV; dkim-atps=neutral Received: from localhost ([::1]:35284 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ar4oI-0002J5-C5 for incoming@patchwork.ozlabs.org; Fri, 15 Apr 2016 10:33:26 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49474) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ar4fE-0000dX-DR for qemu-devel@nongnu.org; Fri, 15 Apr 2016 10:24:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ar4fB-0007fu-OO for qemu-devel@nongnu.org; Fri, 15 Apr 2016 10:24:04 -0400 Received: from mail-wm0-x236.google.com ([2a00:1450:400c:c09::236]:35643) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ar4fB-0007fd-HB for qemu-devel@nongnu.org; Fri, 15 Apr 2016 10:24:01 -0400 Received: by mail-wm0-x236.google.com with SMTP id a140so33785711wma.0 for ; Fri, 15 Apr 2016 07:24:01 -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 :mime-version:content-transfer-encoding; bh=9cCyuwJc8FHYKnCNUDoUaAe+gq0we7rFDfyubYaToxA=; b=jpLwMofVZ9dXKMLu6rMnuWm42uwpmwmDHdW5HQqgD9F0Vw3/B/Xce32EWVEIQbATHA 6Ni7fvFallHKtdP9jGCqwIdJA6eUznGTKS0So+z7qwKKNpPxEwv0pgY1HNuY0ICotmVy Dnh6nWLCgrdemSZzpJQUxZPYkFGNNsAIev7N4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=9cCyuwJc8FHYKnCNUDoUaAe+gq0we7rFDfyubYaToxA=; b=YU00cawnVRKglW9HyMrCSHQORHBK8pN5tzY0mo/gdB8DoBIawa27iVMOna6EjTbhv3 P/cvXlfMfhDUk6HfI/U7QWX0RFfrOEoRdv/SXu0RjJ4ZOafUeJuBlyJo3ku2Bi7W6JV0 tcSsE1uRVQJ85ygs78Ba30NZGOFYrLLzfJG+aXL2ismKoqiJbKcZlMLNfoKKd30Re3TU JjDKtjf2AhlN/5deyQmt6L/OVxfejTJ964v0hp5YJYualvr6NIA7ZT7hyzP1OoLu6X1g 0MQ+uWzLzfKdZdveuD+y34xkMn1wFUBz6K0A+tdttwRznE/bVU6ziSeY2RXbaUiTH30e Oiyg== X-Gm-Message-State: AOPr4FXtcFwq0iM8YFK1svKG2EaAvMIZmmj+HwZEc4yPKIPzhWphcgOuRGRmDcRjH18Aj7+h X-Received: by 10.194.107.74 with SMTP id ha10mr22397614wjb.24.1460730240899; Fri, 15 Apr 2016 07:24:00 -0700 (PDT) Received: from zen.linaro.local ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id o1sm42693540wjm.11.2016.04.15.07.23.53 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 15 Apr 2016 07:23:58 -0700 (PDT) Received: from zen.linaroharston (localhost [127.0.0.1]) by zen.linaro.local (Postfix) with ESMTP id 287C63E05A3; Fri, 15 Apr 2016 15:24:05 +0100 (BST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: mttcg@listserver.greensocs.com, fred.konrad@greensocs.com, a.rigo@virtualopensystems.com, serge.fdrv@gmail.com, cota@braap.org Date: Fri, 15 Apr 2016 15:23:49 +0100 Message-Id: <1460730231-1184-12-git-send-email-alex.bennee@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1460730231-1184-1-git-send-email-alex.bennee@linaro.org> References: <1460730231-1184-1-git-send-email-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::236 Subject: [Qemu-devel] [RFC v1 10/12] arm: use tlb_flush_page_all for tlbimva[a] 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, claudio.fontana@huawei.com, Peter Crosthwaite , jan.kiszka@siemens.com, mark.burton@greensocs.com, qemu-devel@nongnu.org, "open list:ARM" , pbonzini@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , rth@twiddle.net Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" From: KONRAD Frederic Instead of flushing each individual vCPU use the tlb_flush_page_all functions which is async enabled for MTTCG. Signed-off-by: KONRAD Frederic Signed-off-by: Alex Bennée --- include/exec/exec-all.h | 3 +++ target-arm/helper.c | 12 ++---------- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h index 858055b..bc97683 100644 --- a/include/exec/exec-all.h +++ b/include/exec/exec-all.h @@ -208,6 +208,9 @@ static inline void tlb_flush_page_by_mmuidx(CPUState *cpu, static inline void tlb_flush_by_mmuidx(CPUState *cpu, ...) { } +static inline void tlb_flush_page_all(target_ulong addr) +{ +} #endif #define CODE_GEN_ALIGN 16 /* must be >= of the size of a icache line */ diff --git a/target-arm/helper.c b/target-arm/helper.c index 19d5d52..bc9fbda 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -554,21 +554,13 @@ static void tlbiasid_is_write(CPUARMState *env, const ARMCPRegInfo *ri, static void tlbimva_is_write(CPUARMState *env, const ARMCPRegInfo *ri, uint64_t value) { - CPUState *other_cs; - - CPU_FOREACH(other_cs) { - tlb_flush_page(other_cs, value & TARGET_PAGE_MASK); - } + tlb_flush_page_all(value & TARGET_PAGE_MASK); } static void tlbimvaa_is_write(CPUARMState *env, const ARMCPRegInfo *ri, uint64_t value) { - CPUState *other_cs; - - CPU_FOREACH(other_cs) { - tlb_flush_page(other_cs, value & TARGET_PAGE_MASK); - } + tlb_flush_page_all(value & TARGET_PAGE_MASK); } static const ARMCPRegInfo cp_reginfo[] = {