annotate src/g23m-aci/aci/psa_dcms.c @ 216:2be687f4476c default tip

l1_init.c: sync with Tourmaline: L1 recovery ABB init fix
author Mychaela Falconia <falcon@freecalypso.org>
date Mon, 31 Oct 2022 01:23:14 +0000
parents d393cd9bb723
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 /*
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 +-----------------------------------------------------------------------------
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 | Project : DCM and TCPIP
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 | Modul : ACI
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 +-----------------------------------------------------------------------------
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 | Copyright 2002 Texas Instruments Berlin, AG
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 | All rights reserved.
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 |
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 | This file is confidential and a trade secret of Texas
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 | Instruments Berlin, AG
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 | The receipt of or possession of this file does not convey
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 | any rights to reproduce or disclose its contents or to
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 | manufacture, use, or sell anything it may describe, in
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 | whole, or in part, without the specific written consent of
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 | Texas Instruments Berlin, AG.
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 +-----------------------------------------------------------------------------
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 | Purpose :
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 +-----------------------------------------------------------------------------
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 */
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 #ifndef PSA_DCMS_C
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 #define PSA_DCMS_C
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 #endif
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 /*==== INCLUDES ===================================================*/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 #include "aci_all.h"
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 #include "psa_dcm.h"
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 #include "socket_int.h"
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 /*==== CONSTANTS ==================================================*/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31 /*==== TYPES ======================================================*/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 /*==== EXPORT =====================================================*/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 /*==== VARIABLES ==================================================*/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 /*==== FUNCTIONS ==================================================*/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 /***************************************************************************************
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 * Function : psaDCM_open_conn_cnf
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 * Parameter : T_DCM_RET
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 * - dcm result
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 * T_APPLI_USER
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 * - application user id
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 * Return : BOOL
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 * if sending primitive is sucessful , return TREU , otherwise return FALSE
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 * Description : send dcm open conn cnf primitive to application
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 ***************************************************************************************/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49 GLOBAL BOOL psaDCM_open_conn_cnf(T_DCM_RET result, T_SOCK_API_INSTANCE api_instance)
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 T_SOCK_API_INSTANCE_DATA* api_data;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 TRACE_FUNCTION("DCM: psaDCM_open_conn_cnf()");
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 TRACE_EVENT_P1("DCM: result %d",result);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 /* set api_data */
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 api_data = (T_SOCK_API_INSTANCE_DATA*)api_instance;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 PALLOC(dcm_open_conn_cnf, DCM_OPEN_CONN_CNF);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 dcm_open_conn_cnf->result = result;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 PSEND(api_data->hCommAPP, dcm_open_conn_cnf);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 return TRUE;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67 /***************************************************************************************
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 * Function : psaDCM_close_conn_cnf
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69 * Parameter : T_DCM_RET
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70 * - dcm result
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
71 * T_APPLI_USER
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72 * - application user id
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
73 * Return : BOOL
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74 if sending primitive is sucessful , return TREU , otherwise return FALSE
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
75 * Description : send dcm cloes conn cnf primitive to application
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
76 ***************************************************************************************/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77 GLOBAL BOOL psaDCM_close_conn_cnf(T_DCM_RET result, T_SOCK_API_INSTANCE api_instance)
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 T_SOCK_API_INSTANCE_DATA* api_data;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81 TRACE_FUNCTION("DCM: psaDCM_close_conn_cnf()");
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
83 /* set api_data */
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 api_data = (T_SOCK_API_INSTANCE_DATA*)api_instance;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
85 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86 PALLOC(dcm_close_conn_cnf, DCM_CLOSE_CONN_CNF);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
87 dcm_close_conn_cnf->result = result;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88 PSEND(api_data->hCommAPP, dcm_close_conn_cnf);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
89 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
90 return TRUE;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
93
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
94
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
95 /***************************************************************************************
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
96 * Function : psaDCM_get_current_conn_cnf
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
97 * Parameter : T_DCM_RET
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
98 * - dcm result
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
99 * T_APPLI_USER
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
100 * - application user id
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
101 * Return : BOOL
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
102 * if sending primitive is sucessful , return TREU , otherwise return FALSE
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
103 * Description : send dcm get current conn cnf primitive to application
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
104 ***************************************************************************************/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
105 GLOBAL BOOL psaDCM_get_current_conn_cnf(T_DCM_RET result,
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
106 T_SOCK_API_INSTANCE api_instance,
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
107 T_DCM_ENV_CTRL_BLK *dcm_evt_blk)
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
108 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
109 U8 row;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
110 T_SOCK_API_INSTANCE_DATA* api_data;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
111
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
112 TRACE_FUNCTION("DCM: psaDCM_get_current_conn_cnf()");
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
113
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
114 /* set api_data */
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
115 api_data = (T_SOCK_API_INSTANCE_DATA*)api_instance;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
116
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117 row = dcm_evt_blk->current_row;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 PALLOC(dcm_get_current_conn_cnf, DCM_GET_CURRENT_CONN_CNF);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120 dcm_get_current_conn_cnf->result = result;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
121
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
122 if(result == DCM_OK)
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
123 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
124 /* current connected user infomation*/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125 dcm_get_current_conn_cnf->dcm_info_conn.bearer_handle =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126 dcm_evt_blk->ipu_list[row].bearer_handle;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127 dcm_get_current_conn_cnf->dcm_info_conn.app_handle =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
128 dcm_evt_blk->ipu_list[row].app_handle;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
129 dcm_get_current_conn_cnf->dcm_info_conn.bearer_type =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
130 dcm_evt_blk->ipu_list[row].bearer_type;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
131 dcm_get_current_conn_cnf->dcm_info_conn.apn_valid =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
132 dcm_evt_blk->ipu_list[row].apn_valid;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
133 memcpy(dcm_get_current_conn_cnf->dcm_info_conn.apn,
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
134 dcm_evt_blk->ipu_list[row].apn , (CDCM_APN_MAX_LEN + 1) );
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
135 dcm_get_current_conn_cnf->dcm_info_conn.phone_number_valid =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
136 dcm_evt_blk->ipu_list[row].phone_number_valid;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
137 memcpy(dcm_get_current_conn_cnf->dcm_info_conn.phone_number,
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
138 dcm_evt_blk->ipu_list[row].phone_number, (CDCM_PHONE_NR_LEN + 1) );
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
139 dcm_get_current_conn_cnf->dcm_info_conn.user_id_valid =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
140 dcm_evt_blk->ipu_list[row].user_id_valid;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
141 memcpy(dcm_get_current_conn_cnf->dcm_info_conn.user_id,
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
142 dcm_evt_blk->ipu_list[row].user_id, (CDCM_USER_MAX_LEN + 1) );
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
143 dcm_get_current_conn_cnf->dcm_info_conn.password_valid =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
144 dcm_evt_blk->ipu_list[row].password_valid;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
145 memcpy(dcm_get_current_conn_cnf->dcm_info_conn.password,
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
146 dcm_evt_blk->ipu_list[row].password, (CDCM_PASSWORD_MAX_LEN + 1) );
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
147 dcm_get_current_conn_cnf->dcm_info_conn.cid =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
148 dcm_evt_blk->ipu_list[row].cid;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
149 dcm_get_current_conn_cnf->dcm_info_conn.ip_address =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
150 dcm_evt_blk->ipu_list[row].ip_address;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
151 dcm_get_current_conn_cnf->dcm_info_conn.dns1 =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
152 dcm_evt_blk->ipu_list[row].dns1;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
153 dcm_get_current_conn_cnf->dcm_info_conn.dns2 =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
154 dcm_evt_blk->ipu_list[row].dns2;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
155 dcm_get_current_conn_cnf->dcm_info_conn.gateway =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
156 dcm_evt_blk->ipu_list[row].gateway;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
157 dcm_get_current_conn_cnf->dcm_info_conn.auth_type =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
158 dcm_evt_blk->ipu_list[row].auth_type;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
159 dcm_get_current_conn_cnf->dcm_info_conn.data_compr =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
160 dcm_evt_blk->ipu_list[row].data_compr;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
161 dcm_get_current_conn_cnf->dcm_info_conn.header_compr =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
162 dcm_evt_blk->ipu_list[row].header_compr;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
163 dcm_get_current_conn_cnf->dcm_info_conn.precedence =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
164 dcm_evt_blk->ipu_list[row].precedence;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
165 dcm_get_current_conn_cnf->dcm_info_conn.delay =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
166 dcm_evt_blk->ipu_list[row].delay;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
167 dcm_get_current_conn_cnf->dcm_info_conn.reliability =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
168 dcm_evt_blk->ipu_list[row].reliability;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
169 dcm_get_current_conn_cnf->dcm_info_conn.peak_throughput =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
170 dcm_evt_blk->ipu_list[row].peak_throughput;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
171 dcm_get_current_conn_cnf->dcm_info_conn.mean_throughput =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
172 dcm_evt_blk->ipu_list[row].mean_throughput;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
173 dcm_get_current_conn_cnf->dcm_info_conn.shareable =
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
174 dcm_evt_blk->ipu_list[row].shareable;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
175 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
176 PSEND(api_data->hCommAPP, dcm_get_current_conn_cnf);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
177 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
178 return TRUE;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
179 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
180
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
181
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
182 /***************************************************************************************
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
183 * Function : psaDCM_error_ind
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
184 * Parameter : T_DCM_STATUS_IND_MSG *
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
185 * - dcm error indication msg
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
186 * T_APPLI_USER
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
187 * - application user id
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
188 * Return : BOOL
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
189 * if sending primitive is sucessful , return TRUE , otherwise return FALSE
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
190 * Description : send error ind primitive to application
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
191 ***************************************************************************************/
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
192 extern BOOL is_netdrop ;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
193 GLOBAL BOOL psaDCM_error_ind(T_DCM_STATUS_IND_MSG* dcm_error_ind_msg,
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
194 T_SOCK_API_INSTANCE api_instance )
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
195 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
196 T_SOCK_API_INSTANCE_DATA* api_data;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
197
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
198 TRACE_FUNCTION("DCM: psaDCM_error_ind()");
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
199
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
200 /* set api_data */
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
201 api_data = (T_SOCK_API_INSTANCE_DATA*)api_instance;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
202 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
203 PALLOC(dcm_error_ind, DCM_ERROR_IND);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
204 if( is_netdrop==TRUE) //pinghua added
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
205 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
206 dcm_error_ind->dcm_err = 99 ;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
207 dcm_error_ind->result = 99;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
208 is_netdrop=FALSE ;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
209 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
210 else
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
211 {
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
212 dcm_error_ind->dcm_err = dcm_error_ind_msg->error;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
213
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
214 dcm_error_ind->result = DCM_PS_CONN_BROKEN;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
215 } //pinghua add end
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
216 PSEND(api_data->hCommAPP, dcm_error_ind);
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
217 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
218 return TRUE;
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
219 }
d393cd9bb723 src/g23m-*: initial import from Magnetite
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
220