From 71ac9ea4e9b05234bb2568f369d5405f4eba162a Mon Sep 17 00:00:00 2001 From: "Ugen J.S. Antsilevich" Date: Tue, 14 Feb 1995 21:16:43 +0000 Subject: [PATCH] cdevsw[] entry for snoop device. I took 53 and it was too late when Jordan sayd it better been 60..besides i have no clue how to make it 60.. Jordan- pleeease don't kill me..(This is also useful(??) device..) --- sys/i386/i386/conf.c | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/sys/i386/i386/conf.c b/sys/i386/i386/conf.c index 8215e01aed2..827bfbe4757 100644 --- a/sys/i386/i386/conf.c +++ b/sys/i386/i386/conf.c @@ -42,7 +42,7 @@ * SUCH DAMAGE. * * from: @(#)conf.c 5.8 (Berkeley) 5/12/91 - * $Id: conf.c,v 1.60 1995/02/09 11:59:40 jkh Exp $ + * $Id: conf.c,v 1.61 1995/02/11 05:54:04 jkh Exp $ */ #include @@ -407,6 +407,23 @@ extern struct tty pt_tty[]; #define ptsstop nullstop #endif + +#include "snp.h" +#if NSNP > 0 +d_open_t snpopen; +d_close_t snpclose; +d_rdwr_t snpread; +d_select_t snpselect; +d_ioctl_t snpioctl; +#else +#define snpopen nxopen +#define snpclose nxclose +#define snpread nxread +#define snpioctl nxioctl +#define snpselect nxselect +#endif + + /* /dev/klog */ d_open_t logopen; d_close_t logclose; @@ -970,6 +987,9 @@ struct cdevsw cdevsw[] = { tunopen, tunclose, tunread, tunwrite, /*52*/ tunioctl, nostop, nullreset, NULL, /* tunnel */ tunselect, nommap, NULL }, + { snpopen, snpclose, snpread, nowrite, /*53*/ + snpioctl, nostop, nullreset, NULL, /* snoop */ + snpselect, nommap, NULL }, }; int nchrdev = sizeof (cdevsw) / sizeof (cdevsw[0]);