diff options
author | jake <jake@FreeBSD.org> | 2003-01-11 04:15:46 +0000 |
---|---|---|
committer | jake <jake@FreeBSD.org> | 2003-01-11 04:15:46 +0000 |
commit | d13ea619e6788c8eedaf4432084302a1c0da03c0 (patch) | |
tree | b22cf77ec62839cf56119b40a274ec0e18680993 | |
parent | 7c8a733a058ae9f140342e34e2e1cdef2281e435 (diff) | |
download | FreeBSD-src-d13ea619e6788c8eedaf4432084302a1c0da03c0.zip FreeBSD-src-d13ea619e6788c8eedaf4432084302a1c0da03c0.tar.gz |
Reset the channel in attach if its not the console.
-rw-r--r-- | sys/dev/zs/zs.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/dev/zs/zs.c b/sys/dev/zs/zs.c index 71a20f2..9836237 100644 --- a/sys/dev/zs/zs.c +++ b/sys/dev/zs/zs.c @@ -263,6 +263,7 @@ zstty_attach(device_t dev) struct zstty_softc *sc; struct tty *tp; char mode[32]; + int reset; int baud; int clen; char parity; @@ -328,6 +329,12 @@ zstty_attach(device_t dev) device_printf(dev, "console %s\n", mode); sc->sc_console = 1; zstty_cons = sc; + } else { + if ((device_get_unit(dev) & 1) == 0) + reset = ZSWR9_A_RESET; + else + reset = ZSWR9_B_RESET; + ZS_WRITE_REG(sc, 9, reset); } return (0); |