patch-1.3.71 linux/include/asm-sparc/tsunami.h

Next file: linux/include/asm-sparc/unistd.h
Previous file: linux/include/asm-sparc/timer.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.70/linux/include/asm-sparc/tsunami.h linux/include/asm-sparc/tsunami.h
@@ -1,4 +1,4 @@
-/* $Id: tsunami.h,v 1.2 1995/11/25 02:33:06 davem Exp $
+/* $Id: tsunami.h,v 1.3 1996/01/10 21:00:12 davem Exp $
  * tsunami.h:  Module specific definitions for Tsunami V8 Sparcs
  *
  * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu)
@@ -7,6 +7,8 @@
 #ifndef _SPARC_TSUNAMI_H
 #define _SPARC_TSUNAMI_H
 
+#include <asm/asi.h>
+
 /* The MMU control register on the Tsunami:
  *
  * -----------------------------------------------------------------------
@@ -42,5 +44,17 @@
 #define TSUNAMI_DENAB     0x00000100
 #define TSUNAMI_NF        0x00000002
 #define TSUNAMI_ME        0x00000001
+
+extern inline void tsunami_invalidate_icache(void)
+{
+	__asm__ __volatile__("sta %%g0, [%%g0] %0\n\t" : :
+			     "i" (ASI_M_IC_FLCLEAR) : "memory");
+}
+
+extern inline void tsunami_invalidate_dcache(void)
+{
+	__asm__ __volatile__("sta %%g0, [%%g0] %0\n\t" : :
+			     "i" (ASI_M_DC_FLCLEAR) : "memory");
+}
 
 #endif /* !(_SPARC_TSUNAMI_H) */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this