1 /* tlbflush.h: TLB flushing functions
3 * Copyright (C) 2004 Red Hat, Inc. All Rights Reserved.
4 * Written by David Howells (dhowells@redhat.com)
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version
9 * 2 of the License, or (at your option) any later version.
12 #ifndef _ASM_TLBFLUSH_H
13 #define _ASM_TLBFLUSH_H
15 #include <linux/config.h>
17 #include <asm/processor.h>
22 extern void asmlinkage
__flush_tlb_all(void);
23 extern void asmlinkage
__flush_tlb_mm(unsigned long contextid
);
24 extern void asmlinkage
__flush_tlb_page(unsigned long contextid
, unsigned long start
);
25 extern void asmlinkage
__flush_tlb_range(unsigned long contextid
,
26 unsigned long start
, unsigned long end
);
27 #endif /* !__ASSEMBLY__ */
29 #define flush_tlb_all() \
36 #define flush_tlb_mm(mm) \
39 __flush_tlb_mm((mm)->context.id); \
43 #define flush_tlb_range(vma,start,end) \
46 __flush_tlb_range((vma)->vm_mm->context.id, start, end); \
50 #define flush_tlb_page(vma,addr) \
53 __flush_tlb_page((vma)->vm_mm->context.id, addr); \
58 #define __flush_tlb_global() flush_tlb_all()
59 #define flush_tlb() flush_tlb_all()
60 #define flush_tlb_kernel_range(start, end) flush_tlb_all()
61 #define flush_tlb_pgtables(mm,start,end) \
62 asm volatile("movgs %0,scr0 ! movgs %0,scr1" :: "r"(ULONG_MAX) : "memory");
66 #define flush_tlb() BUG()
67 #define flush_tlb_all() BUG()
68 #define flush_tlb_mm(mm) BUG()
69 #define flush_tlb_page(vma,addr) BUG()
70 #define flush_tlb_range(mm,start,end) BUG()
71 #define flush_tlb_pgtables(mm,start,end) BUG()
72 #define flush_tlb_kernel_range(start, end) BUG()
77 #endif /* _ASM_TLBFLUSH_H */