Initial commit
[o-du/l2.git] / src / cm / lrg.x
1 /*******************************************************************************
2 ################################################################################
3 #   Copyright (c) [2017-2019] [Radisys]                                        #
4 #                                                                              #
5 #   Licensed under the Apache License, Version 2.0 (the "License");            #
6 #   you may not use this file except in compliance with the License.           #
7 #   You may obtain a copy of the License at                                    #
8 #                                                                              #
9 #       http://www.apache.org/licenses/LICENSE-2.0                             #
10 #                                                                              #
11 #   Unless required by applicable law or agreed to in writing, software        #
12 #   distributed under the License is distributed on an "AS IS" BASIS,          #
13 #   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.   #
14 #   See the License for the specific language governing permissions and        #
15 #   limitations under the License.                                             #
16 ################################################################################
17 *******************************************************************************/
18
19 /**********************************************************************
20  
21     Name:   LTE MAC layer
22  
23     Type:   C include file
24  
25     Desc:   Defines required by LTE MAC
26  
27     File:   lrg.x
28  
29 **********************************************************************/
30 /**
31   @file lrg.x
32   @brief Structure declarations and definitions for LRG interface.
33   */
34 #ifndef __LRGX__
35 #define __LRGX__
36
37 /* ccpu00121930 : ADD: c++ support*/
38 #ifdef __cplusplus
39 extern "C" {
40 #endif /* __cplusplus */
41
42 /** 
43  * @brief
44    This structure holds configuration parameters for MAC General Configuration. */
45 typedef struct rgGenCfg
46 {
47    Pst      lmPst;      /*!< Layer manager post structure */
48    MemoryId mem;        /*!< Region and pool ID */
49    U8       tmrRes;     /*!< Timer resolution for Low SAP Bind Timer */
50    U8       numRguSaps; /*!< Number of RGU SAP's */
51    U8       startCellId;              /*!< Start cell id value */
52 #ifdef LTE_ADV
53    Bool     forceCntrlSrbBoOnPCel;   /*!< value 1 means scheduler will schedule
54                                           RLC control BO and SRBs only on PCEll
55                                           else it will schedule on both PCell
56                                           and SCell */
57    Bool     isSCellActDeactAlgoEnable; /*!< TRUE will enable activation/deactivation algo at Schd */
58 #endif
59 }RgGenCfg;
60
61 /** 
62  * @brief
63    This structure holds configuration parameters for MAC Upper SAP Configuration. */
64 typedef struct rgUpSapCfg
65 {
66    Selector selector;   /*!< Selector */
67    MemoryId mem;        /*!< Region and pool ID */
68    Priority prior;      /*!< Priority */
69    ProcId   procId;     /*!< Processor ID */
70    Ent      ent;        /*!< Entity ID */
71    Inst     inst;       /*!< Instance ID */
72    Route    route;      /*!< Route */
73    SpId     spId;       /*!< Service provider ID */
74    SuId     suId;       /*!< Service user ID */
75 }RgUpSapCfg;
76
77 /** 
78  * @brief
79    This structure holds configuration parameters for MAC Lower SAP Configuration. */
80 typedef struct rgLowSapCfg
81 {
82    Selector selector;   /*!< Selector */
83    MemoryId mem;        /*!< Region and pool ID */
84    Priority prior;      /*!< Priority */
85    ProcId   procId;     /*!< Processor ID */
86    Ent      ent;        /*!< Entity ID */
87    Inst     inst;       /*!< Instance ID */
88    Route    route;      /*!< Route */
89    SpId     spId;       /*!< Service provider ID */
90    SuId     suId;       /*!< Service user ID */
91    TmrCfg   bndTmr;     /*!< Bind Timer Value */
92 }RgLowSapCfg;
93
94 #ifdef MAC_SCH_STATS
95 /* Data structures */
96 typedef struct rgAckNack
97 {
98    U8           mcs;
99    U16          numOfNacks;
100    U16          numOfAcks;
101 } RgAckNack;
102
103 typedef struct rgSchNackAckStats
104 {
105    RgAckNack dlCqiStat[15];   /*!< DL Stats */
106    RgAckNack ulCqiStat[15];   /*!< UL stats */
107 } RgSchNackAckStats;
108
109 typedef struct rgSchHqNumRetx
110 {
111    U8           mcs;
112    U16          numOfHQ_1;
113    U16          numOfHQ_2;
114    U16          numOfHQ_3;
115    U16          numOfHQ_4;
116    U32          totalTx;
117 } RgSchHqNumRetx;
118
119 typedef struct rgSchHqRetxStats
120 {
121    RgSchHqNumRetx    dlCqiStat[15];   /*!< DL Stats */
122    RgSchHqNumRetx    ulCqiStat[15];   /*!< UL stats */
123 } RgSchHqRetxStats;
124
125 EXTERN RgSchNackAckStats hqFailStats;
126 EXTERN RgSchHqRetxStats  hqRetxStats;
127 #endif /* MAC_SCH_STATS */
128
129 /** 
130  * @brief
131    This structure holds General statistical information of MAC. */
132 typedef struct rgGenSts
133 {
134    U32 numHarqFail;      /*!< Number of HARQ failures */
135    U32 numUeCfg;         /*!< Number of UEs configured */
136    U16 numCellCfg;       /*!< Number of Cells configured */
137 #ifdef MAC_SCH_STATS
138    RgSchNackAckStats nackAckStats;
139    RgSchHqRetxStats  hqRetxStats;
140 #endif /* MAC_SCH_STATS */
141 }RgGenSts;
142
143 /** 
144  * @brief
145    This structure holds statistical information of a SAP in MAC. */
146 typedef struct rgSapSts
147 {
148    U32 numPduRcvd;       /*!< Number of PDUs received. At TFU, PDU refers to TB,
149                               and at RGU it is SDU. */
150    U32 numPduTxmit;      /*!< Number of PDUs transmitted. This field is 
151                               applicable to TFU. */
152    U32 numPduDrop;       /*!< Number of PDUs dropped. At TFU, PDU refers to TB,
153                               and at RGU it is SDU. */
154 }RgSapSts;
155
156 typedef struct rgSchInstCfg
157 {
158    U8          instId;    /*!< Sheduler instance ID */
159    RgGenCfg    genCfg;    /*!< General Configuration for the scheduler instance */
160    U8          numSaps;   /*!< Number of RGR and TFU SAPs must be same */
161    RgUpSapCfg  rgrSap[LRG_MAX_SAPS_PER_INST];  /*!< RGR interface SAPS */
162    RgUpSapCfg  rgmSap[LRG_MAX_SAPS_PER_INST];  /*!< RGR interface SAPS */
163    RgLowSapCfg tfuSap[LRG_MAX_SAPS_PER_INST];  /*!< TFU interface SAPS */
164 } RgSchInstCfg;
165
166 /** 
167  * @brief
168    This structure holds configuration parameters for MAC. */
169 typedef struct rgCfg
170 {
171    union
172    {
173       RgGenCfg    genCfg;  /*!< General Configuration */
174       /* SAPs for the MAC layer */
175       RgUpSapCfg  rguSap;  /*!< RGU interface SAP */
176       RgUpSapCfg  crgSap;  /*!< CRG interface SAP */
177       RgLowSapCfg tfuSap;  /*!< TFU interface SAP */
178       RgSchInstCfg schInstCfg;/*!< General Configuration for scheduler instances */
179    }s;
180 }RgCfg;
181
182 /** 
183  * @brief
184    This structure holds a SAP's status information. */
185 typedef struct rgSapSta
186 {
187    U8 sapState;         /*!< SAP state */
188 }RgSapSta;
189
190 /** 
191  * @brief
192    This structure holds MAC's statistical information. */
193 typedef struct rgSts
194 {
195    DateTime dt;          /*!< Date and Time. */
196    U8       sapInst;     /*!< SAP instance. */
197    Action   action;      /*!< Action on Trafffic load related statistic values.
198                               ARST: To reset the statistic values. */
199    union
200    {
201       RgGenSts genSts;   /*!< General statistics. */
202       RgSapSts rguSts;   /*!< RGU SAP statistics. */
203       RgSapSts crgSts;   /*!< CRG SAP statistics. */
204       RgSapSts rgrSts;   /*!< RGR SAP statistics. */
205       RgSapSts tfuSts;   /*!< TFU SAP statistics. */
206    }s;
207 }RgSts;
208
209 /** 
210  * @brief
211    This structure holds MAC's solicited status information. */
212 typedef struct rgSsta
213 {
214    DateTime dt;             /*!< Date and time */
215    U8       sapInst;        /*!< SAP instance */
216    union
217    {
218       SystemId sysId;       /*!< System information */
219       RgSapSta rguSapSta;   /*!< RGU SAP state */
220       RgSapSta crgSapSta;   /*!< CRG SAP state */
221       RgSapSta rgrSapSta;   /*!< RGR SAP state */
222       RgSapSta rgmSapSta;   /*!< RGM SAP state */
223       RgSapSta tfuSapSta;   /*!< TFU SAP state */
224    }s;
225 }RgSsta;
226
227 /** 
228  * @brief
229    Alarm diagnostics structure. */
230 typedef struct rgUstaDgn
231 {
232    U8          type;         /*!< Diagnostics Type */
233    union
234    {
235    /*lrg_x_001.main_3 - Changed for documentation*/
236       MemoryId mem;          /*!< Memory pool and region <BR> 
237                              LRG_USTA_DGNVAL_MEM Dynamic memory allocation failure. <BR> 
238                              LRG_USTS_DGNVAL_HARQ Harq Process is busy.
239                               */
240    }u;
241 } RgUstaDgn;
242
243 /** 
244  * @brief
245    This structure holds MAC's Unsolicited Status information. */
246 typedef struct rgUsta
247 {
248    CmAlarm   cmAlarm;      /*!< Alarms */
249    RgUstaDgn dgn;          /*!< Alarm diagnostics */
250 }RgUsta;
251
252 /** 
253  * @brief
254    This structure holds MAC's Trace Indication information. */
255 typedef struct rgTrc
256 {
257    DateTime dt;          /*!< Date and time */
258    /*lrg_x_001.main_3 - changed for documentation*/
259    U8       evnt;        /*!< Event <BR> 
260                            EVTRGUDATREQ Trace for Dedicated channel Data Request. <BR> 
261                            EVTRGUCDATREQ Trace for common channel data request.<BR> 
262                           */
263 }RgTrc;
264
265 /** 
266  * @brief
267    This structure holds MAC's Debug Control information. */
268 typedef struct rgDbgCntrl
269 {
270    U32 dbgMask;          /*!< iThe Layer Manager electively enables or disables various levels of Debug printing <BR>
271                           Following are the values: <BR> 
272                           DBGMASK_PRM Enable/Disable function parameter debug prints <BR>
273                           DBGMASK_ERR Enable/Disable error prints <BR>
274                           DBGMASK_INFO Enable/Disable informational prints.
275                           */
276 }RgDbgCntrl;
277
278 /** 
279  * @brief
280    This structure holds MAC's SAP Control information. */
281 typedef struct rgSapCntrl
282 {
283    SuId suId;            /*!< Service user ID */
284    SpId spId;            /*!< Service provider ID */
285 }RgSapCntrl;
286
287 #ifdef PHY_ERROR_LOGING
288 typedef struct rgSchUlAllocCntrl
289 {
290    U8  mcs;
291    U16 numOfRb;
292    U16 rbStart;
293    Bool testStart;
294    Bool enaLog;
295    U16  logTime;
296 }RgSchUlAllocCntrl; 
297 #endif
298
299 /** 
300  * @brief
301    This structure holds MAC's Control information. */
302 typedef struct rgCntrl
303 {
304    DateTime      dt;          /*!< Date and Time */
305    U8            action;      /*!< Action */
306    U8            subAction;   /*!< Sub-action */
307    U8            instId;      /*!< Scheduler instance ID */
308    union
309    {
310       RgDbgCntrl rgDbgCntrl;  /*!< Debug Control */
311       /*lrg_x_001.main_3 - Changed for documentation.*/
312       S16        trcLen;      /*!< Trace Length <BR> 
313                                i)LRG_FULL_TRACE Give full message <BR> 
314                                ii)LRG_NO_TRACE Disable Trace<BR>
315                                iii)Or any valid S16 value in case where only the specified number
316                                of bytes, as indicated by trcLen, are to be sent.*/
317       RgSapCntrl rgSapCntrl;  /*!< SAP Control */
318       U32        logMask;     /*!<  Logging control Mask */
319 #ifdef PHY_ERROR_LOGING
320       RgSchUlAllocCntrl rgSchUlAllocCntrl; /* For setting MCS,Number of RB and RB start */
321 #endif
322    }s;
323 }RgCntrl; 
324
325 /** 
326  * @brief
327    This structure holds MAC's Configuration and Control Management Information. */
328 typedef struct rgMngmt
329 {
330    Header     hdr;       /*!< Header */
331    CmStatus   cfm;       /*!< Confirmation */
332    union
333    {
334       RgCfg   cfg;       /*!< Configuration */
335       RgSts   sts;       /*!< Statistics */
336       RgSsta  ssta;      /*!< Solicited Status */
337       RgUsta  usta;      /*!< Unsolicited Status */
338       RgTrc   trc;       /*!< Trace */
339       RgCntrl cntrl;     /*!< Control */
340    }t;
341 }RgMngmt;
342
343 /* lrg_x_001.main_3 - ADD - Data structures for LTE_L2_MEAS */
344 #ifdef LTE_L2_MEAS
345 /**
346  *  @brief
347    To measure Average Number of PRB's used per QCI for a time period
348    timePrd
349 */
350 typedef struct lrgAvgPrbQCI   
351 {
352    U8        numQci;                 /*!< Numner of QCI's in requests */
353    U8        qci[LRG_MAX_QCI_PER_REQ];  /*!< QCI for which PRB has to be measured */
354 } LrgAvgPrbQCI;
355
356 /**
357  *  @brief
358    To measure number of Active UE's per QCI for the given time period
359    timePrd 
360 **/
361 typedef struct lrgNmbActvUeQCI
362 {
363    U8       sampPrd;                   /*!< sampling prd for which active UE's measured
364                                           Where sampling period is in milli seconds
365                                           value can be at most 100ms */
366    U8        numQci;                   /*!< Numner of QCI's in requests */
367    U8        qci[LRG_MAX_QCI_PER_REQ]; /*!< QCI for which UE has to be considered */
368 } LrgNmbActvUeQCI;
369
370 /**
371  * * @brief 
372      This structure will be used by Layer Manager to L2 Measurement Request
373      Information 
374 **/
375 typedef struct lrgSchMeasReqInfo
376 {
377    Header           hdr;             /*!< Header */
378    U16              measType;        /*!< For type of measurement Following are the */
379                                      /*!< allowed values */
380                                      /*!< LRG_L2MEAS_AVG_PRB_DL , LRG_L2MEAS_AVG_PRB_UL*/
381                                      /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_DL  */
382                                      /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_UL */
383                                      /*!< LRG_L2MEAS_RA_PREAMBLE  */
384                                      /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_UL */
385                                      /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_DL */
386                                      /*!< LRG_L2MEAS_TB_TRANS_DL_COUNT */
387                                      /*!< LRG_L2MEAS_TB_TRANS_DL_FAULTY_COUNT */
388                                      /*!< LRG_L2MEAS_TB_TRANS_UL_COUNT */
389                                      /*!< LRG_L2MEAS_TB_TRANS_UL_FAULTY_COUNT */
390    U32              timePrd;         /*!< Time period UNITS and value will differ depending
391                                        on the action. Might be milli seconds/seconds. */
392    CmLteCellId      cellId;          /*!< CELL Id for which measurement is Done */
393    LrgAvgPrbQCI     avgPrbQciUl;     /*!< Average PRB usage per QCI in UL */
394    LrgAvgPrbQCI     avgPrbQciDl;     /*!< Average PRB usage per QCI in DL */
395    LrgNmbActvUeQCI  nmbActvUeQciUl;  /*!< Number of active UE's per QCI in UL */
396    LrgNmbActvUeQCI  nmbActvUeQciDl;  /*!< Number of active UE's per QCI in DL */
397 } LrgSchMeasReqInfo;
398
399 typedef struct lrgSchMeasSndReqInfo
400 {
401    Header           hdr;             /*!< Header */
402    U16              measType;        /*!< For type of measurement Following are the */
403                                      /*!< allowed values */
404                                      /*!< LRG_L2MEAS_AVG_PRB_DL , LRG_L2MEAS_AVG_PRB_UL*/
405                                      /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_DL  */
406                                      /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_UL */
407                                      /*!< LRG_L2MEAS_RA_PREAMBLE  */
408                                      /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_UL */
409                                      /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_DL */
410    U32              timePrd;         /*!< Time period UNITS and value will differ depending
411                                        on the action. Might be milli seconds/seconds. */
412    CmLteCellId      cellId;          /*!< CELL Id for which measurement is Done */
413  //  LrgAvgPrbQCI     avgPrbQciUl;     /*!< Average PRB usage per QCI in UL */
414  //  LrgAvgPrbQCI     avgPrbQciDl;     /*!< Average PRB usage per QCI in DL */
415  //  LrgNmbActvUeQCI  nmbActvUeQciUl;  /*!< Number of active UE's per QCI in UL */
416  //  LrgNmbActvUeQCI  nmbActvUeQciDl;  /*!< Number of active UE's per QCI in DL */
417 } LrgSchMeasSndReqInfo;
418
419 typedef struct lrgSchMeasStopReqInfo
420 {
421    Header           hdr;             /*!< Header */
422    U16              measType;        /*!< For type of measurement Following are the */
423                                      /*!< allowed values */
424                                      /*!< LRG_L2MEAS_AVG_PRB_DL , LRG_L2MEAS_AVG_PRB_UL*/
425                                      /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_DL  */
426                                      /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_UL */
427                                      /*!< LRG_L2MEAS_RA_PREAMBLE  */
428                                      /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_UL */
429                                      /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_DL */
430  /*  U16              timePrd;  */       /*!< Time period UNITS and value will differ depending
431                                        on the action. Might be milli seconds/seconds. */
432    CmLteCellId      cellId;          /*!< CELL Id for which measurement is Done */
433  /*  LrgAvgPrbQCI     avgPrbQciUl; */     /*!< Average PRB usage per QCI in UL */
434  //  LrgAvgPrbQCI     avgPrbQciDl;     /*!< Average PRB usage per QCI in DL */
435  //  LrgNmbActvUeQCI  nmbActvUeQciUl;  /*!< Number of active UE's per QCI in UL */
436  //   LrgNmbActvUeQCI  nmbActvUeQciDl;  /*!< Number of active UE's per QCI in DL */
437 } LrgSchMeasStopReqInfo;
438
439 /**
440  *@brief
441  Structure to hold Received Random Access Preambles.
442 **/
443 typedef struct lrgRaPreambles
444 {
445    U16    dedPreambles;        /*!< Dedicated RA Preamble received */
446    U16    randSelPreLowRange;  /*!< Randomly selected preambles in low range */
447    U16    randSelPreHighRange; /*!< Randomly selected preambles in high range */
448 } LrgRaPreamblesCfm;
449
450 /**
451  * @brief
452  * Staructure to send Avg PRB for a given Time Period 
453  * */
454 typedef struct lrgAvgPrbcfm
455 {
456    U8    prbPerc;      /*!< PRB usage in percentage for UL */
457 } LrgAvgPrbCfm;
458
459 /*LRG : Review Tag*/
460 typedef struct prbPercQci
461 {
462         U8 qciValue;
463         U8 prbPercQci;
464 }PrbPercQci;
465
466 typedef struct numActvUeQci
467 {
468         U8 qciValue;
469         U8 numActvUeQci;
470 }NumActvUeQci;
471 /*LRG : Review Tag*/
472 /**
473  * @brief
474  * Structure to send Avg PRB for a given period per QCI
475  * */
476 typedef struct lrgAvgPrbQCICfm
477 {
478    U8    numQci;                             /*!< number of QCI */
479 /*LRG : Review Tag*/
480    PrbPercQci    prbPercQci[LRG_MAX_QCI_PER_REQ];    /*!< PRB usage in percentage per QCI for UL/DL */
481 /*LRG : Review Tag*/
482 } LrgAvgPrbQCICfm;
483
484 /**
485  *@brief
486  Structure to send number of Active UE's per QCI
487  */
488 typedef struct lrgNumActvUeQCICfm
489 {
490    U8     numQci;                            /*!< Numner of QCI's in requests */
491 /*LRG : Review Tag*/
492    NumActvUeQci     numActvUeQci[LRG_MAX_QCI_PER_REQ]; /*!< Number of Active UE's in UL/DL per QCI */
493 /*LRG : Review Tag*/
494 } LrgNumActvUeQCICfm;
495 /**
496   @brief
497   Structure to send L2 Measurement confirm 
498 **/
499 typedef struct lrgSchMeasCfmInfo
500 {
501    Header             hdr;               /*!< Header information */
502    U16                measType;          /*!< Type of measurement */
503    CmStatus           cfm;               /*!< Confirmation possible Values when measType
504                                               is invalid status -> NOK and reason -> INVALID
505                                                 */
506    CmLteCellId        cellId;             /*!< Cell for which measurement is done */
507    LrgAvgPrbCfm       avgPrbUl;           /*!< PRB usage in percentage per QCI for UL */
508    LrgAvgPrbCfm       avgPrbDl;           /*!< PRB usage in percentage per QCI for DL */
509    LrgAvgPrbQCICfm    avgPrbQciUlCfm;     /*!< PRB usage in percentage per QCI for UL */
510    LrgAvgPrbQCICfm    avgPrbQciDlCfm;     /*!< PRB usage in percentage per QCI for DL */
511    LrgRaPreamblesCfm  raPrmbsCfm;         /*!< Different received RA preambles */
512    LrgNumActvUeQCICfm numUeQciUlCfm;      /*!< Number of Active UE's in UL per QCI */
513    LrgNumActvUeQCICfm numUeQciDlCfm;      /*!< Number of Active UE's in DL per QCI */
514    U32                tbTransDlTotalCnt;  /*!< Count of DL TB transmitteed */
515    U32                tbTransDlFaulty;    /*!< Count of DL TB for wich NACK not recieved from UE */ 
516    U32                tbTransUlTotalCnt;  /*!< Count of UL TB received successfully */ 
517    U32                tbTransUlFaulty;    /*!< Count of UL TB not recieved successfully */ 
518 } LrgSchMeasCfmInfo;
519
520 #endif /* LTE_L2_MEAS */
521
522 /* 
523    Function Prototype Typedefs 
524 . */
525 typedef S16 (*LrgCfgReq)     ARGS((
526         Pst        *pst,               /* Post Structure */
527         RgMngmt    *cfg                /* Management Structure */
528      ));
529
530 typedef S16 (*LrgSchCfgReq)     ARGS((
531         Pst        *pst,               /* Post Structure */
532         RgMngmt    *cfg                /* Management Structure */
533      ));
534
535 typedef S16 (*LrgCfgCfm)     ARGS((
536         Pst        *pst,               /* Post Structure */
537         RgMngmt    *cfg                /* Management Structure */
538      ));
539
540 typedef S16 (*LrgSchCfgCfm)     ARGS((
541         Pst        *pst,               /* Post Structure */
542         RgMngmt    *cfg                /* Management Structure */
543      ));
544
545 typedef S16 (*LrgCntrlReq)   ARGS((
546         Pst        *pst,               /* Post Structure */
547         RgMngmt    *cntrl              /* Management Structure */
548      ));
549
550 typedef S16 (*LrgSchCntrlReq)   ARGS((
551         Pst        *pst,               /* Post Structure */
552         RgMngmt    *cntrl              /* Management Structure */
553      ));
554
555 typedef S16 (*LrgCntrlCfm)   ARGS((
556         Pst        *pst,               /* Post Structure */
557         RgMngmt    *cntrl              /* Management Structure */
558      ));
559
560 typedef S16 (*LrgSchCntrlCfm)   ARGS((
561         Pst        *pst,               /* Post Structure */
562         RgMngmt    *cntrl              /* Management Structure */
563      ));
564
565 /* lrg_x_001.main_3 - ADD - Data structures for LTE_L2_MEAS */
566 #ifdef LTE_L2_MEAS
567 typedef S16 (*LrgSchL2MeasReq)   ARGS((
568         Pst        *pst,               /* Post Structure */
569         LrgSchMeasReqInfo *meas       /* L2 Measurement structure */
570      ));
571 typedef S16 (*LrgSchL2MeasStopReq)   ARGS((
572         Pst        *pst,               /* Post Structure */
573         LrgSchMeasStopReqInfo *meas       /* L2 Measurement structure */
574      ));
575 typedef S16 (*LrgSchL2MeasSendReq)   ARGS((
576         Pst        *pst,               /* Post Structure */
577         LrgSchMeasSndReqInfo *meas       /* L2 Measurement structure */
578      ));
579 #endif
580 typedef S16 (*LrgStaReq)     ARGS((
581         Pst        *pst,               /* Post Structure */
582         RgMngmt    *sta                /* Management Structure */
583      ));
584
585 typedef S16 (*LrgStaCfm)     ARGS((
586         Pst        *pst,               /* Post Structure */
587         RgMngmt    *sta                /* Management Structure */
588      ));
589
590 typedef S16 (*LrgStaInd)     ARGS((
591         Pst        *pst,               /* Post Structure */
592         RgMngmt    *sta                /* Management Structure */
593      ));
594
595 typedef S16 (*LrgSchStaInd)     ARGS((
596         Pst        *pst,               /* Post Structure */
597         RgMngmt    *sta                /* Management Structure */
598      ));
599
600 typedef S16 (*LrgStsReq)     ARGS((
601         Pst        *pst,               /* Post Structure */
602         RgMngmt    *sts                /* Management Structure */
603      ));
604
605 typedef S16 (*LrgStsCfm)     ARGS((
606         Pst        *pst,               /* Post Structure */
607         RgMngmt    *sts                /* Management Structure */
608      ));
609
610 typedef S16 (*LrgTrcInd)     ARGS((
611         Pst        *pst,               /* Post Structure */
612         RgMngmt    *trc,               /* Management Structure */
613         Buffer     *mBuf               /* Message Buffer */
614      ));
615
616 /* lrg_x_001.main_3 - ADD - Data structures for LTE_L2_MEAS */
617 #ifdef LTE_L2_MEAS
618 typedef S16 (*LrgSchL2MeasCfm)     ARGS((
619         Pst            *pst,              /* Post Structure */
620         LrgSchMeasCfmInfo  *schL2MeasCfm     /* Measurement Info */
621      ));
622 typedef S16 (*LrgSchL2MeasStopCfm)     ARGS((
623         Pst            *pst,              /* Post Structure */
624         LrgSchMeasCfmInfo  *schL2MeasCfm     /* Measurement Info */
625      ));
626 #endif /* LTE_L2_MEAS */
627 /* 
628    Function Prototypes.
629  */
630 #ifdef RG
631 /* lrg_x_001.main_3 - ADD -  Added the comments for the following function */
632  /** @brief This primitive is sent from Layer manager to MAC. It carries
633   * configuration information towards MAC.
634   * @details This primitive can be used by layer manager to configure the
635   * following entities at MAC.
636   * -# General configuration
637   * -# RGU SAP i.e. SAP towards RLC
638   * -# CRG SAP i.e. SAP towards RRC
639   * -# TFU SAP i.e. SAP towards Physical layer
640   * 
641   * @param pst pointer to Pst
642   * @param cfg pointer to RgMngmt
643   * @return ROK/RFAILED
644   */
645 EXTERN S16 RgMiLrgCfgReq ARGS((Pst *pst, RgMngmt *cfg));
646
647  /** @brief This primitive carries the Confirmation for a Configuration Request
648   * sent from the layer manager to MAC.
649   * @details This primitive is used by MAC to inform Layer manager about the
650   * status of a Configuration Request.
651   * @param pst Pointer to the post structure.
652   * @param cfm pointer to RgMngmt 
653   * @return ROK/RFAILED
654   */
655 EXTERN S16 RgMiLrgCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
656
657  /** @brief This primitive is sent from Layer manager to Scheduler. It carries
658   * configuration information towards MAC.
659   * @details This primitive can be used by layer manager to configure the
660   * following entities at Scheduler.
661   * -# General configuration
662   * -# RGR SAP i.e. SAP towards RRM
663   * -# TFU SAP i.e. SAP towards Physical layer
664   * 
665   * @param pst pointer to Pst
666   * @param cfg pointer to RgMngmt
667   * @return ROK/RFAILED
668   */
669 EXTERN S16 RgMiLrgSchCfgReq ARGS((Pst *pst, RgMngmt *cfg));
670
671  /** @brief This primitive carries the Confirmation for a Configuration Request
672   * sent from the layer manager to Scheduler.
673   * @details This primitive is used by Scheduler to inform Layer manager about the
674   * status of a Configuration Request.
675   * @param pst Pointer to the post structure.
676   * @param cfm pointer to RgMngmt 
677   * @return ROK/RFAILED
678   */
679 EXTERN S16 RgMiLrgSchCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
680
681  /** @brief This primitive carries the Request for statistics from MAC layer
682   * sent from the layer manager.
683   * @details This primitive is used by layer manager to request for statistics
684   * on the following
685   * -# General statistics
686   * -# RGU SAP statistics
687   * -# CRG SAP statistics
688   * -# TFU SAP statistics
689   * @param pst Pointer to the post structure.
690   * @param sts pointer to RgMngmt 
691   * @return ROK/RFAILED
692   */
693 EXTERN S16 RgMiLrgStsReq ARGS((Pst *pst, RgMngmt *sts));
694
695  /** @brief This primitive carries the Statistics for a Statistics Request
696   * sent from the layer manager to MAC.
697   * @details This primitive is used by MAC to inform Layer manager about the
698   * Statistics requested earlier.
699   * @param pst Pointer to the post structure.
700   * @param cfm pointer to RgMngmt 
701   * @return ROK/RFAILED
702   */
703 EXTERN S16 RgMiLrgStsCfm ARGS((Pst *pst, RgMngmt *cfm));
704
705  /** @brief This primitive carries the Status request 
706   * sent from the layer manager to MAC.
707   * @details This primitive is used by the layer manager to request
708   * status from the MAC layer.
709   * @param pst Pointer to the post structure.
710   * @param cfm pointer to RgMngmt 
711   * @return ROK/RFAILED
712   */
713 EXTERN S16 RgMiLrgStaReq ARGS((Pst *pst, RgMngmt *sta));
714
715  /** @brief This primitive carries the Confirmation for a Status Request
716   * sent from the layer manager to MAC.
717   * @details This primitive is used by MAC to send a response for the status
718   * Request sent by the layer manager.
719   * @param pst Pointer to the post structure.
720   * @param cfm pointer to RgMngmt 
721   * @return ROK/RFAILED
722   */
723 EXTERN S16 RgMiLrgStaCfm ARGS((Pst *pst, RgMngmt *cfm));
724
725  /** @brief This primitive carries the Unsolicited status indications from MAC
726   * to the layer manager i.e. Alarms.
727   * @details This primitive is used by MAC to inform Layer manager about some
728   * error conditions or bind confirmations.
729   * @param pst Pointer to the post structure.
730   * @param usta pointer to RgMngmt 
731   * @return ROK/RFAILED
732   */
733 EXTERN S16 RgMiLrgStaInd ARGS((Pst *pst, RgMngmt *usta));
734  /** @brief This primitive carries the Unsolicited status indications from
735   * scheduler to the layer manager i.e. Alarms.
736   * @details This primitive is used by Scheduler to inform Layer manager about some
737   * error conditions or bind confirmations.
738   * @param pst Pointer to the post structure.
739   * @param usta pointer to RgMngmt 
740   * @return ROK/RFAILED
741   */
742 EXTERN S16 RgMiLrgSchStaInd ARGS((Pst *pst, RgMngmt *usta));
743
744  /** @brief This primitive carries the control request sent from the layer
745   * manager to MAC layer.
746   * @details This primitive is sent from the layer manager to control the MAC
747   * layer. The following entities could be controlled using this primitive.
748   * -# Debug printing
749   * -# TRACE functionality
750   * -# Binding of lower SAPs
751   * @param pst Pointer to the post structure.
752   * @param cfm pointer to RgMngmt 
753   * @return ROK/RFAILED
754   */
755 EXTERN S16 RgMiLrgCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
756  /** @brief This primitive carries the Confirmation for a Control Request
757   * sent from the layer manager to MAC.
758   * @details This primitive is used by MAC to inform Layer manager about the
759   * status of a Control Request.
760   * @param pst Pointer to the post structure.
761   * @param cfm pointer to RgMngmt 
762   * @return ROK/RFAILED
763   */
764 EXTERN S16 RgMiLrgCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
765  /** @brief This primitive carries the control request sent from the layer
766   * manager to MAC layer.
767   * @details This primitive is sent from the layer manager to control the MAC
768   * layer. The following entities could be controlled using this primitive.
769   * -# Debug printing
770   * -# TRACE functionality
771   * -# Binding of lower SAPs
772   * @param pst Pointer to the post structure.
773   * @param cfm pointer to RgMngmt 
774   * @return ROK/RFAILED
775   */
776 EXTERN S16 RgMiLrgSchCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
777  /** @brief This primitive carries the Confirmation for a Control Request
778   * sent from the layer manager to MAC.
779   * @details This primitive is used by MAC to inform Layer manager about the
780   * status of a Control Request.
781   * @param pst Pointer to the post structure.
782   * @param cfm pointer to RgMngmt 
783   * @return ROK/RFAILED
784   */
785 EXTERN S16 RgMiLrgSchCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
786  /** @brief This primitive carries the a copy of the received buffer from MAC to
787   * the layer manager. This is called the Tracing functionality of the layer.
788   * @details This primitive is used by MAC to send a copy of the received buffer
789   * to the layer manager, if Tracing is enabled via a control request. 
790   * @param pst Pointer to the post structure.
791   * @param trc pointer to RgMngmt 
792   * @param mBuf pointer to Buffer contains the portion of the received message. 
793   * @return ROK/RFAILED
794   */
795 EXTERN S16 RgMiLrgTrcInd ARGS((Pst *pst, RgMngmt *trc, Buffer *mBuf));
796 #ifdef LTE_L2_MEAS
797  /** @brief This primitive is to enable L2 (layer 2) measurements at the MAC
798   * layer.
799   * 
800   * @details Enables the L2 Measurements.
801   * 
802   * @param pst Pointer to the post structure.
803   * @param schL2MeasInfo pointer to LrgSchMeasReqInfo 
804   * @return ROK/RFAILED
805   */
806 EXTERN S16 RgMiLrgSchL2MeasReq ARGS((Pst *pst, LrgSchMeasReqInfo *schL2MeasInfo));
807  /** @brief This primitive carries the results of the L2 Measurements gathered
808   * by MAC to the layer manager.
809   * 
810   * @details Carries the Measurements gathered by MAC.
811   * 
812   * @param pst Pointer to the post structure.
813   * @param schL2MeasCfm pointer to LrgSchMeasCfmInfo 
814   * @return ROK/RFAILED
815   */
816 EXTERN S16 RgMiLrgSchL2MeasCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
817  /** @brief This primitive is to Stop L2 (layer 2) measurements at the MAC
818   * layer.
819   *
820   * @details Enables the L2 Measurements.
821   *
822   * @param pst Pointer to the post structure.
823   * @param schL2MeasInfo pointer to LrgSchMeasReqInfo
824   * @return ROK/RFAILED
825   */
826
827 EXTERN S16 RgMiLrgSchL2MeasStopReq ARGS((Pst *pst, LrgSchMeasStopReqInfo *schL2MeasInfo));
828  /** @brief This primitive is to used to send  L2 (layer 2) measurements at the MAC
829   * layer.
830   *
831   * @details Enables the L2 Measurements.
832   *
833   * @param pst Pointer to the post structure.
834   * @param schL2MeasInfo pointer to LrgSchMeasReqInfo
835   * @return ROK/RFAILED
836   */
837
838 EXTERN S16 RgMiLrgSchL2MeasSendReq ARGS((Pst *pst,LrgSchMeasSndReqInfo *schL2MeasInfo));
839  /** @brief This primitive carries the confrmratoin  of the L2 Measurements gathered
840   * by MAC to the layer manager.
841   *
842   * @details Carries the Measurements gathered by MAC.
843   *
844   * @param pst Pointer to the post structure.
845   * @param schL2MeasCfm pointer to LrgSchMeasCfmInfo
846   * @return ROK/RFAILED
847   */
848
849 EXTERN S16 RgMiLrgSchL2MeasStopCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
850 #endif /* LTE_L2_MEAS */
851 #endif /* RG. */
852
853 #ifdef SM 
854 EXTERN S16 smRgActvInit ARGS((Ent ent,Inst inst, Region region,Reason reason));
855 EXTERN S16 smRgActvTsk ARGS((Pst *pst, Buffer *mBuf));
856 EXTERN S16 SmMiLrgCfgReq ARGS((Pst *pst, RgMngmt *cfg));
857 EXTERN S16 SmMiLrgCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
858 EXTERN S16 SmMiLrgSchCfgReq ARGS((Pst *pst, RgMngmt *cfg));
859 EXTERN S16 SmMiLrgSchCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
860 EXTERN S16 SmMiLrgStsReq ARGS((Pst *pst, RgMngmt *sts));
861 EXTERN S16 SmMiLrgStsCfm ARGS((Pst *pst, RgMngmt *cfm));
862 EXTERN S16 SmMiLrgStaReq ARGS((Pst *pst, RgMngmt *sta));
863 EXTERN S16 SmMiLrgStaCfm ARGS((Pst *pst, RgMngmt *cfm));
864 EXTERN S16 SmMiLrgStaInd ARGS((Pst *pst, RgMngmt *usta));
865 EXTERN S16 SmMiLrgCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
866 EXTERN S16 SmMiLrgSchStaInd ARGS((Pst *pst, RgMngmt *usta));
867 EXTERN S16 SmMiLrgCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
868 EXTERN S16 SmMiLrgSchCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
869 EXTERN S16 SmMiLrgSchCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
870 EXTERN S16 SmMiLrgTrcInd ARGS((Pst *pst, RgMngmt *trc, Buffer *mBuf));
871 /* lrg_x_001.main_3 - ADD -  Added the following functions for LTE_L2_MEAS */
872 #ifdef LTE_L2_MEAS
873 EXTERN S16 SmMiLrgSchL2MeasStartReq ARGS((Pst *pst, LrgSchMeasReqInfo *schL2MeasReq));
874 EXTERN S16 SmMiLrgSchL2MeasCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
875 EXTERN S16 SmMiLrgSchL2MeasStopReq ARGS((Pst *pst, LrgSchMeasStopReqInfo *schL2MeasReq));
876 EXTERN S16 SmMiLrgSchL2MeasSendReq ARGS((Pst *pst, LrgSchMeasSndReqInfo *schL2MeasReq));
877 EXTERN S16 SmMiLrgSchL2MeasStopCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
878 EXTERN S16 SmMiLrgSchL2MeasReq ARGS((Pst *pst, LrgSchMeasReqInfo *meas));
879 EXTERN S16 SmMiLrgSchL2SendMeasReq ARGS((Pst *pst, LrgSchMeasSndReqInfo *meas));
880 EXTERN S16 SmMiLrgSchL2StopMeasReq ARGS((Pst *pst, LrgSchMeasStopReqInfo *meas));
881 #endif /* LTE_L2_MEAS */
882 #endif /* SM. */
883
884 /*
885    Function Prototypes for Packing and Unpacking the primitives.
886  */
887 #if (defined(LCLRG))
888 /** @brief This API is used to send a 
889 Config Request from LM to MAC.*/
890 EXTERN S16 cmPkLrgCfgReq ARGS((
891    Pst *                pst,
892    RgMngmt *            cfg
893 ));
894 /** @brief This API is used to send a 
895 Configuration Request from LM to MAC. */
896 EXTERN S16 cmUnpkLrgCfgReq ARGS((
897    LrgCfgReq            func,
898    Pst *                pst,
899    Buffer               *mBuf
900 ));
901 /** @brief This API is used to send a 
902 Configuration Request from LM to SCH. */
903 EXTERN S16 cmPkLrgSchCfgReq ARGS((
904    Pst *                pst,
905    RgMngmt *            cfg
906 ));
907 /** @brief This API is used to send a 
908 Configuration Request from LM to SCH. */
909 EXTERN S16 cmUnpkLrgSchCfgReq ARGS((
910    LrgSchCfgReq         func,
911    Pst *                pst,
912    Buffer               *mBuf
913 ));
914 /* lrg_x_001.main_3 - ADD -  Added the following pack/unpack functions for LTE_L2_MEAS */
915 #ifdef LTE_L2_MEAS
916 /** @brief This API is used to send a 
917 L2 Measurement Request from LM to SCH. */
918 EXTERN S16 cmPkLrgSchL2MeasReq ARGS((
919    Pst *                pst,
920    LrgSchMeasReqInfo *  meas
921 ));
922 /** @brief This API is used to send a 
923 L2 Measurement Request from LM to SCH. */
924 EXTERN S16 cmUnpkLrgSchL2MeasReq ARGS((
925    LrgSchL2MeasReq         func,
926    Pst *                 pst,
927    Buffer               *mBuf
928 ));
929 EXTERN S16 cmPkLrgSchL2MeasCfm ARGS((
930     Pst * pst,
931     LrgSchMeasCfmInfo  *measInfo
932 ));
933 EXTERN S16 cmUnpkLrgSchL2MeasCfm ARGS((
934     LrgSchL2MeasCfm func,
935     Pst *pst,
936     Buffer *mBuf
937 ));
938 EXTERN S16 cmPkLrgSchL2MeasReq ARGS((
939    Pst *                pst,
940    LrgSchMeasReqInfo *  meas
941 ));
942 /** @brief This API is used to send a 
943 L2 Measurement Request from LM to SCH. */
944 EXTERN S16 cmUnpkLrgSchL2MeasReq ARGS((
945    LrgSchL2MeasReq         func,
946    Pst *                 pst,
947    Buffer               *mBuf
948 ));
949 /** @brief This API is used to send a
950 L2 Measurement Stop Request from LM to SCH. */
951 EXTERN S16 cmPkLrgSchL2MeasSendReq ARGS((
952    Pst *                pst,
953    LrgSchMeasSndReqInfo *  meas
954 ));
955 /** @brief This API is used to send a 
956 L2 Measurement Request from LM to SCH. */
957 EXTERN S16 cmUnpkLrgSchL2MeasSendReq ARGS((
958    LrgSchL2MeasSendReq         func,
959    Pst *                 pst,
960    Buffer               *mBuf
961 ));
962 /** @brief This API is used to send a
963 L2 Measurement Stop Request from LM to SCH. */
964 EXTERN S16 cmPkLrgSchL2MeasStopReq ARGS((
965    Pst *                pst,
966    LrgSchMeasStopReqInfo *  meas
967 ));
968 /** @brief This API is used to send a 
969 L2 Measurement Request from LM to SCH. */
970 EXTERN S16 cmUnpkLrgSchL2MeasStopReq ARGS((
971    LrgSchL2MeasStopReq         func,
972    Pst *                 pst,
973    Buffer               *mBuf
974 ));
975 /** @brief This API is used to carry
976 L2 Measurement Cfm  from SCH. */
977 EXTERN S16 cmPkLrgSchL2MeasStopCfm ARGS((
978     Pst * pst,
979     LrgSchMeasCfmInfo  *measInfo
980 ));
981 /** @brief This API is used to carrya
982 L2 Measurement Cfm  from SCH. */
983 EXTERN S16 cmUnpkLrgSchL2MeasStopCfm ARGS((
984     LrgSchL2MeasStopCfm func,
985     Pst *pst,
986     Buffer *mBuf
987 ));
988 #endif
989 /** @brief This API is used to send a 
990 Configuration Confirm from MAC to LM. */
991 EXTERN S16 cmPkLrgCfgCfm ARGS((
992    Pst *                pst,
993    RgMngmt *            cfm
994 ));
995 /** @brief This API is used to send a 
996 Configuration Confirm from MAC to LM. */
997 EXTERN S16 cmUnpkLrgCfgCfm ARGS((
998    LrgCfgCfm            func,
999    Pst *                pst,
1000    Buffer               *mBuf
1001 ));
1002 /** @brief This API is used to send a 
1003 Configuration Confirm from SCH to LM. */
1004 EXTERN S16 cmPkLrgSchCfgCfm ARGS((
1005    Pst *                pst,
1006    RgMngmt *            cfg
1007 ));
1008 /** @brief This API is used to send a 
1009 Configuration Confirm from SCH to LM. */
1010 EXTERN S16 cmUnpkLrgSchCfgCfm ARGS((
1011    LrgSchCfgCfm         func,
1012    Pst *                pst,
1013    Buffer               *mBuf
1014 ));
1015 /** @brief This API is used to send a 
1016 Statistics Request from LM to MAC. */
1017 EXTERN S16 cmPkLrgStsReq ARGS((
1018    Pst *                pst,
1019    RgMngmt *            sts
1020 ));
1021 /** @brief This API is used to send a 
1022 Statistics Request from LM to MAC. */
1023 EXTERN S16 cmUnpkLrgStsReq ARGS((
1024    LrgStsReq            func,
1025    Pst *                pst,
1026    Buffer               *mBuf
1027 ));
1028 /** @brief This API is used to send a 
1029 Statistics Confirm from MAC to LM. */
1030 EXTERN S16 cmPkLrgStsCfm ARGS((
1031    Pst *                pst,
1032    RgMngmt *            cfm
1033 ));
1034 /** @brief This API is used to send a 
1035 Statistics Confirm from MAC to LM. */
1036 EXTERN S16 cmUnpkLrgStsCfm ARGS((
1037    LrgStsCfm            func,
1038    Pst *                pst,
1039    Buffer               *mBuf
1040 ));
1041 /** @brief This API is used to send a 
1042 Status Request from LM to MAC. */
1043 EXTERN S16 cmPkLrgStaReq ARGS((
1044    Pst *                pst,
1045    RgMngmt *            sta
1046 ));
1047 /** @brief This API is used to send a 
1048 Status Request from LM to MAC. */
1049 EXTERN S16 cmUnpkLrgStaReq ARGS((
1050    LrgStaReq            func,
1051    Pst *                pst,
1052    Buffer               *mBuf
1053 ));
1054 /** @brief This API is used to send a 
1055 Status Confirm from MAC to LM. */
1056 EXTERN S16 cmPkLrgStaCfm ARGS((
1057    Pst *                pst,
1058    RgMngmt *            cfm
1059 ));
1060 /** @brief This API is used to send a 
1061 Status Confirm from MAC to LM. */
1062 EXTERN S16 cmUnpkLrgStaCfm ARGS((
1063    LrgStaCfm            func,
1064    Pst *                pst,
1065    Buffer               *mBuf
1066 ));
1067 /** @brief This API is used to send a 
1068 Status Indication from MAC to LM. */
1069 EXTERN S16 cmPkLrgStaInd ARGS((
1070    Pst *                pst,
1071    RgMngmt *            usta
1072 ));
1073 /** @brief This API is used to send a 
1074 Status Indication from MAC to LM. */
1075 EXTERN S16 cmUnpkLrgStaInd ARGS((
1076    LrgStaInd            func,
1077    Pst *                pst,
1078    Buffer               *mBuf
1079 ));
1080 /** @brief This API is used to send a 
1081 Status Indication from SCH to LM. */
1082 EXTERN S16 cmPkLrgSchStaInd ARGS((
1083    Pst *                pst,
1084    RgMngmt *            sta
1085 ));
1086 /** @brief This API is used to send a 
1087 Status Indication from SCH to LM. */
1088 EXTERN S16 cmUnpkLrgSchStaInd ARGS((
1089    LrgSchStaInd         func,
1090    Pst *                pst,
1091    Buffer               *mBuf
1092 ));
1093 /** @brief This API is used to send a 
1094 Control Request from LM to MAC. */
1095 EXTERN S16 cmPkLrgCntrlReq ARGS((
1096    Pst *                pst,
1097    RgMngmt *            cntrl
1098 ));
1099 /** @brief This API is used to send a 
1100 Control Request from LM to MAC. */
1101 EXTERN S16 cmUnpkLrgCntrlReq ARGS((
1102    LrgCntrlReq          func,
1103    Pst *                pst,
1104    Buffer               *mBuf
1105 ));
1106 /** @brief This API is used to send a 
1107 Control Request from LM to SCH. */
1108 EXTERN S16 cmPkLrgSchCntrlReq ARGS((
1109    Pst *                pst,
1110    RgMngmt *            cntrl
1111 ));
1112 /** @brief This API is used to send a 
1113 Control Request from LM to SCH. */
1114 EXTERN S16 cmUnpkLrgSchCntrlReq ARGS((
1115    LrgSchCntrlReq       func,
1116    Pst *                pst,
1117    Buffer               *mBuf
1118 ));
1119 /** @brief This API is used to send a 
1120 Control Confirm from MAC to LM.*/
1121 EXTERN S16 cmPkLrgCntrlCfm ARGS((
1122    Pst *                pst,
1123    RgMngmt *            cfm
1124 ));
1125 /** @brief This API is used to send a 
1126 Control Confirm from MAC to LM. */
1127 EXTERN S16 cmUnpkLrgCntrlCfm ARGS((
1128    LrgCntrlCfm          func,
1129    Pst *                pst,
1130    Buffer               *mBuf
1131 ));
1132 /** @brief This API is used to send a 
1133 Control Confirm from SCH to LM. */
1134 EXTERN S16 cmPkLrgSchCntrlCfm ARGS((
1135    Pst *                pst,
1136    RgMngmt *            cntrl
1137 ));
1138 /** @brief This API is used to send a 
1139 Control Confirm from SCH to LM. */
1140 EXTERN S16 cmUnpkLrgSchCntrlCfm ARGS((
1141    LrgSchCntrlCfm       func,
1142    Pst *                pst,
1143    Buffer               *mBuf
1144 ));
1145 /** @brief This API is used to send a 
1146 Trace Indication from MAC to LM. */
1147 EXTERN S16 cmPkLrgTrcInd ARGS((
1148    Pst *                pst,
1149    RgMngmt *            trc,
1150    Buffer *             trcBuf
1151 ));
1152 /** @brief This API is used to send a 
1153 Trace Indication from MAC to LM. */
1154 EXTERN S16 cmUnpkLrgTrcInd ARGS((
1155    LrgTrcInd            func,
1156    Pst *                pst,
1157    Buffer               *mBuf
1158 ));
1159 EXTERN S16 cmPkRgGenCfg ARGS((
1160    RgGenCfg             *param,
1161    Buffer               *mBuf
1162 ));
1163 EXTERN S16 cmUnpkRgGenCfg ARGS((
1164    RgGenCfg             *param,
1165    Buffer               *mBuf
1166 ));
1167 EXTERN S16 cmPkRgUpSapCfg ARGS((
1168    RgUpSapCfg           *param,
1169    Buffer               *mBuf
1170 ));
1171 EXTERN S16 cmUnpkRgUpSapCfg ARGS((
1172    RgUpSapCfg           *param,
1173    Buffer               *mBuf
1174 ));
1175 EXTERN S16 cmPkRgLowSapCfg ARGS((
1176    RgLowSapCfg          *param,
1177    Buffer               *mBuf
1178 ));
1179 EXTERN S16 cmUnpkRgLowSapCfg ARGS((
1180    RgLowSapCfg          *param,
1181    Buffer               *mBuf
1182 ));
1183 EXTERN S16 cmPkRgGenSts ARGS((
1184    RgGenSts             *param,
1185    Buffer               *mBuf
1186 ));
1187
1188 #ifdef MAC_SCH_STATS
1189 EXTERN S16 cmPkRgSchHqRetxStats ARGS((
1190    RgSchHqRetxStats     *param,
1191    Buffer               *mBuf
1192 ));
1193 EXTERN S16 cmPkRgSchNackAckStats ARGS((
1194    RgSchNackAckStats    *param,
1195    Buffer               *mBuf
1196 ));
1197 EXTERN S16 cmPkRgHqNumRetx ARGS((
1198    RgSchHqNumRetx       *param,
1199    Buffer               *mBuf
1200 ));
1201 EXTERN S16 cmPkRgAckNack ARGS((
1202    RgAckNack            *param,
1203    Buffer               *mBuf
1204 ));
1205
1206 EXTERN S16 cmUnpkRgSchHqRetxStats ARGS((
1207    RgSchHqRetxStats     *param,
1208    Buffer               *mBuf
1209 ));
1210 EXTERN S16 cmUnpkRgSchNackAckStats ARGS((
1211    RgSchNackAckStats    *param,
1212    Buffer               *mBuf
1213 ));
1214 EXTERN S16 cmUnpkRgHqNumRetx ARGS((
1215    RgSchHqNumRetx       *param,
1216    Buffer               *mBuf
1217 ));
1218 EXTERN S16 cmUnpkRgAckNack ARGS((
1219    RgAckNack            *param,
1220    Buffer               *mBuf
1221 ));
1222 #endif /* MAC_SCH_STATS */
1223
1224 EXTERN S16 cmUnpkRgGenSts ARGS((
1225    RgGenSts             *param,
1226    Buffer               *mBuf
1227 ));
1228 EXTERN S16 cmPkRgSapSts ARGS((
1229    RgSapSts             *param,
1230    Buffer               *mBuf
1231 ));
1232 EXTERN S16 cmUnpkRgSapSts ARGS((
1233    RgSapSts             *param,
1234    Buffer               *mBuf
1235 ));
1236 EXTERN S16 cmPkRgSchInstCfg ARGS((
1237    RgSchInstCfg         *param,
1238    Buffer               *mBuf
1239 ));
1240 EXTERN S16 cmUnpkRgSchInstCfg ARGS((
1241    RgSchInstCfg         *param,
1242    Buffer               *mBuf
1243 ));
1244 EXTERN S16 cmPkRgCfg ARGS((
1245    RgCfg                *param,
1246    S16                  elmnt,
1247    Buffer               *mBuf
1248 ));
1249 EXTERN S16 cmUnpkRgCfg ARGS((
1250    RgCfg                *param,
1251    S16                  elmnt,
1252    Buffer               *mBuf
1253 ));
1254 EXTERN S16 cmPkRgSapSta ARGS((
1255    RgSapSta             *param,
1256    Buffer               *mBuf
1257 ));
1258 EXTERN S16 cmUnpkRgSapSta ARGS((
1259    RgSapSta             *param,
1260    Buffer               *mBuf
1261 ));
1262 EXTERN S16 cmPkRgSts ARGS((
1263    RgSts                *param,
1264    S16                  elmnt,
1265    Buffer               *mBuf
1266 ));
1267 EXTERN S16 cmUnpkRgSts ARGS((
1268    RgSts                *param,
1269    S16                  elmnt,
1270    Buffer               *mBuf
1271 ));
1272 /* lrg_x_001.main_3 - MODIFY -  Modified the below function to hold the event type */
1273 #ifdef LRG_V1
1274 EXTERN S16 cmPkRgSsta ARGS((
1275    Pst                  *pst,
1276    RgSsta               *param,
1277    S16                  elmnt,
1278    /*ccpu00118255 - ADD - eventType param */
1279    U8                   eventType,
1280    Buffer               *mBuf
1281 ));
1282 #else /*LRG_V1 not defined */
1283 EXTERN S16 cmPkRgSsta ARGS((
1284    Pst                  *pst,
1285    RgSsta               *param,
1286    S16                  elmnt,
1287    Buffer               *mBuf
1288 ));
1289 #endif /* LRG_V1 endif */
1290 EXTERN S16 cmUnpkRgSsta ARGS((
1291    Pst                  *pst,
1292    RgSsta               *param,
1293    S16                  elmnt,
1294    Buffer               *mBuf
1295 ));
1296 EXTERN S16 cmPkRgUstaDgn ARGS((
1297    RgUstaDgn            *param,
1298    Buffer               *mBuf
1299 ));
1300 EXTERN S16 cmUnpkRgUstaDgn ARGS((
1301    RgUstaDgn            *param,
1302    Buffer               *mBuf
1303 ));
1304 EXTERN S16 cmPkRgUsta ARGS((
1305    RgUsta               *param,
1306    Buffer               *mBuf
1307 ));
1308 EXTERN S16 cmUnpkRgUsta ARGS((
1309    RgUsta               *param,
1310    Buffer               *mBuf
1311 ));
1312 EXTERN S16 cmPkRgTrc ARGS((
1313    RgTrc                *param,
1314    Buffer               *mBuf
1315 ));
1316 EXTERN S16 cmUnpkRgTrc ARGS((
1317    RgTrc                *param,
1318    Buffer               *mBuf
1319 ));
1320 EXTERN S16 cmPkRgDbgCntrl ARGS((
1321    RgDbgCntrl           *param,
1322    Buffer               *mBuf
1323 ));
1324 EXTERN S16 cmUnpkRgDbgCntrl ARGS((
1325    RgDbgCntrl           *param,
1326    Buffer               *mBuf
1327 ));
1328 EXTERN S16 cmPkRgSapCntrl ARGS((
1329    RgSapCntrl           *param,
1330    Buffer               *mBuf
1331 ));
1332 EXTERN S16 cmUnpkRgSapCntrl ARGS((
1333    RgSapCntrl           *param,
1334    Buffer               *mBuf
1335 ));
1336 EXTERN S16 cmPkRgCntrl ARGS((
1337    RgCntrl              *param,
1338    S16                  elmnt,
1339    Buffer               *mBuf
1340 ));
1341 EXTERN S16 cmUnpkRgCntrl ARGS((
1342    RgCntrl              *param,
1343    S16                  elmnt,
1344    Buffer               *mBuf
1345 ));
1346 EXTERN S16 cmPkRgMngmt ARGS((
1347    Pst *pst,
1348    RgMngmt *param,
1349    U8 eventType,
1350    Buffer *mBuf
1351 ));
1352 EXTERN S16 cmUnpkRgMngmt ARGS((
1353    Pst *pst,
1354    RgMngmt *param,
1355    U8 eventType,
1356    Buffer *mBuf
1357 ));
1358
1359 #ifdef PHY_ERROR_LOGING
1360 EXTERN S16 cmPkRgSchUlAllocCntrl ARGS((
1361    RgSchUlAllocCntrl *param,
1362    Buffer *mBuf
1363 ));
1364
1365 EXTERN S16 cmUnpkRgSchUlAllocCntrl ARGS((
1366    RgSchUlAllocCntrl *param,
1367    Buffer *mBuf
1368 ));
1369 #endif
1370 /* lrg_x_001.main_4 ccpu00117036 - C++ support */
1371 #ifdef __cplusplus
1372 }
1373 #endif
1374 #endif
1375
1376 #endif /* __LRGX__. */
1377
1378 \f
1379 /**********************************************************************
1380    End of file
1381 **********************************************************************/