2 * Platform dependent support for HP simulator.
4 * Copyright (C) 1998, 1999, 2002 Hewlett-Packard Co
5 * David Mosberger-Tang <davidm@hpl.hp.com>
6 * Copyright (C) 1999 Vijay Chander <vijay@engr.sgi.com>
8 #include <linux/config.h>
10 #include <linux/init.h>
11 #include <linux/kernel.h>
12 #include <linux/param.h>
13 #include <linux/string.h>
14 #include <linux/types.h>
15 #include <linux/tty.h>
16 #include <linux/kdev_t.h>
17 #include <linux/console.h>
19 #include <asm/delay.h>
22 #include <asm/machvec.h>
23 #include <asm/pgtable.h>
26 #include "hpsim_ssc.h"
28 static int simcons_init (struct console *, char *);
29 static void simcons_write (struct console *, const char *, unsigned);
30 static struct tty_driver *simcons_console_device (struct console *, int *);
32 struct console hpsim_cons = {
34 .write = simcons_write,
35 .device = simcons_console_device,
36 .setup = simcons_init,
37 .flags = CON_PRINTBUFFER,
42 simcons_init (struct console *cons, char *options)
48 simcons_write (struct console *cons, const char *buf, unsigned count)
54 ia64_ssc(ch, 0, 0, 0, SSC_PUTCHAR);
56 ia64_ssc('\r', 0, 0, 0, SSC_PUTCHAR);
60 static struct tty_driver *simcons_console_device (struct console *c, int *index)
62 extern struct tty_driver *hp_simserial_driver;
64 return hp_simserial_driver;