/* $Id: capidrv.h,v 1.2.8.2 2001/09/23 22:24:33 kai Exp $1*2* ISDN4Linux Driver, using capi20 interface (kernelcapi)3*4* Copyright 1997 by Carsten Paeth <[email protected]>5*6* This software may be used and distributed according to the terms7* of the GNU General Public License, incorporated herein by reference.8*9*/1011#ifndef __CAPIDRV_H__12#define __CAPIDRV_H__1314/*15* LISTEN state machine16*/17#define ST_LISTEN_NONE 0 /* L-0 */18#define ST_LISTEN_WAIT_CONF 1 /* L-0.1 */19#define ST_LISTEN_ACTIVE 2 /* L-1 */20#define ST_LISTEN_ACTIVE_WAIT_CONF 3 /* L-1.1 */212223#define EV_LISTEN_REQ 1 /* L-0 -> L-0.124L-1 -> L-1.1 */25#define EV_LISTEN_CONF_ERROR 2 /* L-0.1 -> L-026L-1.1 -> L-1 */27#define EV_LISTEN_CONF_EMPTY 3 /* L-0.1 -> L-028L-1.1 -> L-0 */29#define EV_LISTEN_CONF_OK 4 /* L-0.1 -> L-130L-1.1 -> L.1 */3132/*33* per plci state machine34*/35#define ST_PLCI_NONE 0 /* P-0 */36#define ST_PLCI_OUTGOING 1 /* P-0.1 */37#define ST_PLCI_ALLOCATED 2 /* P-1 */38#define ST_PLCI_ACTIVE 3 /* P-ACT */39#define ST_PLCI_INCOMING 4 /* P-2 */40#define ST_PLCI_FACILITY_IND 5 /* P-3 */41#define ST_PLCI_ACCEPTING 6 /* P-4 */42#define ST_PLCI_DISCONNECTING 7 /* P-5 */43#define ST_PLCI_DISCONNECTED 8 /* P-6 */44#define ST_PLCI_RESUMEING 9 /* P-0.Res */45#define ST_PLCI_RESUME 10 /* P-Res */46#define ST_PLCI_HELD 11 /* P-HELD */4748#define EV_PLCI_CONNECT_REQ 1 /* P-0 -> P-0.149*/50#define EV_PLCI_CONNECT_CONF_ERROR 2 /* P-0.1 -> P-051*/52#define EV_PLCI_CONNECT_CONF_OK 3 /* P-0.1 -> P-153*/54#define EV_PLCI_FACILITY_IND_UP 4 /* P-0 -> P-155*/56#define EV_PLCI_CONNECT_IND 5 /* P-0 -> P-257*/58#define EV_PLCI_CONNECT_ACTIVE_IND 6 /* P-1 -> P-ACT59*/60#define EV_PLCI_CONNECT_REJECT 7 /* P-2 -> P-561P-3 -> P-562*/63#define EV_PLCI_DISCONNECT_REQ 8 /* P-1 -> P-564P-2 -> P-565P-3 -> P-566P-4 -> P-567P-ACT -> P-568P-Res -> P-5 (*)69P-HELD -> P-5 (*)70*/71#define EV_PLCI_DISCONNECT_IND 9 /* P-1 -> P-672P-2 -> P-673P-3 -> P-674P-4 -> P-675P-5 -> P-676P-ACT -> P-677P-Res -> P-6 (*)78P-HELD -> P-6 (*)79*/80#define EV_PLCI_FACILITY_IND_DOWN 10 /* P-0.1 -> P-581P-1 -> P-582P-ACT -> P-583P-2 -> P-584P-3 -> P-585P-4 -> P-586*/87#define EV_PLCI_DISCONNECT_RESP 11 /* P-6 -> P-088*/89#define EV_PLCI_CONNECT_RESP 12 /* P-6 -> P-090*/9192#define EV_PLCI_RESUME_REQ 13 /* P-0 -> P-0.Res93*/94#define EV_PLCI_RESUME_CONF_OK 14 /* P-0.Res -> P-Res95*/96#define EV_PLCI_RESUME_CONF_ERROR 15 /* P-0.Res -> P-097*/98#define EV_PLCI_RESUME_IND 16 /* P-Res -> P-ACT99*/100#define EV_PLCI_HOLD_IND 17 /* P-ACT -> P-HELD101*/102#define EV_PLCI_RETRIEVE_IND 18 /* P-HELD -> P-ACT103*/104#define EV_PLCI_SUSPEND_IND 19 /* P-ACT -> P-5105*/106#define EV_PLCI_CD_IND 20 /* P-2 -> P-5107*/108109/*110* per ncci state machine111*/112#define ST_NCCI_PREVIOUS -1113#define ST_NCCI_NONE 0 /* N-0 */114#define ST_NCCI_OUTGOING 1 /* N-0.1 */115#define ST_NCCI_INCOMING 2 /* N-1 */116#define ST_NCCI_ALLOCATED 3 /* N-2 */117#define ST_NCCI_ACTIVE 4 /* N-ACT */118#define ST_NCCI_RESETING 5 /* N-3 */119#define ST_NCCI_DISCONNECTING 6 /* N-4 */120#define ST_NCCI_DISCONNECTED 7 /* N-5 */121122#define EV_NCCI_CONNECT_B3_REQ 1 /* N-0 -> N-0.1 */123#define EV_NCCI_CONNECT_B3_IND 2 /* N-0 -> N.1 */124#define EV_NCCI_CONNECT_B3_CONF_OK 3 /* N-0.1 -> N.2 */125#define EV_NCCI_CONNECT_B3_CONF_ERROR 4 /* N-0.1 -> N.0 */126#define EV_NCCI_CONNECT_B3_REJECT 5 /* N-1 -> N-4 */127#define EV_NCCI_CONNECT_B3_RESP 6 /* N-1 -> N-2 */128#define EV_NCCI_CONNECT_B3_ACTIVE_IND 7 /* N-2 -> N-ACT */129#define EV_NCCI_RESET_B3_REQ 8 /* N-ACT -> N-3 */130#define EV_NCCI_RESET_B3_IND 9 /* N-3 -> N-ACT */131#define EV_NCCI_DISCONNECT_B3_IND 10 /* N-4 -> N.5 */132#define EV_NCCI_DISCONNECT_B3_CONF_ERROR 11 /* N-4 -> previous */133#define EV_NCCI_DISCONNECT_B3_REQ 12 /* N-1 -> N-4134N-2 -> N-4135N-3 -> N-4136N-ACT -> N-4 */137#define EV_NCCI_DISCONNECT_B3_RESP 13 /* N-5 -> N-0 */138139#endif /* __CAPIDRV_H__ */140141142