=================================================================== RCS file: /cvs/funnyos/arch/testarm/config.c,v retrieving revision 1.8 retrieving revision 1.13 diff -u -r1.8 -r1.13 --- funnyos/arch/testarm/config.c 2007/10/29 12:43:46 1.8 +++ funnyos/arch/testarm/config.c 2007/11/20 16:10:52 1.13 @@ -1,9 +1,9 @@ /* - * $Id: config.c,v 1.8 2007/10/29 12:43:46 init Exp $ + * $Id: config.c,v 1.13 2007/11/20 16:10:52 nbrk Exp $ */ #include #include - +#include /* * Configuration file for platform (testarm). */ @@ -14,11 +14,18 @@ extern struct driver obio_dr; extern struct driver tacons_dr; extern struct driver fcons_dr; +extern struct driver tartc_dr; +extern struct driver tairqc_dr; +/* putchar & early putchar */ extern void(*putchar)(char); void tacons_early_putc(char ch); +/* tasks */ +extern void hello_enter(void); + + /* amount of physical memory, in Bytes */ uint32_t physmem = 33554432; @@ -26,13 +33,14 @@ * Where to attach each device. */ struct attachinfo config_attachinfo[] = { - /* child, parent, pminor, loc, flags */ - { "cpu" , "root", 0, 0, 0 }, - { "obio", "root", 0, 0, 0 }, - { "tacons", "obio", 0, 0x10000000, 0 }, -// { "tartc", "obio", 0, 0x15000000, 0x01 }, - { "fcons", "tacons", 0, 0, 0}, - { NULL, NULL, 0, 0, 0} + /* child, parent, pminor, loc, intrno, flags */ + { "cpu" , "root", 0, 0, 0, 0 }, + { "obio", "root", 0, 0, 0, 0 }, + { "tacons", "obio", 0, 0x10000000, 0, 0 }, + { "tartc", "obio", 0, 0x15000000, 4, 0 }, + { "tairqc", "obio", 0, 0x16000000, 0, 0 }, + { "fcons", "tacons", 0, 0, 0, 0 }, + { NULL, NULL, 0, 0, 0, 0 } }; @@ -45,24 +53,36 @@ { "obio", &obio_dr, -1 }, { "cpu" , &cpu_dr, -1 }, { "tacons", &tacons_dr, -1 }, -// { "tartc", &tartc_dr, -1 }, + { "tartc", &tartc_dr, -1 }, { "fcons", &fcons_dr, -1 }, + { "tairqc", &tairqc_dr, -1 }, { NULL, NULL, 0 } }; /* + * Tasks. + */ +struct u_task config_tasklist[] = { +/* name, priority, enter */ + { "hello", 1, hello_enter }, + { NULL, 0, NULL } +}; + + +/* * Machine early-stage initialization hooks. */ void -config_consinit(void) +config_machineinit(void) { /* * Configure putchar, so we can printf messages to the console without fcons. */ /* putchar = tauart_early_putc; */ putchar = tacons_early_putc; + }