xref: /csrg-svn/sys/kern/tty_conf.c (revision 37587)
123389Smckusick /*
229108Smckusick  * Copyright (c) 1982, 1986 Regents of the University of California.
323389Smckusick  * All rights reserved.  The Berkeley software License Agreement
423389Smckusick  * specifies the terms and conditions for redistribution.
523389Smckusick  *
6*37587Smarc  *	@(#)tty_conf.c	7.4 (Berkeley) 05/01/89
723389Smckusick  */
88553Sroot 
917096Sbloom #include "param.h"
1017096Sbloom #include "systm.h"
1117096Sbloom #include "buf.h"
1217575Sbloom #include "ioctl.h"
1317096Sbloom #include "tty.h"
1417096Sbloom #include "conf.h"
158553Sroot 
168553Sroot int	nodev();
178553Sroot int	nulldev();
188553Sroot 
1925391Skarels int	ttyopen(),ttylclose(),ttread(),ttwrite(),nullioctl(),ttstart();
2025391Skarels int	ttymodem(), nullmodem(), ttyinput();
218553Sroot 
2235811Smarc int	ottyopen(), ottylclose(), ottread(), ottwrite();
2335811Smarc int	ottyinput(), ottstart(), ottymodem();
2435811Smarc 
258553Sroot #include "tb.h"
268553Sroot #if NTB > 0
278553Sroot int	tbopen(),tbclose(),tbread(),tbinput(),tbioctl();
288553Sroot #endif
2926123Skarels #include "sl.h"
3026123Skarels #if NSL > 0
3126123Skarels int	slopen(),slclose(),slinput(),sltioctl(),slstart();
3226123Skarels #endif
338553Sroot 
3426123Skarels 
358553Sroot struct	linesw linesw[] =
368553Sroot {
3735811Smarc 	ttyopen, ttylclose, ttread, ttwrite, nullioctl,
3835811Smarc 	ttyinput, nodev, nulldev, ttstart, ttymodem,	/* 0- termios */
39*37587Smarc 
40*37587Smarc 	nodev, nodev, nodev, nodev, nodev,		/* 1- defunct */
418553Sroot 	nodev, nodev, nodev, nodev, nodev,
42*37587Smarc 
4335811Smarc 	nodev, nodev, nodev, nodev, nodev,		/* 2- defunct */
4435811Smarc 	nodev, nodev, nodev, nodev, nodev,
458553Sroot #if NTB > 0
468553Sroot 	tbopen, tbclose, tbread, nodev, tbioctl,
4726123Skarels 	tbinput, nodev, nulldev, ttstart, nullmodem,	/* 3- TABLDISC */
488553Sroot #else
498553Sroot 	nodev, nodev, nodev, nodev, nodev,
508553Sroot 	nodev, nodev, nodev, nodev, nodev,
518553Sroot #endif
5226123Skarels #if NSL > 0
5326123Skarels 	slopen, slclose, nodev, nodev, sltioctl,
5434488Skarels 	slinput, nodev, nulldev, slstart, nullmodem,	/* 4- SLIPDISC */
5526123Skarels #else
5626123Skarels 	nodev, nodev, nodev, nodev, nodev,
5726123Skarels 	nodev, nodev, nodev, nodev, nodev,
5826123Skarels #endif
598553Sroot };
608553Sroot 
618562Sroot int	nldisp = sizeof (linesw) / sizeof (linesw[0]);
6212753Ssam 
6312753Ssam /*
6412753Ssam  * Do nothing specific version of line
6512753Ssam  * discipline specific ioctl command.
6612753Ssam  */
6712753Ssam /*ARGSUSED*/
6812753Ssam nullioctl(tp, cmd, data, flags)
6912753Ssam 	struct tty *tp;
7012753Ssam 	char *data;
7112753Ssam 	int flags;
7212753Ssam {
7312753Ssam 
7412753Ssam #ifdef lint
7512753Ssam 	tp = tp; data = data; flags = flags;
7612753Ssam #endif
7712753Ssam 	return (-1);
7812753Ssam }
79