Date: Tue, 18 Nov 1997 09:56:22 GMT
From: Roman Hodek <rnhodek@faui22c.informatik.uni-erlangen.de>
To: linux-m68k@lists.linux-m68k.org
Subject: L68K: Another sercons fix...
Sender: owner-linux-m68k@phil.uni-sb.de


Unfortunately my yesterday sercons patch sucked :-(( The prototypes
must be moved before their usage, and serial_console_cflags is also
used somewhere else, so I can't delete it. Please apply the patch
below after the one from yesterday so things compile again...

Roman (who should try 'make zImage' before posting... :-)

------------------------------------------------------------------------------
--- linux-2.1.64.orig/drivers/char/m68kserial.c	Tue Nov 18 10:53:56 1997
+++ linux-2.1.64/drivers/char/m68kserial.c	Mon Nov 17 21:43:47 1997
@@ -140,6 +140,7 @@
 static struct termios *serial_termios_locked[NR_PORTS];
 #ifdef CONFIG_SERIAL_CONSOLE
 static struct console sercons;
+static int serial_console_cflag;
 #endif
 
 #ifndef MIN
@@ -1653,6 +1654,16 @@
 	return MKDEV(TTY_MAJOR, 64 + c->index);
 }
 
+extern void amiga_serial_console_write(const char *s, unsigned int count);
+extern int amiga_serial_console_wait_key(void);
+extern void amiga_init_serial_console(struct async_struct *info, int cflag);
+extern void atari_mfp_console_write (const char *str, unsigned int count);
+extern int atari_mfp_console_wait_key(void);
+extern void atari_init_mfp_port( int cflag );
+extern void atari_scc_console_write (const char *str, unsigned int count);
+extern int atari_scc_console_wait_key(void);
+extern void atari_init_scc_port( int cflag );
+
 /*
  *	Setup initial baud/bits/parity.
  */
@@ -1716,7 +1727,8 @@
 			cflag |= PARENB;
 			break;
 	}
-
+	serial_console_cflag = cflag;
+	
 	/* Initialization of the port and filling in the missing fields of the
 	 * sercons struct must happen here, since register_console() already uses
 	 * write to print the log buffer. */
@@ -1756,16 +1768,6 @@
 	0,
 	NULL
 };
-
-extern void amiga_serial_console_write(const char *s, unsigned int count);
-extern int amiga_serial_console_wait_key(void);
-extern void amiga_init_serial_console(struct async_struct *info, int cflag);
-extern void atari_mfp_console_write (const char *str, unsigned int count);
-extern int atari_mfp_console_wait_key(void);
-extern void atari_init_mfp_port( int cflag );
-extern void atari_scc_console_write (const char *str, unsigned int count);
-extern int atari_scc_console_wait_key(void);
-extern void atari_init_scc_port( int cflag );
 
 /*
  * This is here to set the speed etc. for a non-initialized
