patch-2.1.126 linux/arch/mips/sgi/kernel/indy_hpc.c

Next file: linux/arch/mips/sgi/kernel/indy_int.c
Previous file: linux/arch/mips/sgi/kernel/indyIRQ.S
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.125/linux/arch/mips/sgi/kernel/indy_hpc.c linux/arch/mips/sgi/kernel/indy_hpc.c
@@ -1,15 +1,13 @@
-/*
+/* $Id: indy_hpc.c,v 1.4 1998/07/14 09:12:27 ralf Exp $
+ *
  * indy_hpc.c: Routines for generic manipulation of the HPC controllers.
  *
  * Copyright (C) 1996 David S. Miller (dm@engr.sgi.com)
- *
- * $Id: indy_hpc.c,v 1.2 1998/05/01 01:35:14 ralf Exp $
+ * Copyright (C) 1998 Ralf Baechle
  */
 #include <linux/init.h>
 
 #include <asm/addrspace.h>
-#include <asm/ptrace.h>
-#include <asm/processor.h>
 #include <asm/sgihpc.h>
 #include <asm/sgint23.h>
 #include <asm/sgialib.h>
@@ -20,27 +18,13 @@
 struct hpc3_miscregs *hpc3mregs;
 
 /* We need software copies of these because they are write only. */
-static unsigned long write1, write2;
+unsigned long sgi_hpc_write1, sgi_hpc_write2;
 
 /* Machine specific identifier knobs. */
 int sgi_has_ioc2 = 0;
 int sgi_guiness = 0;
 int sgi_boardid;
 
-void sgihpc_write1_modify(int set, int clear)
-{
-	write1 |= set;
-	write1 &= ~clear;
-	hpc3mregs->write1 = write1;
-}
-
-void sgihpc_write2_modify(int set, int clear)
-{
-	write2 |= set;
-	write2 &= ~clear;
-	hpc3mregs->write2 = write2;
-}
-
 __initfunc(void sgihpc_init(void))
 {
 	unsigned long sid, crev, brev;
@@ -96,12 +80,12 @@
 	prom_printf("\n");
 #endif
 
-	write1 = (HPC3_WRITE1_PRESET |
+	sgi_hpc_write1 = (HPC3_WRITE1_PRESET |
 		  HPC3_WRITE1_KMRESET |
 		  HPC3_WRITE1_ERESET |
 		  HPC3_WRITE1_LC0OFF);
 
-	write2 = (HPC3_WRITE2_EASEL |
+	sgi_hpc_write2 = (HPC3_WRITE2_EASEL |
 		  HPC3_WRITE2_NTHRESH |
 		  HPC3_WRITE2_TPSPEED |
 		  HPC3_WRITE2_EPSEL |
@@ -109,9 +93,9 @@
 		  HPC3_WRITE2_U1AMODE);
 
 	if(!sgi_guiness)
-		write1 |= HPC3_WRITE1_GRESET;
-	hpc3mregs->write1 = write1;
-	hpc3mregs->write2 = write2;
+		sgi_hpc_write1 |= HPC3_WRITE1_GRESET;
+	hpc3mregs->write1 = sgi_hpc_write1;
+	hpc3mregs->write2 = sgi_hpc_write2;
 
 	hpc3c0->pbus_piocfgs[0][6] |= HPC3_PIOPCFG_HW;
 }

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