Commit aeb968eb authored by Robert Schmidt's avatar Robert Schmidt

log changes

Remove useless message bytes printing

Print message if callback missing

less newlines in log

logs
parent 5238ce91
...@@ -2887,14 +2887,8 @@ static uint8_t unpack_nr_param_response(uint8_t **ppReadPackedMsg, uint8_t *end, ...@@ -2887,14 +2887,8 @@ static uint8_t unpack_nr_param_response(uint8_t **ppReadPackedMsg, uint8_t *end,
}; };
// print ppReadPackedMsg // print ppReadPackedMsg
uint8_t *ptr = *ppReadPackedMsg; uint8_t *ptr = *ppReadPackedMsg;
printf("\n Read message unpack_param_response: ");
while (ptr < end) {
printf(" %02x ", *ptr);
ptr++;
}
printf("\n");
return (pull8(ppReadPackedMsg, &pNfapiMsg->error_code, end) && pull8(ppReadPackedMsg, &pNfapiMsg->num_tlv, end) return (pull8(ppReadPackedMsg, &pNfapiMsg->error_code, end) && pull8(ppReadPackedMsg, &pNfapiMsg->num_tlv, end)
&& unpack_nr_tlv_list(unpack_fns, && unpack_nr_tlv_list(unpack_fns,
sizeof(unpack_fns) / sizeof(unpack_tlv_t), sizeof(unpack_fns) / sizeof(unpack_tlv_t),
...@@ -3123,6 +3117,9 @@ static uint8_t unpack_config_request(uint8_t **ppReadPackedMsg, uint8_t *end, vo ...@@ -3123,6 +3117,9 @@ static uint8_t unpack_config_request(uint8_t **ppReadPackedMsg, uint8_t *end, vo
static uint8_t unpack_nr_config_request(uint8_t **ppReadPackedMsg, uint8_t *end, void *msg, nfapi_p4_p5_codec_config_t *config) static uint8_t unpack_nr_config_request(uint8_t **ppReadPackedMsg, uint8_t *end, void *msg, nfapi_p4_p5_codec_config_t *config)
{ {
for (uint8_t *p = *ppReadPackedMsg; p < end; ++p)
printf("%02x ", *p);
printf("\n");
// Helper vars for indexed TLVs // Helper vars for indexed TLVs
int prach_root_seq_idx = 0; int prach_root_seq_idx = 0;
int unused_root_seq_idx = 0; int unused_root_seq_idx = 0;
...@@ -3344,12 +3341,17 @@ static uint8_t unpack_nr_config_request(uint8_t **ppReadPackedMsg, uint8_t *end, ...@@ -3344,12 +3341,17 @@ static uint8_t unpack_nr_config_request(uint8_t **ppReadPackedMsg, uint8_t *end,
} }
break; break;
default: default:
/* unpack based on unpack_fns table above, this is a normal case */
printf("*** have tag %x, idx %ld\n", generic_tl.tag, idx);
assert(idx <= sizeof(unpack_fns) / sizeof(unpack_fns[0]));
result = (*unpack_fns[idx].unpack_func)(tl, ppReadPackedMsg, end); result = (*unpack_fns[idx].unpack_func)(tl, ppReadPackedMsg, end);
break; break;
} }
if (result == 0) if (result == 0) {
printf("return after tag %x idx %ld\n", generic_tl.tag, idx);
return 0; return 0;
}
// check if the length was right; // check if the length was right;
if (tl->length != (((*ppReadPackedMsg)) - pStartOfValue)) if (tl->length != (((*ppReadPackedMsg)) - pStartOfValue))
...@@ -3776,14 +3778,7 @@ int nfapi_nr_p5_message_unpack(void *pMessageBuf, ...@@ -3776,14 +3778,7 @@ int nfapi_nr_p5_message_unpack(void *pMessageBuf,
} }
uint8_t *ptr = pReadPackedMessage; uint8_t *ptr = pReadPackedMessage;
printf("\n Read NR message unpack: ");
while (ptr < end) {
printf(" %02x ", *ptr);
ptr++;
}
printf("\n");
// clean the supplied buffer for - tag value blanking // clean the supplied buffer for - tag value blanking
(void)memset(pUnpackedBuf, 0, unpackedBufLen); (void)memset(pUnpackedBuf, 0, unpackedBufLen);
......
...@@ -1622,7 +1622,7 @@ void pnf_handle_dl_tti_request(void* pRecvMsg, int recvMsgLen, pnf_p7_t* pnf_p7) ...@@ -1622,7 +1622,7 @@ void pnf_handle_dl_tti_request(void* pRecvMsg, int recvMsgLen, pnf_p7_t* pnf_p7)
struct timespec t; struct timespec t;
clock_gettime(CLOCK_MONOTONIC, &t); clock_gettime(CLOCK_MONOTONIC, &t);
NFAPI_TRACE(NFAPI_TRACE_INFO,"%s() %ld.%09ld POPULATE DL_TTI_REQ current tx sfn/slot:%d.%d p7 msg sfn/slot: %d.%d buffer_index:%d\n", __FUNCTION__, t.tv_sec, t.tv_nsec, pnf_p7->sfn,pnf_p7->slot, req->SFN, req->Slot, buffer_index); NFAPI_TRACE(NFAPI_TRACE_DEBUG,"%s() %ld.%09ld POPULATE DL_TTI_REQ current tx sfn/slot:%d.%d p7 msg sfn/slot: %d.%d buffer_index:%d\n", __FUNCTION__, t.tv_sec, t.tv_nsec, pnf_p7->sfn,pnf_p7->slot, req->SFN, req->Slot, buffer_index);
// if there is already an dl_tti_req make sure we free it. // if there is already an dl_tti_req make sure we free it.
if(pnf_p7->slot_buffer[buffer_index].dl_tti_req != 0) if(pnf_p7->slot_buffer[buffer_index].dl_tti_req != 0)
...@@ -1788,7 +1788,7 @@ void pnf_handle_ul_tti_request(void* pRecvMsg, int recvMsgLen, pnf_p7_t* pnf_p7) ...@@ -1788,7 +1788,7 @@ void pnf_handle_ul_tti_request(void* pRecvMsg, int recvMsgLen, pnf_p7_t* pnf_p7)
struct timespec t; struct timespec t;
clock_gettime(CLOCK_MONOTONIC, &t); clock_gettime(CLOCK_MONOTONIC, &t);
NFAPI_TRACE(NFAPI_TRACE_INFO,"%s() %ld.%09ld POPULATE UL_TTI_REQ current tx sfn/slot:%d.%d p7 msg sfn/slot: %d.%d buffer_index:%d\n", __FUNCTION__, t.tv_sec, t.tv_nsec, pnf_p7->sfn,pnf_p7->slot, req->SFN, req->Slot, buffer_index); NFAPI_TRACE(NFAPI_TRACE_DEBUG,"%s() %ld.%09ld POPULATE UL_TTI_REQ current tx sfn/slot:%d.%d p7 msg sfn/slot: %d.%d buffer_index:%d\n", __FUNCTION__, t.tv_sec, t.tv_nsec, pnf_p7->sfn,pnf_p7->slot, req->SFN, req->Slot, buffer_index);
if(pnf_p7->slot_buffer[buffer_index].ul_tti_req != 0) if(pnf_p7->slot_buffer[buffer_index].ul_tti_req != 0)
{ {
......
...@@ -128,6 +128,8 @@ void vnf_nr_handle_pnf_param_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_ ...@@ -128,6 +128,8 @@ void vnf_nr_handle_pnf_param_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_
if(config->pnf_nr_param_resp) if(config->pnf_nr_param_resp)
{ {
(config->pnf_nr_param_resp)(config, p5_idx, &msg); (config->pnf_nr_param_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no pnf_nr_param_resp cb installed\n", __func__);
} }
} }
else else
...@@ -161,6 +163,8 @@ void vnf_handle_pnf_param_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_con ...@@ -161,6 +163,8 @@ void vnf_handle_pnf_param_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_con
if(config->pnf_param_resp) if(config->pnf_param_resp)
{ {
(config->pnf_param_resp)(config, p5_idx, &msg); (config->pnf_param_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no pnf_params_resp cb installed\n", __func__);
} }
} }
else else
...@@ -195,6 +199,8 @@ void vnf_nr_handle_pnf_config_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf ...@@ -195,6 +199,8 @@ void vnf_nr_handle_pnf_config_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf
if(config->pnf_nr_config_resp) if(config->pnf_nr_config_resp)
{ {
(config->pnf_nr_config_resp)(config, p5_idx, &msg); (config->pnf_nr_config_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no pnf_nr_config_resp cb installed\n", __func__);
} }
} }
else else
...@@ -228,6 +234,8 @@ void vnf_handle_pnf_config_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_co ...@@ -228,6 +234,8 @@ void vnf_handle_pnf_config_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_co
if(config->pnf_config_resp) if(config->pnf_config_resp)
{ {
(config->pnf_config_resp)(config, p5_idx, &msg); (config->pnf_config_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no pnf_config_resp cb installed\n", __func__);
} }
} }
else else
...@@ -260,6 +268,8 @@ void vnf_nr_handle_pnf_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_ ...@@ -260,6 +268,8 @@ void vnf_nr_handle_pnf_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_
if(config->pnf_nr_start_resp) if(config->pnf_nr_start_resp)
{ {
(config->pnf_nr_start_resp)(config, p5_idx, &msg); (config->pnf_nr_start_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no pnf_nr_start_resp cb installed\n", __func__);
} }
} }
else else
...@@ -292,6 +302,8 @@ void vnf_handle_pnf_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_con ...@@ -292,6 +302,8 @@ void vnf_handle_pnf_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_con
if(config->pnf_start_resp) if(config->pnf_start_resp)
{ {
(config->pnf_start_resp)(config, p5_idx, &msg); (config->pnf_start_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no pnf_start_resp cb installed\n", __func__);
} }
} }
else else
...@@ -324,6 +336,8 @@ void vnf_handle_pnf_stop_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_conf ...@@ -324,6 +336,8 @@ void vnf_handle_pnf_stop_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_conf
if(config->pnf_stop_resp) if(config->pnf_stop_resp)
{ {
(config->pnf_stop_resp)(config, p5_idx, &msg); (config->pnf_stop_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no pnf_stop_resp cb installed\n", __func__);
} }
} }
else else
...@@ -564,6 +578,8 @@ void vnf_handle_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_config_ ...@@ -564,6 +578,8 @@ void vnf_handle_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_config_
if(config->start_resp) if(config->start_resp)
{ {
(config->start_resp)(config, p5_idx, &msg); (config->start_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no start_resp cb installed\n", __func__);
} }
} }
else else
...@@ -597,6 +613,8 @@ void vnf_nr_handle_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_conf ...@@ -597,6 +613,8 @@ void vnf_nr_handle_start_response(void *pRecvMsg, int recvMsgLen, nfapi_vnf_conf
if(config->nr_start_resp) if(config->nr_start_resp)
{ {
(config->nr_start_resp)(config, p5_idx, &msg); (config->nr_start_resp)(config, p5_idx, &msg);
} else {
NFAPI_TRACE(NFAPI_TRACE_ERROR, "%s(): no nr_start_resp cb installed\n", __func__);
} }
} }
} }
......
...@@ -2058,7 +2058,7 @@ void vnf_nr_handle_timing_info(void *pRecvMsg, int recvMsgLen, vnf_p7_t* vnf_p7) ...@@ -2058,7 +2058,7 @@ void vnf_nr_handle_timing_info(void *pRecvMsg, int recvMsgLen, vnf_p7_t* vnf_p7)
//printf("VNF-PNF delta - %d", vnf_pnf_sfnslot_delta); //printf("VNF-PNF delta - %d", vnf_pnf_sfnslot_delta);
if (vnf_pnf_sfnslot_delta != 0) if (vnf_pnf_sfnslot_delta != 0)
{ {
NFAPI_TRACE(NFAPI_TRACE_INFO, "%s() LARGE SFN/SLOT DELTA between PNF and VNF. Delta %d. PNF:%d.%d VNF:%d.%d\n\n\n\n\n\n\n\n\n", NFAPI_TRACE(NFAPI_TRACE_INFO, "%s() LARGE SFN/SLOT DELTA between PNF and VNF. Delta %d. PNF:%d.%d VNF:%d.%d\n",
__FUNCTION__, vnf_pnf_sfnslot_delta, __FUNCTION__, vnf_pnf_sfnslot_delta,
ind.last_sfn, ind.last_slot, ind.last_sfn, ind.last_slot,
vnf_p7->p7_connections[0].sfn, vnf_p7->p7_connections[0].slot); vnf_p7->p7_connections[0].sfn, vnf_p7->p7_connections[0].slot);
......
...@@ -608,6 +608,7 @@ void schedule_nr_sib1(module_id_t module_idP, ...@@ -608,6 +608,7 @@ void schedule_nr_sib1(module_id_t module_idP,
nfapi_nr_dl_tti_request_body_t *dl_req = &DL_req->dl_tti_request_body; nfapi_nr_dl_tti_request_body_t *dl_req = &DL_req->dl_tti_request_body;
int pdu_index = gNB_mac->pdu_index[0]++; int pdu_index = gNB_mac->pdu_index[0]++;
LOG_I(NR_MAC, "%s() %4d.%2d\n", __func__, frameP, slotP);
nr_fill_nfapi_dl_sib1_pdu(module_idP, dl_req, pdu_index, type0_PDCCH_CSS_config, TBS, tda_info.startSymbolIndex, tda_info.nrOfSymbols); nr_fill_nfapi_dl_sib1_pdu(module_idP, dl_req, pdu_index, type0_PDCCH_CSS_config, TBS, tda_info.startSymbolIndex, tda_info.nrOfSymbols);
const int ntx_req = TX_req->Number_of_PDUs; const int ntx_req = TX_req->Number_of_PDUs;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment