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: C source code for MAC to MAC (PRG) interface
29 **********************************************************************/
31 /* header include files -- defines (.h) */
32 #include "common_def.h"
33 #include "lrg.h" /* layer manager for MAC */
34 #include "crg.h" /* CRG interface includes*/
35 #include "rgu.h" /* RGU interface includes*/
36 #include "tfu.h" /* TFU interface includes*/
37 #include "rg_sch_inf.h" /* SCH interface includes*/
38 #include "rg_prg.h" /* PRG interface includes*/
39 #include "rg_env.h" /* MAC Enviroments includes */
40 #include "rg.h" /* MAC includes*/
41 #include "rg_err.h" /* MAC error includes*/
43 /* header/extern include files (.x) */
44 #include "rgu.x" /* RGU types */
45 #include "tfu.x" /* RGU types */
46 #include "lrg.x" /* layer management typedefs for MAC */
47 #include "crg.x" /* layer management typedefs for MAC */
48 #include "rg_sch_inf.x" /* layer management typedefs for MAC */
49 #include "rg_prg.x" /* PRG interface typedefs*/
50 #include "du_app_mac_inf.h"
51 #include "rg.x" /* typedefs for MAC */
54 #include "rg_pom_scell.x"
56 /* Matrix for Ue SCell Config Req*/
57 static const RgPrgUeSCellCfgReq RgPrgPMacSMacUeSCellCfgReqMt[RG_PRG_MAX] =
60 cmPkPrgPMacSMacUeSCellCfgReq,
62 RgPrgPMacSMacUeSCellCfgReq
67 * @brief Ue SCell config Req from PMac to SMac
71 * Function : RgPrgPMacSMacUeSCellCfg
74 * @param[in] RgPrgUeSCellCfgInfo *ueSCellCfgInfo;
79 S16 RgPrgPMacSMacUeSCellCfg
82 RgPrgUeSCellCfgInfo *ueSCellCfgInfo
85 S16 RgPrgPMacSMacUeSCellCfg(pst, ueSCellCfgInfo)
87 RgPrgUeSCellCfgInfo *ueSCellCfgInfo;
91 return ((*RgPrgPMacSMacUeSCellCfgReqMt[0])(pst, ueSCellCfgInfo));
94 /* Matrix for config confirm from SMac to Pmac*/
95 static const RgSMacPMacCfgCfm RgPrgSMacPMacCfgCfmMt[RG_PRG_MAX] =
98 cmPkPrgSMacPMacCfgCfm,
105 * @brief Config confirm from SMac to PMac for Ue Cell Config Req
109 * Function :RgPrgSMacPMacCfg
111 * @param[in] Pst *pst
112 * @param[in] RgPrgCfgCfmInfo *cfmCfm
120 RgPrgCfgCfmInfo *cfgCfm
123 S16 RgPrgSMacPMacCfg(pst, cfgCfm)
125 RgPrgCfgCfmInfo *cfgCfm;
129 return ((*RgPrgSMacPMacCfgCfmMt[0])(pst, cfgCfm));
132 /* Matrix for Ue SCell delete req/Ue Id change req from PMac to SMac */
133 static const RgUeSCellDelReq RgPrgPMacSMacUeSCellDelReqMt[RG_PRG_MAX] =
136 cmPkPrgPMacSMacUeSCellDelReq,
138 RgPrgPMacSMacUeSCellDelReq
143 * @brief Ue SCell delete Req/Ue Id change Req from PMac to SMac
147 * Function : RgPrgPMacSMacUeSCellDel
149 * @param[in] Pst *pst
150 * @param[in] RgPrgUeSCellDelInfo *ueSCellDelInfo;
155 S16 RgPrgPMacSMacUeSCellDel
158 RgPrgUeSCellDelInfo *ueSCellDelInfo
161 S16 RgPrgPMacSMacUeSCellDel(pst, ueSCellDelInfo)
163 RgPrgUeSCellDelInfo *ueSCellDelInfo;
167 return ((*RgPrgPMacSMacUeSCellDelReqMt[0])(pst, ueSCellDelInfo));
172 /* Matrix for Lch ReConfig Req*/
173 static const RgPrgUeScellModLchReq RgPrgPMacSMacUeScellModLchReqMt[RG_PRG_MAX] =
176 cmPkPrgPMacSMacUeSCellLchModReq,
178 RgPrgPMacSMacUeSCellLchModReq
184 * @brief Ue Lch Reconfig Req from PMac to SMac
188 * Function : RgPrgPMacSMacUeScellLchMod
190 * @param[in] Pst *pst
191 * @param[in] RgPrgUeSCellLchModInfo *lchCfgInfo
196 S16 RgPrgPMacSMacUeScellLchMod
199 RgPrgUeSCellLchModInfo *lchCfgInfo
202 S16 RgPrgPMacSMacUeScellLchMod(pst, lchCfgInfo)
204 RgPrgUeSCellLchModInfo *lchCfgInfo;
208 return ((*RgPrgPMacSMacUeScellModLchReqMt[0])(pst, lchCfgInfo));
212 /* Matrix for delete Lch Req*/
213 static const RgPrgUeScellDelLchReq RgPrgPMacSMacUeScellDelLchReqMt[RG_PRG_MAX] =
216 cmPkPrgPMacSMacUeSCellLchDelReq,
218 RgPrgPMacSMacUeSCellLchDelReq
224 * @brief Delete Lch Req from PMac to SMac
228 * Function : RgPrgPMacSMacUeScellLchDel
230 * @param[in] Pst *pst
231 * @param[in] RgPrgUeSCellLchDelInfo *delLcCb
236 S16 RgPrgPMacSMacUeScellLchDel
239 RgPrgUeSCellLchDelInfo *delLcCb
242 S16 RgPrgPMacSMacUeScellLchDel(pst, delLcCb)
244 RgPrgUeSCellLchDelInfo *delLcCb;
248 return ((*RgPrgPMacSMacUeScellDelLchReqMt[0])(pst, delLcCb));
252 /* Matrix for Lch Config Req*/
253 static const RgPrgUeScellAddLchReq RgPrgPMacSMacUeScellAddLchReqMt[RG_PRG_MAX] =
256 cmPkPrgPMacSMacUeSCellLchAddReq,
258 RgPrgPMacSMacUeSCellLchAddReq
264 * @brief Ue Lch config Req from PMac to SMac
268 * Function : RgPrgPMacSMacUeScellLchAdd
270 * @param[in] Pst *pst
271 * @param[in] RgPrgUeSCellLchAddInfo *lchCfgInfo
276 S16 RgPrgPMacSMacUeScellLchAdd
279 RgPrgUeSCellLchAddInfo *lchCfgInfo
282 S16 RgPrgPMacSMacUeScellLchAdd(pst, lchCfgInfo)
284 RgPrgUeSCellLchAddInfo *lchCfgInfo;
288 return ((*RgPrgPMacSMacUeScellAddLchReqMt[0])(pst, lchCfgInfo));
293 /**********************************************************************
296 **********************************************************************/