nr: add MAC PDU traces for wireshark
The T tracer macpdu2wireshark has been modified to handle the new traces. The usage is the same as for LTE. In NR the RACH is logged as an LTE RACH. Maybe we'll change that in the future. Looking at the source code of wireshark, I could not find any way to report NR RACH. Maybe they forgot it. Or I did not search correctly...
This commit is contained in:
@@ -921,6 +921,10 @@ void nr_generate_Msg2(module_id_t module_idP,
|
||||
nr_mac->TX_req[CC_id].Slot = slotP;
|
||||
memcpy((void*)&tx_req->TLVs[0].value.direct[0], (void*)&cc[CC_id].RAR_pdu.payload[0], tx_req->TLVs[0].length);
|
||||
|
||||
T(T_GNB_MAC_DL_RAR_PDU_WITH_DATA, T_INT(module_idP), T_INT(CC_id),
|
||||
T_INT(RA_rnti), T_INT(frameP), T_INT(slotP), T_INT(0) /* harq pid, meaningful? */,
|
||||
T_BUFFER(&cc[CC_id].RAR_pdu.payload[0], tx_req->TLVs[0].length));
|
||||
|
||||
/* mark the corresponding RBs as used */
|
||||
uint8_t *vrb_map = cc[CC_id].vrb_map;
|
||||
for (int rb = 0; rb < pdsch_pdu_rel15->rbSize; rb++)
|
||||
|
||||
@@ -804,6 +804,9 @@ void nr_schedule_ue_spec(module_id_t module_id,
|
||||
retInfo->mcs = sched_ctrl->mcs;
|
||||
retInfo->numDmrsCdmGrpsNoData = sched_ctrl->numDmrsCdmGrpsNoData;
|
||||
|
||||
T(T_GNB_MAC_DL_PDU_WITH_DATA, T_INT(module_id), T_INT(CC_id), T_INT(rnti),
|
||||
T_INT(frame), T_INT(slot), T_INT(current_harq_pid), T_BUFFER(buf, TBS));
|
||||
|
||||
#if defined(ENABLE_MAC_PAYLOAD_DEBUG)
|
||||
if (frame%100 == 0) {
|
||||
LOG_I(MAC,
|
||||
|
||||
@@ -324,6 +324,12 @@ void nr_rx_sdu(const module_id_t gnb_mod_idP,
|
||||
|
||||
NR_RA_t *ra = &gNB_mac->common_channels[CC_idP].ra[0];
|
||||
|
||||
if (sduP != NULL) {
|
||||
T(T_GNB_MAC_UL_PDU_WITH_DATA, T_INT(gnb_mod_idP), T_INT(CC_idP),
|
||||
T_INT(rntiP), T_INT(frameP), T_INT(slotP), T_INT(-1) /* harq_pid */,
|
||||
T_BUFFER(sduP, sdu_lenP));
|
||||
}
|
||||
|
||||
// random access pusch with TC-RNTI
|
||||
if (ra->state == WAIT_Msg3) {
|
||||
if (sduP != NULL) { // if the CRC passed
|
||||
|
||||
Reference in New Issue
Block a user