From owner-freebsd-commit Mon Jul 31 11:30:01 1995 Return-Path: commit-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.11/8.6.6) id LAA17413 for commit-outgoing; Mon, 31 Jul 1995 11:30:01 -0700 Received: (from majordom@localhost) by freefall.cdrom.com (8.6.11/8.6.6) id LAA17392 for cvs-sys-outgoing; Mon, 31 Jul 1995 11:29:57 -0700 Received: (from bde@localhost) by freefall.cdrom.com (8.6.11/8.6.6) id LAA17382 ; Mon, 31 Jul 1995 11:29:53 -0700 Date: Mon, 31 Jul 1995 11:29:53 -0700 From: Bruce Evans Message-Id: <199507311829.LAA17382@freefall.cdrom.com> To: CVS-commiters, cvs-sys Subject: cvs commit: src/sys/i386/isa cy.c rc.c sio.c Sender: commit-owner@FreeBSD.org Precedence: bulk bde 95/07/31 11:29:52 Modified: sys/kern tty.c sys/sys tty.h sys/i386/isa cy.c rc.c sio.c Log: Improve input flow control. Use input buffer watermarks of TTYHOG-512 (high) and (high)*7/8 (low) instead of TTYHOG/2 (high) and TTYHOG/5 (low) to agree with some drivers. 512 is magic and some things depended on TTYHOG/2 >= TTYHOG-512 to work; now they depend on the 512 magic not changing and TTYHOG-512 being significantly larger than 0. This should be handled in ttsetwater(). Separate the decision about whether to do input flow control from doing it. ttyblock() now just starts input flow control (hardware and/or software) and there is a new function ttyunblock() to stop it. The decisions are the same except for the watermark changes and allowing for input expansion for PARMRK. When flushing input, try harder at first to send a start character if required, but give up if the first attempt fails. cy.c, rc.c, sio.c: Simplify: let ttyinput() handle input flow control if it is not being bypassed. Use ttyblock() to start flow control otherwise. rc.c: Use same input flow control test as elsewhere: test in a more efficient order and start flow control at >= highwater instead of at > highwater.