aboutsummaryrefslogtreecommitdiff
path: root/sys/i4b/layer2
diff options
context:
space:
mode:
authorHellmuth Michaelis <hm@FreeBSD.org>1999-12-14 20:48:35 +0000
committerHellmuth Michaelis <hm@FreeBSD.org>1999-12-14 20:48:35 +0000
commitacfb47d41cfb4df742a37277d3a6aa0ee94e2faa (patch)
treeead126347847bb4825729267f9316802d6a0a4d4 /sys/i4b/layer2
parentea8271a8bbc80f9e936cec7ba35754cc4a4065e6 (diff)
Notes
Diffstat (limited to 'sys/i4b/layer2')
-rw-r--r--sys/i4b/layer2/i4b_iframe.c13
-rw-r--r--sys/i4b/layer2/i4b_l2.c14
-rw-r--r--sys/i4b/layer2/i4b_l2.h8
-rw-r--r--sys/i4b/layer2/i4b_l2fsm.c10
-rw-r--r--sys/i4b/layer2/i4b_l2fsm.h6
-rw-r--r--sys/i4b/layer2/i4b_l2timer.c29
-rw-r--r--sys/i4b/layer2/i4b_lme.c10
-rw-r--r--sys/i4b/layer2/i4b_mbuf.c10
-rw-r--r--sys/i4b/layer2/i4b_sframe.c10
-rw-r--r--sys/i4b/layer2/i4b_tei.c14
-rw-r--r--sys/i4b/layer2/i4b_uframe.c10
-rw-r--r--sys/i4b/layer2/i4b_util.c10
12 files changed, 94 insertions, 50 deletions
diff --git a/sys/i4b/layer2/i4b_iframe.c b/sys/i4b/layer2/i4b_iframe.c
index a043d851340f..ea7350d79199 100644
--- a/sys/i4b/layer2/i4b_iframe.c
+++ b/sys/i4b/layer2/i4b_iframe.c
@@ -27,9 +27,11 @@
* i4b_iframe.c - i frame handling routines
* ------------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_iframe.c,v 1.22 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Fri May 28 15:52:41 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:03:16 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
@@ -236,7 +240,8 @@ i4b_i_frame_queued_up(l2_softc_t *l2sc)
if(!(IF_QEMPTY(&l2sc->i_queue)))
{
DBGL2(L2_I_MSG, "i4b_i_frame_queued_up", ("re-scheduling IFQU call!\n"));
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+
+#if defined(__FreeBSD__)
l2sc->IFQU_callout = timeout((TIMEOUT_FUNC_T)i4b_i_frame_queued_up, (void *)l2sc, IFQU_DLY);
#else
timeout((TIMEOUT_FUNC_T)i4b_i_frame_queued_up, (void *)l2sc, IFQU_DLY);
diff --git a/sys/i4b/layer2/i4b_l2.c b/sys/i4b/layer2/i4b_l2.c
index cee25ab9bbb6..3bd986333fb3 100644
--- a/sys/i4b/layer2/i4b_l2.c
+++ b/sys/i4b/layer2/i4b_l2.c
@@ -27,9 +27,11 @@
* i4b_l2.c - ISDN layer 2 (Q.921)
* -------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_l2.c,v 1.30 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Fri May 28 16:15:39 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:03:23 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
@@ -284,7 +288,7 @@ i4b_mph_status_ind(int unit, int status, int parm)
bzero(&l2sc->stat, sizeof(lapdstat_t));
i4b_l2_unit_init(unit);
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
/* initialize the callout handles for timeout routines */
callout_handle_init(&l2sc->T200_callout);
callout_handle_init(&l2sc->T202_callout);
@@ -297,7 +301,7 @@ i4b_mph_status_ind(int unit, int status, int parm)
break;
case STI_PDEACT: /* Timer 4 expired */
- if((l2sc->Q921_state >= ST_AW_EST) &&
+/*XXX*/ if((l2sc->Q921_state >= ST_AW_EST) &&
(l2sc->Q921_state <= ST_TIMREC))
{
DBGL2(L2_ERROR, "i4b_mph_status_ind", ("unit %d, persistent deactivation!\n", unit));
diff --git a/sys/i4b/layer2/i4b_l2.h b/sys/i4b/layer2/i4b_l2.h
index 0b838b0fd29d..b00c3864cc1e 100644
--- a/sys/i4b/layer2/i4b_l2.h
+++ b/sys/i4b/layer2/i4b_l2.h
@@ -27,9 +27,11 @@
* i4b_l2.h - ISDN layer 2 (Q.921) definitions
* ---------------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_l2.h,v 1.20 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Fri May 28 15:51:17 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:03:29 1999]
*
*---------------------------------------------------------------------------*/
@@ -61,7 +63,7 @@ typedef struct {
void(*T202func)(void *);/* function to be called when T202 expires */
int T203; /* max line idle time */
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
struct callout_handle T200_callout;
struct callout_handle T202_callout;
struct callout_handle T203_callout;
diff --git a/sys/i4b/layer2/i4b_l2fsm.c b/sys/i4b/layer2/i4b_l2fsm.c
index 051c5b2a064d..333650c1043f 100644
--- a/sys/i4b/layer2/i4b_l2fsm.c
+++ b/sys/i4b/layer2/i4b_l2fsm.c
@@ -27,9 +27,11 @@
* i4b_l2fsm.c - layer 2 FSM
* -------------------------
*
- * $FreeBSD$
+ * $Id: i4b_l2fsm.c,v 1.17 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Tue Mar 16 16:27:12 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:03:36 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
diff --git a/sys/i4b/layer2/i4b_l2fsm.h b/sys/i4b/layer2/i4b_l2fsm.h
index ae3f6def3aa5..56a11ff69295 100644
--- a/sys/i4b/layer2/i4b_l2fsm.h
+++ b/sys/i4b/layer2/i4b_l2fsm.h
@@ -27,9 +27,11 @@
* i4b_l2fsm.h - layer 2 FSM
* -------------------------
*
- * $FreeBSD$
+ * $Id: i4b_l2fsm.h,v 1.5 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Sun Feb 14 10:31:43 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:03:48 1999]
*
*---------------------------------------------------------------------------*/
diff --git a/sys/i4b/layer2/i4b_l2timer.c b/sys/i4b/layer2/i4b_l2timer.c
index 50ace65d6caf..468c2a4378f9 100644
--- a/sys/i4b/layer2/i4b_l2timer.c
+++ b/sys/i4b/layer2/i4b_l2timer.c
@@ -27,9 +27,11 @@
* i4b_l2timer.c - layer 2 timer handling
* --------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_l2timer.c,v 1.17 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Wed Apr 21 09:17:58 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:03:56 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,7 +43,8 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
@@ -91,7 +94,7 @@ i4b_T200_start(l2_softc_t *l2sc)
DBGL2(L2_T_MSG, "i4b_T200_start", ("unit %d\n", l2sc->unit));
l2sc->T200 = TIMER_ACTIVE;
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
l2sc->T200_callout = timeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc, T200DEF);
#else
timeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc, T200DEF);
@@ -108,7 +111,7 @@ i4b_T200_stop(l2_softc_t *l2sc)
CRIT_BEG;
if(l2sc->T200 != TIMER_IDLE)
{
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
untimeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc, l2sc->T200_callout);
#else
untimeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc);
@@ -129,7 +132,7 @@ i4b_T200_restart(l2_softc_t *l2sc)
CRIT_BEG;
if(l2sc->T200 != TIMER_IDLE)
{
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
untimeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc, l2sc->T200_callout);
#else
untimeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc);
@@ -140,7 +143,7 @@ i4b_T200_restart(l2_softc_t *l2sc)
l2sc->T200 = TIMER_ACTIVE;
}
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
l2sc->T200_callout = timeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc, T200DEF);
#else
timeout((TIMEOUT_FUNC_T)i4b_T200_timeout, (void *)l2sc, T200DEF);
@@ -176,7 +179,7 @@ i4b_T202_start(l2_softc_t *l2sc)
l2sc->N202 = N202DEF;
l2sc->T202 = TIMER_ACTIVE;
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
l2sc->T202_callout = timeout((TIMEOUT_FUNC_T)i4b_T202_timeout, (void *)l2sc, T202DEF);
#else
timeout((TIMEOUT_FUNC_T)i4b_T202_timeout, (void *)l2sc, T202DEF);
@@ -193,7 +196,7 @@ i4b_T202_stop(l2_softc_t *l2sc)
CRIT_BEG;
if(l2sc->T202 != TIMER_IDLE)
{
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
untimeout((TIMEOUT_FUNC_T)i4b_T202_timeout, (void *)l2sc, l2sc->T202_callout);
#else
untimeout((TIMEOUT_FUNC_T)i4b_T202_timeout, (void *)l2sc);
@@ -229,7 +232,7 @@ i4b_T203_start(l2_softc_t *l2sc)
DBGL2(L2_T_MSG, "i4b_T203_start", ("unit %d\n", l2sc->unit));
l2sc->T203 = TIMER_ACTIVE;
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
l2sc->T203_callout = timeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc, T203DEF);
#else
timeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc, T203DEF);
@@ -248,7 +251,7 @@ i4b_T203_stop(l2_softc_t *l2sc)
CRIT_BEG;
if(l2sc->T203 != TIMER_IDLE)
{
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
untimeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc, l2sc->T203_callout);
#else
untimeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc);
@@ -272,7 +275,7 @@ i4b_T203_restart(l2_softc_t *l2sc)
if(l2sc->T203 != TIMER_IDLE)
{
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
untimeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc, l2sc->T203_callout);
#else
untimeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc);
@@ -283,7 +286,7 @@ i4b_T203_restart(l2_softc_t *l2sc)
l2sc->T203 = TIMER_ACTIVE;
}
-#if defined(__FreeBSD_version) && __FreeBSD_version >= 300001
+#if defined(__FreeBSD__)
l2sc->T203_callout = timeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc, T203DEF);
#else
timeout((TIMEOUT_FUNC_T)i4b_T203_timeout, (void *)l2sc, T203DEF);
diff --git a/sys/i4b/layer2/i4b_lme.c b/sys/i4b/layer2/i4b_lme.c
index cdfddee41cb1..a3690b9cce6d 100644
--- a/sys/i4b/layer2/i4b_lme.c
+++ b/sys/i4b/layer2/i4b_lme.c
@@ -27,9 +27,11 @@
* i4b_lme.c - layer management entity
* -------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_lme.c,v 1.11 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Sun Feb 14 10:31:55 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:04:03 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
diff --git a/sys/i4b/layer2/i4b_mbuf.c b/sys/i4b/layer2/i4b_mbuf.c
index 21b12bb6eb25..4fb0fb604530 100644
--- a/sys/i4b/layer2/i4b_mbuf.c
+++ b/sys/i4b/layer2/i4b_mbuf.c
@@ -27,20 +27,24 @@
* i4b - mbuf handling support routines
* ------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_mbuf.c,v 1.13 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Sun Feb 14 10:32:00 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:04:10 1999]
*
*---------------------------------------------------------------------------*/
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/tty.h>
#include <sys/proc.h>
#include <sys/uio.h>
diff --git a/sys/i4b/layer2/i4b_sframe.c b/sys/i4b/layer2/i4b_sframe.c
index 309d952e36e8..f0c6702c6b20 100644
--- a/sys/i4b/layer2/i4b_sframe.c
+++ b/sys/i4b/layer2/i4b_sframe.c
@@ -27,9 +27,11 @@
* i4b_sframe.c - s frame handling routines
* ----------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_sframe.c,v 1.12 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Fri May 28 16:14:04 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:04:17 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
diff --git a/sys/i4b/layer2/i4b_tei.c b/sys/i4b/layer2/i4b_tei.c
index 1ca81aa84b5e..fd813c881cb5 100644
--- a/sys/i4b/layer2/i4b_tei.c
+++ b/sys/i4b/layer2/i4b_tei.c
@@ -27,9 +27,11 @@
* i4b_tei.c - tei handling procedures
* -----------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_tei.c,v 1.17 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Fri May 28 16:14:14 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:04:24 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/syslog.h>
@@ -61,7 +65,7 @@
#include <i4b/i4b_ioctl.h>
#endif
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+#if defined(__FreeBSD__)
#include <machine/random.h>
#endif
@@ -289,7 +293,7 @@ void
i4b_make_rand_ri(l2_softc_t *l2sc)
{
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+#if defined(__FreeBSD__)
u_short val;
read_random((char *)&val, sizeof(val));
diff --git a/sys/i4b/layer2/i4b_uframe.c b/sys/i4b/layer2/i4b_uframe.c
index 127bb303ce36..7de4965e8c2a 100644
--- a/sys/i4b/layer2/i4b_uframe.c
+++ b/sys/i4b/layer2/i4b_uframe.c
@@ -27,9 +27,11 @@
* i4b_uframe.c - routines for handling U-frames
* -----------------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_uframe.c,v 1.10 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Fri May 28 16:14:32 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:04:30 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/mbuf.h>
diff --git a/sys/i4b/layer2/i4b_util.c b/sys/i4b/layer2/i4b_util.c
index 32666672aff1..4356a8c70e40 100644
--- a/sys/i4b/layer2/i4b_util.c
+++ b/sys/i4b/layer2/i4b_util.c
@@ -27,9 +27,11 @@
* i4b_util.c - layer 2 utility routines
* -------------------------------------
*
- * $FreeBSD$
+ * $Id: i4b_util.c,v 1.22 1999/12/13 21:25:27 hm Exp $
*
- * last edit-date: [Thu Apr 15 10:47:52 1999]
+ * $FreeBSD$
+ *
+ * last edit-date: [Mon Dec 13 22:04:37 1999]
*
*---------------------------------------------------------------------------*/
@@ -41,11 +43,13 @@
#if NI4BQ921 > 0
#include <sys/param.h>
-#if defined(__FreeBSD__) && __FreeBSD__ >= 3
+
+#if defined(__FreeBSD__)
#include <sys/ioccom.h>
#else
#include <sys/ioctl.h>
#endif
+
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/mbuf.h>