patch-2.3.43 linux/include/asm-sparc64/pgalloc.h

Next file: linux/include/asm-sparc64/posix_types.h
Previous file: linux/include/asm-sparc64/mmu_context.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.42/linux/include/asm-sparc64/pgalloc.h linux/include/asm-sparc64/pgalloc.h
@@ -94,6 +94,28 @@
 
 #endif /* ! __SMP__ */
 
+/* This will change for Cheetah and later chips. */
+#define VPTE_BASE	0xfffffffe00000000
+
+extern __inline__ void flush_tlb_pgtables(struct mm_struct *mm, unsigned long start,
+					  unsigned long end)
+{
+	/* Note the signed type.  */
+	long s = start, e = end;
+	if (s > e)
+		/* Nobody should call us with start below VM hole and end above.
+		   See if it is really true.  */
+		BUG();
+#if 0
+	/* Currently free_pgtables guarantees this.  */
+	s &= PMD_MASK;
+	e = (e + PMD_SIZE - 1) & PMD_MASK;
+#endif
+	flush_tlb_range(mm,
+			VPTE_BASE + (s >> (PAGE_SHIFT - 3)),
+			VPTE_BASE + (e >> (PAGE_SHIFT - 3)));
+}
+
 /* Page table allocation/freeing. */
 #ifdef __SMP__
 /* Sliiiicck */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)