Lines Matching refs:word

76 static void clear_group_ind_mask_bit(PLCI *plci, word b);
77 static byte test_group_ind_mask_bit(PLCI *plci, word b);
79 word CapiRelease(word);
80 word CapiRegister(word);
81 word api_put(APPL *, CAPI_MSG *);
82 static word api_parse(byte *, word, byte *, API_PARSE *);
86 word api_remove_start(void);
107 static byte connect_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
108 static byte connect_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
109 static byte connect_a_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
110 static byte disconnect_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
111 static byte disconnect_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
112 static byte listen_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
113 static byte info_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
114 static byte info_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
115 static byte alert_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
116 static byte facility_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
117 static byte facility_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
118 static byte connect_b3_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
119 static byte connect_b3_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
120 static byte connect_b3_a_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
121 static byte disconnect_b3_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
122 static byte disconnect_b3_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
123 static byte data_b3_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
124 static byte data_b3_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
125 static byte reset_b3_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
126 static byte reset_b3_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
127 static byte connect_b3_t90_a_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
128 static byte select_b_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
129 static byte manufacturer_req(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
130 static byte manufacturer_res(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
132 static word get_plci(DIVA_CAPI_ADAPTER *);
136 static void add_ie(PLCI *plci, byte code, byte *p, word p_length);
137 static void add_d(PLCI *, word, byte *);
139 static word add_b1(PLCI *, API_PARSE *, word, word);
140 static word add_b23(PLCI *, API_PARSE *);
141 static word add_modem_b23(PLCI *plci, API_PARSE *bp_parms);
146 static word plci_remove_check(PLCI *);
150 static void IndParse(PLCI *, word *, byte **, byte);
152 static word find_cip(DIVA_CAPI_ADAPTER *, byte *, byte *);
153 static word CPN_filter_ok(byte *cpn, DIVA_CAPI_ADAPTER *, word);
167 static word AdvCodecSupport(DIVA_CAPI_ADAPTER *, PLCI *, APPL *, byte);
171 static void adv_voice_write_coefs(PLCI *plci, word write_command);
174 static word get_b1_facilities(PLCI *plci, byte b1_resource);
175 static byte add_b1_facilities(PLCI *plci, byte b1_resource, word b1_facilities);
176 static void adjust_b1_facilities(PLCI *plci, byte new_b1_resource, word new_b1_facilities);
177 static word adjust_b_process(dword Id, PLCI *plci, byte Rc);
178 static void adjust_b1_resource(dword Id, PLCI *plci, API_SAVE *bp_msg, word b1_facilities, word int…
193 static byte dtmf_request(dword Id, word Number, DIVA_CAPI_ADAPTER *a, PLCI *plci, APPL *appl, API_P…
195 static void dtmf_indication(dword Id, PLCI *plci, byte *msg, word length);
204 static byte mixer_request(dword Id, word Number, DIVA_CAPI_ADAPTER *a, PLCI *plci, APPL *appl, API_…
206 static void mixer_indication_xconnect_from(dword Id, PLCI *plci, byte *msg, word length);
207 static void mixer_indication_xconnect_to(dword Id, PLCI *plci, byte *msg, word length);
212 static byte ec_request(dword Id, word Number, DIVA_CAPI_ADAPTER *a, PLCI *plci, APPL *appl, API_PAR…
213 static void ec_indication(dword Id, PLCI *plci, byte *msg, word length);
232 void sendf(APPL *, word, dword, word, byte *, ...);
260 word command;
262 byte (*function)(dword, word, DIVA_CAPI_ADAPTER *, PLCI *, APPL *, API_PARSE *);
386 word api_put(APPL *appl, CAPI_MSG *msg) in api_put()
388 word i, j, k, l, n; in api_put()
389 word ret; in api_put()
395 word ncci; in api_put()
559 if (!api_parse(msg->info.b, (word)(msg->header.length - 12), ftable[i].format, msg_parms)) { in api_put()
593 static word api_parse(byte *msg, word length, byte *format, API_PARSE *parms) in api_parse()
595 word i; in api_parse()
596 word p; in api_parse()
634 word i, j, n = 0; in api_save_msg()
666 word i; in api_load_msg()
681 word api_remove_start(void) in api_remove_start()
683 word i; in api_remove_start()
684 word j; in api_remove_start()
717 word i; in init_internal_command_queue()
730 word i; in start_internal_command()
752 word i; in next_internal_command()
778 static word get_ncci(PLCI *plci, byte ch, word force_ncci) in get_ncci()
781 word ncci, i, j, k; in get_ncci()
852 static void ncci_free_receive_buffers(PLCI *plci, word ncci) in ncci_free_receive_buffers()
856 word i, ncci_code; in ncci_free_receive_buffers()
860 Id = (((dword) ncci) << 16) | (((word)(plci->Id)) << 8) | a->Id; in ncci_free_receive_buffers()
874 ncci_code = ncci | (((word) a->Id) << 8); in ncci_free_receive_buffers()
901 ncci_code = ncci | (((word) a->Id) << 8); in ncci_free_receive_buffers()
917 static void cleanup_ncci_data(PLCI *plci, word ncci) in cleanup_ncci_data()
944 static void ncci_remove(PLCI *plci, word ncci, byte preserve_ncci) in ncci_remove()
948 word i; in ncci_remove()
951 Id = (((dword) ncci) << 16) | (((word)(plci->Id)) << 8) | a->Id; in ncci_remove()
1019 word i; in plci_free_msg_in_queue()
1095 word i; in set_group_ind_mask()
1101 static void clear_group_ind_mask_bit(PLCI *plci, word b) in clear_group_ind_mask_bit()
1106 static byte test_group_ind_mask_bit(PLCI *plci, word b) in test_group_ind_mask_bit()
1117 word i; in clear_c_ind_mask()
1125 word i; in c_ind_mask_empty()
1133 static void set_c_ind_mask_bit(PLCI *plci, word b) in set_c_ind_mask_bit()
1138 static void clear_c_ind_mask_bit(PLCI *plci, word b) in clear_c_ind_mask_bit()
1143 static byte test_c_ind_mask_bit(PLCI *plci, word b) in test_c_ind_mask_bit()
1152 word i, j, k; in dump_c_ind_mask()
1195 static byte connect_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in connect_req()
1198 word ch; in connect_req()
1199 word i; in connect_req()
1200 word Info; in connect_req()
1205 word channel = 0; in connect_req()
1211 word dir = 0; in connect_req()
1223 Id = ((word)1 << 8) | a->Id; in connect_req()
1253 if (!api_parse(&ai->info[1], (word)ai->length, "ssss", ai_parms)) in connect_req()
1411 static byte connect_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in connect_res()
1414 word i, Info; in connect_res()
1415 word Reject; in connect_res()
1420 word ch = 0; in connect_res()
1434 if (!api_parse(&ai->info[1], (word)ai->length, "ssss", ai_parms)) in connect_res()
1462 clear_c_ind_mask_bit(plci, (word)(appl->Id - 1)); in connect_res()
1568 static byte connect_a_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in connect_a_res()
1575 static byte disconnect_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in disconnect_req()
1578 word Info; in disconnect_req()
1579 word i; in disconnect_req()
1589 clear_c_ind_mask_bit(plci, (word)(appl->Id - 1)); in disconnect_req()
1631 static byte disconnect_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in disconnect_res()
1639 clear_c_ind_mask_bit(plci, (word)(appl->Id - 1)); in disconnect_res()
1659 static byte listen_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in listen_req()
1662 word Info; in listen_req()
1709 static byte info_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in info_req()
1712 word i; in info_req()
1716 word Info = 0; in info_req()
1725 if (api_parse(&ai->info[1], (word)ai->length, "ssss", ai_parms)) in info_req()
1819 static byte info_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in info_res()
1826 static byte alert_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in alert_req()
1829 word Info; in alert_req()
1857 static byte facility_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in facility_req()
1860 word Info = 0; in facility_req()
1861 word i = 0; in facility_req()
1863 word selector; in facility_req()
1864 word SSreq; in facility_req()
1936 if (api_parse(&parms->info[1], (word)parms->length, "wbd", ss_parms)) in facility_req()
1972 api_parse(&parms->info[1], (word)parms->length, "ws", ss_parms); in facility_req()
2019 if (api_parse(&parms->info[1], (word)parms->length, "wbs", ss_parms)) in facility_req()
2060 if (api_parse(&parms->info[1], (word)parms->length, "wbs", ss_parms)) in facility_req()
2090 if (api_parse(&parms->info[1], (word)parms->length, "wbd", ss_parms)) in facility_req()
2142 if (api_parse(&parms->info[1], (word)parms->length, "wbd", ss_parms)) in facility_req()
2151 if (api_parse(&parms->info[1], (word)parms->length, "wbdb", ss_parms)) in facility_req()
2284 if (api_parse(&parms->info[1], (word)parms->length, "wbwss", ss_parms)) in facility_req()
2310 if (api_parse(&parms->info[1], (word)parms->length, "wbdwwsss", ss_parms)) in facility_req()
2357 if (api_parse(&parms->info[1], (word)parms->length, "wbd", ss_parms)) in facility_req()
2365 if (api_parse(&parms->info[1], (word)parms->length, "wbdw", ss_parms)) in facility_req()
2372 if (api_parse(&parms->info[1], (word)parms->length, "wbdws", ss_parms)) in facility_req()
2379 if (api_parse(&parms->info[1], (word)parms->length, "wbdwws", ss_parms)) in facility_req()
2468 if (api_parse(&parms->info[1], (word)parms->length, "wbwdwwwssss", ss_parms)) in facility_req()
2520 if (api_parse(&parms->info[1], (word)parms->length, "wbwwss", ss_parms)) in facility_req()
2608 static byte facility_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in facility_res()
2615 static byte connect_b3_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in connect_b3_req()
2618 word Info = 0; in connect_b3_req()
2621 word w; in connect_b3_req()
2622 word fax_control_bits, fax_feature_bits, fax_info_change; in connect_b3_req()
2627 word i; in connect_b3_req()
2680 add_d(plci, (word)(ncpi->length - 3), &ncpi->info[4]); in connect_b3_req()
2698 … if ((w & 0x0001) != ((word)(((T30_INFO *)(plci->fax_connect_info_buffer))->resolution & 0x0001))) in connect_b3_req()
2850 static byte connect_b3_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in connect_b3_res()
2853 word ncci; in connect_b3_res()
2857 word w; in connect_b3_res()
2861 word i; in connect_b3_res()
2867 ncci = (word)(Id >> 16); in connect_b3_res()
2950 add_d(plci, (word)(ncpi->length - 3), &ncpi->info[4]); in connect_b3_res()
2966 static byte connect_b3_a_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in connect_b3_a_res()
2969 word ncci; in connect_b3_a_res()
2971 ncci = (word)(Id >> 16); in connect_b3_a_res()
2987 static byte disconnect_b3_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in disconnect_b3_req()
2990 word Info; in disconnect_b3_req()
2991 word ncci; in disconnect_b3_req()
2997 ncci = (word)(Id >> 16); in disconnect_b3_req()
3028 add_d(plci, (word)(ncpi->length - 3), (byte *)&(ncpi->info[4])); in disconnect_b3_req()
3044 static byte disconnect_b3_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in disconnect_b3_res()
3047 word ncci; in disconnect_b3_res()
3048 word i; in disconnect_b3_res()
3050 ncci = (word)(Id >> 16); in disconnect_b3_res()
3075 "ws", (word)3, "\x03\x04\x00\x00"); in disconnect_b3_res()
3101 static byte data_b3_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in data_b3_req()
3106 word Info; in data_b3_req()
3107 word ncci; in data_b3_req()
3108 word i; in data_b3_req()
3113 ncci = (word)(Id >> 16); in data_b3_req()
3179 static byte data_b3_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in data_b3_res()
3182 word n; in data_b3_res()
3183 word ncci; in data_b3_res()
3184 word NCCIcode; in data_b3_res()
3188 ncci = (word)(Id >> 16); in data_b3_res()
3192 NCCIcode = ncci | (((word) a->Id) << 8); in data_b3_res()
3213 static byte reset_b3_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in reset_b3_req()
3216 word Info; in reset_b3_req()
3217 word ncci; in reset_b3_req()
3222 ncci = (word)(Id >> 16); in reset_b3_req()
3255 static byte reset_b3_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in reset_b3_res()
3258 word ncci; in reset_b3_res()
3262 ncci = (word)(Id >> 16); in reset_b3_res()
3280 static byte connect_b3_t90_a_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in connect_b3_t90_a_res()
3283 word ncci; in connect_b3_t90_a_res()
3289 ncci = (word)(Id >> 16); in connect_b3_t90_a_res()
3304 add_d(plci, (word)(ncpi->length - 3), &ncpi->info[4]); in connect_b3_t90_a_res()
3315 static byte select_b_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in select_b_req()
3318 word Info = 0; in select_b_req()
3319 word i; in select_b_req()
3341 else if (msg->length && api_parse(&msg->info[1], (word)msg->length, "wwwsss", bp_parms)) in select_b_req()
3356 clear_c_ind_mask_bit(plci, (word)(appl->Id - 1)); in select_b_req()
3435 static byte manufacturer_req(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in manufacturer_req()
3438 word command; in manufacturer_req()
3439 word i; in manufacturer_req()
3440 word ncci; in manufacturer_req()
3443 word codec; in manufacturer_req()
3453 word Info = 0; in manufacturer_req()
3467 if (api_parse(&m->info[1], (word)m->length, "wbbs", m_parms)) { in manufacturer_req()
3481 Id = (((word)plci->Id << 8) | plci->adapter->Id | 0x80); in manufacturer_req()
3572 if (api_parse(&m->info[1], (word)m->length, "bs", m_parms)) { in manufacturer_req()
3735 if (api_parse(&m->info[1], (word)m->length, "d", m_parms)) { in manufacturer_req()
3764 static byte manufacturer_res(dword Id, word Number, DIVA_CAPI_ADAPTER *a, in manufacturer_res()
3767 word indication; in manufacturer_res()
3772 word i; in manufacturer_res()
3846 word i, j; in callback()
4102 word Number; in control_rc()
4103 word Info = 0; in control_rc()
4104 word i; in control_rc()
4105 word ncci; in control_rc()
4134 Id = (((dword)(ncci ? ncci : ch)) << 16) | ((word)plci->Id << 8) | a->Id; in control_rc()
4358 plci->number, "wws", Info, (word)3, SSparms); in control_rc()
4367 rId = ((word)rplci->Id << 8) | rplci->adapter->Id; in control_rc()
4379 "wws", Info, (word)3, SSparms); in control_rc()
4388 rId = ((word)rplci->Id << 8) | rplci->adapter->Id; in control_rc()
4400 "wws", Info, (word)3, SSparms); in control_rc()
4527 "wws", Info, (word)3, SSparms); in control_rc()
4536 "wws", Info, (word)3, SSparms); in control_rc()
4558 rId = ((word)rplci->Id << 8) | rplci->adapter->Id; in control_rc()
4584 "wws", Info, (word)3, SSparms); in control_rc()
4618 plci->number, "wws", Info, (word)3, SSparms); in control_rc()
4644 Id = ((word)plci->Id << 8) | plci->adapter->Id; in control_rc()
4682 plci->number, "wws", Info, (word)3, SSparms); in control_rc()
4770 word ncci; in data_rc()
4786 Id = (((dword)ncci) << 16) | ((word)plci->Id << 8) | a->Id; in data_rc()
4805 word ncci; in data_ack()
4814 Id = (((dword)ncci) << 16) | ((word)plci->Id << 8) | a->Id; in data_ack()
4831 word i; in sig_ind()
4832 word cip; in sig_ind()
4863 word parms_id[] = in sig_ind()
4871 word multi_fac_id[] = {1, FTY}; in sig_ind()
4872 word multi_pi_id[] = {1, PI}; in sig_ind()
4873 word multi_CiPN_id[] = {1, OAD}; in sig_ind()
4874 word multi_ssext_id[] = {1, ESC_SSEXT}; in sig_ind()
4876 word multi_vswitch_id[] = {1, ESC_VSWITCH}; in sig_ind()
4879 word ncci; in sig_ind()
4887 word w; in sig_ind()
4890 Id = ((word)plci->Id << 8) | a->Id; in sig_ind()
5138 rId = ((word)tplci->Id << 8) | tplci->adapter->Id; in sig_ind()
5154 PUT_WORD(&SS_Ind[4], 0x3600 | (word)pty_cai[2]); in sig_ind()
5168 PUT_WORD(&SS_Ind[4], 0x3600 | (word)pty_cai[2]); in sig_ind()
5197 PUT_WORD(&Interr_Err_Ind[4], 0x3600 | (word)pty_cai[2]); in sig_ind()
5264 PUT_WORD(&SS_Ind[4], 0x3600 | (word)pty_cai[2]); in sig_ind()
5323 PUT_WORD(&CONF_Ind[4], 0x3600 | (word)pty_cai[2]); in sig_ind()
5348 rId = ((word)tplci->Id << 8) | tplci->adapter->Id; in sig_ind()
5790 x_Id = ((word)tplci->Id << 8) | tplci->adapter->Id | 0x80; in sig_ind()
5956 Id = ((word)tplci->Id << 8) | a->Id; in sig_ind()
5962 "ws", (word)0, "\x01+"); in sig_ind()
5981 Id = ((word)a->AdvSignalPLCI->Id << 8) | a->Id; in sig_ind()
5987 "ws", (word)0, "\x01-"); in sig_ind()
5999 clear_c_ind_mask_bit(plci, (word)(plci->appl->Id - 1)); in sig_ind()
6001 sendf(plci->appl, _FACILITY_I, Id, 0, "ws", (word)3, resume_cau); in sig_ind()
6017 sendf(plci->appl, _FACILITY_I, Id, 0, "ws", (word)3, "\x05\x04\x00\x02\x00\x00"); in sig_ind()
6086 sendf(plci->appl, _FACILITY_I, Id, 0, "ws", (word)3, resume_cau); in sig_ind()
6120 word i; in SendSetupInfo()
6122 word Info_Number; in SendSetupInfo()
6124 word Info_Mask = 0; in SendSetupInfo()
6194 word i; in SendInfo()
6195 word j; in SendInfo()
6196 word k; in SendInfo()
6198 word Info_Number; in SendInfo()
6200 word Info_Mask = 0; in SendInfo()
6300 Info_Number = (word)NI; in SendInfo()
6305 Info_Number = (word)CST; in SendInfo()
6371 word i; in SendMultiIE()
6372 word j; in SendMultiIE()
6374 word Info_Number; in SendMultiIE()
6377 word Info_Mask = 0; in SendMultiIE()
6400 Info_Number = (word)ie_type; in SendMultiIE()
6401 Info_Mask = (word)info_mask; in SendMultiIE()
6444 word i; in SendSSExtInd()
6491 word ncci; in nl_ind()
6494 word NCCIcode; in nl_ind()
6496 word count; in nl_ind()
6497 word Num; in nl_ind()
6498 word i, ncpi_state; in nl_ind()
6500 word msg; in nl_ind()
6501 word info = 0; in nl_ind()
6502 word fax_feature_bits; in nl_ind()
6505 static word fax_info[] = { in nl_ind()
6558 static word rtp_info[] = { in nl_ind()
6572 Id = (((dword)(ncci ? ncci : ch)) << 16) | (((word) plci->Id) << 8) | a->Id; in nl_ind()
6627 word conn_opt, ncpi_opt = 0x00; in nl_ind()
6643 PUT_WORD(&(plci->ncpi_buffer[1]), (word)(GET_DWORD(data) & 0x0000FFFF)); in nl_ind()
6715 …capidtmf_recv_process_block(&(plci->capidtmf_state), plci->RData[0].P + 1, (word)(plci->RData[0].P… in nl_ind()
6720 dtmf_indication(Id, plci, dtmf_code_buffer, (word)(i + 1)); in nl_ind()
7123 "ws", (word)3, "\x03\x04\x00\x00"); in nl_ind()
7181 NCCIcode = ncci | (((word)a->Id) << 8); in nl_ind()
7199 (word)((a->manufacturer_features & MANUFACTURER_FEATURE_OOB_CHANNEL) ? 40 : 2000)) in nl_ind()
7270 static word get_plci(DIVA_CAPI_ADAPTER *a) in get_plci()
7272 word i, j; in get_plci()
7350 word p_length; in add_p()
7362 if (p) add_ie(plci, code, p->info, (word)p->length); in add_s()
7376 add_ie(plci, p->info[i - 1], (byte *)&(p->info[i]), (word)p->info[i]); in add_ss()
7403 static void add_ie(PLCI *plci, byte code, byte *p, word p_length) in add_ie()
7405 word i; in add_ie()
7429 static void add_d(PLCI *plci, word length, byte *p) in add_d()
7431 word i; in add_d()
7449 word i; in add_ai()
7456 if (api_parse(&ai->info[1], (word)ai->length, "ssss", ai_parms)) in add_ai()
7468 static word add_b1(PLCI *plci, API_PARSE *bp, word b_channel_info, in add_b1()
7469 word b1_facilities) in add_b1()
7477 word i; in add_b1()
7480 word j, n, w; in add_b1()
7507 plci->B1_resource = add_b1_facilities(plci, 9, (word)(b1_facilities | B1_FACILITY_VOICE)); in add_b1()
7508 adjust_b1_facilities(plci, plci->B1_resource, (word)(b1_facilities | B1_FACILITY_VOICE)); in add_b1()
7528 dbug(1, dprintf("b_prot_len=%d", (word)bp->length)); in add_b1()
7530 if (api_parse(&bp->info[1], (word)bp->length, "wwwsssb", bp_parms)) in add_b1()
7533 if (api_parse(&bp->info[1], (word)bp->length, "wwwsss", bp_parms)) in add_b1()
7539 else if (api_parse(&bp->info[1], (word)bp->length, "wwwssss", bp_parms)) in add_b1()
7547 if (api_parse(&bp_parms[6].info[1], (word)bp_parms[6].length, "w", global_config)) in add_b1()
7567 plci->B1_resource = add_b1_facilities(plci, 31, (word)(b1_facilities & ~B1_FACILITY_VOICE)); in add_b1()
7568 adjust_b1_facilities(plci, plci->B1_resource, (word)(b1_facilities & ~B1_FACILITY_VOICE)); in add_b1()
7585 …plci->B1_resource = add_b1_facilities(plci, 35/* PIAFS HARDWARE FACILITY */, (word)(b1_facilities … in add_b1()
7586 adjust_b1_facilities(plci, plci->B1_resource, (word)(b1_facilities & ~B1_FACILITY_VOICE)); in add_b1()
7607 (word)(b1_facilities & ~B1_FACILITY_VOICE)); in add_b1()
7608 adjust_b1_facilities(plci, plci->B1_resource, (word)(b1_facilities & ~B1_FACILITY_VOICE)); in add_b1()
7621 if (api_parse(&bp_parms[3].info[1], (word)bp_parms[3].length, "wwwwww", mdm_cfg)) in add_b1()
7748 if (!api_parse(&bp_parms[3].info[1], (word)bp_parms[3].length, "wwwwwws", mdm_cfg)) in add_b1()
7811 if (!api_parse(&bp_parms[3].info[1], (word)bp_parms[3].length, "wwwwwwss", mdm_cfg)) in add_b1()
7813 if (!api_parse(&mdm_cfg[7].info[1], (word)mdm_cfg[7].length, "sss", mdm_cfg_v18)) in add_b1()
7818 for (j = 1; j < ((word)(cai[i] + 1)); j++) in add_b1()
7933 static word add_b23(PLCI *plci, API_PARSE *bp) in add_b23()
7935 word i, fax_control_bits; in add_b23()
8023 dbug(1, dprintf("b_prot_len=%d", (word)bp->length)); in add_b23()
8024 if ((word)bp->length > 256) return _WRONG_MESSAGE_FORMAT; in add_b23()
8026 if (api_parse(&bp->info[1], (word)bp->length, "wwwsssb", bp_parms)) in add_b23()
8029 if (api_parse(&bp->info[1], (word)bp->length, "wwwsss", bp_parms)) in add_b23()
8035 else if (api_parse(&bp->info[1], (word)bp->length, "wwwssss", bp_parms)) in add_b23()
8110 if (api_parse(&bp_parms[6].info[1], (word)bp_parms[6].length, "w", global_config)) in add_b23()
8167 …if (b2_config->length && api_parse(&b2_config->info[1], (word)b2_config->length, "bwww", b2_config… in add_b23()
8224 …if ((llc[1] == V120_V42BIS) && api_parse(&b2_config->info[1], (word)b2_config->length, "bbbbwww", … in add_b23()
8263 if (api_parse(&b2_config->info[1], (word)b2_config->length, "bbbbwww", b2_config_parms)) in add_b23()
8269 if (api_parse(&b2_config->info[1], (word)b2_config->length, "bbbbs", b2_config_parms)) in add_b23()
8337 PUT_WORD(&dlc[7], (word)b2_config_parms[4].length); in add_b23()
8352 if (api_parse(&b3_config->info[1], (word)b3_config->length, "wwss", b3_config_parms)) in add_b23()
8498 if (api_parse(&b3_config->info[1], (word)b3_config->length, "wwsss", b3_config_parms)) in add_b23()
8570 static word add_modem_b23(PLCI *plci, API_PARSE *bp_parms) in add_modem_b23()
8576 word i; in add_modem_b23()
8577 word b2_config = 0; in add_modem_b23()
8601 (word)bp_parms[4].length, "w", in add_modem_b23()
8754 word l; in send_req()
8812 word ncci; in send_data()
8888 word i, j; in listen_check()
8902 for (i = a->listen_active; i < ((word)(a->max_listen + activnotifiedcalls)); i++) { in listen_check()
8929 static void IndParse(PLCI *plci, word *parms_id, byte **parms, byte multiIEsize) in IndParse()
8931 word ploc; /* points to current location within packet */ in IndParse()
8936 word i; in IndParse()
8937 word code; in IndParse()
8938 word mIEindex = 0; in IndParse()
9016 word i; in ie_compare()
9019 for (i = 0; i < (word)(ie1[0] + 1); i++) if (ie1[i] != ie2[i]) return false; in ie_compare()
9023 static word find_cip(DIVA_CAPI_ADAPTER *a, byte *bc, byte *hlc) in find_cip()
9025 word i; in find_cip()
9026 word j; in find_cip()
9122 static word AdvCodecSupport(DIVA_CAPI_ADAPTER *a, PLCI *plci, APPL *appl, in AdvCodecSupport()
9125 word j; in AdvCodecSupport()
9315 word j; in AutomaticLaw()
9337 word CapiRelease(word Id) in CapiRelease()
9339 word i, j, appls_found; in CapiRelease()
9378 if (test_c_ind_mask_bit(plci, (word)(Id - 1))) in CapiRelease()
9380 clear_c_ind_mask_bit(plci, (word)(Id - 1)); in CapiRelease()
9389 if (test_c_ind_mask_bit(plci, (word)(Id - 1))) in CapiRelease()
9391 clear_c_ind_mask_bit(plci, (word)(Id - 1)); in CapiRelease()
9454 static word plci_remove_check(PLCI *plci) in plci_remove_check()
9592 word min_digit_duration, min_gap_duration; in dtmf_enable_receiver()
9628 static void dtmf_send_digits(PLCI *plci, byte *digit_buffer, word digit_count) in dtmf_send_digits()
9630 word w, i; in dtmf_send_digits()
9701 static word dtmf_save_config(dword Id, PLCI *plci, byte Rc) in dtmf_save_config()
9711 static word dtmf_restore_config(dword Id, PLCI *plci, byte Rc) in dtmf_restore_config()
9713 word Info; in dtmf_restore_config()
9750 word internal_command, Info; in dtmf_command()
9777 adjust_b1_resource(Id, plci, NULL, (word)(plci->B1_facilities | in dtmf_command()
9851 adjust_b1_resource(Id, plci, NULL, (word)(plci->B1_facilities & in dtmf_command()
9877 adjust_b1_resource(Id, plci, NULL, (word)(plci->B1_facilities | in dtmf_command()
9919 static byte dtmf_request(dword Id, word Number, DIVA_CAPI_ADAPTER *a, PLCI *plci, APPL *appl, API… in dtmf_request()
9921 word Info; in dtmf_request()
9922 word i, j; in dtmf_request()
10118 word i; in dtmf_confirmation()
10137 static void dtmf_indication(dword Id, PLCI *plci, byte *msg, word length) in dtmf_indication()
10139 word i, j, n; in dtmf_indication()
10189 word i; in dtmf_parameter_write()
10226 static word dtmf_parameter_save_config(dword Id, PLCI *plci, byte Rc) in dtmf_parameter_save_config()
10236 static word dtmf_parameter_restore_config(dword Id, PLCI *plci, byte Rc) in dtmf_parameter_restore_config()
10238 word Info; in dtmf_parameter_restore_config()
10280 word li_total_channels;
10511 word n, i, j; in mixer_calculate_coefs()
10872 word w, ch; in xconnect_query_addresses()
10906 static void xconnect_write_coefs(PLCI *plci, word internal_command) in xconnect_write_coefs()
10921 word w, n, i, j, r, s, to_ch; in xconnect_write_coefs_process()
11087 && (ADV_VOICE_NEW_COEF_BASE + sizeof(word) <= a->adv_voice_coef_length)) in xconnect_write_coefs_process()
11131 if (ADV_VOICE_NEW_COEF_BASE + sizeof(word) + w < a->adv_voice_coef_length) in xconnect_write_coefs_process()
11132 *p = a->adv_voice_coef_buffer[ADV_VOICE_NEW_COEF_BASE + sizeof(word) + w]; in xconnect_write_coefs_process()
11193 && (ADV_VOICE_NEW_COEF_BASE + sizeof(word) <= a->adv_voice_coef_length)) in xconnect_write_coefs_process()
11232 if (ADV_VOICE_NEW_COEF_BASE + sizeof(word) + w < a->adv_voice_coef_length) in xconnect_write_coefs_process()
11233 *p = a->adv_voice_coef_buffer[ADV_VOICE_NEW_COEF_BASE + sizeof(word) + w]; in xconnect_write_coefs_process()
11259 word i, w; in mixer_notify_update()
11332 word i, j; in mixer_clear_config()
11406 static word mixer_save_config(dword Id, PLCI *plci, byte Rc) in mixer_save_config()
11409 word i, j; in mixer_save_config()
11431 static word mixer_restore_config(dword Id, PLCI *plci, byte Rc) in mixer_restore_config()
11434 word Info; in mixer_restore_config()
11517 word i, internal_command; in mixer_command()
11536 adjust_b1_resource(Id, plci, NULL, (word)(plci->B1_facilities | in mixer_command()
11554 && (add_b1_facilities(plci, plci->B1_resource, (word)(plci->B1_facilities & in mixer_command()
11569 && (add_b1_facilities(plci, plci->B1_resource, (word)(plci->B1_facilities & in mixer_command()
11594 adjust_b1_resource(Id, plci, NULL, (word)(plci->B1_facilities & in mixer_command()
11640 word i, ch_a, ch_a_v, ch_a_s, ch_b, ch_b_v, ch_b_s; in li_update_connect()
11783 word ch_a, ch_a_v, ch_a_s, ch_b, ch_b_v, ch_b_s; in li2_update_connect()
11888 static word li_check_main_plci(dword Id, PLCI *plci) in li_check_main_plci()
11910 dword plci_b_id, word plci_b_write_pos, byte *p_result) in li_check_plci_b()
11961 (word)(plci_b->B1_facilities | B1_FACILITY_MIXER))) & B1_FACILITY_MIXER)) in li_check_plci_b()
11973 dword plci_b_id, word plci_b_write_pos, byte *p_result) in li2_check_plci_b()
12024 (word)(plci_b->B1_facilities | B1_FACILITY_MIXER))) & B1_FACILITY_MIXER)) in li2_check_plci_b()
12035 static byte mixer_request(dword Id, word Number, DIVA_CAPI_ADAPTER *a, PLCI *plci, APPL *appl, AP… in mixer_request()
12037 word Info; in mixer_request()
12038 word i; in mixer_request()
12045 word participant_parms_pos; in mixer_request()
12048 word result_pos; in mixer_request()
12049 word plci_b_write_pos; in mixer_request()
12212 (word)(li_parms[1].length - participant_parms_pos), "s", li_participant_struct)) in mixer_request()
12246 …participant_parms_pos = (word)((&li_participant_struct[0].info[1 + li_participant_struct[0].length… in mixer_request()
12334 (word)(li_parms[1].length - participant_parms_pos), "s", li_participant_struct)) in mixer_request()
12365 …participant_parms_pos = (word)((&li_participant_struct[0].info[1 + li_participant_struct[0].length… in mixer_request()
12498 static void mixer_indication_xconnect_from(dword Id, PLCI *plci, byte *msg, word length) in mixer_indication_xconnect_from()
12500 word i, j, ch; in mixer_indication_xconnect_from()
12541 static void mixer_indication_xconnect_to(dword Id, PLCI *plci, byte *msg, word length) in mixer_indication_xconnect_to()
12552 word plci_b_write_pos; in mixer_notify_source_removed()
12575 word i, j; in mixer_remove()
12626 word w; in ec_write_parameters()
12667 static word ec_save_config(dword Id, PLCI *plci, byte Rc) in ec_save_config()
12677 static word ec_restore_config(dword Id, PLCI *plci, byte Rc) in ec_restore_config()
12679 word Info; in ec_restore_config()
12716 word internal_command, Info; in ec_command()
12747 adjust_b1_resource(Id, plci, NULL, (word)(plci->B1_facilities | in ec_command()
12805 adjust_b1_resource(Id, plci, NULL, (word)(plci->B1_facilities & in ec_command()
12827 static byte ec_request(dword Id, word Number, DIVA_CAPI_ADAPTER *a, PLCI *plci, APPL *appl, API_P… in ec_request()
12829 word Info; in ec_request()
12830 word opt; in ec_request()
13017 static void ec_indication(dword Id, PLCI *plci, byte *msg, word length) in ec_indication()
13073 static void adv_voice_write_coefs(PLCI *plci, word write_command) in adv_voice_write_coefs()
13076 word i; in adv_voice_write_coefs()
13079 word w, n, j, k; in adv_voice_write_coefs()
13092 while (i + sizeof(word) <= a->adv_voice_coef_length) in adv_voice_write_coefs()
13098 while (i < ADV_VOICE_OLD_COEF_COUNT * sizeof(word)) in adv_voice_write_coefs()
13179 if (ADV_VOICE_NEW_COEF_BASE + sizeof(word) <= a->adv_voice_coef_length) in adv_voice_write_coefs()
13204 *(p++) = (ADV_VOICE_NEW_COEF_BASE + sizeof(word) + n < a->adv_voice_coef_length) ? in adv_voice_write_coefs()
13205 a->adv_voice_coef_buffer[ADV_VOICE_NEW_COEF_BASE + sizeof(word) + n] : 0x00; in adv_voice_write_coefs()
13232 word i, j; in adv_voice_clear_config()
13299 static word adv_voice_save_config(dword Id, PLCI *plci, byte Rc) in adv_voice_save_config()
13309 static word adv_voice_restore_config(dword Id, PLCI *plci, byte Rc) in adv_voice_restore_config()
13312 word Info; in adv_voice_restore_config()
13399 static word get_b1_facilities(PLCI *plci, byte b1_resource) in get_b1_facilities()
13401 word b1_facilities; in get_b1_facilities()
13431 static byte add_b1_facilities(PLCI *plci, byte b1_resource, word b1_facilities) in add_b1_facilities()
13536 static void adjust_b1_facilities(PLCI *plci, byte new_b1_resource, word new_b1_facilities) in adjust_b1_facilities()
13538 word removed_facilities; in adjust_b1_facilities()
13581 static word adjust_b_process(dword Id, PLCI *plci, byte Rc) in adjust_b_process()
13583 word Info; in adjust_b_process()
13738 (word)((plci->adjust_b_mode & ADJUST_B_MODE_NO_RESOURCE) ? 2 : 0), in adjust_b_process()
13933 static void adjust_b1_resource(dword Id, PLCI *plci, API_SAVE *bp_msg, word b1_facilities, word i… in adjust_b1_resource()
13943 plci->adjust_b_ncci = (word)(Id >> 16); in adjust_b1_resource()
13957 word internal_command; in adjust_b_restore()
13983 plci->adjust_b_ncci = (word)(Id >> 16); in adjust_b_restore()
14003 word Info; in reset_b3_command()
14004 word internal_command; in reset_b3_command()
14019 plci->adjust_b_ncci = (word)(Id >> 16); in reset_b3_command()
14043 word Info; in select_b_command()
14044 word internal_command; in select_b_command()
14063 plci->adjust_b_ncci = (word)(Id >> 16); in select_b_command()
14102 word internal_command; in fax_connect_ack_command()
14149 word internal_command; in fax_edata_ack_command()
14187 word Info; in fax_connect_info_command()
14188 word internal_command; in fax_connect_info_command()
14238 word Info; in fax_adjust_b23_command()
14239 word internal_command; in fax_adjust_b23_command()
14254 plci->adjust_b_ncci = (word)(Id >> 16); in fax_adjust_b23_command()
14286 word internal_command; in fax_disconnect_command()
14329 word Info; in rtp_connect_b3_req_command()
14330 word internal_command; in rtp_connect_b3_req_command()
14382 word internal_command; in rtp_connect_b3_res_command()
14434 word Info; in hold_save_command()
14435 word internal_command; in hold_save_command()
14452 plci->adjust_b_ncci = (word)(Id >> 16); in hold_save_command()
14475 word Info; in retrieve_restore_command()
14476 word internal_command; in retrieve_restore_command()
14491 plci->adjust_b_ncci = (word)(Id >> 16); in retrieve_restore_command()
14573 word i; in channel_flow_control_remove()
14690 word NCCIcode; in channel_can_xon()
14692 word Num; in channel_can_xon()
14693 word i; in channel_can_xon()
14701 NCCIcode = a->ch_ncci[ch] | (((word) a->Id) << 8); in channel_can_xon()
14721 static word CPN_filter_ok(byte *cpn, DIVA_CAPI_ADAPTER *a, word offset) in CPN_filter_ok()
14738 word i, j, k, busy, group_found; in group_optimization()
14741 word appl_number_group_type[MAX_APPL]; in group_optimization()
14852 word CapiRegister(word id) in CapiRegister()
14854 word i, j, appls_found; in CapiRegister()
14905 word i; in VSwitchReqInd()