patch-2.1.115 linux/arch/ppc/kernel/ppc_htab.c

Next file: linux/arch/ppc/kernel/ppc_ksyms.c
Previous file: linux/arch/ppc/kernel/ppc-stub.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.114/linux/arch/ppc/kernel/ppc_htab.c linux/arch/ppc/kernel/ppc_htab.c
@@ -1,5 +1,5 @@
 /*
- * $Id: ppc_htab.c,v 1.18 1998/04/24 12:29:39 davem Exp $
+ * $Id: ppc_htab.c,v 1.21 1998/05/13 22:34:55 cort Exp $
  *
  * PowerPC hash table management proc entry.  Will show information
  * about the current hash table and will allow changes to it.
@@ -89,7 +89,6 @@
 #define PMC1 953
 #define PMC2 954
 
-#ifndef CONFIG_8xx
 char *pmc1_lookup(unsigned long mmcr0)
 {
 	switch ( mmcr0 & (0x7f<<7) )
@@ -125,7 +124,6 @@
 		return "unknown";
 	}
 }	
-#endif /* CONFIG_8xx */
 
 /*
  * print some useful info about the hash table.  This function
@@ -135,7 +133,6 @@
 static ssize_t ppc_htab_read(struct file * file, char * buf,
 			     size_t count, loff_t *ppos)
 {
-#ifndef CONFIG_8xx
 	unsigned long mmcr0 = 0, pmc1 = 0, pmc2 = 0;
 	int n = 0, valid;
 	unsigned int kptes = 0, overflow = 0, uptes = 0, zombie_ptes = 0;
@@ -239,12 +236,14 @@
 
 	n += sprintf( buffer + n,
 		      "Reloads\t\t: %08lx\n"
-		      "Evicts\t\t: %08lx\n"
-		      "Non-error misses: %08lx\n"
-		      "Error misses\t: %08lx\n",
-		      htab_reloads, htab_evicts, pte_misses, pte_errors);
+		      "Evicts\t\t: %08lx\n",
+		      htab_reloads, htab_evicts);
 	
 return_string:
+	n += sprintf( buffer + n,
+		      "Non-error misses: %08lx\n"
+		      "Error misses\t: %08lx\n",
+		      pte_misses, pte_errors);
 	if (*ppos >= strlen(buffer))
 		return 0;
 	if (n > strlen(buffer) - *ppos)
@@ -252,9 +251,6 @@
 	copy_to_user(buf, buffer + *ppos, n);
 	*ppos += n;
 	return n;
-#else /* CONFIG_8xx */
-	return 0;
-#endif /* CONFIG_8xx */
 }
 
 /*

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov