1 /*******************************************************************************
2 ################################################################################
3 # Copyright (c) [2017-2019] [Radisys] #
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 #
9 # http://www.apache.org/licenses/LICENSE-2.0 #
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 *******************************************************************************/
19 /**********************************************************************
25 Desc: Defines required by LTE MAC
29 **********************************************************************/
32 @brief Structure declarations and definitions for LRG interface.
39 /* ccpu00121930 : ADD: c++ support*/
42 #endif /* __cplusplus */
46 This structure holds configuration parameters for MAC General Configuration. */
47 typedef struct rgGenCfg
49 Pst lmPst; /*!< Layer manager post structure */
50 MemoryId mem; /*!< Region and pool ID */
51 U8 tmrRes; /*!< Timer resolution for Low SAP Bind Timer */
52 U8 numRguSaps; /*!< Number of RGU SAP's */
53 U8 startCellId; /*!< Start cell id value */
55 Bool forceCntrlSrbBoOnPCel; /*!< value 1 means scheduler will schedule
56 RLC control BO and SRBs only on PCEll
57 else it will schedule on both PCell
59 Bool isSCellActDeactAlgoEnable; /*!< TRUE will enable activation/deactivation algo at Schd */
65 This structure holds configuration parameters for MAC Upper SAP Configuration. */
66 typedef struct rgUpSapCfg
68 Selector selector; /*!< Selector */
69 MemoryId mem; /*!< Region and pool ID */
70 Priority prior; /*!< Priority */
71 ProcId procId; /*!< Processor ID */
72 Ent ent; /*!< Entity ID */
73 Inst inst; /*!< Instance ID */
74 Route route; /*!< Route */
75 SpId spId; /*!< Service provider ID */
76 SuId suId; /*!< Service user ID */
81 This structure holds configuration parameters for MAC Lower SAP Configuration. */
82 typedef struct rgLowSapCfg
84 Selector selector; /*!< Selector */
85 MemoryId mem; /*!< Region and pool ID */
86 Priority prior; /*!< Priority */
87 ProcId procId; /*!< Processor ID */
88 Ent ent; /*!< Entity ID */
89 Inst inst; /*!< Instance ID */
90 Route route; /*!< Route */
91 SpId spId; /*!< Service provider ID */
92 SuId suId; /*!< Service user ID */
93 TmrCfg bndTmr; /*!< Bind Timer Value */
98 typedef struct rgAckNack
105 typedef struct rgSchNackAckStats
107 RgAckNack dlCqiStat[15]; /*!< DL Stats */
108 RgAckNack ulCqiStat[15]; /*!< UL stats */
111 typedef struct rgSchHqNumRetx
121 typedef struct rgSchHqRetxStats
123 RgSchHqNumRetx dlCqiStat[15]; /*!< DL Stats */
124 RgSchHqNumRetx ulCqiStat[15]; /*!< UL stats */
127 EXTERN RgSchNackAckStats hqFailStats;
128 EXTERN RgSchHqRetxStats hqRetxStats;
129 #endif /* MAC_SCH_STATS */
133 This structure holds General statistical information of MAC. */
134 typedef struct rgGenSts
136 U32 numHarqFail; /*!< Number of HARQ failures */
137 U32 numUeCfg; /*!< Number of UEs configured */
138 U16 numCellCfg; /*!< Number of Cells configured */
140 RgSchNackAckStats nackAckStats;
141 RgSchHqRetxStats hqRetxStats;
142 #endif /* MAC_SCH_STATS */
147 This structure holds statistical information of a SAP in MAC. */
148 typedef struct rgSapSts
150 U32 numPduRcvd; /*!< Number of PDUs received. At TFU, PDU refers to TB,
151 and at RGU it is SDU. */
152 U32 numPduTxmit; /*!< Number of PDUs transmitted. This field is
153 applicable to TFU. */
154 U32 numPduDrop; /*!< Number of PDUs dropped. At TFU, PDU refers to TB,
155 and at RGU it is SDU. */
158 typedef struct rgSchInstCfg
160 U8 instId; /*!< Sheduler instance ID */
161 RgGenCfg genCfg; /*!< General Configuration for the scheduler instance */
162 U8 numSaps; /*!< Number of RGR and TFU SAPs must be same */
163 RgUpSapCfg rgrSap[LRG_MAX_SAPS_PER_INST]; /*!< RGR interface SAPS */
164 RgUpSapCfg rgmSap[LRG_MAX_SAPS_PER_INST]; /*!< RGR interface SAPS */
165 RgLowSapCfg tfuSap[LRG_MAX_SAPS_PER_INST]; /*!< TFU interface SAPS */
170 This structure holds configuration parameters for MAC. */
175 RgGenCfg genCfg; /*!< General Configuration */
176 /* SAPs for the MAC layer */
177 RgUpSapCfg rguSap; /*!< RGU interface SAP */
178 RgUpSapCfg crgSap; /*!< CRG interface SAP */
179 RgLowSapCfg tfuSap; /*!< TFU interface SAP */
180 RgSchInstCfg schInstCfg;/*!< General Configuration for scheduler instances */
187 This structure holds a SAP's status information. */
188 typedef struct rgSapSta
190 U8 sapState; /*!< SAP state */
195 This structure holds MAC's statistical information. */
198 DateTime dt; /*!< Date and Time. */
199 U8 sapInst; /*!< SAP instance. */
200 Action action; /*!< Action on Trafffic load related statistic values.
201 ARST: To reset the statistic values. */
204 RgGenSts genSts; /*!< General statistics. */
205 RgSapSts rguSts; /*!< RGU SAP statistics. */
206 RgSapSts crgSts; /*!< CRG SAP statistics. */
207 RgSapSts rgrSts; /*!< RGR SAP statistics. */
208 RgSapSts tfuSts; /*!< TFU SAP statistics. */
214 This structure holds MAC's solicited status information. */
215 typedef struct rgSsta
217 DateTime dt; /*!< Date and time */
218 U8 sapInst; /*!< SAP instance */
221 SystemId sysId; /*!< System information */
222 RgSapSta rguSapSta; /*!< RGU SAP state */
223 RgSapSta crgSapSta; /*!< CRG SAP state */
224 RgSapSta rgrSapSta; /*!< RGR SAP state */
225 RgSapSta rgmSapSta; /*!< RGM SAP state */
226 RgSapSta tfuSapSta; /*!< TFU SAP state */
232 Alarm diagnostics structure. */
233 typedef struct rgUstaDgn
235 U8 type; /*!< Diagnostics Type */
238 /*lrg_x_001.main_3 - Changed for documentation*/
239 MemoryId mem; /*!< Memory pool and region <BR>
240 LRG_USTA_DGNVAL_MEM Dynamic memory allocation failure. <BR>
241 LRG_USTS_DGNVAL_HARQ Harq Process is busy.
248 This structure holds MAC's Unsolicited Status information. */
249 typedef struct rgUsta
251 CmAlarm cmAlarm; /*!< Alarms */
252 RgUstaDgn dgn; /*!< Alarm diagnostics */
257 This structure holds MAC's Trace Indication information. */
260 DateTime dt; /*!< Date and time */
261 /*lrg_x_001.main_3 - changed for documentation*/
262 U8 evnt; /*!< Event <BR>
263 EVTRGUDATREQ Trace for Dedicated channel Data Request. <BR>
264 EVTRGUCDATREQ Trace for common channel data request.<BR>
270 This structure holds MAC's Debug Control information. */
271 typedef struct rgDbgCntrl
273 U32 dbgMask; /*!< iThe Layer Manager electively enables or disables various levels of Debug printing <BR>
274 Following are the values: <BR>
275 DBGMASK_PRM Enable/Disable function parameter debug prints <BR>
276 DBGMASK_ERR Enable/Disable error prints <BR>
277 DBGMASK_INFO Enable/Disable informational prints.
283 This structure holds MAC's SAP Control information. */
284 typedef struct rgSapCntrl
286 SuId suId; /*!< Service user ID */
287 SpId spId; /*!< Service provider ID */
290 #ifdef PHY_ERROR_LOGING
291 typedef struct rgSchUlAllocCntrl
304 This structure holds MAC's Control information. */
305 typedef struct rgCntrl
307 DateTime dt; /*!< Date and Time */
308 U8 action; /*!< Action */
309 U8 subAction; /*!< Sub-action */
310 U8 instId; /*!< Scheduler instance ID */
313 RgDbgCntrl rgDbgCntrl; /*!< Debug Control */
314 /*lrg_x_001.main_3 - Changed for documentation.*/
315 S16 trcLen; /*!< Trace Length <BR>
316 i)LRG_FULL_TRACE Give full message <BR>
317 ii)LRG_NO_TRACE Disable Trace<BR>
318 iii)Or any valid S16 value in case where only the specified number
319 of bytes, as indicated by trcLen, are to be sent.*/
320 RgSapCntrl rgSapCntrl; /*!< SAP Control */
321 U32 logMask; /*!< Logging control Mask */
322 #ifdef PHY_ERROR_LOGING
323 RgSchUlAllocCntrl rgSchUlAllocCntrl; /* For setting MCS,Number of RB and RB start */
330 This structure holds MAC's Configuration and Control Management Information. */
331 typedef struct rgMngmt
333 Header hdr; /*!< Header */
334 CmStatus cfm; /*!< Confirmation */
337 RgCfg cfg; /*!< Configuration */
338 RgSts sts; /*!< Statistics */
339 RgSsta ssta; /*!< Solicited Status */
340 RgUsta usta; /*!< Unsolicited Status */
341 RgTrc trc; /*!< Trace */
342 RgCntrl cntrl; /*!< Control */
346 /* lrg_x_001.main_3 - ADD - Data structures for LTE_L2_MEAS */
350 To measure Average Number of PRB's used per QCI for a time period
353 typedef struct lrgAvgPrbQCI
355 U8 numQci; /*!< Numner of QCI's in requests */
356 U8 qci[LRG_MAX_QCI_PER_REQ]; /*!< QCI for which PRB has to be measured */
361 To measure number of Active UE's per QCI for the given time period
364 typedef struct lrgNmbActvUeQCI
366 U8 sampPrd; /*!< sampling prd for which active UE's measured
367 Where sampling period is in milli seconds
368 value can be at most 100ms */
369 U8 numQci; /*!< Numner of QCI's in requests */
370 U8 qci[LRG_MAX_QCI_PER_REQ]; /*!< QCI for which UE has to be considered */
375 This structure will be used by Layer Manager to L2 Measurement Request
378 typedef struct lrgSchMeasReqInfo
380 Header hdr; /*!< Header */
381 U16 measType; /*!< For type of measurement Following are the */
382 /*!< allowed values */
383 /*!< LRG_L2MEAS_AVG_PRB_DL , LRG_L2MEAS_AVG_PRB_UL*/
384 /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_DL */
385 /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_UL */
386 /*!< LRG_L2MEAS_RA_PREAMBLE */
387 /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_UL */
388 /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_DL */
389 /*!< LRG_L2MEAS_TB_TRANS_DL_COUNT */
390 /*!< LRG_L2MEAS_TB_TRANS_DL_FAULTY_COUNT */
391 /*!< LRG_L2MEAS_TB_TRANS_UL_COUNT */
392 /*!< LRG_L2MEAS_TB_TRANS_UL_FAULTY_COUNT */
393 U32 timePrd; /*!< Time period UNITS and value will differ depending
394 on the action. Might be milli seconds/seconds. */
395 CmLteCellId cellId; /*!< CELL Id for which measurement is Done */
396 LrgAvgPrbQCI avgPrbQciUl; /*!< Average PRB usage per QCI in UL */
397 LrgAvgPrbQCI avgPrbQciDl; /*!< Average PRB usage per QCI in DL */
398 LrgNmbActvUeQCI nmbActvUeQciUl; /*!< Number of active UE's per QCI in UL */
399 LrgNmbActvUeQCI nmbActvUeQciDl; /*!< Number of active UE's per QCI in DL */
402 typedef struct lrgSchMeasSndReqInfo
404 Header hdr; /*!< Header */
405 U16 measType; /*!< For type of measurement Following are the */
406 /*!< allowed values */
407 /*!< LRG_L2MEAS_AVG_PRB_DL , LRG_L2MEAS_AVG_PRB_UL*/
408 /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_DL */
409 /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_UL */
410 /*!< LRG_L2MEAS_RA_PREAMBLE */
411 /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_UL */
412 /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_DL */
413 U32 timePrd; /*!< Time period UNITS and value will differ depending
414 on the action. Might be milli seconds/seconds. */
415 CmLteCellId cellId; /*!< CELL Id for which measurement is Done */
416 // LrgAvgPrbQCI avgPrbQciUl; /*!< Average PRB usage per QCI in UL */
417 // LrgAvgPrbQCI avgPrbQciDl; /*!< Average PRB usage per QCI in DL */
418 // LrgNmbActvUeQCI nmbActvUeQciUl; /*!< Number of active UE's per QCI in UL */
419 // LrgNmbActvUeQCI nmbActvUeQciDl; /*!< Number of active UE's per QCI in DL */
420 } LrgSchMeasSndReqInfo;
422 typedef struct lrgSchMeasStopReqInfo
424 Header hdr; /*!< Header */
425 U16 measType; /*!< For type of measurement Following are the */
426 /*!< allowed values */
427 /*!< LRG_L2MEAS_AVG_PRB_DL , LRG_L2MEAS_AVG_PRB_UL*/
428 /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_DL */
429 /*!< LRG_L2MEAS_AVG_PRB_PER_QCI_UL */
430 /*!< LRG_L2MEAS_RA_PREAMBLE */
431 /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_UL */
432 /*!< LRG_L2MEAS_NMB_ACTV_UE_PER_QCI_DL */
433 /* U16 timePrd; */ /*!< Time period UNITS and value will differ depending
434 on the action. Might be milli seconds/seconds. */
435 CmLteCellId cellId; /*!< CELL Id for which measurement is Done */
436 /* LrgAvgPrbQCI avgPrbQciUl; */ /*!< Average PRB usage per QCI in UL */
437 // LrgAvgPrbQCI avgPrbQciDl; /*!< Average PRB usage per QCI in DL */
438 // LrgNmbActvUeQCI nmbActvUeQciUl; /*!< Number of active UE's per QCI in UL */
439 // LrgNmbActvUeQCI nmbActvUeQciDl; /*!< Number of active UE's per QCI in DL */
440 } LrgSchMeasStopReqInfo;
444 Structure to hold Received Random Access Preambles.
446 typedef struct lrgRaPreambles
448 U16 dedPreambles; /*!< Dedicated RA Preamble received */
449 U16 randSelPreLowRange; /*!< Randomly selected preambles in low range */
450 U16 randSelPreHighRange; /*!< Randomly selected preambles in high range */
455 * Staructure to send Avg PRB for a given Time Period
457 typedef struct lrgAvgPrbcfm
459 U8 prbPerc; /*!< PRB usage in percentage for UL */
463 typedef struct prbPercQci
469 typedef struct numActvUeQci
477 * Structure to send Avg PRB for a given period per QCI
479 typedef struct lrgAvgPrbQCICfm
481 U8 numQci; /*!< number of QCI */
483 PrbPercQci prbPercQci[LRG_MAX_QCI_PER_REQ]; /*!< PRB usage in percentage per QCI for UL/DL */
489 Structure to send number of Active UE's per QCI
491 typedef struct lrgNumActvUeQCICfm
493 U8 numQci; /*!< Numner of QCI's in requests */
495 NumActvUeQci numActvUeQci[LRG_MAX_QCI_PER_REQ]; /*!< Number of Active UE's in UL/DL per QCI */
497 } LrgNumActvUeQCICfm;
500 Structure to send L2 Measurement confirm
502 typedef struct lrgSchMeasCfmInfo
504 Header hdr; /*!< Header information */
505 U16 measType; /*!< Type of measurement */
506 CmStatus cfm; /*!< Confirmation possible Values when measType
507 is invalid status -> NOK and reason -> INVALID
509 CmLteCellId cellId; /*!< Cell for which measurement is done */
510 LrgAvgPrbCfm avgPrbUl; /*!< PRB usage in percentage per QCI for UL */
511 LrgAvgPrbCfm avgPrbDl; /*!< PRB usage in percentage per QCI for DL */
512 LrgAvgPrbQCICfm avgPrbQciUlCfm; /*!< PRB usage in percentage per QCI for UL */
513 LrgAvgPrbQCICfm avgPrbQciDlCfm; /*!< PRB usage in percentage per QCI for DL */
514 LrgRaPreamblesCfm raPrmbsCfm; /*!< Different received RA preambles */
515 LrgNumActvUeQCICfm numUeQciUlCfm; /*!< Number of Active UE's in UL per QCI */
516 LrgNumActvUeQCICfm numUeQciDlCfm; /*!< Number of Active UE's in DL per QCI */
517 U32 tbTransDlTotalCnt; /*!< Count of DL TB transmitteed */
518 U32 tbTransDlFaulty; /*!< Count of DL TB for wich NACK not recieved from UE */
519 U32 tbTransUlTotalCnt; /*!< Count of UL TB received successfully */
520 U32 tbTransUlFaulty; /*!< Count of UL TB not recieved successfully */
523 #endif /* LTE_L2_MEAS */
526 Function Prototype Typedefs
528 typedef S16 (*LrgCfgReq) ARGS((
529 Pst *pst, /* Post Structure */
530 RgMngmt *cfg /* Management Structure */
533 typedef S16 (*LrgSchCfgReq) ARGS((
534 Pst *pst, /* Post Structure */
535 RgMngmt *cfg /* Management Structure */
538 typedef S16 (*LrgCfgCfm) ARGS((
539 Pst *pst, /* Post Structure */
540 RgMngmt *cfg /* Management Structure */
543 typedef S16 (*LrgSchCfgCfm) ARGS((
544 Pst *pst, /* Post Structure */
545 RgMngmt *cfg /* Management Structure */
548 typedef S16 (*LrgCntrlReq) ARGS((
549 Pst *pst, /* Post Structure */
550 RgMngmt *cntrl /* Management Structure */
553 typedef S16 (*LrgSchCntrlReq) ARGS((
554 Pst *pst, /* Post Structure */
555 RgMngmt *cntrl /* Management Structure */
558 typedef S16 (*LrgCntrlCfm) ARGS((
559 Pst *pst, /* Post Structure */
560 RgMngmt *cntrl /* Management Structure */
563 typedef S16 (*LrgSchCntrlCfm) ARGS((
564 Pst *pst, /* Post Structure */
565 RgMngmt *cntrl /* Management Structure */
568 /* lrg_x_001.main_3 - ADD - Data structures for LTE_L2_MEAS */
570 typedef S16 (*LrgSchL2MeasReq) ARGS((
571 Pst *pst, /* Post Structure */
572 LrgSchMeasReqInfo *meas /* L2 Measurement structure */
574 typedef S16 (*LrgSchL2MeasStopReq) ARGS((
575 Pst *pst, /* Post Structure */
576 LrgSchMeasStopReqInfo *meas /* L2 Measurement structure */
578 typedef S16 (*LrgSchL2MeasSendReq) ARGS((
579 Pst *pst, /* Post Structure */
580 LrgSchMeasSndReqInfo *meas /* L2 Measurement structure */
583 typedef S16 (*LrgStaReq) ARGS((
584 Pst *pst, /* Post Structure */
585 RgMngmt *sta /* Management Structure */
588 typedef S16 (*LrgStaCfm) ARGS((
589 Pst *pst, /* Post Structure */
590 RgMngmt *sta /* Management Structure */
593 typedef S16 (*LrgStaInd) ARGS((
594 Pst *pst, /* Post Structure */
595 RgMngmt *sta /* Management Structure */
598 typedef S16 (*LrgSchStaInd) ARGS((
599 Pst *pst, /* Post Structure */
600 RgMngmt *sta /* Management Structure */
603 typedef S16 (*LrgStsReq) ARGS((
604 Pst *pst, /* Post Structure */
605 RgMngmt *sts /* Management Structure */
608 typedef S16 (*LrgStsCfm) ARGS((
609 Pst *pst, /* Post Structure */
610 RgMngmt *sts /* Management Structure */
613 typedef S16 (*LrgTrcInd) ARGS((
614 Pst *pst, /* Post Structure */
615 RgMngmt *trc, /* Management Structure */
616 Buffer *mBuf /* Message Buffer */
619 /* lrg_x_001.main_3 - ADD - Data structures for LTE_L2_MEAS */
621 typedef S16 (*LrgSchL2MeasCfm) ARGS((
622 Pst *pst, /* Post Structure */
623 LrgSchMeasCfmInfo *schL2MeasCfm /* Measurement Info */
625 typedef S16 (*LrgSchL2MeasStopCfm) ARGS((
626 Pst *pst, /* Post Structure */
627 LrgSchMeasCfmInfo *schL2MeasCfm /* Measurement Info */
629 #endif /* LTE_L2_MEAS */
634 /* lrg_x_001.main_3 - ADD - Added the comments for the following function */
635 /** @brief This primitive is sent from Layer manager to MAC. It carries
636 * configuration information towards MAC.
637 * @details This primitive can be used by layer manager to configure the
638 * following entities at MAC.
639 * -# General configuration
640 * -# RGU SAP i.e. SAP towards RLC
641 * -# CRG SAP i.e. SAP towards RRC
642 * -# TFU SAP i.e. SAP towards Physical layer
644 * @param pst pointer to Pst
645 * @param cfg pointer to RgMngmt
646 * @return ROK/RFAILED
648 EXTERN S16 RgMiLrgCfgReq ARGS((Pst *pst, RgMngmt *cfg));
650 /** @brief This primitive carries the Configuration Request
651 * for Scheduler sent from the DU APP to MAC.
652 * @details This primitive is used by MAC to sned the configuration
654 * @param pst Pointer to the post structure.
655 * @param cfm pointer to RgMngmt
656 * @return ROK/RFAILED
658 EXTERN S16 MacSchGenCfgReq ARGS((Pst *pst, RgMngmt *cfg));
660 /** @brief This primitive carries the Confirmation for a Configuration Request
661 * sent from the layer manager to MAC.
662 * @details This primitive is used by MAC to inform Layer manager about the
663 * status of a Configuration Request.
664 * @param pst Pointer to the post structure.
665 * @param cfm pointer to RgMngmt
666 * @return ROK/RFAILED
668 EXTERN S16 RgMiLrgCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
670 /** @brief This primitive is sent from Layer manager to Scheduler. It carries
671 * configuration information towards MAC.
672 * @details This primitive can be used by layer manager to configure the
673 * following entities at Scheduler.
674 * -# General configuration
675 * -# RGR SAP i.e. SAP towards RRM
676 * -# TFU SAP i.e. SAP towards Physical layer
678 * @param pst pointer to Pst
679 * @param cfg pointer to RgMngmt
680 * @return ROK/RFAILED
682 EXTERN S16 HandleSchGenCfgReq ARGS((Pst *pst, RgMngmt *cfg));
684 /** @brief This primitive carries the Confirmation for a Configuration Request
685 * sent from the layer manager to Scheduler.
686 * @details This primitive is used by Scheduler to inform Layer manager about the
687 * status of a Configuration Request.
688 * @param pst Pointer to the post structure.
689 * @param cfm pointer to RgMngmt
690 * @return ROK/RFAILED
692 EXTERN S16 RgMiLrgSchCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
694 /** @brief This primitive carries the Request for statistics from MAC layer
695 * sent from the layer manager.
696 * @details This primitive is used by layer manager to request for statistics
698 * -# General statistics
699 * -# RGU SAP statistics
700 * -# CRG SAP statistics
701 * -# TFU SAP statistics
702 * @param pst Pointer to the post structure.
703 * @param sts pointer to RgMngmt
704 * @return ROK/RFAILED
706 EXTERN S16 RgMiLrgStsReq ARGS((Pst *pst, RgMngmt *sts));
708 /** @brief This primitive carries the Statistics for a Statistics Request
709 * sent from the layer manager to MAC.
710 * @details This primitive is used by MAC to inform Layer manager about the
711 * Statistics requested earlier.
712 * @param pst Pointer to the post structure.
713 * @param cfm pointer to RgMngmt
714 * @return ROK/RFAILED
716 EXTERN S16 RgMiLrgStsCfm ARGS((Pst *pst, RgMngmt *cfm));
718 /** @brief This primitive carries the Status request
719 * sent from the layer manager to MAC.
720 * @details This primitive is used by the layer manager to request
721 * status from the MAC layer.
722 * @param pst Pointer to the post structure.
723 * @param cfm pointer to RgMngmt
724 * @return ROK/RFAILED
726 EXTERN S16 RgMiLrgStaReq ARGS((Pst *pst, RgMngmt *sta));
728 /** @brief This primitive carries the Confirmation for a Status Request
729 * sent from the layer manager to MAC.
730 * @details This primitive is used by MAC to send a response for the status
731 * Request sent by the layer manager.
732 * @param pst Pointer to the post structure.
733 * @param cfm pointer to RgMngmt
734 * @return ROK/RFAILED
736 EXTERN S16 RgMiLrgStaCfm ARGS((Pst *pst, RgMngmt *cfm));
738 /** @brief This primitive carries the Unsolicited status indications from MAC
739 * to the layer manager i.e. Alarms.
740 * @details This primitive is used by MAC to inform Layer manager about some
741 * error conditions or bind confirmations.
742 * @param pst Pointer to the post structure.
743 * @param usta pointer to RgMngmt
744 * @return ROK/RFAILED
746 EXTERN S16 RgMiLrgStaInd ARGS((Pst *pst, RgMngmt *usta));
747 /** @brief This primitive carries the Unsolicited status indications from
748 * scheduler to the layer manager i.e. Alarms.
749 * @details This primitive is used by Scheduler to inform Layer manager about some
750 * error conditions or bind confirmations.
751 * @param pst Pointer to the post structure.
752 * @param usta pointer to RgMngmt
753 * @return ROK/RFAILED
755 EXTERN S16 RgMiLrgSchStaInd ARGS((Pst *pst, RgMngmt *usta));
757 /** @brief This primitive carries the control request sent from the layer
758 * manager to MAC layer.
759 * @details This primitive is sent from the layer manager to control the MAC
760 * layer. The following entities could be controlled using this primitive.
762 * -# TRACE functionality
763 * -# Binding of lower SAPs
764 * @param pst Pointer to the post structure.
765 * @param cfm pointer to RgMngmt
766 * @return ROK/RFAILED
768 EXTERN S16 RgMiLrgCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
769 /** @brief This primitive carries the Confirmation for a Control Request
770 * sent from the layer manager to MAC.
771 * @details This primitive is used by MAC to inform Layer manager about the
772 * status of a Control Request.
773 * @param pst Pointer to the post structure.
774 * @param cfm pointer to RgMngmt
775 * @return ROK/RFAILED
777 EXTERN S16 RgMiLrgCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
778 /** @brief This primitive carries the control request sent from the layer
779 * manager to MAC layer.
780 * @details This primitive is sent from the layer manager to control the MAC
781 * layer. The following entities could be controlled using this primitive.
783 * -# TRACE functionality
784 * -# Binding of lower SAPs
785 * @param pst Pointer to the post structure.
786 * @param cfm pointer to RgMngmt
787 * @return ROK/RFAILED
789 EXTERN S16 RgMiLrgSchCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
790 /** @brief This primitive carries the Confirmation for a Control Request
791 * sent from the layer manager to MAC.
792 * @details This primitive is used by MAC to inform Layer manager about the
793 * status of a Control Request.
794 * @param pst Pointer to the post structure.
795 * @param cfm pointer to RgMngmt
796 * @return ROK/RFAILED
798 EXTERN S16 RgMiLrgSchCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
799 /** @brief This primitive carries the a copy of the received buffer from MAC to
800 * the layer manager. This is called the Tracing functionality of the layer.
801 * @details This primitive is used by MAC to send a copy of the received buffer
802 * to the layer manager, if Tracing is enabled via a control request.
803 * @param pst Pointer to the post structure.
804 * @param trc pointer to RgMngmt
805 * @param mBuf pointer to Buffer contains the portion of the received message.
806 * @return ROK/RFAILED
808 EXTERN S16 RgMiLrgTrcInd ARGS((Pst *pst, RgMngmt *trc, Buffer *mBuf));
810 /** @brief This primitive is to enable L2 (layer 2) measurements at the MAC
813 * @details Enables the L2 Measurements.
815 * @param pst Pointer to the post structure.
816 * @param schL2MeasInfo pointer to LrgSchMeasReqInfo
817 * @return ROK/RFAILED
819 EXTERN S16 RgMiLrgSchL2MeasReq ARGS((Pst *pst, LrgSchMeasReqInfo *schL2MeasInfo));
820 /** @brief This primitive carries the results of the L2 Measurements gathered
821 * by MAC to the layer manager.
823 * @details Carries the Measurements gathered by MAC.
825 * @param pst Pointer to the post structure.
826 * @param schL2MeasCfm pointer to LrgSchMeasCfmInfo
827 * @return ROK/RFAILED
829 EXTERN S16 RgMiLrgSchL2MeasCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
830 /** @brief This primitive is to Stop L2 (layer 2) measurements at the MAC
833 * @details Enables the L2 Measurements.
835 * @param pst Pointer to the post structure.
836 * @param schL2MeasInfo pointer to LrgSchMeasReqInfo
837 * @return ROK/RFAILED
840 EXTERN S16 RgMiLrgSchL2MeasStopReq ARGS((Pst *pst, LrgSchMeasStopReqInfo *schL2MeasInfo));
841 /** @brief This primitive is to used to send L2 (layer 2) measurements at the MAC
844 * @details Enables the L2 Measurements.
846 * @param pst Pointer to the post structure.
847 * @param schL2MeasInfo pointer to LrgSchMeasReqInfo
848 * @return ROK/RFAILED
851 EXTERN S16 RgMiLrgSchL2MeasSendReq ARGS((Pst *pst,LrgSchMeasSndReqInfo *schL2MeasInfo));
852 /** @brief This primitive carries the confrmratoin of the L2 Measurements gathered
853 * by MAC to the layer manager.
855 * @details Carries the Measurements gathered by MAC.
857 * @param pst Pointer to the post structure.
858 * @param schL2MeasCfm pointer to LrgSchMeasCfmInfo
859 * @return ROK/RFAILED
862 EXTERN S16 RgMiLrgSchL2MeasStopCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
863 #endif /* LTE_L2_MEAS */
867 EXTERN S16 smRgActvInit ARGS((Ent ent,Inst inst, Region region,Reason reason));
868 EXTERN S16 smRgActvTsk ARGS((Pst *pst, Buffer *mBuf));
869 EXTERN S16 SmMiLrgCfgReq ARGS((Pst *pst, RgMngmt *cfg));
870 EXTERN S16 SmMiLrgCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
871 EXTERN S16 SmMiLrgSchCfgReq ARGS((Pst *pst, RgMngmt *cfg));
872 EXTERN S16 SmMiLrgSchCfgCfm ARGS((Pst *pst, RgMngmt *cfm));
873 EXTERN S16 SmMiLrgStsReq ARGS((Pst *pst, RgMngmt *sts));
874 EXTERN S16 SmMiLrgStsCfm ARGS((Pst *pst, RgMngmt *cfm));
875 EXTERN S16 SmMiLrgStaReq ARGS((Pst *pst, RgMngmt *sta));
876 EXTERN S16 SmMiLrgStaCfm ARGS((Pst *pst, RgMngmt *cfm));
877 EXTERN S16 SmMiLrgStaInd ARGS((Pst *pst, RgMngmt *usta));
878 EXTERN S16 SmMiLrgCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
879 EXTERN S16 SmMiLrgSchStaInd ARGS((Pst *pst, RgMngmt *usta));
880 EXTERN S16 SmMiLrgCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
881 EXTERN S16 SmMiLrgSchCntrlReq ARGS((Pst *pst, RgMngmt *cntrl));
882 EXTERN S16 SmMiLrgSchCntrlCfm ARGS(( Pst *pst, RgMngmt *cfm));
883 EXTERN S16 SmMiLrgTrcInd ARGS((Pst *pst, RgMngmt *trc, Buffer *mBuf));
884 /* lrg_x_001.main_3 - ADD - Added the following functions for LTE_L2_MEAS */
886 EXTERN S16 SmMiLrgSchL2MeasStartReq ARGS((Pst *pst, LrgSchMeasReqInfo *schL2MeasReq));
887 EXTERN S16 SmMiLrgSchL2MeasCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
888 EXTERN S16 SmMiLrgSchL2MeasStopReq ARGS((Pst *pst, LrgSchMeasStopReqInfo *schL2MeasReq));
889 EXTERN S16 SmMiLrgSchL2MeasSendReq ARGS((Pst *pst, LrgSchMeasSndReqInfo *schL2MeasReq));
890 EXTERN S16 SmMiLrgSchL2MeasStopCfm ARGS((Pst *pst, LrgSchMeasCfmInfo *schL2MeasCfm));
891 EXTERN S16 SmMiLrgSchL2MeasReq ARGS((Pst *pst, LrgSchMeasReqInfo *meas));
892 EXTERN S16 SmMiLrgSchL2SendMeasReq ARGS((Pst *pst, LrgSchMeasSndReqInfo *meas));
893 EXTERN S16 SmMiLrgSchL2StopMeasReq ARGS((Pst *pst, LrgSchMeasStopReqInfo *meas));
894 #endif /* LTE_L2_MEAS */
898 Function Prototypes for Packing and Unpacking the primitives.
901 /** @brief This API is used to send a
902 Config Request from LM to MAC.*/
903 EXTERN S16 cmPkLrgCfgReq ARGS((
907 /** @brief This API is used to send a
908 Configuration Request from LM to MAC. */
909 EXTERN S16 cmUnpkLrgCfgReq ARGS((
914 /** @brief This API is used to send a
915 Configuration Request from LM to SCH. */
916 EXTERN S16 cmPkLrgSchCfgReq ARGS((
920 /** @brief This API is used to send a
921 Configuration Request from LM to SCH. */
922 EXTERN S16 cmUnpkLrgSchCfgReq ARGS((
927 /* lrg_x_001.main_3 - ADD - Added the following pack/unpack functions for LTE_L2_MEAS */
929 /** @brief This API is used to send a
930 L2 Measurement Request from LM to SCH. */
931 EXTERN S16 cmPkLrgSchL2MeasReq ARGS((
933 LrgSchMeasReqInfo * meas
935 /** @brief This API is used to send a
936 L2 Measurement Request from LM to SCH. */
937 EXTERN S16 cmUnpkLrgSchL2MeasReq ARGS((
938 LrgSchL2MeasReq func,
942 EXTERN S16 cmPkLrgSchL2MeasCfm ARGS((
944 LrgSchMeasCfmInfo *measInfo
946 EXTERN S16 cmUnpkLrgSchL2MeasCfm ARGS((
947 LrgSchL2MeasCfm func,
951 EXTERN S16 cmPkLrgSchL2MeasReq ARGS((
953 LrgSchMeasReqInfo * meas
955 /** @brief This API is used to send a
956 L2 Measurement Request from LM to SCH. */
957 EXTERN S16 cmUnpkLrgSchL2MeasReq ARGS((
958 LrgSchL2MeasReq func,
962 /** @brief This API is used to send a
963 L2 Measurement Stop Request from LM to SCH. */
964 EXTERN S16 cmPkLrgSchL2MeasSendReq ARGS((
966 LrgSchMeasSndReqInfo * meas
968 /** @brief This API is used to send a
969 L2 Measurement Request from LM to SCH. */
970 EXTERN S16 cmUnpkLrgSchL2MeasSendReq ARGS((
971 LrgSchL2MeasSendReq func,
975 /** @brief This API is used to send a
976 L2 Measurement Stop Request from LM to SCH. */
977 EXTERN S16 cmPkLrgSchL2MeasStopReq ARGS((
979 LrgSchMeasStopReqInfo * meas
981 /** @brief This API is used to send a
982 L2 Measurement Request from LM to SCH. */
983 EXTERN S16 cmUnpkLrgSchL2MeasStopReq ARGS((
984 LrgSchL2MeasStopReq func,
988 /** @brief This API is used to carry
989 L2 Measurement Cfm from SCH. */
990 EXTERN S16 cmPkLrgSchL2MeasStopCfm ARGS((
992 LrgSchMeasCfmInfo *measInfo
994 /** @brief This API is used to carrya
995 L2 Measurement Cfm from SCH. */
996 EXTERN S16 cmUnpkLrgSchL2MeasStopCfm ARGS((
997 LrgSchL2MeasStopCfm func,
1002 /** @brief This API is used to send a
1003 Configuration Confirm from MAC to LM. */
1004 EXTERN S16 cmPkLrgCfgCfm ARGS((
1008 /** @brief This API is used to send a
1009 Configuration Confirm from MAC to LM. */
1010 EXTERN S16 cmUnpkLrgCfgCfm ARGS((
1015 /** @brief This API is used to send a
1016 Configuration Confirm from SCH to LM. */
1017 EXTERN S16 cmPkLrgSchCfgCfm ARGS((
1021 /** @brief This API is used to send a
1022 Configuration Confirm from SCH to LM. */
1023 EXTERN S16 cmUnpkLrgSchCfgCfm ARGS((
1028 /** @brief This API is used to send a
1029 Statistics Request from LM to MAC. */
1030 EXTERN S16 cmPkLrgStsReq ARGS((
1034 /** @brief This API is used to send a
1035 Statistics Request from LM to MAC. */
1036 EXTERN S16 cmUnpkLrgStsReq ARGS((
1041 /** @brief This API is used to send a
1042 Statistics Confirm from MAC to LM. */
1043 EXTERN S16 cmPkLrgStsCfm ARGS((
1047 /** @brief This API is used to send a
1048 Statistics Confirm from MAC to LM. */
1049 EXTERN S16 cmUnpkLrgStsCfm ARGS((
1054 /** @brief This API is used to send a
1055 Status Request from LM to MAC. */
1056 EXTERN S16 cmPkLrgStaReq ARGS((
1060 /** @brief This API is used to send a
1061 Status Request from LM to MAC. */
1062 EXTERN S16 cmUnpkLrgStaReq ARGS((
1067 /** @brief This API is used to send a
1068 Status Confirm from MAC to LM. */
1069 EXTERN S16 cmPkLrgStaCfm ARGS((
1073 /** @brief This API is used to send a
1074 Status Confirm from MAC to LM. */
1075 EXTERN S16 cmUnpkLrgStaCfm ARGS((
1080 /** @brief This API is used to send a
1081 Status Indication from MAC to LM. */
1082 EXTERN S16 cmPkLrgStaInd ARGS((
1086 /** @brief This API is used to send a
1087 Status Indication from MAC to LM. */
1088 EXTERN S16 cmUnpkLrgStaInd ARGS((
1093 /** @brief This API is used to send a
1094 Status Indication from SCH to LM. */
1095 EXTERN S16 cmPkLrgSchStaInd ARGS((
1099 /** @brief This API is used to send a
1100 Status Indication from SCH to LM. */
1101 EXTERN S16 cmUnpkLrgSchStaInd ARGS((
1106 /** @brief This API is used to send a
1107 Control Request from LM to MAC. */
1108 EXTERN S16 cmPkLrgCntrlReq ARGS((
1112 /** @brief This API is used to send a
1113 Control Request from LM to MAC. */
1114 EXTERN S16 cmUnpkLrgCntrlReq ARGS((
1119 /** @brief This API is used to send a
1120 Control Request from LM to SCH. */
1121 EXTERN S16 cmPkLrgSchCntrlReq ARGS((
1125 /** @brief This API is used to send a
1126 Control Request from LM to SCH. */
1127 EXTERN S16 cmUnpkLrgSchCntrlReq ARGS((
1128 LrgSchCntrlReq func,
1132 /** @brief This API is used to send a
1133 Control Confirm from MAC to LM.*/
1134 EXTERN S16 cmPkLrgCntrlCfm ARGS((
1138 /** @brief This API is used to send a
1139 Control Confirm from MAC to LM. */
1140 EXTERN S16 cmUnpkLrgCntrlCfm ARGS((
1145 /** @brief This API is used to send a
1146 Control Confirm from SCH to LM. */
1147 EXTERN S16 cmPkLrgSchCntrlCfm ARGS((
1151 /** @brief This API is used to send a
1152 Control Confirm from SCH to LM. */
1153 EXTERN S16 cmUnpkLrgSchCntrlCfm ARGS((
1154 LrgSchCntrlCfm func,
1158 /** @brief This API is used to send a
1159 Trace Indication from MAC to LM. */
1160 EXTERN S16 cmPkLrgTrcInd ARGS((
1165 /** @brief This API is used to send a
1166 Trace Indication from MAC to LM. */
1167 EXTERN S16 cmUnpkLrgTrcInd ARGS((
1172 EXTERN S16 cmPkRgGenCfg ARGS((
1176 EXTERN S16 cmUnpkRgGenCfg ARGS((
1180 EXTERN S16 cmPkRgUpSapCfg ARGS((
1184 EXTERN S16 cmUnpkRgUpSapCfg ARGS((
1188 EXTERN S16 cmPkRgLowSapCfg ARGS((
1192 EXTERN S16 cmUnpkRgLowSapCfg ARGS((
1196 EXTERN S16 cmPkRgGenSts ARGS((
1201 #ifdef MAC_SCH_STATS
1202 EXTERN S16 cmPkRgSchHqRetxStats ARGS((
1203 RgSchHqRetxStats *param,
1206 EXTERN S16 cmPkRgSchNackAckStats ARGS((
1207 RgSchNackAckStats *param,
1210 EXTERN S16 cmPkRgHqNumRetx ARGS((
1211 RgSchHqNumRetx *param,
1214 EXTERN S16 cmPkRgAckNack ARGS((
1219 EXTERN S16 cmUnpkRgSchHqRetxStats ARGS((
1220 RgSchHqRetxStats *param,
1223 EXTERN S16 cmUnpkRgSchNackAckStats ARGS((
1224 RgSchNackAckStats *param,
1227 EXTERN S16 cmUnpkRgHqNumRetx ARGS((
1228 RgSchHqNumRetx *param,
1231 EXTERN S16 cmUnpkRgAckNack ARGS((
1235 #endif /* MAC_SCH_STATS */
1237 EXTERN S16 cmUnpkRgGenSts ARGS((
1241 EXTERN S16 cmPkRgSapSts ARGS((
1245 EXTERN S16 cmUnpkRgSapSts ARGS((
1249 EXTERN S16 cmPkRgSchInstCfg ARGS((
1250 RgSchInstCfg *param,
1253 EXTERN S16 cmUnpkRgSchInstCfg ARGS((
1254 RgSchInstCfg *param,
1257 EXTERN S16 cmPkRgCfg ARGS((
1262 EXTERN S16 cmUnpkRgCfg ARGS((
1267 EXTERN S16 cmPkRgSapSta ARGS((
1271 EXTERN S16 cmUnpkRgSapSta ARGS((
1275 EXTERN S16 cmPkRgSts ARGS((
1280 EXTERN S16 cmUnpkRgSts ARGS((
1285 /* lrg_x_001.main_3 - MODIFY - Modified the below function to hold the event type */
1287 EXTERN S16 cmPkRgSsta ARGS((
1291 /*ccpu00118255 - ADD - eventType param */
1295 #else /*LRG_V1 not defined */
1296 EXTERN S16 cmPkRgSsta ARGS((
1302 #endif /* LRG_V1 endif */
1303 EXTERN S16 cmUnpkRgSsta ARGS((
1309 EXTERN S16 cmPkRgUstaDgn ARGS((
1313 EXTERN S16 cmUnpkRgUstaDgn ARGS((
1317 EXTERN S16 cmPkRgUsta ARGS((
1321 EXTERN S16 cmUnpkRgUsta ARGS((
1325 EXTERN S16 cmPkRgTrc ARGS((
1329 EXTERN S16 cmUnpkRgTrc ARGS((
1333 EXTERN S16 cmPkRgDbgCntrl ARGS((
1337 EXTERN S16 cmUnpkRgDbgCntrl ARGS((
1341 EXTERN S16 cmPkRgSapCntrl ARGS((
1345 EXTERN S16 cmUnpkRgSapCntrl ARGS((
1349 EXTERN S16 cmPkRgCntrl ARGS((
1354 EXTERN S16 cmUnpkRgCntrl ARGS((
1359 EXTERN S16 cmPkRgMngmt ARGS((
1365 EXTERN S16 cmUnpkRgMngmt ARGS((
1372 #ifdef PHY_ERROR_LOGING
1373 EXTERN S16 cmPkRgSchUlAllocCntrl ARGS((
1374 RgSchUlAllocCntrl *param,
1378 EXTERN S16 cmUnpkRgSchUlAllocCntrl ARGS((
1379 RgSchUlAllocCntrl *param,
1383 /* lrg_x_001.main_4 ccpu00117036 - C++ support */
1389 #endif /* __LRGX__. */
1392 /**********************************************************************
1394 **********************************************************************/