summaryrefslogtreecommitdiffstats
path: root/gnu/usr.sbin/isdn/rst
diff options
context:
space:
mode:
authorjkh <jkh@FreeBSD.org>1995-02-15 00:46:26 +0000
committerjkh <jkh@FreeBSD.org>1995-02-15 00:46:26 +0000
commit0cb129cc755064f31fb42abf2c721a8605381511 (patch)
tree87521af8f33d69817699aec072374bf2d3734e3e /gnu/usr.sbin/isdn/rst
downloadFreeBSD-src-0cb129cc755064f31fb42abf2c721a8605381511.zip
FreeBSD-src-0cb129cc755064f31fb42abf2c721a8605381511.tar.gz
Import the ISDN userland utilities. Just about ready to start shaking
this baby out in earnest..
Diffstat (limited to 'gnu/usr.sbin/isdn/rst')
-rw-r--r--gnu/usr.sbin/isdn/rst/Makefile4
-rw-r--r--gnu/usr.sbin/isdn/rst/rst.c35
2 files changed, 39 insertions, 0 deletions
diff --git a/gnu/usr.sbin/isdn/rst/Makefile b/gnu/usr.sbin/isdn/rst/Makefile
new file mode 100644
index 0000000..a3c6932
--- /dev/null
+++ b/gnu/usr.sbin/isdn/rst/Makefile
@@ -0,0 +1,4 @@
+PROG= rst
+CFLAGS+= -DBSD -O
+
+.include <bsd.prog.mk>
diff --git a/gnu/usr.sbin/isdn/rst/rst.c b/gnu/usr.sbin/isdn/rst/rst.c
new file mode 100644
index 0000000..331bdba
--- /dev/null
+++ b/gnu/usr.sbin/isdn/rst/rst.c
@@ -0,0 +1,35 @@
+static char rcsid[] = "@(#)$Id: rst.c,v 1.1 1995/01/25 14:07:55 jkr Exp jkr $";
+/*******************************************************************************
+ * II - Version 0.1 $Revision: 1.1 $ $State: Exp $
+ *
+ * Copyright 1994 Dietmar Friede
+ *******************************************************************************
+ * Bug reports, patches, comments, suggestions should be sent to:
+ *
+ * jkr@saarlink.de or jkrause@guug.de
+ *
+ *******************************************************************************
+ * $Log: rst.c,v $
+ *
+ ******************************************************************************/
+
+#include <sys/types.h>
+#include <stdio.h>
+#include <sys/ioctl.h>
+#include <sys/file.h>
+#include "../../../../sys/gnu/i386/isa/niccyreg.h"
+
+main()
+{
+ int s, f;
+
+ if ((f = open("/dev/nic0", O_RDWR)) < 0)
+ {
+ perror("open");
+ exit(1);
+ }
+ if (ioctl(f, NICCY_RESET, &s) < 0)
+ {
+ perror("ioctl");
+ }
+}
OpenPOWER on IntegriCloud