freebsd-dev/sys/kern
Bruce Evans 9fa18570a2 Obtained from: partly from ancient patches of mine via 1.1.5
Introduce TS_CONNECTED and TS_ZOMBIE states.  TS_CONNECTED is set
while a connection is established.  It is set while (TS_CARR_ON or
CLOCAL is set) and TS_ZOMBIE is clear.  TS_ZOMBIE is set for on to
off transitions of TS_CARR_ON that occur when CLOCAL is clear and
is cleared for off to on transitions of CLOCAL.  I/o can only occur
while TS_CONNECTED is set.  TS_ZOMBIE prevents further i/o.

Split the input-event sleep address TSA_CARR_ON(tp) into TSA_CARR_ON(tp)
and TSA_HUP_OR_INPUT(tp).  The former address is now used only for
off to on carrier transitions and equivalent CLOCAL transitions.
The latter is used for all input events, all carrier transitions
and certain CLOCAL transitions.  There are some harmless extra
wakeups for rare connection- related events.  Previously there were
too many extra wakeups for non-rare input events.

Drivers now call l_modem() instead of setting TS_CARR_ON directly
to handle even the initial off to on transition of carrier.  They
should always have done this.  l_modem() now handles TS_CONNECTED
and TS_ZOMBIE as well as TS_CARR_ON.

gnu/isdn/iitty.c:
Set TS_CONNECTED for first open ourself to go with bogusly setting
CLOCAL.

i386/isa/syscons.c, i386/isa/pcvt/pcvt_drv.c:
We fake carrier, so don't also fake CLOCAL.

kern/tty.c:
Testing TS_CONNECTED instead of TS_CARR_ON fixes TIOCCONS forgetting to
test CLOCAL.  TS_ISOPEN was tested instead, but that broke when we disabled
the clearing of TS_ISOPEN for certain transitions of CLOCAL.

Testing TS_CONNECTED fixes ttyselect() returning false success for output
to devices in state !TS_CARR_ON && !CLOCAL.

Optimize the other selwakeup() call (this is not related to the other
changes).

kern/tty_pty.c:
ptcopen() can be declared in traditional C now that dev_t isn't short.
1995-07-31 21:02:00 +00:00
..
imgact_aout.c Merge RELENG_2_0_5 into HEAD 1995-06-11 19:33:05 +00:00
imgact_gzip.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
imgact_shell.c While in the real world, I had a bad case of being swapped out for a lot of 1994-09-25 19:34:02 +00:00
inflate.c Changes needed for kzip to work. 1995-04-15 06:54:13 +00:00
init_main.c NFS diskless operation was broken because swapdev_vp wasn't initialized. 1995-05-19 03:27:08 +00:00
init_sysent.c Make setreuid/setregid active syscalls 1995-04-23 12:22:06 +00:00
kern_acct.c Use the same method to determine the time that the process 1995-07-23 23:02:20 +00:00
kern_clock.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
kern_descrip.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_devconf.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_exec.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_exit.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_fork.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_ktrace.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_lkm.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_lockf.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_malloc.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_ntptime.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_physio.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_proc.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_prot.c Optimized and simplified version of setreuid/gid 1995-06-15 22:32:03 +00:00
kern_resource.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_sig.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_subr.c Improved hashinit panic strings. 1995-05-08 23:11:12 +00:00
kern_synch.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
kern_sysctl.c Fix the sysctl string routines to return as much of the 1995-07-31 10:07:31 +00:00
kern_tc.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
kern_time.c Killed "TIMEZONE" and "DST" options. They have been forced to 0 by config 1995-06-29 07:07:00 +00:00
kern_timeout.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
kern_xxx.c Rewrote shutdown_nice() to fix the init-not-yet-started panic(). 1995-07-30 17:10:36 +00:00
Make.tags.inc Added $Id$ 1994-08-02 07:55:43 +00:00
Makefile Added namespace information for future pollution-control measures. 1994-09-13 00:48:26 +00:00
makesyscalls.sh Add and move declarations to fix all of the warnings from `gcc -Wimplicit' 1995-03-16 18:17:34 +00:00
md5c.c Clean a bunch of -Wall warnings. 1995-02-24 08:51:34 +00:00
subr_autoconf.c Added $Id$ 1994-08-02 07:55:43 +00:00
subr_clist.c Optimize the zeroing of quotes. b_to_q() was always taking about 20% of 1995-07-11 19:39:54 +00:00
subr_disklabel.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
subr_diskmbr.c Make the "information" slice printfs if(bootverbose). 1995-05-18 22:45:35 +00:00
subr_diskslice.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
subr_dkbad.c subr_diskslice.c implements everything related to slices and labels except 1994-12-12 00:20:34 +00:00
subr_log.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
subr_param.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
subr_prf.c Convert %p to 0x%x instead of to 0x%8x. The latter gives blank padding 1995-06-14 07:55:07 +00:00
subr_prof.c Add and move declarations to fix all of the warnings from `gcc -Wimplicit' 1995-03-16 18:17:34 +00:00
subr_rlist.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
subr_rmap.c Added $Id$ 1994-08-02 07:55:43 +00:00
subr_trap.c Fix a bug in my disabled version of trap_pfault()...curpcb may be NULL even 1995-07-30 17:49:24 +00:00
subr_xxx.c Added $Id$ 1994-08-02 07:55:43 +00:00
sys_generic.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
sys_process.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
sys_socket.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
syscalls.c Make setreuid/setregid active syscalls 1995-04-23 12:22:06 +00:00
syscalls.master Make setreuid/setregid active syscalls 1995-04-23 12:22:06 +00:00
sysv_ipc.c Added SYSV ipcs. 1994-09-13 14:47:38 +00:00
sysv_msg.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
sysv_sem.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
sysv_shm.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
tty_compat.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
tty_conf.c Obtained from: partly from ancient patches by ache and me via 1.1.5 1995-07-29 13:40:13 +00:00
tty_cons.c Partially fix `sysctl machdep.console_device'. The fix will be complete 1995-06-26 07:39:52 +00:00
tty_pty.c Obtained from: partly from ancient patches of mine via 1.1.5 1995-07-31 21:02:00 +00:00
tty_snoop.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
tty_subr.c Optimize the zeroing of quotes. b_to_q() was always taking about 20% of 1995-07-11 19:39:54 +00:00
tty_tb.c Added $Id$ 1994-08-02 07:55:43 +00:00
tty_tty.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
tty.c Obtained from: partly from ancient patches of mine via 1.1.5 1995-07-31 21:02:00 +00:00
uipc_domain.c Delete two debugging printfs that mistakenly crept in. 1995-05-11 00:16:44 +00:00
uipc_mbuf.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
uipc_proto.c Make networking domains drop-ins, through the magic of GNU ld. (Some day, 1995-05-11 00:13:26 +00:00
uipc_sockbuf.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
uipc_socket2.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
uipc_socket.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
uipc_syscalls.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
uipc_usrreq.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
vfs_bio.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
vfs_cache.c Eliminate sloppy common-style declarations. There should be none left for 1995-07-29 11:44:31 +00:00
vfs_cluster.c Don't include vm_pageout.h. 1995-06-28 12:31:47 +00:00
vfs_conf.c Make a kernel sans FFS possible. 1994-11-12 01:47:43 +00:00
vfs_export.c NOTE: libkvm, w, ps, 'top', and any other utility which depends on struct 1995-07-13 08:48:48 +00:00
vfs_extattr.c Ignore trailing slashes in pathnames that "refer to a directory", 1995-07-31 00:35:58 +00:00
vfs_init.c Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
vfs_lookup.c Ignore trailing slashes in pathnames that "refer to a directory", 1995-07-31 00:35:58 +00:00
vfs_mount.c Make a kernel sans FFS possible. 1994-11-12 01:47:43 +00:00
vfs_subr.c NOTE: libkvm, w, ps, 'top', and any other utility which depends on struct 1995-07-13 08:48:48 +00:00
vfs_syscalls.c Ignore trailing slashes in pathnames that "refer to a directory", 1995-07-31 00:35:58 +00:00
vfs_vnops.c vnode_pager_alloc() never returns NULL, so don't check for it. 1995-07-20 09:43:12 +00:00
vnode_if.pl The generated VCALL always uses the first vp which in the case of /link/ 1995-07-07 13:41:28 +00:00
vnode_if.sh The generated VCALL always uses the first vp which in the case of /link/ 1995-07-07 13:41:28 +00:00
vnode_if.src The generated VCALL always uses the first vp which in the case of /link/ 1995-07-07 13:41:28 +00:00