Cleaning up logs removing unecessary code
This commit is contained in:
@@ -166,9 +166,6 @@ typedef struct {
|
|||||||
|
|
||||||
} vnf_info;
|
} vnf_info;
|
||||||
|
|
||||||
bool is_rx = false;
|
|
||||||
bool is_crc = false;
|
|
||||||
|
|
||||||
int vnf_pack_vendor_extension_tlv(void *ve, uint8_t **ppWritePackedMsg, uint8_t *end, nfapi_p4_p5_codec_config_t *codec) {
|
int vnf_pack_vendor_extension_tlv(void *ve, uint8_t **ppWritePackedMsg, uint8_t *end, nfapi_p4_p5_codec_config_t *codec) {
|
||||||
//NFAPI_TRACE(NFAPI_TRACE_INFO, "vnf_pack_vendor_extension_tlv\n");
|
//NFAPI_TRACE(NFAPI_TRACE_INFO, "vnf_pack_vendor_extension_tlv\n");
|
||||||
nfapi_tl_t *tlv = (nfapi_tl_t *)ve;
|
nfapi_tl_t *tlv = (nfapi_tl_t *)ve;
|
||||||
@@ -409,17 +406,6 @@ int phy_subframe_indication(struct nfapi_vnf_p7_config *config, uint16_t phy_id,
|
|||||||
first_time = 0;
|
first_time = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(UL_RCC_INFO.rx_ind->sfn_sf != 0 && !is_rx)
|
|
||||||
{
|
|
||||||
LOG_E(MAC, "Test1 phy_subframe_ind sfn_sf: %u rx_ind sfn_sf: %u\n", sfn_sf, UL_RCC_INFO.rx_ind->sfn_sf);
|
|
||||||
is_rx = true;
|
|
||||||
}
|
|
||||||
if(UL_RCC_INFO.crc_ind->sfn_sf != 0 && !is_crc)
|
|
||||||
{
|
|
||||||
LOG_E(MAC, "Test1 phy_subframe_ind sfn_sf: %u crc_ind sfn_sf: %u\n", sfn_sf, UL_RCC_INFO.crc_ind->sfn_sf);
|
|
||||||
is_crc = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (RC.eNB && RC.eNB[0][0]->configured) {
|
if (RC.eNB && RC.eNB[0][0]->configured) {
|
||||||
uint16_t sfn = NFAPI_SFNSF2SFN(sfn_sf);
|
uint16_t sfn = NFAPI_SFNSF2SFN(sfn_sf);
|
||||||
uint16_t sf = NFAPI_SFNSF2SF(sfn_sf);
|
uint16_t sf = NFAPI_SFNSF2SF(sfn_sf);
|
||||||
@@ -441,16 +427,7 @@ int phy_rach_indication(struct nfapi_vnf_p7_config *config, nfapi_rach_indicatio
|
|||||||
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
||||||
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
||||||
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
||||||
// for(uint8_t i= 0;i< NUM_NFPAI_SUBFRAME;i++){
|
|
||||||
// if((UL_RCC_INFO.rach_ind[i].header.message_id == 0) && (index == -1)){
|
|
||||||
// index = i;
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if(index == -1){
|
|
||||||
// LOG_E(MAC,"phy_rach_indication : num of rach reach max \n");
|
|
||||||
// return 0;
|
|
||||||
// }
|
|
||||||
UL_RCC_INFO.rach_ind[index] = *ind;
|
UL_RCC_INFO.rach_ind[index] = *ind;
|
||||||
|
|
||||||
if (ind->rach_indication_body.number_of_preambles > 0)
|
if (ind->rach_indication_body.number_of_preambles > 0)
|
||||||
@@ -505,16 +482,7 @@ int phy_harq_indication(struct nfapi_vnf_p7_config *config, nfapi_harq_indicatio
|
|||||||
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
||||||
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
||||||
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
||||||
// for(uint8_t i= 0;i< NUM_NFPAI_SUBFRAME;i++){
|
|
||||||
// if((UL_RCC_INFO.harq_ind[i].header.message_id == 0) && (index == -1)){
|
|
||||||
// index = i;
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if(index == -1){
|
|
||||||
// LOG_E(MAC,"phy_harq_indication : num of harq reach max \n");
|
|
||||||
// return 0;
|
|
||||||
// }
|
|
||||||
UL_RCC_INFO.harq_ind[index] = *ind;
|
UL_RCC_INFO.harq_ind[index] = *ind;
|
||||||
|
|
||||||
if (ind->harq_indication_body.number_of_harqs > 0)
|
if (ind->harq_indication_body.number_of_harqs > 0)
|
||||||
@@ -541,19 +509,7 @@ int phy_crc_indication(struct nfapi_vnf_p7_config *config, nfapi_crc_indication_
|
|||||||
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
||||||
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
||||||
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
||||||
// for(uint8_t i= 0;i< NUM_NFPAI_SUBFRAME;i++){
|
|
||||||
// if((UL_RCC_INFO.crc_ind[i].header.message_id == 0) && (index == -1)){
|
|
||||||
// index = i;
|
|
||||||
// }
|
|
||||||
// if(UL_RCC_INFO.rx_ind[i].sfn_sf == ind->sfn_sf){
|
|
||||||
// index = i;
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if(index == -1){
|
|
||||||
// LOG_E(MAC,"phy_crc_indication : num of crc reach max \n");
|
|
||||||
// return 0;
|
|
||||||
// }
|
|
||||||
UL_RCC_INFO.crc_ind[index] = *ind;
|
UL_RCC_INFO.crc_ind[index] = *ind;
|
||||||
|
|
||||||
if (ind->crc_indication_body.number_of_crcs > 0)
|
if (ind->crc_indication_body.number_of_crcs > 0)
|
||||||
@@ -631,19 +587,7 @@ int phy_rx_indication(struct nfapi_vnf_p7_config *config, nfapi_rx_indication_t
|
|||||||
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
||||||
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
||||||
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
||||||
// for(uint8_t i= 0;i< NUM_NFPAI_SUBFRAME;i++){
|
|
||||||
// if((UL_RCC_INFO.rx_ind[i].header.message_id == 0) && (index == -1)){
|
|
||||||
// index = i;
|
|
||||||
// }
|
|
||||||
// if(UL_RCC_INFO.crc_ind[i].sfn_sf == ind->sfn_sf){
|
|
||||||
// index = i;
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if(index == -1){
|
|
||||||
// LOG_E(MAC,"phy_rx_indication : num of rx reach max \n");
|
|
||||||
// return 0;
|
|
||||||
// }
|
|
||||||
UL_RCC_INFO.rx_ind[index] = *ind;
|
UL_RCC_INFO.rx_ind[index] = *ind;
|
||||||
|
|
||||||
if (ind->rx_indication_body.number_of_pdus > 0)
|
if (ind->rx_indication_body.number_of_pdus > 0)
|
||||||
@@ -717,16 +661,7 @@ int phy_sr_indication(struct nfapi_vnf_p7_config *config, nfapi_sr_indication_t
|
|||||||
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
||||||
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
||||||
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
||||||
// for(uint8_t i= 0;i< NUM_NFPAI_SUBFRAME;i++){
|
|
||||||
// if((UL_RCC_INFO.sr_ind[i].header.message_id == 0) && (index == -1)){
|
|
||||||
// index = i;
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if(index == -1){
|
|
||||||
// LOG_E(MAC,"phy_sr_indication : num of sr reach max \n");
|
|
||||||
// return 0;
|
|
||||||
// }
|
|
||||||
UL_RCC_INFO.sr_ind[index] = *ind;
|
UL_RCC_INFO.sr_ind[index] = *ind;
|
||||||
LOG_D(MAC,"%s() UL_INFO[%d].sr_ind.sr_indication_body.number_of_srs:%d\n", __FUNCTION__, index, eNB->UL_INFO.sr_ind.sr_indication_body.number_of_srs);
|
LOG_D(MAC,"%s() UL_INFO[%d].sr_ind.sr_indication_body.number_of_srs:%d\n", __FUNCTION__, index, eNB->UL_INFO.sr_ind.sr_indication_body.number_of_srs);
|
||||||
if (ind->sr_indication_body.number_of_srs > 0)
|
if (ind->sr_indication_body.number_of_srs > 0)
|
||||||
@@ -768,16 +703,7 @@ int phy_cqi_indication(struct nfapi_vnf_p7_config *config, nfapi_cqi_indication_
|
|||||||
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
pthread_mutex_lock(&eNB->UL_INFO_mutex);
|
||||||
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
if(NFAPI_MODE == NFAPI_MODE_VNF){
|
||||||
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
int8_t index = NFAPI_SFNSF2SF(ind->sfn_sf);
|
||||||
// for(uint8_t i= 0;i< NUM_NFPAI_SUBFRAME;i++){
|
|
||||||
// if((UL_RCC_INFO.cqi_ind[i].header.message_id == 0) && (index == -1)){
|
|
||||||
// index = i;
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if(index == -1){
|
|
||||||
// LOG_E(MAC,"phy_cqi_indication : num of cqi reach max \n");
|
|
||||||
// return 0;
|
|
||||||
// }
|
|
||||||
UL_RCC_INFO.cqi_ind[index] = *ind;
|
UL_RCC_INFO.cqi_ind[index] = *ind;
|
||||||
if (ind->cqi_indication_body.number_of_cqis > 0){
|
if (ind->cqi_indication_body.number_of_cqis > 0){
|
||||||
UL_RCC_INFO.cqi_ind[index].cqi_indication_body.cqi_pdu_list = malloc(sizeof(nfapi_cqi_indication_pdu_t)*ind->cqi_indication_body.number_of_cqis );
|
UL_RCC_INFO.cqi_ind[index].cqi_indication_body.cqi_pdu_list = malloc(sizeof(nfapi_cqi_indication_pdu_t)*ind->cqi_indication_body.number_of_cqis );
|
||||||
|
|||||||
@@ -694,26 +694,6 @@ uint8_t unpack_tl(uint8_t **ppReadPackedMsg, nfapi_tl_t *tl, uint8_t *end)
|
|||||||
pull16(ppReadPackedMsg, &tl->length, end));
|
pull16(ppReadPackedMsg, &tl->length, end));
|
||||||
}
|
}
|
||||||
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <execinfo.h>
|
|
||||||
#include <sys/types.h>
|
|
||||||
#include <sys/stat.h>
|
|
||||||
#include <fcntl.h>
|
|
||||||
#define MSG( X ) r = write(fd, X, sizeof(X) - 1)
|
|
||||||
static void show_backtrace()
|
|
||||||
{
|
|
||||||
printf("Bruins\n");
|
|
||||||
fflush(stdout);
|
|
||||||
void *buffer[100];
|
|
||||||
__attribute__((unused)) int r;
|
|
||||||
int nptrs = backtrace(buffer, sizeof(buffer) / sizeof(buffer[0]));
|
|
||||||
int fd = 1;
|
|
||||||
MSG("---stack trace---\n");
|
|
||||||
backtrace_symbols_fd(buffer, nptrs, fd);
|
|
||||||
MSG("---end stack trace---\n");
|
|
||||||
}
|
|
||||||
|
|
||||||
int unpack_tlv_list(unpack_tlv_t unpack_fns[], uint16_t size, uint8_t **ppReadPackedMsg, uint8_t* end, nfapi_p4_p5_codec_config_t* config, nfapi_tl_t** ve)
|
int unpack_tlv_list(unpack_tlv_t unpack_fns[], uint16_t size, uint8_t **ppReadPackedMsg, uint8_t* end, nfapi_p4_p5_codec_config_t* config, nfapi_tl_t** ve)
|
||||||
{
|
{
|
||||||
nfapi_tl_t generic_tl;
|
nfapi_tl_t generic_tl;
|
||||||
@@ -749,8 +729,7 @@ int unpack_tlv_list(unpack_tlv_t unpack_fns[], uint16_t size, uint8_t **ppReadPa
|
|||||||
// check if the length was right;
|
// check if the length was right;
|
||||||
if(tl->length != (*ppReadPackedMsg - pStartOfValue))
|
if(tl->length != (*ppReadPackedMsg - pStartOfValue))
|
||||||
{
|
{
|
||||||
NFAPI_TRACE(NFAPI_TRACE_ERROR, "Warning Michael Angry Now tlv tag 0x%x length %d not equal to unpack %d\n", tl->tag, tl->length, (*ppReadPackedMsg - pStartOfValue));
|
NFAPI_TRACE(NFAPI_TRACE_ERROR, "Warning tlv tag 0x%x length %d not equal to unpack %d\n", tl->tag, tl->length, (*ppReadPackedMsg - pStartOfValue));
|
||||||
show_backtrace();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -851,8 +830,7 @@ int unpack_p7_tlv_list(unpack_p7_tlv_t unpack_fns[], uint16_t size, uint8_t **pp
|
|||||||
// check if the length was right;
|
// check if the length was right;
|
||||||
if(tl->length != (*ppReadPackedMsg - pStartOfValue))
|
if(tl->length != (*ppReadPackedMsg - pStartOfValue))
|
||||||
{
|
{
|
||||||
NFAPI_TRACE(NFAPI_TRACE_ERROR, "Warning Andrew Angry tlv tag 0x%x length %d not equal to unpack %d\n", tl->tag, tl->length, (*ppReadPackedMsg - pStartOfValue));
|
NFAPI_TRACE(NFAPI_TRACE_ERROR, "Warning tlv tag 0x%x length %d not equal to unpack %d\n", tl->tag, tl->length, (*ppReadPackedMsg - pStartOfValue));
|
||||||
show_backtrace();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4500,6 +4500,7 @@ static uint8_t unpack_tx_request(uint8_t **ppReadPackedMsg, uint8_t *end, void *
|
|||||||
{
|
{
|
||||||
if(!pullarray8(ppReadPackedMsg, pdu->segments[0].segment_data, pdu->segments[0].segment_length, pdu->segments[0].segment_length, end))
|
if(!pullarray8(ppReadPackedMsg, pdu->segments[0].segment_data, pdu->segments[0].segment_length, pdu->segments[0].segment_length, end))
|
||||||
return 0;
|
return 0;
|
||||||
|
#if 0
|
||||||
if (pdu->segments[0].segment_length == 3)
|
if (pdu->segments[0].segment_length == 3)
|
||||||
{
|
{
|
||||||
NFAPI_TRACE(NFAPI_TRACE_INFO, "%s() BCH? segment_data:%x %x %x\n", __FUNCTION__,
|
NFAPI_TRACE(NFAPI_TRACE_INFO, "%s() BCH? segment_data:%x %x %x\n", __FUNCTION__,
|
||||||
@@ -4508,6 +4509,7 @@ static uint8_t unpack_tx_request(uint8_t **ppReadPackedMsg, uint8_t *end, void *
|
|||||||
pdu->segments[0].segment_data[2]
|
pdu->segments[0].segment_data[2]
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -6206,8 +6208,6 @@ int nfapi_p7_message_unpack(void *pMessageBuf, uint32_t messageBufLen, void *pUn
|
|||||||
{
|
{
|
||||||
nfapi_rx_indication_t *pNfapiMsg = (nfapi_rx_indication_t*)pMessageHeader;
|
nfapi_rx_indication_t *pNfapiMsg = (nfapi_rx_indication_t*)pMessageHeader;
|
||||||
result = unpack_rx_indication(&pReadPackedMessage, end, pMessageHeader, config);
|
result = unpack_rx_indication(&pReadPackedMessage, end, pMessageHeader, config);
|
||||||
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s Celtics RX_IND Frame: %d Subframe %d\n", __FUNCTION__,
|
|
||||||
pNfapiMsg->sfn_sf >> 4, pNfapiMsg->sfn_sf & 15);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
return -1;
|
return -1;
|
||||||
|
|||||||
@@ -30,9 +30,9 @@ void handle_rach(UL_IND_t *UL_info) {
|
|||||||
{
|
{
|
||||||
if (UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles > 1)
|
if (UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles > 1)
|
||||||
{
|
{
|
||||||
LOG_I(MAC, "handle_rach j: %d UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles: %d\n",
|
LOG_D(MAC, "handle_rach j: %d UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles: %d\n",
|
||||||
j, UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles);
|
j, UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles);
|
||||||
LOG_I(MAC, "UL_info[Frame %d, Subframe %d] Calling initiate_ra_proc RACH:Frame: %d Subframe: %d\n",
|
LOG_D(MAC, "UL_info[Frame %d, Subframe %d] Calling initiate_ra_proc RACH:Frame: %d Subframe: %d\n",
|
||||||
UL_info->frame, UL_info->subframe, NFAPI_SFNSF2SFN(UL_RCC_INFO.rach_ind[j].sfn_sf), NFAPI_SFNSF2SF(UL_RCC_INFO.rach_ind[j].sfn_sf));
|
UL_info->frame, UL_info->subframe, NFAPI_SFNSF2SFN(UL_RCC_INFO.rach_ind[j].sfn_sf), NFAPI_SFNSF2SF(UL_RCC_INFO.rach_ind[j].sfn_sf));
|
||||||
}
|
}
|
||||||
AssertFatal(UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles == 1, "More than 1 preamble not supported\n"); // dump frame/sf and all things in UL_RCC_INFO
|
AssertFatal(UL_RCC_INFO.rach_ind[j].rach_indication_body.number_of_preambles == 1, "More than 1 preamble not supported\n"); // dump frame/sf and all things in UL_RCC_INFO
|
||||||
@@ -705,7 +705,7 @@ void UL_indication(UL_IND_t *UL_info, L1_rxtx_proc_t *proc) {
|
|||||||
eNB_MAC_INST *mac = RC.mac[module_id];
|
eNB_MAC_INST *mac = RC.mac[module_id];
|
||||||
if (UL_info->subframe == 3)
|
if (UL_info->subframe == 3)
|
||||||
{
|
{
|
||||||
LOG_I(PHY,"SFN/SF:%d%d module_id:%d CC_id:%d UL_info[rx_ind:%d harqs:%d crcs:%d cqis:%d preambles:%d sr_ind:%d]\n",
|
LOG_D(PHY,"SFN/SF:%d%d module_id:%d CC_id:%d UL_info[rx_ind:%d harqs:%d crcs:%d cqis:%d preambles:%d sr_ind:%d]\n",
|
||||||
UL_info->frame,UL_info->subframe,
|
UL_info->frame,UL_info->subframe,
|
||||||
module_id,CC_id,
|
module_id,CC_id,
|
||||||
UL_info->rx_ind.rx_indication_body.number_of_pdus, UL_info->harq_ind.harq_indication_body.number_of_harqs, UL_info->crc_ind.crc_indication_body.number_of_crcs,
|
UL_info->rx_ind.rx_indication_body.number_of_pdus, UL_info->harq_ind.harq_indication_body.number_of_harqs, UL_info->crc_ind.crc_indication_body.number_of_crcs,
|
||||||
|
|||||||
Reference in New Issue
Block a user