comparison src/g23m-gprs/grr/grr_gfpp.c @ 1:fa8dc04885d8

src/g23m-*: import from Magnetite
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 16 Oct 2020 06:25:50 +0000
parents
children
comparison
equal deleted inserted replaced
0:4e78acac3d88 1:fa8dc04885d8
1 /*
2 +-----------------------------------------------------------------------------
3 | Project : GPRS (8441)
4 | Modul : GRR
5 +-----------------------------------------------------------------------------
6 | Copyright 2002 Texas Instruments Berlin, AG
7 | All rights reserved.
8 |
9 | This file is confidential and a trade secret of Texas
10 | Instruments Berlin, AG
11 | The receipt of or possession of this file does not convey
12 | any rights to reproduce or disclose its contents or to
13 | manufacture, use, or sell anything it may describe, in
14 | whole, or in part, without the specific written consent of
15 | Texas Instruments Berlin, AG.
16 +-----------------------------------------------------------------------------
17 | Purpose : This module implements primitive handler functions for service
18 | GFP of entity GRR.
19 +-----------------------------------------------------------------------------
20 */
21
22 #ifndef GRR_GFPP_C
23 #define GRR_GFPP_C
24 #endif
25
26 #define ENTITY_GRR
27
28 /*==== INCLUDES =============================================================*/
29
30 #include "typedefs.h" /* to get Condat data types */
31
32 #include "vsi.h" /* to get a lot of macros */
33 #include "macdef.h"
34 #include "gprs.h"
35 #include "gsm.h" /* to get a lot of macros */
36 #include "ccdapi.h" /* to get CCD API */
37 #include "prim.h" /* to get the definitions of used SAP and directions */
38 #include "message.h"
39 #include "grr.h" /* to get the global entity definitions */
40 #include "grr_f.h" /* to get the global entity procedure definitions */
41 #include "grr_gfpf.h"
42 #include "grr_pgs.h"
43 #include "grr_psis.h"
44 #include "grr_css.h"
45 #include "grr_meass.h"
46 #include "grr_measf.h"
47 #include "grr_tcs.h"
48 #include "grr_ctrls.h"
49 #include "cl_rlcmac.h"
50
51 /*==== CONST ================================================================*/
52
53 /*==== DIAGNOSTICS ==========================================================*/
54
55 /*==== LOCAL VARS ===========================================================*/
56 LOCAL void gfp_adapt_fn ( ULONG fn );
57 /*==== PRIVATE FUNCTIONS ====================================================*/
58
59 /*
60 +------------------------------------------------------------------------------
61 | Function : gfp_adapt_fn()
62 +------------------------------------------------------------------------------
63 | Description : The function gfp_adapt_fn() calculates the received frame
64 | number and the first framenumber of the current radio block
65 |
66 | Parameters : fn - frame number, where the block is passed to layer23
67 |
68 +------------------------------------------------------------------------------
69 */
70 LOCAL void gfp_adapt_fn ( ULONG fn )
71 {
72 TRACE_FUNCTION( "gfp_adapt_fn" );
73
74 /*
75 * The received frame number is always 4 frames before fn.
76 */
77
78
79 grr_data->dl_fn = fn-4;
80 /*
81 * adapte uplink framenumber from downlink framenumber.
82 * fn could be an idle frame !!!
83 */
84
85 if(!fn)
86 {
87 TRACE_EVENT_P1("INVALID FN IN MPHP PRIMITIVE: fn = %ld not alowed",fn);
88 grr_data->dl_fn = fn;
89 }
90 grr_data->ul_fn = fn;
91 if((grr_data->ul_fn % 13) EQ 12)
92 grr_data->ul_fn++;
93 grr_data->ul_fn %= FN_MAX;
94
95 } /* gfp_adapt_fn() */
96
97
98 /*==== PUBLIC FUNCTIONS =====================================================*/
99
100
101
102 /*
103 +------------------------------------------------------------------------------
104 | Function : gfp_mphp_data_ind
105 +------------------------------------------------------------------------------
106 | Description : Handles the primitive MPHP_DATA_IND
107 |
108 | Parameters : *mphp_data_ind - Ptr to primitive payload
109 |
110 +------------------------------------------------------------------------------
111 */
112 GLOBAL void gfp_mphp_data_ind ( T_MPHP_DATA_IND *mphp_data_ind )
113 {
114 TRACE_FUNCTION( "gfp_mphp_data_ind" );
115
116
117 gfp_adapt_fn(mphp_data_ind->fn);
118
119 switch( GET_STATE( GFP ) )
120 {
121 case GFP_IDLE:
122 PACCESS(mphp_data_ind);
123
124 if(mphp_data_ind->error_flag)
125 {
126 if(mphp_data_ind->l2_channel EQ L2_PCHANNEL_PPCH)
127 {
128 if(grr_decrease_dsc())
129 {
130 /*
131 * Inform GRR
132 */
133 sig_gfp_ctrl_dsf_ind();
134 }
135 }
136 /*
137 TRACE_ERROR( "MPHP_DATA_IND with error_flag(invalid block)" );
138 */
139
140 TRACE_BINDUMP
141 ( hCommGRR, TC_USER5,
142 cl_rlcmac_get_msg_name( D_MSG_TYPE_CRC_ERROR_c, RLC_MAC_ROUTE_DL ),
143 mphp_data_ind->l2_frame, MAX_L2_FRAME_SIZE ); /*lint !e569*/
144 }
145 else
146 {
147 if(mphp_data_ind->l2_channel EQ L2_PCHANNEL_PPCH)
148 {
149 sig_gfp_meas_rxlev_pccch_ind( mphp_data_ind->pccch_lev );
150 grr_increase_dsc();
151 }
152 gfp_prcs_ctrl_msg( &mphp_data_ind->l2_frame[0],
153 mphp_data_ind->l2_channel,
154 mphp_data_ind->relative_pos,
155 mphp_data_ind->fn - 4 );
156 }
157 break;
158 default:
159 TRACE_ERROR( "MPHP_DATA_IND unexpected" );
160 /*
161 * SZML-SGLBL/008
162 */
163 break;
164 }
165 PFREE(mphp_data_ind);
166
167
168 } /* gfp_mphp_data_ind() */
169
170 /*
171 +------------------------------------------------------------------------------
172 | Function : gfp_mphp_scell_pbcch_stop_con
173 +------------------------------------------------------------------------------
174 | Description : Handles the primitive MPHP_SCELL_PBCCH_STOP_CON
175 |
176 | Parameters : *mphp_scell_pbcch_stop_con - Ptr to primitive payload
177 |
178 +------------------------------------------------------------------------------
179 */
180 GLOBAL void gfp_mphp_scell_pbcch_stop_con (
181 T_MPHP_SCELL_PBCCH_STOP_CON *mphp_scell_pbcch_stop_con )
182 {
183 TRACE_FUNCTION( "gfp_mphp_scell_pbcch_stop_con" );
184
185
186 switch( GET_STATE( GFP ) )
187 {
188 case GFP_IDLE:
189 PACCESS(mphp_scell_pbcch_stop_con);
190 sig_gfp_psi_scell_pbcch_stop_con(mphp_scell_pbcch_stop_con);
191 break;
192 default:
193 TRACE_ERROR( "MPHP_SCELL_PBCCH_STOP_CON unexpected" );
194 break;
195 }
196 PFREE(mphp_scell_pbcch_stop_con);
197
198 } /* gfp_mphp_scell_pbcch_stop_con() */
199
200
201
202 /*
203 +------------------------------------------------------------------------------
204 | Function : gfp_mphp_stop_pccch_con
205 +------------------------------------------------------------------------------
206 | Description : Handles the primitive MPHP_STOP_PCCCH_CON
207 |
208 | Parameters : *mphp_stop_pccch_con - Ptr to primitive payload
209 |
210 +------------------------------------------------------------------------------
211 */
212 GLOBAL void gfp_mphp_stop_pccch_con ( T_MPHP_STOP_PCCCH_CON *mphp_stop_pccch_con )
213 {
214 TRACE_FUNCTION( "gfp_mphp_stop_pccch_con" );
215
216
217 switch( GET_STATE( GFP ) )
218 {
219 case GFP_IDLE:
220 PACCESS(mphp_stop_pccch_con);
221 sig_gfp_pg_stop_pccch_con(mphp_stop_pccch_con);
222 break;
223 default:
224 TRACE_ERROR( "MPHP_STOP_PCCCH_CON unexpected" );
225 break;
226 }
227 PFREE(mphp_stop_pccch_con);
228
229 } /* gfp_mphp_stop_pccch_con() */
230
231
232
233 /*
234 +------------------------------------------------------------------------------
235 | Function : gfp_mphp_cr_meas_ind
236 +------------------------------------------------------------------------------
237 | Description : Handles the primitive MPHP_CR_MEAS_IND
238 |
239 | Parameters : *mphp_cr_meas_ind - Ptr to primitive payload
240 |
241 +------------------------------------------------------------------------------
242 */
243 GLOBAL void gfp_mphp_cr_meas_ind ( T_MPHP_CR_MEAS_IND *mphp_cr_meas_ind )
244 {
245 TRACE_FUNCTION( "gfp_mphp_cr_meas_ind" );
246
247 switch( GET_STATE( GFP ) )
248 {
249 case GFP_IDLE:
250 PACCESS( mphp_cr_meas_ind );
251 sig_gfp_cs_cr_meas_ind( mphp_cr_meas_ind );
252 break;
253 default:
254 TRACE_ERROR( "MPHP_CR_MEAS_IND unexpected" );
255 break;
256 }
257
258 PFREE( mphp_cr_meas_ind );
259 } /* gfp_mphp_cr_meas_ind() */
260
261
262
263 /*
264 +------------------------------------------------------------------------------
265 | Function : gfp_mphp_cr_meas_stop_con
266 +------------------------------------------------------------------------------
267 | Description : Handles the primitive MPHP_CR_MEAS_STOP_CON
268 |
269 | Parameters : *mphp_cr_meas_stop_con - Ptr to primitive payload
270 |
271 +------------------------------------------------------------------------------
272 */
273 GLOBAL void gfp_mphp_cr_meas_stop_con ( T_MPHP_CR_MEAS_STOP_CON *mphp_cr_meas_stop_con )
274 {
275 TRACE_FUNCTION( "gfp_mphp_cr_meas_stop_con" );
276
277 switch( GET_STATE( GFP ) )
278 {
279 case GFP_IDLE:
280 PACCESS( mphp_cr_meas_stop_con );
281 sig_gfp_cs_cr_meas_stop_con( mphp_cr_meas_stop_con );
282 break;
283 default:
284 TRACE_ERROR( "MPHP_CR_MEAS_STOP_CON unexpected" );
285 break;
286 }
287
288 PFREE( mphp_cr_meas_stop_con );
289 } /* gfp_mphp_cr_meas_stop_con() */
290
291
292
293 /*
294 +------------------------------------------------------------------------------
295 | Function : gfp_mphp_int_meas_ind
296 +------------------------------------------------------------------------------
297 | Description : Handles the primitive MPHP_INT_MEAS_IND
298 |
299 | Parameters : *mphp_int_meas_ind - Ptr to primitive payload
300 |
301 +------------------------------------------------------------------------------
302 */
303 GLOBAL void gfp_mphp_int_meas_ind ( T_MPHP_INT_MEAS_IND *mphp_int_meas_ind )
304 {
305 TRACE_FUNCTION( "gfp_mphp_int_meas_ind" );
306
307 switch( GET_STATE( GFP ) )
308 {
309 case GFP_IDLE:
310 PACCESS(mphp_int_meas_ind);
311 sig_gfp_meas_int_meas_ind(mphp_int_meas_ind);
312 break;
313 default:
314 TRACE_ERROR( "MPHP_INT_MEAS_IND unexpected" );
315 break;
316 }
317
318 PFREE(mphp_int_meas_ind);
319 } /* gfp_mphp_int_meas_ind() */
320
321 /*
322 +------------------------------------------------------------------------------
323 | Function : gfp_mphp_tint_meas_ind
324 +------------------------------------------------------------------------------
325 | Description : Handles the primitive MPHP_TINT_MEAS_IND
326 |
327 | Parameters : *mphp_tint_meas_ind - Ptr to primitive payload
328 |
329 +------------------------------------------------------------------------------
330 */
331 GLOBAL void gfp_mphp_tint_meas_ind ( T_MPHP_TINT_MEAS_IND *mphp_tint_meas_ind )
332 {
333 TRACE_FUNCTION( "gfp_mphp_tint_meas_ind" );
334
335 switch( GET_STATE( GFP ) )
336 {
337 case GFP_IDLE:
338 PACCESS(mphp_tint_meas_ind);
339 sig_gfp_meas_int_meas_ind((T_MPHP_INT_MEAS_IND*)mphp_tint_meas_ind);
340 break;
341 default:
342 TRACE_ERROR( "MPHP_TINT_MEAS_IND unexpected" );
343 break;
344 }
345
346 PFREE(mphp_tint_meas_ind);
347 } /* gfp_mphp_tint_meas_ind() */
348
349
350
351 /*
352 +------------------------------------------------------------------------------
353 | Function : gfp_mphp_int_meas_stop_con
354 +------------------------------------------------------------------------------
355 | Description : Handles the primitive MPHP_INT_MEAS_STOP_CON
356 |
357 | Parameters : *mphp_int_meas_stop_con - Ptr to primitive payload
358 |
359 +------------------------------------------------------------------------------
360 */
361 GLOBAL void gfp_mphp_int_meas_stop_con (
362 T_MPHP_INT_MEAS_STOP_CON *mphp_int_meas_stop_con )
363 {
364 TRACE_FUNCTION( "gfp_mphp_int_meas_stop_con" );
365
366
367 switch( GET_STATE( GFP ) )
368 {
369 case GFP_IDLE:
370 PACCESS(mphp_int_meas_stop_con);
371 sig_gfp_meas_int_meas_stop_con(mphp_int_meas_stop_con);
372 break;
373 default:
374 TRACE_ERROR( "MPHP_INT_MEAS_STOP_CON unexpected" );
375 break;
376 }
377
378 PFREE(mphp_int_meas_stop_con);
379 } /* gfp_mphp_int_meas_stop_con() */
380
381
382
383 /*
384 +------------------------------------------------------------------------------
385 | Function : gfp_mphp_ncell_pbcch_ind
386 +------------------------------------------------------------------------------
387 | Description : Handles the primitive MPHP_NCELL_PBCCH_IND
388 |
389 | Parameters : *mphp_ncell_pbcch_ind - Ptr to primitive payload
390 |
391 +------------------------------------------------------------------------------
392 */
393 GLOBAL void gfp_mphp_ncell_pbcch_ind (
394 T_MPHP_NCELL_PBCCH_IND *mphp_ncell_pbcch_ind )
395 {
396 TRACE_FUNCTION( "gfp_mphp_ncell_pbcch_ind" );
397
398 gfp_adapt_fn(mphp_ncell_pbcch_ind->fn);
399
400 switch( GET_STATE( GFP ) )
401 {
402 case GFP_IDLE:
403 PACCESS(mphp_ncell_pbcch_ind);
404 if(mphp_ncell_pbcch_ind->error_flag)
405 {
406 TRACE_ERROR( "MPHP_NCELL_PBCCH_IND with error_flag(invalid block)" );
407
408 TRACE_BINDUMP
409 ( hCommGRR, TC_USER5,
410 cl_rlcmac_get_msg_name( D_MSG_TYPE_CRC_ERROR_c, RLC_MAC_ROUTE_DL ),
411 mphp_ncell_pbcch_ind->l2_frame, MAX_L2_FRAME_SIZE ); /*lint !e569*/
412 }
413 else
414 {
415 gfp_prcs_ctrl_msg( &mphp_ncell_pbcch_ind->l2_frame[0],
416 mphp_ncell_pbcch_ind->l2_channel,
417 mphp_ncell_pbcch_ind->relative_pos,
418 mphp_ncell_pbcch_ind->fn - 4 );
419 }
420 break;
421 default:
422 TRACE_ERROR( "MPHP_NCELL_PBCCH_IND unexpected" );
423 break;
424 }
425 PFREE(mphp_ncell_pbcch_ind);
426
427 } /* gfp_mphp_ncell_pbcch_ind() */
428
429
430
431 /*
432 +------------------------------------------------------------------------------
433 | Function : gfp_mphp_ra_con
434 +------------------------------------------------------------------------------
435 | Description : Handles the primitive MPHP_RA_CON
436 |
437 | Parameters : *mphp_ra_con - Ptr to primitive payload
438 |
439 +------------------------------------------------------------------------------
440 */
441 GLOBAL void gfp_mphp_ra_con ( T_MPHP_RA_CON *mphp_ra_con )
442 {
443 TRACE_FUNCTION( "gfp_mphp_ra_con" );
444
445 gfp_adapt_fn(mphp_ra_con->fn);
446
447 switch( GET_STATE( GFP ) )
448 {
449 case GFP_IDLE:
450 PACCESS(mphp_ra_con);
451 sig_gfp_tc_ra_con(mphp_ra_con);
452 break;
453 default:
454 TRACE_ERROR( "MPHP_RA_CON unexpected" );
455 break;
456 }
457 PFREE(mphp_ra_con);
458
459 } /* gfp_mphp_ra_con() */
460
461
462
463 /*
464 +------------------------------------------------------------------------------
465 | Function : gfp_mphp_ra_stop_con
466 +------------------------------------------------------------------------------
467 | Description : Handles the primitive MPHP_RA_STOP_CON
468 |
469 | Parameters : *mphp_ra_stop_con - Ptr to primitive payload
470 |
471 +------------------------------------------------------------------------------
472 */
473 GLOBAL void gfp_mphp_ra_stop_con ( T_MPHP_RA_STOP_CON *mphp_ra_stop_con )
474 {
475 TRACE_FUNCTION( "gfp_mphp_ra_stop_con" );
476
477
478 switch( GET_STATE( GFP ) )
479 {
480 case GFP_IDLE:
481 PACCESS(mphp_ra_stop_con);
482 sig_gfp_tc_ra_stop_con(mphp_ra_stop_con);
483 break;
484 default:
485 TRACE_ERROR( "MPHP_RA_STOP_CON unexpected" );
486 break;
487 }
488 PFREE(mphp_ra_stop_con);
489
490 } /* gfp_mphp_ra_stop_con() */
491
492
493
494 /*
495 +------------------------------------------------------------------------------
496 | Function : gfp_mphp_polling_ind
497 +------------------------------------------------------------------------------
498 | Description : Handles the primitive MPHP_POLLING_IND
499 |
500 | Parameters : *mphp_polling_ind - Ptr to primitive payload
501 |
502 +------------------------------------------------------------------------------
503 */
504 GLOBAL void gfp_mphp_polling_ind ( T_MPHP_POLLING_IND *mphp_polling_ind )
505 {
506 TRACE_FUNCTION( "gfp_mphp_polling_ind" );
507
508
509 gfp_adapt_fn(mphp_polling_ind->fn);
510
511 switch( GET_STATE( GFP ) )
512 {
513 case GFP_IDLE:
514 PACCESS(mphp_polling_ind);
515 /*
516 * This Message is not reported to TC, it is not requested
517 */
518 break;
519 default:
520 TRACE_ERROR( "MPHP_POLLING_IND unexpected" );
521 break;
522 }
523 PFREE(mphp_polling_ind);
524
525 } /* gfp_mphp_polling_ind() */
526
527
528
529 /*
530 +------------------------------------------------------------------------------
531 | Function : gfp_mphp_assignment_con
532 +------------------------------------------------------------------------------
533 | Description : Handles the primitive MPHP_ASSIGNMENT_CON
534 |
535 | Parameters : *mphp_assignment_con - Ptr to primitive payload
536 |
537 +------------------------------------------------------------------------------
538 */
539 GLOBAL void gfp_mphp_assignment_con ( T_MPHP_ASSIGNMENT_CON *mphp_assignment_con )
540 {
541 TRACE_FUNCTION( "gfp_mphp_assignment_con" );
542
543 switch( GET_STATE( GFP ) )
544 {
545 case GFP_IDLE:
546 PACCESS(mphp_assignment_con);
547 sig_gfp_tc_assignment_con();
548 break;
549 default:
550 TRACE_ERROR( "MPHP_ASSIGNMENT_CON unexpected" );
551 break;
552 }
553 PFREE(mphp_assignment_con);
554 } /* gfp_mphp_assignment_con() */
555
556 /*
557 +------------------------------------------------------------------------------
558 | Function : gfp_mphp_repeat_ul_fixed_alloc_con
559 +------------------------------------------------------------------------------
560 | Description : Handles the primitive MPHP_REPEAT_UL_FIXED_ALLOC_CON
561 |
562 | Parameters : *mphp_repeat_ul_fixed_alloc_con - Ptr to primitive payload
563 |
564 +------------------------------------------------------------------------------
565 */
566 GLOBAL void gfp_mphp_repeat_ul_fixed_alloc_con (
567 T_MPHP_REPEAT_UL_FIXED_ALLOC_CON *mphp_repeat_ul_fixed_alloc_con )
568 {
569 TRACE_FUNCTION( "gfp_mphp_repeat_ul_fixed_alloc_con" );
570
571
572 switch( GET_STATE( GFP ) )
573 {
574 case GFP_IDLE:
575 PACCESS(mphp_repeat_ul_fixed_alloc_con);
576 /*
577 * no signal to tc requested
578 */
579 break;
580 default:
581 TRACE_ERROR( "MPHP_REPEAT_UL_FIXED_ALLOC_CON unexpected" );
582 break;
583 }
584 PFREE(mphp_repeat_ul_fixed_alloc_con);
585 } /* gfp_mphp_repeat_ul_fixed_alloc_con() */
586
587
588
589 /*
590 +------------------------------------------------------------------------------
591 | Function : gfp_mphp_single_block_con
592 +------------------------------------------------------------------------------
593 | Description : Handles the primitive MPHP_SINGLE_BLOCK_CON
594 |
595 | Parameters : *mphp_single_block_con - Ptr to primitive payload
596 |
597 +------------------------------------------------------------------------------
598 */
599 GLOBAL void gfp_mphp_single_block_con (
600 T_MPHP_SINGLE_BLOCK_CON *mphp_single_block_con )
601 {
602 BOOL result = FALSE;
603 TRACE_FUNCTION( "gfp_mphp_single_block_con" );
604
605
606 TRACE_EVENT_P8("BLK_C purp=%d dl_err=%d last_id=%d rec_id=%d sb_st=%d l2_f[0]=0x%x l2_f[1]=0x%x l2_f[2]=0x%x"
607 ,mphp_single_block_con->purpose
608 ,mphp_single_block_con->dl_error
609 ,grr_data->tc.last_rec_nb_id
610 ,mphp_single_block_con->assign_id
611 ,mphp_single_block_con->sb_status
612 ,mphp_single_block_con->l2_frame[0]
613 ,mphp_single_block_con->l2_frame[1]
614 ,mphp_single_block_con->l2_frame[2]);
615
616
617 switch( GET_STATE( GFP ) )
618 {
619 case GFP_IDLE:
620 PACCESS(mphp_single_block_con);
621 if ( (mphp_single_block_con->purpose EQ SINGLE_BLOCK_TRANSFER_DL) AND
622 (grr_data->tc.last_rec_nb_id EQ mphp_single_block_con->assign_id) )
623 {
624 if( (!mphp_single_block_con->dl_error) AND
625 (mphp_single_block_con->sb_status EQ SB_STAT_DL_OK) )
626 {
627 result = gfp_prcs_ctrl_msg( mphp_single_block_con->l2_frame,
628 L2_PCHANNEL_PACCH,
629 NOT_PRESENT_8BIT,
630 grr_data->tc.last_rec_nb_fn );
631 }
632 else
633 {
634 TRACE_BINDUMP
635 ( hCommGRR, TC_USER5,
636 cl_rlcmac_get_msg_name( D_MSG_TYPE_CRC_ERROR_c, RLC_MAC_ROUTE_DL ),
637 mphp_single_block_con->l2_frame, MAX_L2_FRAME_SIZE ); /*lint !e569*/
638 }
639 }
640
641 if(!result)
642 {
643 /*
644 * no SINGLE_BLOCK_TRANSFER_DL or
645 * sb_status = 1 --> invalid single block or
646 * no assignment in downlink single block
647 */
648 sig_gfp_tc_single_block_cnf(mphp_single_block_con);
649 }
650 break;
651 default:
652 TRACE_ERROR( "MPHP_SINGLE_BLOCK_CON unexpected" );
653 break;
654 }
655 PFREE(mphp_single_block_con);
656 } /* gfp_mphp_single_block_con() */
657
658
659
660 /*
661 +------------------------------------------------------------------------------
662 | Function : gfp_mphp_tbf_release_con
663 +------------------------------------------------------------------------------
664 | Description : Handles the primitive MPHP_TBF_RELEASE_CON
665 |
666 | Parameters : *mphp_tbf_release_con - Ptr to primitive payload
667 |
668 +------------------------------------------------------------------------------
669 */
670 GLOBAL void gfp_mphp_tbf_release_con (
671 T_MPHP_TBF_RELEASE_CON *mphp_tbf_release_con )
672 {
673 TRACE_FUNCTION( "gfp_mphp_tbf_release_con" );
674
675
676 switch( GET_STATE( GFP ) )
677 {
678 case GFP_IDLE:
679 PACCESS(mphp_tbf_release_con);
680 sig_gfp_tc_tbf_release_con(mphp_tbf_release_con);
681 break;
682 default:
683 TRACE_ERROR( "MPHP_TBF_RELEASE_CON unexpected" );
684 break;
685 }
686 PFREE(mphp_tbf_release_con);
687
688 } /* gfp_mphp_tbf_release_con() */
689
690
691
692 /*
693 +------------------------------------------------------------------------------
694 | Function : gfp_mphp_pdch_release_con
695 +------------------------------------------------------------------------------
696 | Description : Handles the primitive MPHP_PDCH_RELEASE_CON
697 |
698 | Parameters : *mphp_pdch_release_con - Ptr to primitive payload
699 |
700 +------------------------------------------------------------------------------
701 */
702 GLOBAL void gfp_mphp_pdch_release_con (
703 T_MPHP_PDCH_RELEASE_CON *mphp_pdch_release_con )
704 {
705 TRACE_FUNCTION( "gfp_mphp_pdch_release_con" );
706
707
708 switch( GET_STATE( GFP ) )
709 {
710 case GFP_IDLE:
711 PACCESS(mphp_pdch_release_con);
712 /*
713 * no signal to tc requested
714 */
715 break;
716 default:
717 TRACE_ERROR( "MPHP_PDCH_RELEASE_CON unexpected" );
718 break;
719 }
720 PFREE(mphp_pdch_release_con);
721
722 } /* gfp_mphp_pdch_release_con() */
723
724
725
726 /*
727 +------------------------------------------------------------------------------
728 | Function : gfp_mphp_timing_advance_con
729 +------------------------------------------------------------------------------
730 | Description : Handles the primitive MPHP_TIMING_ADVANCE_CON
731 |
732 | Parameters : *mphp_timing_advance_con - Ptr to primitive payload
733 |
734 +------------------------------------------------------------------------------
735 */
736 GLOBAL void gfp_mphp_timing_advance_con (
737 T_MPHP_TIMING_ADVANCE_CON *mphp_timing_advance_con )
738 {
739 TRACE_FUNCTION( "gfp_mphp_timing_advance_con" );
740
741
742 switch( GET_STATE( GFP ) )
743 {
744 case GFP_IDLE:
745 PACCESS(mphp_timing_advance_con);
746 /*not passed to other service, not needed*/
747 break;
748 default:
749 TRACE_ERROR( "MPHP_TIMING_ADVANCE_CON unexpected" );
750 break;
751 }
752 PFREE(mphp_timing_advance_con);
753
754 } /* gfp_mphp_timing_advance_con() */
755
756
757
758 /*
759 +------------------------------------------------------------------------------
760 | Function : gfp_mphp_update_psi_param_con
761 +------------------------------------------------------------------------------
762 | Description : Handles the primitive MPHP_UPDATE_PSI_PARAM_CON
763 |
764 | Parameters : *mphp_update_psi_param_con - Ptr to primitive payload
765 |
766 +------------------------------------------------------------------------------
767 */
768 GLOBAL void gfp_mphp_update_psi_param_con (
769 T_MPHP_UPDATE_PSI_PARAM_CON *mphp_update_psi_param_con )
770 {
771 TRACE_FUNCTION( "gfp_mphp_update_psi_param_con" );
772
773
774 switch( GET_STATE( GFP ) )
775 {
776 case GFP_IDLE:
777 PACCESS(mphp_update_psi_param_con);
778 /*not passed to other service, not needed*/
779 break;
780 default:
781 TRACE_ERROR( "MPHP_UPDATE_PSI_PARAM_CON unexpected" );
782 break;
783 }
784 PFREE(mphp_update_psi_param_con);
785
786 } /* gfp_mphp_update_psi_param_con() */
787
788
789
790 /*
791 +------------------------------------------------------------------------------
792 | Function : gfp_mphp_tcr_meas_ind
793 +------------------------------------------------------------------------------
794 | Description : Handles the primitive MPHP_TCR_MEAS_IND
795 |
796 | Parameters : *mphp_tcr_meas_ind - Ptr to primitive payload
797 |
798 +------------------------------------------------------------------------------
799 */
800 GLOBAL void gfp_mphp_tcr_meas_ind ( T_MPHP_TCR_MEAS_IND *mphp_tcr_meas_ind )
801 {
802 TRACE_FUNCTION( "gfp_mphp_tcr_meas_ind" );
803
804 switch( GET_STATE( GFP ) )
805 {
806 case GFP_IDLE:
807 PACCESS(mphp_tcr_meas_ind);
808 sig_gfp_cs_tcr_meas_ind( mphp_tcr_meas_ind );
809 break;
810 default:
811 TRACE_ERROR( "MPHP_TCR_MEAS_IND unexpected" );
812 break;
813 }
814
815 PFREE( mphp_tcr_meas_ind );
816 } /* gfp_mphp_tcr_meas_ind() */
817
818
819
820
821
822 /*
823 +------------------------------------------------------------------------------
824 | Function : gfp_mphp_stop_single_block_con
825 +------------------------------------------------------------------------------
826 | Description : Handles the primitive GFP_MPHP_STOP_SINGLE_BLOCK_CON
827 |
828 | Parameters : *gfp_mphp_stop_single_block_con - Ptr to primitive payload
829 |
830 +------------------------------------------------------------------------------
831 */
832 GLOBAL void gfp_mphp_stop_single_block_con ( T_MPHP_STOP_SINGLE_BLOCK_CON *mphp_stop_single_block_con )
833 {
834 TRACE_FUNCTION( "gfp_mphp_stop_single_block_con" );
835
836 /* SZML-SGLBL/010 */
837
838 switch( GET_STATE( GFP ) )
839 {
840 case GFP_IDLE:
841 sig_gfp_tc_stop_single_block_con( mphp_stop_single_block_con );
842 break;
843 default:
844 break;
845 }
846 PFREE(mphp_stop_single_block_con);
847
848 } /* gfp_mphp_stop_single_block_con() */
849
850
851
852
853
854 /*
855 +------------------------------------------------------------------------------
856 | Function : gfp_mphp_ncell_pbcch_stop_con
857 +------------------------------------------------------------------------------
858 | Description : Handles the primitive MPHP_NCELL_PBCCH_STOP_CON
859 |
860 | Parameters : *mphp_ncell_pbcch_stop_con - Ptr to primitive payload
861 |
862 +------------------------------------------------------------------------------
863 */
864 GLOBAL void gfp_mphp_ncell_pbcch_stop_con ( T_MPHP_NCELL_PBCCH_STOP_CON *mphp_ncell_pbcch_stop_con )
865 {
866 TRACE_FUNCTION( "gfp_mphp_ncell_pbcch_stop_con" );
867
868 /* SZML-SGLBL/011 */
869
870 switch( GET_STATE( GFP ) )
871 {
872 case GFP_IDLE:
873 break;
874 default:
875 break;
876 }
877 PFREE(mphp_ncell_pbcch_stop_con);
878
879 } /* gfp_mphp_ncell_pbcch_stop_con() */
880
881
882 /*
883 +------------------------------------------------------------------------------
884 | Function : gfp_cgrlc_data_ind
885 +------------------------------------------------------------------------------
886 | Description : Handles the primitive gfp_cgrlc_data_ind
887 |
888 | Parameters : cgrlc_data_ind - Ptr to primitive payload
889 |
890 +------------------------------------------------------------------------------
891 */
892 GLOBAL void gfp_cgrlc_data_ind ( T_CGRLC_DATA_IND * cgrlc_data_ind )
893 {
894 T_D_HEADER header;
895 T_MSGBUF * ptr_msg_complete;
896
897 TRACE_FUNCTION( "gfp_cgrlc_data_ind" );
898
899 gfp_adapt_fn ( cgrlc_data_ind->fn+4 );
900
901 switch( GET_STATE( GFP ) )
902 {
903 case GFP_IDLE:
904 grr_decode_rlcmac((UBYTE *)(cgrlc_data_ind->data_array), &header);
905
906 if(gfp_check_tfi(&header,cgrlc_data_ind->tn))
907 {
908 if(header.payload NEQ 3)
909 {
910 ptr_msg_complete = grr_handle_rlcmac_header(PACKET_MODE_PTM,&header,cgrlc_data_ind->fn);
911 if(ptr_msg_complete != NULL)
912 gfp_send_ctrl_block(cgrlc_data_ind->fn,
913 cgrlc_data_ind->tn,
914 header.d_ctrl.rrbp,
915 header.d_ctrl.sp,
916 header.pctrl_ack,
917 ptr_msg_complete);
918 }
919 }
920 break;
921 default:
922 TRACE_ERROR( "cgrlc_data_ind unexpected" );
923 break;
924 }
925
926 PFREE(cgrlc_data_ind);
927
928 } /* gfp_cgrlc_data_ind() */