Received: by 2002:a05:6358:bb9e:b0:b9:5105:a5b4 with SMTP id df30csp4307363rwb; Tue, 6 Sep 2022 05:52:47 -0700 (PDT) X-Google-Smtp-Source: AA6agR6z/+4JpybZLzicluoLRcJhgE8GiVJcmm5VTkP0ppoQWD3Vvucia9n2nOFfWXcV34TzJyjJ X-Received: by 2002:a05:6402:274e:b0:447:4e9d:69e8 with SMTP id z14-20020a056402274e00b004474e9d69e8mr47358229edd.295.1662468767393; Tue, 06 Sep 2022 05:52:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662468767; cv=none; d=google.com; s=arc-20160816; b=gfSf1KX2GveJ3EixwPjcjw0W42UN2SxBoKsUAf36jWGs7HSkqBbPz+RMap/ZA2oDtk GU8yAmeXBlu7nHaUkTkHqV6XxT7CfSP/aDmDxYkcjwrLpSWJzHDdN9/kBhpdm0gVTNoY 9JGxTUQgU+JaxcQZtUlJQ3tnbccyZ05NUonbW6ihEEztEIV4hFRhh3VxdICiQNutn2aw tmPUf7V8atpO0Z72KT9bLNqxZ0cQzVQNu0QVRRd/bj43EAwAT66we6LITskwn1tN7sHq 8Ek3T00MrFUGFB784rvsuzOq5eWpAD3/BH/ayKv8+NwugXW/7DznWVw4r33TaKGsWRuz Pqmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=ABlJFeYOIQ1yMO4RgFSt8TOjiYFH1v4bYER/CMetTR8=; b=rA8/QufjFuaw7i5M4alVYItwkDFTklTbgtfD8MrcAUaw27VWqZodnWrmWtyobAk+u9 WR45nNO9RkptpTyRP9qL3K8bkLU1f4m/nwtuuOYPnAQb1KfzezNu5XoQQK+mHN7iFGsg 5NNG5qLORYy1kIAdWsMAdHvGaZSvji/YKDGKiLkXcqpoOCXEF6PWbP56eZF7SPl6qVcZ w5lSPbXQKSwAI9+D+6Wy367FHZLSDgybKYPTSFkziIs0Y+ZHbo9nVlP4apW7oe4HONc4 cV+GaT4Pg0rjdrjEYyb5F6L0W3PQohJ2XkY0p8Wj07YDVU+sD5fMFytpDLnZVD6Ghox4 Id6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b=Lu6vgE9U; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w6-20020a50c446000000b004486fbe974asi9143656edf.590.2022.09.06.05.52.05; Tue, 06 Sep 2022 05:52:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@163.com header.s=s110527 header.b=Lu6vgE9U; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=163.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233308AbiIFMZl (ORCPT + 99 others); Tue, 6 Sep 2022 08:25:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44072 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232012AbiIFMX1 (ORCPT ); Tue, 6 Sep 2022 08:23:27 -0400 Received: from m12-17.163.com (m12-17.163.com [220.181.12.17]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id F2BC819C18 for ; Tue, 6 Sep 2022 05:20:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id:MIME-Version; bh=ABlJF eYOIQ1yMO4RgFSt8TOjiYFH1v4bYER/CMetTR8=; b=Lu6vgE9UhNP6WbYwomcKj K18e/JS0PdkV1sXt5seLfKV7ChMGqeig1pMxxOSPr6+3LeessyB9HibdL9s0mVkB ajf6Ax8BMAxz8EaKj79cBqOrXkpimagkeQglsNF0ApHsEjhGn0r1BZU9D4XGLLfO Q6SPsegjECfKTkx7wyflOQ= Received: from whoami-VirtualBox.. (unknown [223.72.91.155]) by smtp13 (Coremail) with SMTP id EcCowABn1lLLOhdjrfx8aQ--.20577S2; Tue, 06 Sep 2022 20:19:24 +0800 (CST) From: Jinyu Tang To: paul.walmsley@sifive.com, palmer@dabbelt.com, aou@eecs.berkeley.edu, conor.dooley@microchip.com, anup@brainfault.org, alexandre.ghiti@canonical.com, guoren@kernel.org, akpm@linux-foundation.org, heiko@sntech.de, tongtiangen@huawei.com, sunnanyong@huawei.com Cc: linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, falcon@tinylab.org, tjytimi@163.com Subject: [PATCH v1] riscv : support update_mmu_tlb() for riscv Date: Tue, 6 Sep 2022 20:19:21 +0800 Message-Id: <20220906121921.8355-1-tjytimi@163.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID: EcCowABn1lLLOhdjrfx8aQ--.20577S2 X-Coremail-Antispam: 1Uf129KBjvdXoW7JF45JFW8XFyftFyfXrWrXwb_yoWfGrc_W3 WxCw4vgryvqF4xua1DXF1fWr45K34rAF1DXrs2qa13tF98JanrJ3ykta15Jr4UuanIvF4I kr95GryFgFy2kjkaLaAFLSUrUUUUjb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUvcSsGvfC2KfnxnUUI43ZEXa7sREuWlUUUUUU== X-Originating-IP: [223.72.91.155] X-CM-SenderInfo: xwm13xlpl6il2tof0z/1tbiTgx0eFUDRgjDigAAsf X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add macro definition to support updata_mmu_tlb() for riscv, this function is from commit:7df676974359 ("mm/memory.c:Update local TLB if PTE entry exists"). Signed-off-by: Jinyu Tang --- arch/riscv/include/asm/pgtable.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/riscv/include/asm/pgtable.h b/arch/riscv/include/asm/pgtable.h index 7ec936910a96..84a791d54f95 100644 --- a/arch/riscv/include/asm/pgtable.h +++ b/arch/riscv/include/asm/pgtable.h @@ -418,6 +418,9 @@ static inline void update_mmu_cache(struct vm_area_struct *vma, local_flush_tlb_page(address); } +#define __HAVE_ARCH_UPDATE_MMU_TLB +#define update_mmu_tlb update_mmu_cache + static inline void update_mmu_cache_pmd(struct vm_area_struct *vma, unsigned long address, pmd_t *pmdp) { -- 2.30.2