timeout()/untimeout() API:
- Clients supply callout handle storage, thus eliminating problems of
resource allocation.
- Insertion and removal of callouts is constant time, important as
this facility is used quite a lot in the kernel.
The old timeout()/untimeout() API has been removed from the kernel.
* Move the printf() delay to just after the printf(), where it actually makes
sense.
* Use zstty_stint() and zstty_softint() from zsparam(), to force an immediate
update of the carrier and flow control status. Abuse this in the attach and
open functions to defer all of that work. This insures that we don't lose
any status updates.
* Don't screw with register 1 when closing the console.
* Fix bugs in TIOCM??? (stay semicolon, clearing DTR while transmitting).
* Add comments in a couple of places.
Thanks to Scott for pointing this out to me (I got his mail and figured out
this change before seeing the discussion on tech-kern) and to Charles for
the initial explanation.
- When doing a first open, don't enable receive & status interupts before
the MD layer has had a chance to set things up.
- Enable logic to only enable DCD/CTS interupts if we are looking for/
expecting interupts on those pins. Disable otherwise.
- in zs_param, only pass up the state of ZSRR0_DCD if we have enabled
interupts on that pin.
Henry Hotz (<hotz@jpl.nasa.gov>) and Greg walsh <gwalsh@artec.com> have
tried these changes to get certain printers from hanging at boot. They
work in a 1.3.2 kernel for Greg.
The attach routine calls zsparam if we're setting up the console, and
zsparam needs this field to tell which zstty to set up. Otherwise, we
set up zstty0 even if it's not the console!
* Carrier detect (TS_CARR_ON) is based on the actual DCD bit, even if it's
being ignored.
* Set TS_WOPEN early on in zsopen().
* Don't disable interrupts on the console during close if we have DDB.
Inert changes:
* Don't handle ZS_HWFLAG_NO_DCD here; the frontend does it.
* Deprecate `register'.
* Use SET(), CLR(), and ISSET().
More performance changes:
* Rototill receive handling; use a backpressure mechanism to prevent livelock.
* Output silo/ibuf overflow warnings at most once per minute, from a callout.
* When we exhaust the current transmit run, turn off transmit interrupts in
zstty_txint(), so we're fairly sure we don't get another one.
control any more, and the speed of changing DTR isn't really an issue. Also,
the old code created a bug where zsparam() might have failed to set some
registers.
Change the interface to zs_hwiflow(); just have it use zst_rx_blocked.
Make zs_modem() a tiny bit faster.
Do RTS updates immediately; do not allow them to be held.
Stop output as fast as possible when DCD is deasserted.
Do *not* automatically drop DTR when DCD is deasserted.
Only check for rr0 bits that we care about (DTR and DCD).
Make sure we turn on DTR and/or RTS as appropriate during open.
Rearrange close sequence so the tty is flushed before turning off interrupts.
Deal with `softcar' and the console device by silently asserting CLOCAL and
|HUPCL, as in com driver.
Do *not* fiddle with DTR when changing the line speed.
Make sure we update the tty's carrier status when CLOCAL or MDMBUF is changed.
Only change rr1 when we actually need to turn on or off TIE.