diff --git a/sys/dev/dec/dz.c b/sys/dev/dec/dz.c index fe6aefeadd75..373513f377f9 100644 --- a/sys/dev/dec/dz.c +++ b/sys/dev/dec/dz.c @@ -1,4 +1,4 @@ -/* $NetBSD: dz.c,v 1.3 2002/09/06 13:18:43 gehenna Exp $ */ +/* $NetBSD: dz.c,v 1.4 2002/09/18 16:51:16 ad Exp $ */ /* * Copyright (c) 1996 Ken C. Wellsch. All rights reserved. * Copyright (c) 1992, 1993 @@ -37,7 +37,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: dz.c,v 1.3 2002/09/06 13:18:43 gehenna Exp $"); +__KERNEL_RCSID(0, "$NetBSD: dz.c,v 1.4 2002/09/18 16:51:16 ad Exp $"); #include "opt_ddb.h" @@ -152,8 +152,10 @@ dzattach(struct dz_softc *sc, struct evcnt *parent_evcnt) /* Initialize our softc structure. Should be done in open? */ - for (n = 0; n < sc->sc_type; n++) + for (n = 0; n < sc->sc_type; n++) { + sc->sc_dz[n].dz_line = n; sc->sc_dz[n].dz_tty = ttymalloc(); + } evcnt_attach_dynamic(&sc->sc_rintrcnt, EVCNT_TYPE_INTR, parent_evcnt, sc->sc_dev.dv_xname, "rintr"); diff --git a/sys/dev/dec/dzvar.h b/sys/dev/dec/dzvar.h index 2ea91f4f0a67..e71b4fe39ed7 100644 --- a/sys/dev/dec/dzvar.h +++ b/sys/dev/dec/dzvar.h @@ -1,4 +1,4 @@ -/* $NetBSD: dzvar.h,v 1.1 2002/02/25 14:58:08 ad Exp $ */ +/* $NetBSD: dzvar.h,v 1.2 2002/09/18 16:51:16 ad Exp $ */ /* * Copyright (c) 1996 Ken C. Wellsch. All rights reserved. * Copyright (c) 1992, 1993 @@ -61,7 +61,7 @@ struct dz_softc { u_char sc_dsr; /* DSR set bits if no mdm ctrl */ struct dz_linestate { struct dz_softc *dz_sc; /* backpointer to softc */ - int dz_line; /* sub-driver unit number */ + int dz_line; /* channel number */ void *dz_private; /* sub-driver data pointer */ int (*dz_catch) __P((void *, int)); /* Fast catch recv */ struct tty * dz_tty; /* what we work on */