annotate src/g23m-gprs/upm/upm_sndcp_output_handler.c @ 495:9e55fe3a5ee4

OSL: os_mis_fl.c compiles
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 24 Jun 2018 20:47:42 +0000
parents 2cf312e56ee7
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
197
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 /*----------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 | Project : 3G PS
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 | Module : UPM
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 +-----------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 | Copyright 2003 Texas Instruments.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 | All rights reserved.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 |
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 | This file is confidential and a trade secret of Texas
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 | Instruments .
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 | The receipt of or possession of this file does not convey
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 | any rights to reproduce or disclose its contents or to
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 | manufacture, use, or sell anything it may describe, in
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 | whole, or in part, without the specific written consent of
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 | Texas Instruments.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 +-----------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 | Purpose: Output functions for primitives from UPM to the MM entity.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 | For design details, see:
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 | 8010.939 UPM Detailed Specification
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 +---------------------------------------------------------------------------*/
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 /*==== DECLARATION CONTROL =================================================*/
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 /*==== INCLUDES ============================================================*/
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 #include "upm.h"
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 #include "upm_sndcp_output_handler.h"
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 #include "upm_mm_output_handler.h"
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 #ifndef UPM_WITHOUT_USER_PLANE
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 #include "upm_dti_output_handler.h"
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31 #endif /* UPM_WITHOUT_USER_PLANE */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 /*==== CONSTS ===============================================================*/
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 /*==== TYPES ================================================================*/
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 /*==== LOCALS ===============================================================*/
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 /*==== PUBLIC FUNCTIONS =====================================================*/
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 /*
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 | Function : send_sn_activate_req
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 | Description : Allocate, pack and send SN_ACTIVATE_REQ primitive.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 |
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 | Parameters : ptr_context_data - context data
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 | active - active/passive establishment flag to SNDCP
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 void send_sn_activate_req(struct T_CONTEXT_DATA *ptr_context_data,
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52 T_NAS_comp_params *comp_params, BOOL active)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 (void)TRACE_FUNCTION("send_sn_activate_req");
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 struct T_UPM_CONTEXT_DATA_GPRS *gprs_data = &ptr_context_data->gprs_data;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58 PALLOC(prim, SN_ACTIVATE_REQ);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 /*lint -e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 prim->nsapi = ptr_context_data->nsapi;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 prim->sapi = gprs_data->sndcp_llc_sapi;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 prim->radio_prio = gprs_data->sndcp_radio_prio;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 prim->snsm_qos.delay = gprs_data->sndcp_delay;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 prim->snsm_qos.relclass = gprs_data->sndcp_relclass;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66 prim->snsm_qos.peak = gprs_data->sndcp_peak_bitrate;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67 prim->snsm_qos.preced = gprs_data->sndcp_preced;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 prim->snsm_qos.mean = gprs_data->sndcp_mean;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70 prim->establish = (active ? (U8)SN_ACTIVE_ESTABLISHMENT :
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
71 (U8)SN_PASSIVE_ESTABLISHMENT);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72 if (comp_params != NULL)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
73 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74 memcpy(&prim->comp_params, comp_params, sizeof(T_NAS_comp_params));
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
75 } else {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
76 memset(&prim->comp_params, 0, sizeof(T_NAS_comp_params));
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78 prim->pkt_flow_id = (U16)gprs_data->pkt_flow_id;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 /*lint +e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80 (void)PSEND(hCommSNDCP, prim);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
83
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 /*
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
85 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86 | Function : send_sn_count_req
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
87 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88 | Description : Allocate, pack and send SN_COUNT_REQ primitive.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
89 |
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
90 | Parameters : nsapi - NSAPI
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91 | reset - Reset indicator
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
93 */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
94 void send_sn_count_req(U8 nsapi, U8 reset)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
95 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
96 (void)TRACE_FUNCTION("send_sn_count_req");
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
97
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
98 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
99 PALLOC(prim, SN_COUNT_REQ);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
100 /*lint -e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
101 prim->nsapi = nsapi;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
102 prim->reset = reset;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
103
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
104 /*lint +e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
105 (void)PSEND(hCommSNDCP, prim);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
106 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
107 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
108
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
109 /*
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
110 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
111 | Function : send_sn_deactivate_req
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
112 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
113 | Description : Allocate, pack and send SN_DEACTIVATE_REQ primitive.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
114 |
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
115 | Parameters : nsapi - NSAPI to deactivate
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
116 | rel_ind - local release indicator for SNDCP
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118 */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 void send_sn_deactivate_req(U8 nsapi, U8 rel_ind)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
121 (void)TRACE_FUNCTION("send_sn_deactivate_req");
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
122
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
123 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
124 PALLOC(prim, SN_DEACTIVATE_REQ);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125 /*lint -e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126 prim->nsapi = nsapi;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127 prim->rel_ind = rel_ind;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
128 /*lint +e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
129 (void)PSEND(hCommSNDCP, prim);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
130 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
131 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
132
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
133 /*
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
134 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
135 | Function : send_sn_modify_req
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
136 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
137 | Description : Allocate, pack and send SN_MODIFY_REQ primitive.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
138 |
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
139 | Parameters : ptr_context_data - context data
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
140 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
141 */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
142 void send_sn_modify_req(struct T_CONTEXT_DATA *ptr_context_data)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
143 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
144 (void)TRACE_FUNCTION("send_sn_modify_req");
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
145
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
146 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
147 struct T_UPM_CONTEXT_DATA_GPRS *gprs_data = &ptr_context_data->gprs_data;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
148 PALLOC(prim, SN_MODIFY_REQ);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
149
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
150 /*lint -e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
151 prim->nsapi = ptr_context_data->nsapi;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
152 prim->sapi = gprs_data->sndcp_llc_sapi;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
153 prim->radio_prio = gprs_data->sndcp_radio_prio;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
154 prim->snsm_qos.delay = gprs_data->sndcp_delay;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
155 prim->snsm_qos.relclass = gprs_data->sndcp_relclass;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
156 prim->snsm_qos.peak = gprs_data->sndcp_peak_bitrate;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
157 prim->snsm_qos.preced = gprs_data->sndcp_preced;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
158 prim->snsm_qos.mean = gprs_data->sndcp_mean;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
159 prim->pkt_flow_id = (U16)gprs_data->pkt_flow_id;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
160 /*lint +e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
161 (void)PSEND(hCommSNDCP, prim);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
162 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
163 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
164
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
165 /*
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
166 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
167 | Function : send_sn_sequence_req
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
168 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
169 | Description : Allocate, pack and send SN_SEQUENCE_REQ primitive.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
170 |
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
171 | Parameters : mmpm_sequence_ind - MMPM primitive containing sequence numbers
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
172 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
173 */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
174 void send_sn_sequence_req(T_MMPM_SEQUENCE_IND *mmpm_sequence_ind)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
175 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
176 U16 index;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
177 (void)TRACE_FUNCTION("send_sn_sequence_req");
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
178
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
179 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
180 PALLOC(prim, SN_SEQUENCE_REQ);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
181 /*lint -e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
182 prim->c_receive_no_list = mmpm_sequence_ind->c_npdu_list;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
183
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
184 for (index = 0; index < (U16)mmpm_sequence_ind->c_npdu_list; index++)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
185 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
186 prim->receive_no_list[index].nsapi = mmpm_sequence_ind->npdu_list[index].nsapi;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
187 prim->receive_no_list[index].receive_no = mmpm_sequence_ind->npdu_list[index].receive_n_pdu_number_val;
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
188 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
189 /*lint +e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
190 (void)PSEND(hCommSNDCP, prim);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
191 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
192 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
193
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
194 /*
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
195 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
196 | Function : send_sn_get_pending_pdu_req
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
197 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
198 | Description : Allocate, pack and send SN_GET_PENDING_PDU_REQ primitive.
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
199 |
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
200 | Parameters : None
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
201 +------------------------------------------------------------------------------
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
202 */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
203 #ifdef TI_DUAL_MODE
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
204 void send_sn_get_pending_pdu_req(void)
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
205 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
206 (void)TRACE_FUNCTION("send_sn_get_pending_pdu_req");
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
207
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
208 {
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
209 PALLOC(prim, SN_GET_PENDING_PDU_REQ);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
210
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
211 /*lint +e613 (Possible use of null pointer 'prim' in left argument to operator '->') */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
212 (void)PSEND(hCommSNDCP, prim);
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
213 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
214 }
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
215 #endif /* TI_DUAL_MODE */
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
216
2cf312e56ee7 src/g23m-gprs/upm: import from LoCosto source
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
217 /*==== END OF FILE ==========================================================*/