1 /* 2 * datakit common-control interface definitions 3 * @(#)dkcmc.h 1.3 Garage 84/03/27 4 */ 5 6 7 /* 8 * protocol codes generated by driver 9 */ 10 #define T_SRV 1 /* service request */ 11 #define D_REINIT 7 /* re-init after splice */ 12 13 #define T_CHG 3 /* status change to/from cmc */ 14 #define D_CLOSE 1 /* close a channel */ 15 #define D_ISCLOSED 2 /* channel is closed */ 16 #define D_CLOSEALL 3 /* close all channels */ 17 #define D_SPLICE 4 /* splice two calls together */ 18 19 #define T_LSTNR 4 /* keep-alive message */ 20 21 #define T_REPLY 2 /* reply to channel setup */ 22 #define D_OK 1 /* setup OK */ 23 #define D_OPEN 2 /* channel now open */ 24 #define D_FAIL 3 /* setup failed */ 25 26 #define T_RESTART 8 /* cmc crashed, we should init circuit */ 27 28 struct lmsg { 29 char type ; /* message type T_??? */ 30 char srv ; /* message code D_??? */ 31 short param0 ; /* various aditional info */ 32 short param1 ; 33 short param2 ; 34 short param3 ; 35 short param4 ; 36 } ; 37 38 #define CMCFMT "bbsssss" 39 #define CMCSIZ 12 40 41 /* 42 * active setup requests 43 * (used in dkctl.c) 44 */ 45 46 struct dksetupreq { 47 int (*rq_endfcn)() ; 48 caddr_t rq_endparm ; 49 struct lmsg rq_msg ; 50 }; 51