Message ID | 20240429103346.59115-2-libang.li@antgroup.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7945EC04FFE for <linux-mm@archiver.kernel.org>; Mon, 29 Apr 2024 10:36:01 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D94016B0083; Mon, 29 Apr 2024 06:35:59 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id D43CB6B0085; Mon, 29 Apr 2024 06:35:59 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C0B816B0087; Mon, 29 Apr 2024 06:35:59 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id A8BA36B0083 for <linux-mm@kvack.org>; Mon, 29 Apr 2024 06:35:59 -0400 (EDT) Received: from smtpin08.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 52054A17BB for <linux-mm@kvack.org>; Mon, 29 Apr 2024 10:35:59 +0000 (UTC) X-FDA: 82062214038.08.B95943B Received: from out0-208.mail.aliyun.com (out0-208.mail.aliyun.com [140.205.0.208]) by imf02.hostedemail.com (Postfix) with ESMTP id 3A4D18000D for <linux-mm@kvack.org>; Mon, 29 Apr 2024 10:35:56 +0000 (UTC) Authentication-Results: imf02.hostedemail.com; dkim=pass header.d=antgroup.com header.s=default header.b=WiL+qiQq; dmarc=pass (policy=quarantine) header.from=antgroup.com; spf=pass (imf02.hostedemail.com: domain of libang.li@antgroup.com designates 140.205.0.208 as permitted sender) smtp.mailfrom=libang.li@antgroup.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1714386957; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=6Lf/KTNGeV9HQ9Bw8oLzpkcGoRQJ7Qoem8o9ZsWDa00=; b=aXqRjE/lXlIYWbgCWcMA/oMDz4dPzqc6+XeD0x5GwrvGz3Xorlfc0HcViKg1Cht//xnrYI tUiDbeIWNKzXyVJ9qMCcBNKo8UEsSgA6deDu0S3lW8Du/FI5XI1d323f2LWiutid99U1Lw lzqOE4H9IGsh4IZUrw1HHZQJTcUMev8= ARC-Authentication-Results: i=1; imf02.hostedemail.com; dkim=pass header.d=antgroup.com header.s=default header.b=WiL+qiQq; dmarc=pass (policy=quarantine) header.from=antgroup.com; spf=pass (imf02.hostedemail.com: domain of libang.li@antgroup.com designates 140.205.0.208 as permitted sender) smtp.mailfrom=libang.li@antgroup.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1714386957; a=rsa-sha256; cv=none; b=14oZ/mG9wNy8wvW7iudmY1SaxiR62NTFFw6N8qMX6b0//kZb9dM3wV7tC2lUM5s4xIFazy JTe69xz3/GanCdjccmfDwUH7++1Zu94dJESd7rEe36KTRh1O6TrBkHxjqlXuczi91lPxOC XSoyzY23yEMDX5XsNBNFG+rUiWAoTNc= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1714386954; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=6Lf/KTNGeV9HQ9Bw8oLzpkcGoRQJ7Qoem8o9ZsWDa00=; b=WiL+qiQq5ggcx6KKouoOmmZdbRu4tyn6tVR+PSDU5+g4LD/aG7bh/F+kWEy0F1E9p8rWRXZiHBUAWW7PX579FC6dQiUgUk9xNK2yMzX3LUka9AgQPSqlKtbMXXHD0AU+0AS1Mpo/4+vlWn3JfM9lNMp2eHNxyknvhk/ymbLEbnc= X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R111e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018047203;MF=libang.li@antgroup.com;NM=1;PH=DS;RN=17;SR=0;TI=SMTPD_---.XOEanKl_1714386951; Received: from localhost(mailfrom:libang.li@antgroup.com fp:SMTPD_---.XOEanKl_1714386951) by smtp.aliyun-inc.com; Mon, 29 Apr 2024 18:35:52 +0800 From: "Bang Li" <libang.li@antgroup.com> To: akpm@linux-foundation.org, chenhuacai@kernel.org, tsbogend@alpha.franken.de, paul.walmsley@sifive.com, palmer@dabbelt.com, chris@zankel.net, jcmvbkbc@gmail.com Cc: <david@redhat.com>, <ryan.roberts@arm.com>, <libang.linux@gmail.com>, <ioworker0@gmail.com>, <linux-kernel@vger.kernel.org>, <linux-mm@kvack.org>, <loongarch@lists.linux.dev>, <linux-mips@vger.kernel.org>, <linux-riscv@lists.infradead.org>, "Bang Li" <libang.li@antgroup.com> Subject: [PATCH v1 1/5] LoongArch: Add update_mmu_tlb_range() Date: Mon, 29 Apr 2024 18:33:42 +0800 Message-Id: <20240429103346.59115-2-libang.li@antgroup.com> X-Mailer: git-send-email 2.19.1.6.gb485710b In-Reply-To: <20240429103346.59115-1-libang.li@antgroup.com> References: <20240429103346.59115-1-libang.li@antgroup.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Server: rspam01 X-Stat-Signature: 9187ymqb65xcdscuikg36jpz1mqg8q9y X-Rspam-User: X-Rspamd-Queue-Id: 3A4D18000D X-HE-Tag: 1714386956-460552 X-HE-Meta: U2FsdGVkX18hPDhT1DsWEZ8006kWswt3YXdUHj3lf5hWEVoxr836PgNyIhFkAOhUrecRad3imfiUZwHB1O/SuC1GXyUSB3RkRf5m2SAozdb19+tYXZieJTs68nM2E5FnkKRwKRnjD36S0amuPddbKu8PaiCdh3CUTi1p/mAqMQpwVV6eGCps2lHQoldBKwpJ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6XAy4Cibvzb/AGu7+mOcxuC8DNQYjETVKKaPtta+A5NBJEVqQ97qHbBYJJbgBFwztQtduIsbA4NiiVu94= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000022, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series | Add update_mmu_tlb_range() to simplify code | expand |
diff --git a/arch/loongarch/include/asm/pgtable.h b/arch/loongarch/include/asm/pgtable.h index af3acdf3481a..5ccc2a3a6f7a 100644 --- a/arch/loongarch/include/asm/pgtable.h +++ b/arch/loongarch/include/asm/pgtable.h @@ -469,6 +469,8 @@ static inline void update_mmu_cache_range(struct vm_fault *vmf, #define __HAVE_ARCH_UPDATE_MMU_TLB #define update_mmu_tlb update_mmu_cache +#define update_mmu_tlb_range(vma, addr, ptep, nr) \ + update_mmu_cache_range(NULL, vma, addr, ptep, nr) static inline void update_mmu_cache_pmd(struct vm_area_struct *vma, unsigned long address, pmd_t *pmdp)
Added update_mmu_tlb_range function, we can batch update tlb of an address range. Signed-off-by: Bang Li <libang.li@antgroup.com> --- arch/loongarch/include/asm/pgtable.h | 2 ++ 1 file changed, 2 insertions(+)