=================================================================== RCS file: /cvs/funnyos/arch/testarm/dev/tacons.c,v retrieving revision 1.2 retrieving revision 1.4 diff -u -r1.2 -r1.4 --- funnyos/arch/testarm/dev/tacons.c 2007/10/16 21:28:24 1.2 +++ funnyos/arch/testarm/dev/tacons.c 2007/10/16 22:33:24 1.4 @@ -1,11 +1,12 @@ /* - * $Id: tacons.c,v 1.2 2007/10/16 20:28:24 init Exp $ + * $Id: tacons.c,v 1.4 2007/10/16 21:33:24 init Exp $ */ #include #include #include #include +#include #include #include @@ -29,7 +30,7 @@ tacons_attach(struct device *self, uint32_t loc, uint8_t flags) { struct tacons_dd *ddp = self->dv_devdata; - struct consoleops *cop = &ddp->td_consops; + struct fcons_handle *fhp = &ddp->td_fh; /* aquire bus handle from parent */ ddp->td_bhp = self->dv_parent->dv_aux; @@ -37,11 +38,14 @@ /* all reads/writes will use this addr; in testarm cons this is the same addr for getc/putc */ ddp->td_ioaddr = loc; - /* we export struct consoleops */ - cop->getc = tacons_getc; - cop->putc = tacons_putc; + /* we export struct fcons_handle */ + fhp->getc = tacons_getc; + fhp->putc = tacons_putc; - self->dv_aux = cop; + /* give our dd to fcons_handle */ + fhp->fh_ownerdd = ddp; + + self->dv_aux = fhp; printf("testarm simple console (non-blocking, halt)\n");