|
From: Jan-Benedict G. <jb...@us...> - 2004-09-30 21:13:13
|
Update of /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25055 Modified Files: cpu_generic.c Log Message: - Console helpers for VXT2000. There's yet a problem with them, but I hope to fix that these days:-) Index: cpu_generic.c =================================================================== RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/cpu_generic.c,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- cpu_generic.c 30 Jul 2004 00:17:16 -0000 1.11 +++ cpu_generic.c 30 Sep 2004 21:13:03 -0000 1.12 @@ -172,3 +172,39 @@ } //#endif /* CONFIG_DZ */ +#ifdef CONFIG_CPU_VXT +volatile int *vxt2694_addr = NULL; + +void +vxt2694_putchar (int c) +{ + /* wait for TxRDY */ + while ((vxt2694_addr[1] & 4) == 0) + /* spin */; + + /* send the character */ + vxt2694_addr[3] = c & 0xff; +} + +int +vxt2694_getchar (void) +{ + HALT; + return 0; +} + +void +init_vxt2694_console (unsigned long phys_addr) +{ + char *teststring = "Hello you!"; + int i; + + if (vxt2694_addr) + return; + vxt2694_addr = ioremap (phys_addr, 256); + + for (i = 0; i < strlen (teststring); i++) + vxt2694_putchar (teststring[i]); +} +#endif /* CONFIG_CPU_VXT */ + |