include $(COM_BUILD_DIR)/compile.mak
I_OPTS+=-I$(ROOT_DIR)/src/mt
+I_OPTS+=-I$(ROOT_DIR)/src/intel_fapi
#-------------------------------------------------------------#
#Linker macros
CONFIG_REQUEST,
CONFIG_RESPONSE,
START_REQUEST,
+#ifdef NFAPI_ENABLED
+ START_RESPONSE,
+#endif
STOP_REQUEST,
MAX_EVENT
}EventState;
}
}
MAC_FREE(cellParam, sizeof(ClCellParam));
- sendToLowerMac(FAPI_CONFIG_REQUEST, 0, (void *)NULL);
+ sendEventToLowerMacFsm(FAPI_CONFIG_REQUEST, 0, (void *)NULL);
return ROK;
}
else
*
* @details
*
- * Function : sendToLowerMac
+ * Function : sendEventToLowerMacFsm
*
* Functionality:
* -Sends message to LowerMac
* @return void
*
******************************************************************/
-void sendToLowerMac(uint16_t msgType, uint32_t msgLen, void *msg)
+void sendEventToLowerMacFsm(uint16_t msgType, uint32_t msgLen, void *msg)
{
lwrMacCb.event = msgType;
fapiEvtHdlr[lwrMacCb.phyState][lwrMacCb.event](msg);
uint8_t lwr_mac_procConfigReqEvt(void *msg);
uint8_t lwr_mac_procConfigRspEvt(void *msg);
uint8_t lwr_mac_procStartReqEvt(void *msg);
-void sendToLowerMac(uint16_t, uint32_t, void *);
+void sendEventToLowerMacFsm(uint16_t, uint32_t, void *);
void procPhyMessages(uint16_t msgType, uint32_t msgSize, void *msg);
uint16_t fillDlTtiReq(SlotTimingInfo currTimingInfo);
typedef uint8_t (*lwrMacFsmHdlr)(void *);
DU_LOG("\nDEBUG --> LWR_MAC: Received FAPI_VENDOR_EXT_UL_IQ_SAMPLES");
//send config req
uint16_t cellId = 1;
- sendToLowerMac(CONFIG_REQUEST, 0, (void *)&cellId);
+ sendEventToLowerMacFsm(CONFIG_REQUEST, 0, (void *)&cellId);
break;
}
#endif
case FAPI_PARAM_RESPONSE:
{
- sendToLowerMac(PARAM_RESPONSE, msgSize, msg);
+ sendEventToLowerMacFsm(PARAM_RESPONSE, msgSize, msg);
break;
}
case FAPI_CONFIG_RESPONSE:
{
- sendToLowerMac(CONFIG_RESPONSE, msgSize, msg);
+ sendEventToLowerMacFsm(CONFIG_RESPONSE, msgSize, msg);
break;
}
case FAPI_SLOT_INDICATION:
{
cellId = &schCellCfgCfm->cellId;
#ifdef INTEL_TIMER_MODE
- sendToLowerMac(UL_IQ_SAMPLE, 0, (void *)cellId);
+ sendEventToLowerMacFsm(UL_IQ_SAMPLE, 0, (void *)cellId);
#else
- sendToLowerMac(CONFIG_REQUEST, 0, (void *)cellId);
+ sendEventToLowerMacFsm(CONFIG_REQUEST, 0, (void *)cellId);
#endif
}
else
{
DU_LOG("\nINFO --> MAC : Handling cell start request");
gConfigInfo.gSlotCount = 0;
- sendToLowerMac(START_REQUEST, 0, cellStart);
+ sendEventToLowerMacFsm(START_REQUEST, 0, cellStart);
MAC_FREE_SHRABL_BUF(pst->region, pst->pool, cellStart, \
sizeof(CellStartInfo));
strcpy(message,"EVENT_DL_CQI_TO_SCH");
break;
}
- case EVENT_PHR_IND_TO_SCH
+ case EVENT_PHR_IND_TO_SCH:
{
strcpy(message,"EVENT_PHR_IND_TO_SCH");
}
S16 SPkS8 ARGS((S8 val,Buffer *mBuf));
S16 oduUnpackUInt8 ARGS((uint8_t val,Buffer *mBuf));
+S16 oduPackPostUInt8 ARGS((uint8_t val,Buffer *mBuf));
S16 SPkS16 ARGS((S16 val,Buffer *mBuf));
S16 oduUnpackUInt16 ARGS((uint16_t val,Buffer *mBuf));
+S16 oduPackPostUInt16 ARGS((uint16_t val,Buffer *mBuf));
S16 SPkS32 ARGS((S32 val,Buffer *mBuf));
S16 oduUnpackUInt32 ARGS((uint32_t val,Buffer *mBuf));
+S16 oduPackPostUInt32 ARGS((uint32_t val,Buffer *mBuf));
/* ssi_x_001.main_49 : added packing of F32 and F64*/
#ifdef SS_FLOAT
S16 SPkF32 ARGS((F32 val,Buffer *mBuf));
#endif
return (ret);
} /* end of oduUnpackUInt8 */
+
+/*
+*
+* Fun: oduPackPostUInt8
+*
+* Desc: This function packs an unsigned 8 bit value into a message.
+*
+* Ret: ROK - ok
+* RFAILED - failed, general (optional)
+* ROUTRES - failed, out of resources (optional)
+*
+* Notes: None
+*
+* File: ss_pack.c
+*
+*/
+S16 oduPackPostUInt8
+(
+uint8_t val, /* value */
+Buffer *mBuf /* message buffer */
+)
+{
+ S16 ret; /* return code */
+ ret = SAddPstMsg((Data) val, mBuf);
+ return (ret);
+} /* end of oduPackPostUInt8 */
+
\f
/*
*
return (ret);
} /* end of oduUnpackUInt16 */
+/*
+*
+* Fun: oduPackPostUInt16
+*
+* Desc: This function packs an unsigned 16 bit value into a message.
+*
+* Ret: ROK - ok
+* RFAILED - failed, general (optional)
+* ROUTRES - failed, out of resources (optional)
+*
+* Notes: None
+*
+* File: ss_pack.c
+*
+*/
+
+S16 oduPackPostUInt16
+(
+uint16_t val, /* value */
+Buffer *mBuf /* message buffer */
+)
+{
+ Data pkArray[2]; /* array for packing */
+ S16 ret; /* return code */
+
+ pkArray[1] = (Data) GetHiByte(val);
+ pkArray[0] = (Data) GetLoByte(val);
+ ret = SAddPstMsgMult(pkArray, (MsgLen) 2, mBuf);
+ return (ret);
+} /* end of oduPackPostUInt16 */
+
\f
/*
*
return (ret);
} /* end of oduUnpackUInt32 */
+/*
+*
+* Fun: oduPackPostUInt32
+*
+* Desc: This function packs an unsigned 32 bit value into a message.
+*
+* Ret: ROK - ok
+* RFAILED - failed, general (optional)
+* ROUTRES - failed, out of resources (optional)
+*
+* Notes: None
+*
+* File: ss_pack.c
+*
+*/
+
+S16 oduPackPostUInt32
+(
+uint32_t val, /* value */
+Buffer *mBuf /* message buffer */
+)
+{
+ uint16_t tmp; /* temporary value */
+ Data pkArray[4]; /* packing array */
+ S16 ret; /* return code */
+
+ tmp = (uint16_t) GetHiWord(val);
+ pkArray[3] = (Data) GetHiByte(tmp);
+ pkArray[2] = (Data) GetLoByte(tmp);
+ tmp = (uint16_t) GetLoWord(val);
+ pkArray[1] = (Data) GetHiByte(tmp);
+ pkArray[0] = (Data) GetLoByte(tmp);
+ ret = SAddPstMsgMult(pkArray, (MsgLen) 4, mBuf);
+ return (ret);
+} /* end of oduPackPostUInt32 */
+
/*ss038.103 1. Added Floating point support*/
#ifdef SS_FLOAT
/*