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 /* header include files -- defines (.h) */
20 #include "envopt.h" /* environment options */
21 #include "envdep.h" /* environment dependent */
22 #include "envind.h" /* environment independent */
23 #include "gen.h" /* general layer */
24 #include "ssi.h" /* system services */
25 #include "cm5.h" /* common timers defines */
26 #include "cm_hash.h" /* common hash list defines */
27 #include "cm_llist.h" /* common linked list defines */
28 #include "cm_mblk.h" /* memory management */
29 #include "cm_tkns.h" /* common tokens */
30 #include "cm_lte.h" /* common tokens */
33 #include "rg_sch_inf.h"
41 /* header/extern include files (.x) */
42 #include "gen.x" /* general layer typedefs */
43 #include "ssi.x" /* system services typedefs */
44 #include "cm5.x" /* common timers */
45 #include "cm_hash.x" /* common hash list */
46 #include "cm_lib.x" /* common library */
47 #include "cm_llist.x" /* common linked list */
48 #include "cm_mblk.x" /* memory management */
49 #include "cm_tkns.x" /* common tokens */
50 #include "cm_lte.x" /* common tokens */
53 #include "rg_sch_inf.x"
57 #include "du_app_mac_inf.h"
59 #include "lwr_mac_fsm.h"
60 /* This file contains message handling functionality for MAC */
62 extern void sendToLowerMac(uint16_t msgType, uint32_t msgLen, void *msg);
64 /*******************************************************************
66 * @brief Handles cell start reuqest from DU APP
70 * Function : MacHdlCellStartReq
73 * Handles cell start reuqest from DU APP
75 * @params[in] Post structure pointer
76 * Cell Start Request info pointer
77 * @return ROK - success
80 * ****************************************************************/
81 uint16_t MacHdlCellStartReq(Pst *pst, MacCellStartInfo *cellStartInfo)
83 DU_LOG("\nMAC : Handling cell start request");
84 sendToLowerMac(START_REQUEST, 0, cellStartInfo);
86 MAC_FREE_MEM(pst->region, pst->pool, cellStartInfo, \
87 sizeof(MacCellStartInfo));
92 /*******************************************************************
94 * @brief Handles cell stop request from DU APP
98 * Function : MacHdlCellStartReq
101 * Handles cell stop request from DU APP
103 * @params[in] Post structure pointer
104 * Mac Cell stop information
105 * @return ROK - success
108 * ****************************************************************/
109 uint16_t MacHdlCellStopReq(Pst *pst, MacCellStopInfo *cellStopInfo)
111 DU_LOG("\nMAC : Handling cell stop request");
112 sendToLowerMac(STOP_REQUEST, 0, cellStopInfo);
114 MAC_FREE_MEM(pst->region, pst->pool, cellStopInfo, \
115 sizeof(MacCellStopInfo));
120 /**********************************************************************
122 **********************************************************************/