Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site watmath.UUCP Path: utzoo!watmath!kwlalonde From: kwlalonde@watmath.UUCP (Ken Lalonde) Newsgroups: net.unix-wizards Subject: Re: Problem with modem ports (bug in 4.2BSD dmf driver) Message-ID: <14504@watmath.UUCP> Date: Fri, 17-May-85 13:32:18 EDT Article-I.D.: watmath.14504 Posted: Fri May 17 13:32:18 1985 Date-Received: Sat, 18-May-85 01:01:18 EDT References: <235@amdimage.UUCP> Distribution: net Organization: U of Waterloo, Ontario Lines: 39 The DMF driver stops listening for carrier transitions when the other end hangs up. Look at vaxuba/dmf.c, function dmfrint(). Change the code to read as shown below. } else { if (tp->t_state & TS_CARR_ON) { gsignal(tp->t_pgrp, SIGHUP); gsignal(tp->t_pgrp, SIGCONT); addr->dmfcsr = DMF_IE | DMFIR_LCR | ((c>>8)&07); /* next line used to read addr->dmftms = 0; */ addr->dmfun.dmfirw = DMFLCR_ENA; ttyflush(tp, FREAD|FWRITE); } tp->t_state &= ~TS_CARR_ON; } In fact, all references to field dmftms are in error, since that register is not byte addressable. While you have your feet wet, there is a missing splx() in dmfparam(): /* * Block interrupts so parameters will be set * before the line interrupts. */ s = spl5(); addr->dmfcsr = (unit&07) | DMFIR_LCR | DMF_IE; if ((tp->t_ispeed)==0) { tp->t_state |= TS_HUPCLS; (void) dmfmctl(unit, DMF_OFF, DMSET); splx(s); /* This was missing */ return; } Also, the first argument to dmfparam() is sometimes a device number, sometimes a minor number. It should always be the minor number, since some callers don't have the device number handy. - Ken Lalonde ihnp4!watmath!kwlalonde