Received: by 2002:ab2:7b86:0:b0:1f7:5705:b850 with SMTP id q6csp1482498lqh; Mon, 6 May 2024 08:57:59 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUAyrwKlUM7IbOJS1AuaJ0cby1PUHvPVOSDX1DdSgxQQOmXBJ3j7vsyNN93wDTsZ3ukICsQYLcnw7dJPcJKTCGbxhipZZztx5EbEMrhvQ== X-Google-Smtp-Source: AGHT+IFMqKEZrz8CpmkXWOFdy+e+A7TngWkW6pCut04sHb3cRfpWmVUWqBRl0//EaQoJtUBLAzI3 X-Received: by 2002:a05:6358:4423:b0:183:9a25:852a with SMTP id z35-20020a056358442300b001839a25852amr14900817rwc.7.1715011079101; Mon, 06 May 2024 08:57:59 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715011079; cv=pass; d=google.com; s=arc-20160816; b=hBbmbEKIqCpBG7X74mkVAFjhs8L79jNYrHtW3fxINuqf+KyHnztKhvsc+F7IR6mhN4 6KtNe3jyPuFFPUZWL10Zo98qg/BpxjTRadlTf6Aco5eZ+hFAALFbbKqo7A670zNj0G9T 1WB4eI10YSmvIMqXok9zhItzpWSQ6ldMC2k5LgiqzAm0Zh1aEj7ll/DEKWwwckq/XMNS 2owMVxAlZcsTn9TicQkJW8zsxfKzprwN1puqgf49fEMAp6AD9ta+BkPuynTSHuo9z3L5 Vs9MIpO/RL/VJXq+8THRIqWDqJDBfWk1y6tmaUZtod0MwEAtDkD6E5yu7kxtjv4MKDSy HEow== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=pTrt2D6LnlSlcqnfLWOg4gAqNc+Zz7gJTsSV/QHl4Kk=; fh=ZaPvTvk3greVAhtlw/faBL7y/bcze5JBULOYO1tsevI=; b=QkjV3Oon8gkS9Og2jEHG6qKykkikHmh4sE0UpGxQHvweM3fM/01cPW45+IU181Sltt szbJdcv9tEyQ3hYwTfZ3Dz3zt3RvUq3fdYhBSJ/eX2IkT7MCC0zPxKnvLv7Gs99aHgNm lIzctgAAF8lDzLyGaS96CrX86D2cirxbBPCXLtWTE0oswKAOcNTT19oqBZL1mVlwugEn 67FkV1Tc7YFIPatdtTL1V0ZBbaI0RdxwvYRbV5P+3rJeSBFRvVnWbo4DOjaV5vA3PpL4 eV8D03HZ8j9IjFXNZu83hIyNVGeHdngQ5Ewl47ygI460dT7/y/89hTCynvy4KGkkQE5v lFeg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@antgroup.com header.s=default header.b=u6jU+xOc; arc=pass (i=1 spf=pass spfdomain=antgroup.com dkim=pass dkdomain=antgroup.com dmarc=pass fromdomain=antgroup.com); spf=pass (google.com: domain of linux-kernel+bounces-170108-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-170108-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=antgroup.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id z15-20020a65664f000000b0061ece34d06dsi5787851pgv.196.2024.05.06.08.57.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 May 2024 08:57:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-170108-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@antgroup.com header.s=default header.b=u6jU+xOc; arc=pass (i=1 spf=pass spfdomain=antgroup.com dkim=pass dkdomain=antgroup.com dmarc=pass fromdomain=antgroup.com); spf=pass (google.com: domain of linux-kernel+bounces-170108-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-170108-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=antgroup.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id CE8A02850C4 for ; Mon, 6 May 2024 15:57:55 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6CB18155A25; Mon, 6 May 2024 15:57:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b="u6jU+xOc" Received: from out187-1.us.a.mail.aliyun.com (out187-1.us.a.mail.aliyun.com [47.90.187.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1249615574E for ; Mon, 6 May 2024 15:57:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=47.90.187.1 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715011056; cv=none; b=j8yHQSyibTq2JzWoxh1UcKFJLGmCDvCHX2niGq/M5LH4FJg+4VfbnaAWn6JDwx/TrlOYkluPNKiRgW0FWvPGtO8CuH6jxMhStW5h2yc1bbJl60GMS/1wRWKxuw4XNJpshHCbJGX/S7poR0eBOTk86LL5qpaJ3erOh10hhL9MrCw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715011056; c=relaxed/simple; bh=icpePUeswEr53u3rw5CGtDkngqPYtbaGrZOhDxsPtc8=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=R9hq0RgvTAyFVQlj4NhdGm2SYxX+/6gKfCiCL2P56mDuoYXAjib2z2YdaSe6/cRT60606lj50pVnF/k6SI9bMQ/AvWqUoEwH4wLWHNOnI5H1wPxNBjSjK5ZtbEBMcuI0+lgG18Ly8/wmHuS+5zJrWvDCSoBgSz2tqoDfP9RTtgc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com; spf=pass smtp.mailfrom=antgroup.com; dkim=pass (1024-bit key) header.d=antgroup.com header.i=@antgroup.com header.b=u6jU+xOc; arc=none smtp.client-ip=47.90.187.1 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=antgroup.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=antgroup.com DKIM-Signature:v=1; a=rsa-sha256; c=relaxed/relaxed; d=antgroup.com; s=default; t=1715011043; h=From:To:Subject:Date:Message-Id:MIME-Version; bh=pTrt2D6LnlSlcqnfLWOg4gAqNc+Zz7gJTsSV/QHl4Kk=; b=u6jU+xOcFJ1Q70WH10dGsLlx1HnJrJssmMdS5Lx+lpjN4quxtLIgif1j1sdoLSVLFOmUW7AzFncatfwJjokmtYdwGWexLbcOCQs60BeySP6aPQEhWvAATUPotD0MzZhk6u+HSDrNAYcI57Tv9RI96Eef+XwQkg/ipP0WSKyfyyc= X-Alimail-AntiSpam:AC=PASS;BC=-1|-1;BR=01201311R101e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018047199;MF=libang.li@antgroup.com;NM=1;PH=DS;RN=16;SR=0;TI=SMTPD_---.XTcewE9_1715010723; Received: from localhost(mailfrom:libang.li@antgroup.com fp:SMTPD_---.XTcewE9_1715010723) by smtp.aliyun-inc.com; Mon, 06 May 2024 23:52:04 +0800 From: "Bang Li" 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: , , , , , , , , "Bang Li" Subject: [PATCH v2 2/5] mips: Add update_mmu_tlb_range() Date: Mon, 06 May 2024 23:51:17 +0800 Message-Id: <20240506155120.83105-3-libang.li@antgroup.com> X-Mailer: git-send-email 2.19.1.6.gb485710b In-Reply-To: <20240506155120.83105-1-libang.li@antgroup.com> References: <20240506155120.83105-1-libang.li@antgroup.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Added update_mmu_tlb_range function, we can batch update tlb of an address range. Signed-off-by: Bang Li --- arch/mips/include/asm/pgtable.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/mips/include/asm/pgtable.h b/arch/mips/include/asm/pgtable.h index e27a4c83c548..9416c9b971e5 100644 --- a/arch/mips/include/asm/pgtable.h +++ b/arch/mips/include/asm/pgtable.h @@ -597,6 +597,10 @@ 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 __HAVE_ARCH_UPDATE_MMU_TLB_RANGE +#define update_mmu_tlb_range(vma, address, ptep, nr) \ + update_mmu_cache_range(NULL, vma, address, ptep, nr) + static inline void update_mmu_cache_pmd(struct vm_area_struct *vma, unsigned long address, pmd_t *pmdp) { -- 2.19.1.6.gb485710b