2 * Wrap-around code for a console using the
3 * SGI PROM io-routines.
5 * Copyright (c) 1999 Ulf Carlsson
7 * Derived from DECstation promcon.c
8 * Copyright (c) 1998 Harald Koerfgen
10 #include <linux/tty.h>
11 #include <linux/init.h>
12 #include <linux/console.h>
14 static void prom_console_write(struct console
*co
, const char *s
,
17 extern int CONSOLE_CHANNEL
; // The default serial port
20 for (i
= 0; i
< count
; i
++) {
22 serial_putc(CONSOLE_CHANNEL
, 13);
23 serial_putc(CONSOLE_CHANNEL
, *s
++);
27 int prom_getchar(void)
32 static struct console sercons
= {
34 .write
= prom_console_write
,
35 .flags
= CON_PRINTBUFFER
,
43 static int gal_serial_console_init(void)
48 register_console(&sercons
);
53 console_initcall(gal_serial_console_init
);