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 /* Contains definitions for MAC CL modules */
23 #define MAX_NUM_CELL_SUPP 1
25 #include "du_app_mac_inf.h"
28 #define LWR_MAC_ALLOC(_datPtr, _size) WLS_MEM_ALLOC(_datPtr, _size);
30 #define LWR_MAC_ALLOC(_datPtr, _size) MAC_ALLOC(_datPtr, _size);
41 /* Events in Lower Mac */
56 Bool clCfgDone; /* CL configuration done */
57 CmHashListCp cellCbLst; /* List of Cells configured */
58 U8 numOfCells; /* Number of Cells configured */
59 PhyState phyState; /* State of PHY */
60 EventState event; /* State of Event */
83 NORMAL_CYCLIC_PREFIX_MASK,
84 EXTENDED_CYCLIC_PREFIX_MASK
114 CCE_MAPPING_INTERLEAVED_MASK,
115 CCE_MAPPING_NONINTERLVD_MASK
141 VRB_TO_PRB_MAP_NON_INTLV,
142 VRB_TO_PRB_MAP_INTLVD
159 DMRS_ADDITIONAL_POS_0,
160 DMRS_ADDITIONAL_POS_1,
161 DMRS_ADDITIONAL_POS_2,
162 DMRS_ADDITIONAL_POS_3
196 PRACH_FD_OCC_IN_A_SLOT_1 = 1,
197 PRACH_FD_OCC_IN_A_SLOT_2 = 2,
198 PRACH_FD_OCC_IN_A_SLOT_4 = 4,
199 PRACH_FD_OCC_IN_A_SLOT_8 = 8
208 typedef struct clCellParam
210 ReleaseCapab releaseCapability; /* Release Capability */
211 PhyState ParamPhystate;
212 ParamSupport skipBlankDlConfig;
213 ParamSupport skipBlankUlConfig;
214 ParamSupport numTlvsToReport;
215 CyclicPrefix cyclicPrefix;
216 SubCarrierSpacing supportedSubcarrierSpacingDl;
217 SupportedBandwidth supportedBandwidthDl;
218 SubCarrierSpacing supportedSubcarrierSpacingsUl;
219 SupportedBandwidth supportedBandwidthUl;
220 CCEMappingType cceMappingType;
221 ParamSupport coresetOutsideFirst3OfdmSymsOfSlot;
222 ParamSupport precoderGranularityCoreset;
223 ParamSupport pdcchMuMimo;
224 ParamSupport pdcchPrecoderCycling;
226 Formats pucchFormats;
228 MappingType pdschMappingType;
229 AllocationType pdschAllocationTypes;
230 VrbToPrbMap pdschVrbToPrbMapping;
231 ParamSupport pdschCbg;
232 DmrsConfigType pdschDmrsConfigTypes;
233 DmrMaxLen pdschDmrsMaxLength;
234 DmrsPos pdschDmrsAdditionalPos;
235 U8 maxPdschsTBsPerSlot;
236 U8 maxNumberMimoLayersPdsch;
237 ModulationOrder supportedMaxModulationOrderDl;
239 ParamSupport pdschDataInDmrsSymbols;
240 ParamSupport premptionSupport;
241 ParamSupport pdschNonSlotSupport;
242 ParamSupport uciMuxUlschInPusch;
243 ParamSupport uciOnlyPusch;
244 ParamSupport puschFrequencyHopping;
245 DmrsConfigType puschDmrsConfigTypes;
246 DmrMaxLen puschDmrsMaxLength;
247 DmrsPos puschDmrsAdditionalPos;
248 ParamSupport puschCbg;
249 MappingType puschMappingType;
250 AllocationType puschAllocationTypes;
251 VrbToPrbMap puschVrbToPrbMapping;
252 U8 puschMaxPtrsPorts;
253 U8 maxPduschsTBsPerSlot;
254 U8 maxNumberMimoLayersNonCbPusch;
255 ModulationOrder supportedModulationOrderUl;
257 ParamSupport dftsOfdmSupport;
258 AggregationFactor puschAggregationFactor;
259 Formats prachLongFormats;
260 ShortFormat prachShortFormats;
261 ParamSupport prachRestrictedSets;
262 FdOccPerSlot maxPrachFdOccasionsInASlot;
263 RssiMeasurement rssiMeasurementSupport;
266 EXTERN ClCb clGlobalCp;
267 EXTERN ClCellCb * rgClUtlGetCellCb ARGS((U16 cellId));
268 EXTERN uint32_t reverseBits(uint32_t num, uint8_t numBits);
269 EXTERN void fillDlDciPayload(uint8_t *buf, uint8_t *bytePos, uint8_t *bitPos,\
270 uint32_t val, uint8_t valSize);
271 EXTERN void lwrMacInit();
275 /**********************************************************************
277 **********************************************************************/