Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp1243943ybt; Thu, 9 Jul 2020 02:11:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx9ZX96TacpAHRywXvo8vWstoRjq+codiKJMx/uh6egb4qOASxAFpATr6oQWQgDueshwJXp X-Received: by 2002:a17:906:f2c4:: with SMTP id gz4mr54572072ejb.484.1594285917912; Thu, 09 Jul 2020 02:11:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594285917; cv=none; d=google.com; s=arc-20160816; b=jLQn78gxGcTfvJE3Z8hZTxcVKuILwMBtWzDGKhoFrAcQW+zFTDh6p/C0e03tQRwa1i L1v0Z6xRZZQk6wBK9HX0D0xYBNr4jtOhK7cxD20awEVYb26SBovsU87xbT5+3BXr3051 XQ+TFPy/fhUUyJ7D8x0/yz1V/peWCgQYkLA8TGZYtc+tbzYW/mvgYYRFkhf9LXrKRrkY nHReib0IUxmfVPUeTZO2cTZzp/PmQkT07tcVBlPmpXPQoMBiNqxopJCUUTOTF2GEiRM+ j2tCk+GPWltmRNBG8DyiStVswsZbh6w4GiL0CWqNdmsvh/jYcnYZkiTJoKeADHDcY4mA DG6Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=ZHscjeL9z7NbhiV0fI02yyov9nKXzm9j56Pp5BD7eXk=; b=wNj+J/ZV4lorOIwLLO4efx0f5P0wYfx0U45NgLep+BjiLXA/LjCmAOpTYFlHCchrmH p70WArPgQshD9KUS3V5U67DExEZbvwIzVzHSM7fk+eH0vn/JKdKEraj+DoOT5hjM8tYK KSMnx0BDFX/B34Zzjl4krwSrEppP3kD2IS/olfnmvIc1yeDknUQGrduo3aNeoc2ZIbjy RNCCpA1LUPJocMIW8G/hDf+HhOmo+NIsP6Nqy/0DkLEoYKaAG9zuspBo+jFIYw8ate3R WgMaPNy64V3PPkw3PMYBGg/IllJ53oSN3gbmwxCr15Hha2XbWQkEBpQyOFepf38rNTgW jBHg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y19si1599937ejb.186.2020.07.09.02.11.35; Thu, 09 Jul 2020 02:11:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726482AbgGIJLO (ORCPT + 99 others); Thu, 9 Jul 2020 05:11:14 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:7826 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726140AbgGIJLN (ORCPT ); Thu, 9 Jul 2020 05:11:13 -0400 Received: from DGGEMS410-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 67D4C386280350642122; Thu, 9 Jul 2020 17:11:10 +0800 (CST) Received: from DESKTOP-KKJBAGG.china.huawei.com (10.174.186.75) by DGGEMS410-HUB.china.huawei.com (10.3.19.210) with Microsoft SMTP Server id 14.3.487.0; Thu, 9 Jul 2020 17:11:03 +0800 From: Zhenyu Ye To: , , , , , , CC: , , , , , , , , , Subject: [PATCH v1 0/2] arm64: tlb: add support for TLBI RANGE instructions Date: Thu, 9 Jul 2020 17:10:52 +0800 Message-ID: <20200709091054.1698-1-yezhenyu2@huawei.com> X-Mailer: git-send-email 2.22.0.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.174.186.75] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org NOTICE: this series are based on the arm64 for-next/tlbi branch: git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-next/tlbi -- ARMv8.4-TLBI provides TLBI invalidation instruction that apply to a range of input addresses. This series add support for this feature. I tested this feature on a FPGA machine whose cpus support the tlbi range. As the page num increases, the performance is improved significantly. When page num = 256, the performance is improved by about 10 times. Below is the test data when the stride = PTE: [page num] [classic] [tlbi range] 1 16051 13524 2 11366 11146 3 11582 12171 4 11694 11101 5 12138 12267 6 12290 11105 7 12400 12002 8 12837 11097 9 14791 12140 10 15461 11087 16 18233 11094 32 26983 11079 64 43840 11092 128 77754 11098 256 145514 11089 512 280932 11111 See more details in: https://lore.kernel.org/linux-arm-kernel/504c7588-97e5-e014-fca0-c5511ae0d256@huawei.com/ -- RFC patches: - Link: https://lore.kernel.org/linux-arm-kernel/20200708124031.1414-1-yezhenyu2@huawei.com/ Zhenyu Ye (2): arm64: tlb: Detect the ARMv8.4 TLBI RANGE feature arm64: tlb: Use the TLBI RANGE feature in arm64 arch/arm64/include/asm/cpucaps.h | 3 +- arch/arm64/include/asm/sysreg.h | 3 + arch/arm64/include/asm/tlbflush.h | 156 ++++++++++++++++++++++++------ arch/arm64/kernel/cpufeature.c | 10 ++ 4 files changed, 141 insertions(+), 31 deletions(-) -- 2.19.1