patch-2.1.30 linux/arch/sparc/prom/init.c

Next file: linux/arch/sparc/prom/memory.c
Previous file: linux/arch/sparc/prom/devops.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.29/linux/arch/sparc/prom/init.c linux/arch/sparc/prom/init.c
@@ -1,4 +1,4 @@
-/* $Id: init.c,v 1.9 1996/12/18 06:46:55 tridge Exp $
+/* $Id: init.c,v 1.11 1997/03/18 17:58:24 jj Exp $
  * init.c:  Initialize internal variables used by the PROM
  *          library functions.
  *
@@ -19,6 +19,8 @@
 /* The root node of the prom device tree. */
 int prom_root_node;
 
+int prom_stdin, prom_stdout;
+
 /* Pointer to the device tree operations structure. */
 struct linux_nodeops *prom_nodeops;
 
@@ -49,11 +51,6 @@
 	case 3:
 		prom_vers = PROM_V3;
 		break;
-	case 4:
-		prom_vers = PROM_P1275;
-		prom_printf("PROMLIB: Sun IEEE Prom not supported yet\n");
-		prom_halt();
-		break;
 	case 42: /* why not :-) */
 		prom_vers = PROM_AP1000;
 		break;
@@ -77,6 +74,11 @@
 	   (((unsigned long) prom_nodeops) == -1))
 		prom_halt();
 
+	if(prom_vers == PROM_V2 || prom_vers == PROM_V3) {
+		prom_stdout = *romvec->pv_v2bootargs.fd_stdout;
+		prom_stdin  = *romvec->pv_v2bootargs.fd_stdin;
+	}
+	
 	prom_meminit();
 
 	prom_ranges_init();

FUNET's LINUX-ADM group, [email protected]
TCL-scripts by Sam Shen, [email protected]