ip22zilog resurrection

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello !

Switch back the channels according to PROM/documentation/case numbering,
do some other small changes (patch attached), and you should have serial
console available again.

However, i couldn't test this fully. On my IP28, when entering userland
in 2.6 (no matter whether /sbin/init or /bin/sh), the output in the
console-window becomes slower and slower, asymptotically reaching a
standstill, before the login prompt appears (while the machine still can
be ping'ed over ethernet without degradation)  :-(

Good luck

peter



On Thu, 17 Jun 2004, Kumba wrote:

> Date: Thu, 17 Jun 2004 17:47:56 -0400
> From: Kumba <kumba@xxxxxxxxxx>
> To: linux-mips@xxxxxxxxxxxxxx
> Subject: Re: Swap and 2.6
> 
> ..., and ip22zilog is shot dead in 
> 2.6.x, ...
> 
> --Kumba

diff -Naur linux-2.6.x-cvsweb/arch/mips/sgi-ip22/ip22-setup.c linux-2.6.x-local/arch/mips/sgi-ip22/ip22-setup.c
--- linux-2.6.x-cvsweb/arch/mips/sgi-ip22/ip22-setup.c	Thu Apr 29 14:37:10 2004
+++ linux-2.6.x-local/arch/mips/sgi-ip22/ip22-setup.c	Wed Jun 16 23:23:07 2004
@@ -99,6 +99,9 @@
 			strcpy(options, baud);
 		add_preferred_console("ttyS", *(ctype + 1) == '2' ? 1 : 0,
 				      baud ? options : NULL);
+#ifdef CONFIG_SERIAL_IP22_ZILOG_CONSOLE
+		serial_console = *(ctype + 1) == '2' ? 2 : 1;
+#endif
 	} else if (!ctype || *ctype != 'g') {
 		/* Use ARC if we don't want serial ('d') or Newport ('g'). */
 		prom_flags |= PROM_FLAG_USE_AS_CONSOLE;
@@ -150,3 +153,7 @@
 }
 
 early_initcall(ip22_setup);
+/*
+ * Revision 1.38, Thu Apr 29 14:37:10 2004 UTC
+ * Wed Jun 16 23:23:07 2004
+ */
diff -Naur linux-2.6.x-cvsweb/drivers/serial/ip22zilog.c linux-2.6.x-local/drivers/serial/ip22zilog.c
--- linux-2.6.x-cvsweb/drivers/serial/ip22zilog.c	Tue Dec 23 16:02:13 2003
+++ linux-2.6.x-local/drivers/serial/ip22zilog.c	Wed Jun 16 23:22:37 2004
@@ -62,7 +62,7 @@
 #define NUM_IP22ZILOG	1
 #define NUM_CHANNELS	(NUM_IP22ZILOG * 2)
 
-#define ZS_CLOCK		4915200 /* Zilog input clock rate. */
+#define ZS_CLOCK		3672000	/* Zilog input clock rate */
 #define ZS_CLOCK_DIVISOR	16      /* Divisor this driver uses. */
 
 /*
@@ -955,6 +955,7 @@
 	.driver_name	=	"ttyS",
 	.devfs_name	=	"tty/",
 	.major		=	TTY_MAJOR,
+	.dev_name	=	"ttyS",
 };
 
 static void * __init alloc_one_table(unsigned long size)
@@ -1169,8 +1170,11 @@
 		if (!ip22zilog_chip_regs[chip]) {
 			ip22zilog_chip_regs[chip] = rp = get_zs(chip);
 
-			up[(chip * 2) + 0].port.membase = (char *) &rp->channelA;
-			up[(chip * 2) + 1].port.membase = (char *) &rp->channelB;
+			up[(chip * 2) + 0].port.membase = (char *) &rp->channelB;
+			up[(chip * 2) + 1].port.membase = (char *) &rp->channelA;
+
+			up[(chip * 2) + 0].port.mapbase = CPHYSADDR(&rp->channelB);
+			up[(chip * 2) + 1].port.mapbase = CPHYSADDR(&rp->channelA);
 		}
 
 		/* Channel A */
@@ -1305,3 +1309,7 @@
 MODULE_AUTHOR("Ralf Baechle <ralf@xxxxxxxxxxxxxx>");
 MODULE_DESCRIPTION("SGI Zilog serial port driver");
 MODULE_LICENSE("GPL");
+/*
+ * Revision 1.11, Tue Dec 23 16:02:13 2003 UTC
+ * Wed Jun 16 23:22:37 2004 (1087420957)
+ */

[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux