1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * Copyright (C) 2012 Regents of the University of California
6 #ifndef _ASM_RISCV_TLB_H
7 #define _ASM_RISCV_TLB_H
11 static void tlb_flush(struct mmu_gather *tlb);
13 #define tlb_flush tlb_flush
14 #include <asm-generic/tlb.h>
16 static inline void tlb_flush(struct mmu_gather *tlb)
19 if (tlb->fullmm || tlb->need_flush_all)
20 flush_tlb_mm(tlb->mm);
22 flush_tlb_mm_range(tlb->mm, tlb->start, tlb->end,
23 tlb_get_unmap_size(tlb));
27 #endif /* _ASM_RISCV_TLB_H */