xref: /csrg-svn/sys/kern/tty_conf.c (revision 23389)
1*23389Smckusick /*
2*23389Smckusick  * Copyright (c) 1982 Regents of the University of California.
3*23389Smckusick  * All rights reserved.  The Berkeley software License Agreement
4*23389Smckusick  * specifies the terms and conditions for redistribution.
5*23389Smckusick  *
6*23389Smckusick  *	@(#)tty_conf.c	6.5 (Berkeley) 06/08/85
7*23389Smckusick  */
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 
198553Sroot int	ttyopen(),ttyclose(),ttread(),ttwrite(),nullioctl(),ttstart();
208553Sroot int	ttyinput();
218553Sroot 
228553Sroot #include "bk.h"
238553Sroot #if NBK > 0
248553Sroot int	bkopen(),bkclose(),bkread(),bkinput(),bkioctl();
258553Sroot #endif
268553Sroot 
278553Sroot #include "tb.h"
288553Sroot #if NTB > 0
298553Sroot int	tbopen(),tbclose(),tbread(),tbinput(),tbioctl();
308553Sroot #endif
318553Sroot 
328553Sroot struct	linesw linesw[] =
338553Sroot {
3415079Skarels 	ttyopen, nulldev, ttread, ttwrite, nullioctl,
358553Sroot 	ttyinput, nodev, nulldev, ttstart, nulldev,
368553Sroot #if NBK > 0
378553Sroot 	bkopen, bkclose, bkread, ttwrite, bkioctl,
388553Sroot 	bkinput, nodev, nulldev, ttstart, nulldev,
398553Sroot #else
408553Sroot 	nodev, nodev, nodev, nodev, nodev,
418553Sroot 	nodev, nodev, nodev, nodev, nodev,
428553Sroot #endif
438553Sroot 	ttyopen, ttyclose, ttread, ttwrite, nullioctl,
448553Sroot 	ttyinput, nodev, nulldev, ttstart, nulldev,
458553Sroot #if NTB > 0
468553Sroot 	tbopen, tbclose, tbread, nodev, tbioctl,
478553Sroot 	tbinput, nodev, nulldev, ttstart, nulldev,		/* 3 */
488553Sroot #else
498553Sroot 	nodev, nodev, nodev, nodev, nodev,
508553Sroot 	nodev, nodev, nodev, nodev, nodev,
518553Sroot #endif
528553Sroot #if NTB > 0
538553Sroot 	tbopen, tbclose, tbread, nodev, tbioctl,
548553Sroot 	tbinput, nodev, nulldev, ttstart, nulldev,		/* 4 */
558553Sroot #else
568553Sroot 	nodev, nodev, nodev, nodev, nodev,
578553Sroot 	nodev, nodev, nodev, nodev, nodev,
588553Sroot #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