summaryrefslogtreecommitdiffstats
path: root/sys/i4b/include
diff options
context:
space:
mode:
authorhm <hm@FreeBSD.org>2000-10-09 13:18:17 +0000
committerhm <hm@FreeBSD.org>2000-10-09 13:18:17 +0000
commit9fc2bc8a46f4f09ca71eaf59e5c203b5d61533fb (patch)
treeca1e99e8eac9fd3f8c8cecbcbfc102b0bfa6f03f /sys/i4b/include
parent7fc1fa165474e47dca5d7dfb2584d97d169d686d (diff)
downloadFreeBSD-src-9fc2bc8a46f4f09ca71eaf59e5c203b5d61533fb.zip
FreeBSD-src-9fc2bc8a46f4f09ca71eaf59e5c203b5d61533fb.tar.gz
update to i4b version 0.95.04
Diffstat (limited to 'sys/i4b/include')
-rw-r--r--sys/i4b/include/i4b_cause.h9
-rw-r--r--sys/i4b/include/i4b_debug.h154
-rw-r--r--sys/i4b/include/i4b_global.h58
-rw-r--r--sys/i4b/include/i4b_ioctl.h40
-rw-r--r--sys/i4b/include/i4b_isdnq931.h6
-rw-r--r--sys/i4b/include/i4b_l1l2.h11
-rw-r--r--sys/i4b/include/i4b_l2l3.h6
-rw-r--r--sys/i4b/include/i4b_l3l4.h27
-rw-r--r--sys/i4b/include/i4b_mbuf.h8
-rw-r--r--sys/i4b/include/i4b_tel_ioctl.h19
-rw-r--r--sys/i4b/include/i4b_trace.h13
11 files changed, 224 insertions, 127 deletions
diff --git a/sys/i4b/include/i4b_cause.h b/sys/i4b/include/i4b_cause.h
index 96589e5..36c6142 100644
--- a/sys/i4b/include/i4b_cause.h
+++ b/sys/i4b/include/i4b_cause.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 1999 Hellmuth Michaelis. All rights reserved.
+ * Copyright (c) 1997, 2000 Hellmuth Michaelis. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -27,11 +27,11 @@
* i4b_cause.h - causes and cause handling for i4b
* -----------------------------------------------
*
- * $Id: i4b_cause.h,v 1.11 1999/12/13 21:25:28 hm Exp $
+ * $Id: i4b_cause.h,v 1.13 2000/02/06 19:01:14 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 22:06:51 1999]
+ * last edit-date: [Sun Feb 6 19:46:41 2000]
*
*---------------------------------------------------------------------------*/
@@ -70,7 +70,8 @@
#define CAUSE_I4B_L1ERROR 7 /* L1 error / persistent deact */
#define CAUSE_I4B_LLDIAL 8 /* no dialout on leased line */
#define CAUSE_I4B_MAX 9
- /* NOTE: update isdnd/pcause.c when adding causes !!!!! */
+ /* NOTE: update isdnd/pcause.c when adding causes !!!!! */
+ /* NOTE: update layer3/i4b_q931.c when adding causes !!!!! */
/* CAUSET_Q850 - causes defined in Q.850 */
diff --git a/sys/i4b/include/i4b_debug.h b/sys/i4b/include/i4b_debug.h
index aabc498..0e7eab2 100644
--- a/sys/i4b/include/i4b_debug.h
+++ b/sys/i4b/include/i4b_debug.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 1999 Hellmuth Michaelis. All rights reserved.
+ * Copyright (c) 1997, 2000 Hellmuth Michaelis. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -27,58 +27,52 @@
* i4b_debug.h - i4b debug header file
* -----------------------------------
*
- * $Id: i4b_debug.h,v 1.20 1999/12/13 21:25:28 hm Exp $
+ * $Id: i4b_debug.h,v 1.32 2000/07/24 12:22:08 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 22:06:59 1999]
+ * last edit-date: [Wed May 31 09:51:34 2000]
*
*---------------------------------------------------------------------------*/
-#define DO_I4B_DEBUG /* enable debugging code inclusion */
+#if !defined DO_I4B_DEBUG
+# define DO_I4B_DEBUG 1 /* default = include debugging code */
+#elif DO_I4B_DEBUG != 0
+# undef DO_I4B_DEBUG
+# define DO_I4B_DEBUG 1
+#endif
-#undef DO_I4B_MAXDEBUG /* enable ALL debug messages by default */
+#undef DO_I4B_MAXDEBUG /* default = disable ALL debug messages */
-#ifdef DO_I4B_DEBUG
+#if DO_I4B_DEBUG
extern unsigned int i4b_l1_debug;
extern unsigned int i4b_l2_debug;
extern unsigned int i4b_l3_debug;
extern unsigned int i4b_l4_debug;
-#define DBGL1(bits, routine, what) \
- if(bits & i4b_l1_debug) \
- { \
- printf("i4b-L1-%s: ", routine); \
- printf what ; \
- }
-
-#define DBGL2(bits, routine, what) \
- if(bits & i4b_l2_debug) \
- { \
- printf("i4b-L2-%s: ", routine); \
- printf what ; \
- }
-
-#define DBGL3(bits, routine, what) \
- if(bits & i4b_l3_debug) \
- { \
- printf("i4b-L3-%s: ", routine); \
- printf what ; \
- }
-
-#define DBGL4(bits, routine, what) \
- if(bits & i4b_l4_debug) \
- { \
- printf("i4b-L4-%s: ", routine); \
- printf what ; \
- }
+#define NDBGL1(bits, fmt, args...) \
+ if(bits & i4b_l1_debug) \
+ { printf("i4b-L1 %s: " fmt "\n", __FUNCTION__ , ##args ); }
+
+#define NDBGL2(bits, fmt, args...) \
+ if(bits & i4b_l2_debug) \
+ { printf("i4b-L2 %s: " fmt "\n", __FUNCTION__ , ##args ); }
+
+#define NDBGL3(bits, fmt, args...) \
+ if(bits & i4b_l3_debug) \
+ { printf("i4b-L3 %s: " fmt "\n", __FUNCTION__ , ##args ); }
+
+#define NDBGL4(bits, fmt, args...) \
+ if(bits & i4b_l4_debug) \
+ { printf("i4b-L4 %s: " fmt "\n", __FUNCTION__ , ##args ); }
+
#else /* !DO_I4B_DEBUG */
-#define DBGL1(bits, routine, what);
-#define DBGL2(bits, routine, what);
-#define DBGL3(bits, routine, what);
-#define DBGL4(bits, routine, what);
+#define NDBGL1(bits, fmt, args...);
+#define NDBGL2(bits, fmt, args...);
+#define NDBGL3(bits, fmt, args...);
+#define NDBGL4(bits, fmt, args...);
#endif /* DO_I4B_DEBUG */
@@ -98,9 +92,11 @@ extern unsigned int i4b_l4_debug;
#define L1_T_ERR 0x0800 /* Timer error messages */
#define L1_H_XFRERR 0x1000 /* HSCX data xfer error */
#define L1_I_CICO 0x2000 /* ISAC command in/out */
+#define L1_S_MSG 0x4000 /* silent messages (soft-HDLC) */
+#define L1_S_ERR 0x8000 /* error messages (soft-HDLC) */
-#define L1_DEBUG_MAX 0x3fef /* all messages on except IRQ! */
-#define L1_DEBUG_ERR (L1_H_ERR | L1_I_ERR | L1_F_ERR | L1_T_ERR | L1_ERROR)
+#define L1_DEBUG_MAX 0xffef /* all messages on except IRQ! */
+#define L1_DEBUG_ERR (L1_S_ERR | L1_H_ERR | L1_I_ERR | L1_F_ERR | L1_T_ERR | L1_ERROR)
#ifndef L1_DEBUG_DEFAULT
#ifdef DO_I4B_MAXDEBUG
@@ -176,8 +172,9 @@ extern unsigned int i4b_l4_debug;
#define L4_TINADBG 0x0100 /* tina driver debug messages */
#define L4_TINAMSG 0x0200 /* tina driver messages */
#define L4_TINAERR 0x0400 /* tina driver error messages */
+#define L4_INGDBG 0x0800 /* ing driver debug messages */
-#define L4_DEBUG_MAX 0x07ff /* all messages on */
+#define L4_DEBUG_MAX 0x0fff /* all messages on */
#define L4_DEBUG_ERR (L4_ERR | L4_TINADBG | L4_TINAMSG | L4_TINAERR)
#ifndef L4_DEBUG_DEFAULT
@@ -205,9 +202,23 @@ typedef struct {
#define I4B_CTL_SET_DEBUG _IOW('C', 1, ctl_debug_t)
/*---------------------------------------------------------------------------*
- * get hscx statistics
+ * generic get chipset statistics
*---------------------------------------------------------------------------*/
+/* for the ihfc-driver: structure for HFC-1/S/SP statistics */
+
+typedef struct {
+ int txframes;
+ int rxframes;
+ int xdu;
+ int rdo;
+ int crc;
+ int rab;
+} hfcstat_t;
+
+
+/* for the isic-driver: structure for HSCX statistics */
+
typedef struct {
int unit; /* controller number */
int chan; /* channel number */
@@ -218,44 +229,61 @@ typedef struct {
int xdu;
int rfo;
} hscxstat_t;
-
-#define I4B_CTL_GET_HSCXSTAT _IOWR('C', 2, hscxstat_t)
-#define I4B_CTL_CLR_HSCXSTAT _IOW('C', 3, hscxstat_t)
+/* generic statistics structure */
+
+struct chipstat {
+ int driver_type; /* type, L1DRVR_XXXX */
+ int driver_unit; /* the unit number */
+ int driver_bchannel; /* the B-channel */
+ union stats { /* union for all drivers */
+ hfcstat_t hfcstat; /* for ihfc driver, L1DRVR_IHFC */
+ hscxstat_t hscxstat; /* for isic driver, L1DRVR_ISIC */
+ } stats;
+};
+
+/* get statistics */
+
+#define I4B_CTL_GET_CHIPSTAT _IOWR('C', 2, struct chipstat)
+
+/* clear statistics */
+
+#define I4B_CTL_CLR_CHIPSTAT _IOW('C', 3, struct chipstat)
/*---------------------------------------------------------------------------*
* get LAPD/Q.921 statistics
*---------------------------------------------------------------------------*/
typedef struct {
- /* transmit */
- u_long tx_i; /* I */
- u_long tx_rr; /* RR */
- u_long tx_rnr; /* RNR */
- u_long tx_rej; /* REJ */
+ /* transmit */
+
+ u_long tx_i; /* I */
+ u_long tx_rr; /* RR */
+ u_long tx_rnr; /* RNR */
+ u_long tx_rej; /* REJ */
u_long tx_sabme; /* SABME*/
- u_long tx_dm; /* DM */
+ u_long tx_dm; /* DM */
u_long tx_disc; /* DISC */
- u_long tx_ua; /* UA */
+ u_long tx_ua; /* UA */
u_long tx_frmr; /* FRMR */
- u_long tx_tei; /* TEI */
+ u_long tx_tei; /* TEI */
- /* receive */
+ /* receive */
- u_long rx_i; /* I */
- u_long rx_rr; /* RR */
- u_long rx_rnr; /* RNR */
- u_long rx_rej; /* REJ */
+ u_long rx_i; /* I */
+ u_long rx_rr; /* RR */
+ u_long rx_rnr; /* RNR */
+ u_long rx_rej; /* REJ */
u_long rx_sabme; /* SABME*/
- u_long rx_tei; /* TEI */
- u_long rx_ui; /* UI */
+ u_long rx_tei; /* TEI */
+ u_long rx_ui; /* UI */
u_long rx_disc; /* DISC */
- u_long rx_xid; /* XID */
- u_long rx_dm; /* DM */
- u_long rx_ua; /* UA */
+ u_long rx_xid; /* XID */
+ u_long rx_dm; /* DM */
+ u_long rx_ua; /* UA */
u_long rx_frmr; /* FRMR */
- /* errors */
+ /* errors */
u_long err_rx_len; /* incorrect length */
u_long err_rx_badf; /* bad frame type */
diff --git a/sys/i4b/include/i4b_global.h b/sys/i4b/include/i4b_global.h
index 4b8bfb6..9bf3025 100644
--- a/sys/i4b/include/i4b_global.h
+++ b/sys/i4b/include/i4b_global.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 1999 Hellmuth Michaelis. All rights reserved.
+ * Copyright (c) 1997, 2000 Hellmuth Michaelis. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -27,11 +27,11 @@
* i4b_global.h - i4b global include file
* --------------------------------------
*
- * $Id: i4b_global.h,v 1.23 1999/12/13 21:25:24 hm Exp $
+ * $Id: i4b_global.h,v 1.27 2000/08/28 07:24:58 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 21:44:17 1999]
+ * last edit-date: [Thu Aug 24 12:38:50 2000]
*
*---------------------------------------------------------------------------*/
@@ -77,6 +77,29 @@
#endif /* __NetBSD__ */
+/*----------------*/
+/* timer handling */
+/*----------------*/
+
+#if defined(__NetBSD__)
+
+#if __NetBSD_Version__ >= 104230000
+#define START_TIMER(XHANDLE, XF, XSC, XTIME) callout_reset(&XHANDLE, XTIME, (TIMEOUT_FUNC_T)XF, (void*)XSC)
+#define STOP_TIMER(XHANDLE, XF, XSC) callout_stop(&XHANDLE)
+#else
+#define START_TIMER(XHANDLE, XF, XSC, XTIME) timeout((TIMEOUT_FUNC_T)XF, (void*)XSC, XTIME)
+#define STOP_TIMER(XHANDLE, XF, XSC) untimeout((TIMEOUT_FUNC_T)XF, (void*)XSC)
+#endif
+
+#else
+#define START_TIMER(XHANDLE, XF, XSC, XTIME) XHANDLE = timeout((TIMEOUT_FUNC_T)XF, (void*)XSC, XTIME)
+#ifdef __FreeBSD__
+#define STOP_TIMER(XHANDLE, XF, XSC) untimeout((TIMEOUT_FUNC_T)XF, (void*)XSC, XHANDLE)
+#else
+#define STOP_TIMER(XHANDLE, XF, XSC) untimeout((TIMEOUT_FUNC_T)XF, (void*)XSC)
+#endif
+#endif
+
/*----------------------*/
/* poll/select handling */
/*----------------------*/
@@ -110,28 +133,19 @@
/* definitions for the STATUS indications L1 -> L2 -> L3 */
-#define STI_ATTACH 0 /* attach at boot time */
-#define STI_L1STAT 1 /* layer 1 status */
-#define STI_L2STAT 2 /* layer 2 status */
-#define STI_TEIASG 3 /* TEI assignments */
+#define STI_ATTACH 0 /* attach at boot time */
+#define STI_L1STAT 1 /* layer 1 status */
+#define STI_L2STAT 2 /* layer 2 status */
+#define STI_TEIASG 3 /* TEI assignments */
#define STI_PDEACT 4 /* Layer 1 T4 expired = persistent deactivation */
-#define STI_NOL1ACC 5 /* no outgoing L1 access possible */
+#define STI_NOL1ACC 5 /* no outgoing L1 access possible */
/* definitions for the COMMAND requests L3 -> L2 -> L1 */
-#define CMR_DOPEN 0 /* daemon opened /dev/i4b */
-#define CMR_DCLOSE 1 /* daemon closed /dev/i4b */
-
-/*---------------------------------------------------------------------------
- *
- * Number of max supported passive card units
- *
- * Teles/Creatix/Neuhaus cards have a hardware limitation
- * as one is able to set 3 (sometimes 4) different configurations by
- * jumpers so a maximum of 3 (4) cards per ISA bus is possible.
- * (Note: there are multiple ISA buses on some architectures)
- *
- *---------------------------------------------------------------------------*/
-#define ISIC_MAXUNIT 3 /* max no of supported units 0..3 */
+#define CMR_DOPEN 0 /* daemon opened /dev/i4b */
+#define CMR_DCLOSE 1 /* daemon closed /dev/i4b */
+#define CMR_SETTRACE 2 /* set D-channel and B-channel trace */
+#define CMR_GCST 3 /* get chipset statistics */
+#define CMR_CCST 4 /* clear chipset statistics */
#endif /* _I4B_GLOBAL_H_ */
diff --git a/sys/i4b/include/i4b_ioctl.h b/sys/i4b/include/i4b_ioctl.h
index c2a2460..0a498b9 100644
--- a/sys/i4b/include/i4b_ioctl.h
+++ b/sys/i4b/include/i4b_ioctl.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 1999 Hellmuth Michaelis. All rights reserved.
+ * Copyright (c) 1997, 2000 Hellmuth Michaelis. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -27,11 +27,11 @@
* i4b_ioctl.h - messages kernel <--> userland
* -------------------------------------------
*
- * $Id: i4b_ioctl.h,v 1.150 1999/12/13 21:25:28 hm Exp $
+ * $Id: i4b_ioctl.h,v 1.196 2000/10/09 11:17:07 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 22:12:16 1999]
+ * last edit-date: [Mon Oct 9 13:17:34 2000]
*
*---------------------------------------------------------------------------*/
@@ -48,8 +48,8 @@
* version and release number for isdn4bsd package
*---------------------------------------------------------------------------*/
#define VERSION 0 /* version number */
-#define REL 90 /* release number */
-#define STEP 1 /* release step */
+#define REL 95 /* release number */
+#define STEP 04 /* release step */
/*---------------------------------------------------------------------------*
* date/time format in i4b log messages
@@ -87,6 +87,20 @@
#define CTRL_NUMTYPES 5 /* number of controller types */
/*---------------------------------------------------------------------------*
+ * CTRL_PASSIVE: driver types
+ *---------------------------------------------------------------------------*/
+#define MAXL1UNITS 8 /* max number of units */
+
+#define L1DRVR_ISIC 0 /* isic - driver */
+#define L1DRVR_IWIC 1 /* iwic - driver */
+#define L1DRVR_IFPI 2 /* ifpi - driver */
+#define L1DRVR_IHFC 3 /* ihfc - driver */
+#define L1DRVR_IFPNP 4 /* ifpnp - driver */
+
+/* MAXL1DRVR MUST be updated when more passive drivers are added !!! */
+#define MAXL1DRVR (L1DRVR_IFPNP + 1)
+
+/*---------------------------------------------------------------------------*
* card types for CTRL_PASSIVE
*---------------------------------------------------------------------------*/
#define CARD_TYPEP_INVAL (-1) /* invalid, error */
@@ -114,16 +128,21 @@
#define CARD_TYPEP_AVM_PNP 21 /* AVM FRITZ!CARD PnP */
#define CARD_TYPEP_SIE_ISURF2 22 /* Siemens I-Surf 2 PnP */
#define CARD_TYPEP_ASUSCOMIPAC 23 /* Asuscom ISDNlink 128 K PnP */
+#define CARD_TYPEP_WINB6692 24 /* Winbond W6692 based */
+#define CARD_TYPEP_16_3C 25 /* Teles S0/16.3c PnP (HFC-S/SP */
+#define CARD_TYPEP_ACERP10 26 /* Acer ISDN P10 (HFC-S) */
+#define CARD_TYPEP_TELEINT_NO_1 27 /* TELEINT ISDN SPEED No. 1 (HFC-1) */
+
/*
* in case you add support for more cards, please update:
*
- * isdnd: support.c, name_of_controller()
+ * isdnd: controller.c, name_of_controller()
* diehl/diehlctl: main.c, listall()
*
* and adjust CARD_TYPEP_MAX below.
*/
-#define CARD_TYPEP_MAX 23 /* max type */
+#define CARD_TYPEP_MAX 27 /* max type */
/*---------------------------------------------------------------------------*
* card types for CTRL_DAIC
@@ -162,6 +181,7 @@
#define BDRV_IPR 2 /* IP over raw HDLC interface driver */
#define BDRV_ISPPP 3 /* sync Kernel PPP interface driver */
#define BDRV_IBC 4 /* BSD/OS point to point driver */
+#define BDRV_ING 5 /* NetGraph ing driver */
/*---------------------------------------------------------------------------*
* B channel protocol
@@ -311,6 +331,12 @@ typedef struct {
#define SCR_USR_PASS 2 /* screening user provided, verified & passed */
#define SCR_USR_FAIL 3 /* screening user provided, verified & failed */
#define SCR_NET 4 /* screening network provided */
+ int prs_ind;/* presentation indicator */
+#define PRS_NONE 0 /* no presentation indicator transmitted*/
+#define PRS_ALLOWED 1 /* presentation allowed */
+#define PRS_RESTRICT 2 /* presentation restricted */
+#define PRS_NNINTERW 3 /* number not available due to interworking */
+#define PRS_RESERVED 4 /* reserved */
char display[DISPLAY_MAX]; /* content of display IE*/
} msg_connect_ind_t;
diff --git a/sys/i4b/include/i4b_isdnq931.h b/sys/i4b/include/i4b_isdnq931.h
index 76c84f1..19ef428 100644
--- a/sys/i4b/include/i4b_isdnq931.h
+++ b/sys/i4b/include/i4b_isdnq931.h
@@ -27,11 +27,11 @@
* i4b_isdnq931.h - DSS1 layer 3 message types
* -------------------------------------------
*
- * $Id: i4b_isdnq931.h,v 1.6 1999/12/13 21:25:24 hm Exp $
+ * $Id: i4b_isdnq931.h,v 1.7 2000/04/27 07:42:43 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 21:44:28 1999]
+ * last edit-date: [Thu Apr 27 09:46:13 2000]
*
*---------------------------------------------------------------------------*/
@@ -76,7 +76,7 @@
#define IEI_LLCOMPAT 0x7c /* low layer compatibility */
#define IEI_HLCOMPAT 0x7d /* high layer compatibility */
#define IEI_USERUSER 0x7e /* user-user */
-#define IEI_ESACPE 0x7f /* escape for extension */
+#define IEI_ESCAPE 0x7f /* escape for extension */
/* Q.932 variable length information element identifiers */
diff --git a/sys/i4b/include/i4b_l1l2.h b/sys/i4b/include/i4b_l1l2.h
index 704fc5d..4a8ccba 100644
--- a/sys/i4b/include/i4b_l1l2.h
+++ b/sys/i4b/include/i4b_l1l2.h
@@ -27,11 +27,11 @@
* i4b_l1l2.h - i4b layer 1 / layer 2 interactions
* ---------------------------------------------------
*
- * $Id: i4b_l1l2.h,v 1.9 1999/12/13 21:25:24 hm Exp $
+ * $Id: i4b_l1l2.h,v 1.11 2000/06/02 16:14:35 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 21:44:39 1999]
+ * last edit-date: [Fri Jun 2 14:35:03 2000]
*
*---------------------------------------------------------------------------*/
@@ -67,11 +67,6 @@ struct i4b_l1l2_func
/* =================== */
int (*PH_DATA_REQ) (int, struct mbuf *, int);
-
- /* 3rd ph_data_req parameter */
-#define MBUF_DONTFREE 0
-#define MBUF_FREE 1
-
int (*PH_ACTIVATE_REQ) (int);
#define PH_Data_Req(unit, data, freeflag) \
@@ -89,7 +84,7 @@ struct i4b_l1l2_func
/* L1/L2 management command and status information */
/* =============================================== */
int (*MPH_STATUS_IND) (int, int, int);
- int (*MPH_COMMAND_REQ) (int, int, int);
+ int (*MPH_COMMAND_REQ) (int, int, void *);
#define MPH_Status_Ind(unit, status, parm) \
((*i4b_l1l2_func.MPH_STATUS_IND)(unit, status, parm))
diff --git a/sys/i4b/include/i4b_l2l3.h b/sys/i4b/include/i4b_l2l3.h
index d25bc7b..6e0e197 100644
--- a/sys/i4b/include/i4b_l2l3.h
+++ b/sys/i4b/include/i4b_l2l3.h
@@ -27,11 +27,11 @@
* i4b_l2l3.h - i4b layer 2 / layer 3 interactions
* -----------------------------------------------
*
- * $Id: i4b_l2l3.h,v 1.7 1999/12/13 21:25:24 hm Exp $
+ * $Id: i4b_l2l3.h,v 1.8 2000/06/02 16:14:35 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 21:44:47 1999]
+ * last edit-date: [Fri Jun 2 14:33:34 2000]
*
*---------------------------------------------------------------------------*/
@@ -108,7 +108,7 @@ struct i4b_l2l3_func
/* Layer 3 --> Layer 2 management */
/* ============================== */
- int (*MDL_COMMAND_REQ) (int, int, int); /* L3 --> L2 command */
+ int (*MDL_COMMAND_REQ) (int, int, void *); /* L3 --> L2 command */
#define MDL_Command_Req(unit, command, parm) \
((*i4b_l2l3_func.MDL_COMMAND_REQ)(unit, command, parm))
diff --git a/sys/i4b/include/i4b_l3l4.h b/sys/i4b/include/i4b_l3l4.h
index 622baf2..518aa60 100644
--- a/sys/i4b/include/i4b_l3l4.h
+++ b/sys/i4b/include/i4b_l3l4.h
@@ -27,11 +27,11 @@
* i4b_l3l4.h - layer 3 / layer 4 interface
* ------------------------------------------
*
- * $Id: i4b_l3l4.h,v 1.27 1999/12/13 21:25:24 hm Exp $
+ * $Id: i4b_l3l4.h,v 1.32 2000/08/24 11:48:57 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 21:44:56 1999]
+ * last edit-date: [Fri Jun 2 14:29:35 2000]
*
*---------------------------------------------------------------------------*/
@@ -121,6 +121,12 @@ drvr_link_t *ibc_ret_linktab(int unit);
void ibc_set_linktab(int unit, isdn_link_t *ilt);
#endif
+/* global linktab functions for ING network driver */
+
+drvr_link_t *ing_ret_linktab(int unit);
+void ing_set_linktab(int unit, isdn_link_t *ilt);
+
+
/*---------------------------------------------------------------------------*
* this structure describes one call/connection on one B-channel
* and all its parameters
@@ -150,7 +156,9 @@ typedef struct
u_char dst_telno[TELNO_MAX]; /* destination number */
u_char src_telno[TELNO_MAX]; /* source number */
+
int scr_ind; /* screening ind for incoming call */
+ int prs_ind; /* presentation ind for incoming call */
int Q931state; /* Q.931 state for call */
int event; /* event to be processed */
@@ -194,6 +202,17 @@ typedef struct
struct callout_handle T400_callout;
int callouts_inited; /* must init before use */
#endif
+#if defined(__NetBSD__) && __NetBSD_Version__ >= 104230000
+ struct callout idle_timeout_handle;
+ struct callout T303_callout;
+ struct callout T305_callout;
+ struct callout T308_callout;
+ struct callout T309_callout;
+ struct callout T310_callout;
+ struct callout T313_callout;
+ struct callout T400_callout;
+ int callouts_inited; /* must init before use */
+#endif
int idletime_state; /* wait for idle_time begin */
#define IST_IDLE 0 /* shorthold mode disabled */
@@ -257,11 +276,9 @@ typedef struct
void (*N_CONNECT_RESPONSE) (unsigned int, int, int);
void (*N_DISCONNECT_REQUEST) (unsigned int, int);
void (*N_ALERT_REQUEST) (unsigned int);
- void (*N_SET_TRACE) (int unit, int val);
- int (*N_GET_TRACE) (int unit);
int (*N_DOWNLOAD) (int unit, int numprotos, struct isdn_dr_prot *protocols);
int (*N_DIAGNOSTICS) (int unit, struct isdn_diagnostic_request*);
- void (*N_MGMT_COMMAND) (int unit, int cmd, int parm);
+ void (*N_MGMT_COMMAND) (int unit, int cmd, void *);
} ctrl_desc_t;
extern ctrl_desc_t ctrl_desc[MAX_CONTROLLERS];
diff --git a/sys/i4b/include/i4b_mbuf.h b/sys/i4b/include/i4b_mbuf.h
index b7d8984..b1b46c0 100644
--- a/sys/i4b/include/i4b_mbuf.h
+++ b/sys/i4b/include/i4b_mbuf.h
@@ -27,17 +27,21 @@
* i4b - mbuf handling support routines
* --------------------------------------
*
- * $Id: i4b_mbuf.h,v 1.8 1999/12/13 21:25:24 hm Exp $
+ * $Id: i4b_mbuf.h,v 1.9 2000/03/07 14:21:18 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 21:45:05 1999]
+ * last edit-date: [Fri Mar 3 14:30:09 2000]
*
*---------------------------------------------------------------------------*/
#ifndef _I4B_MBUF_H_
#define _I4B_MBUF_H_
+/* layer 1 / layer 2 comunication: 3rd ph_data_req parameter */
+#define MBUF_DONTFREE 0
+#define MBUF_FREE 1
+
#define IF_QEMPTY(ifq) ((ifq)->ifq_len == 0)
struct mbuf *i4b_Dgetmbuf( int );
diff --git a/sys/i4b/include/i4b_tel_ioctl.h b/sys/i4b/include/i4b_tel_ioctl.h
index 2cc9e15..0f955af 100644
--- a/sys/i4b/include/i4b_tel_ioctl.h
+++ b/sys/i4b/include/i4b_tel_ioctl.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 1999 Hellmuth Michaelis. All rights reserved.
+ * Copyright (c) 1997, 2000 Hellmuth Michaelis. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -27,11 +27,11 @@
* i4b_tel_ioctl.h telephony interface ioctls
* ------------------------------------------
*
- * $Id: i4b_tel_ioctl.h,v 1.11 1999/12/13 21:25:28 hm Exp $
+ * $Id: i4b_tel_ioctl.h,v 1.13 2000/01/12 14:49:36 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 22:07:18 1999]
+ * last edit-date: [Wed Jan 12 15:47:11 2000]
*
*---------------------------------------------------------------------------*/
@@ -62,6 +62,19 @@
#define I4B_TEL_VR_REQ _IOR('A', 3, msg_vr_req_t)
+/*---------------------------------------------------------------------------*
+ * send tones out of the tel interface
+ *---------------------------------------------------------------------------*/
+
+#define I4B_TEL_MAXTONES 32
+
+struct i4b_tel_tones {
+ int frequency[I4B_TEL_MAXTONES];
+ int duration[I4B_TEL_MAXTONES];
+};
+
+#define I4B_TEL_TONES _IOR('A', 4, struct i4b_tel_tones)
+
/*===========================================================================*
* /dev/i4bteld<n> devices (dialer interface)
*===========================================================================*/
diff --git a/sys/i4b/include/i4b_trace.h b/sys/i4b/include/i4b_trace.h
index fa1a9a6..24229ec 100644
--- a/sys/i4b/include/i4b_trace.h
+++ b/sys/i4b/include/i4b_trace.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 1999 Hellmuth Michaelis. All rights reserved.
+ * Copyright (c) 1997, 2000 Hellmuth Michaelis. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -27,11 +27,11 @@
* i4b_trace.h - header file for trace data read device
* ----------------------------------------------------
*
- * $Id: i4b_trace.h,v 1.7 1999/12/13 21:25:28 hm Exp $
+ * $Id: i4b_trace.h,v 1.8 2000/03/08 16:08:18 hm Exp $
*
* $FreeBSD$
*
- * last edit-date: [Mon Dec 13 22:07:25 1999]
+ * last edit-date: [Wed Mar 8 16:41:43 2000]
*
*---------------------------------------------------------------------------*/
@@ -70,8 +70,7 @@ typedef struct {
* get/set current trace flag settings
*---------------------------------------------------------------------------*/
-#define I4B_TRC_GET _IOR('T', 0, int) /* get trace settings */
-#define I4B_TRC_SET _IOW('T', 1, int) /* set trace settings */
+#define I4B_TRC_SET _IOW('T', 0, int) /* set trace settings */
#define TRACE_OFF 0x00 /* tracing off */
#define TRACE_I 0x01 /* trace L1 INFO's on */
@@ -87,7 +86,7 @@ typedef struct {
int txflags; /* d and/or b channel */
} i4b_trace_setupa_t;
-#define I4B_TRC_SETA _IOW('T', 2, i4b_trace_setupa_t) /* set analyze mode */
-#define I4B_TRC_RESETA _IOW('T', 3, int) /* reset analyze mode */
+#define I4B_TRC_SETA _IOW('T', 1, i4b_trace_setupa_t) /* set analyze mode */
+#define I4B_TRC_RESETA _IOW('T', 2, int) /* reset analyze mode */
#endif /* _I4B_TRACE_H_ */
OpenPOWER on IntegriCloud