added pdu tstamp

master
Ismael Gomez 8 years ago
parent 5e030dc805
commit 80092fd888

@ -48,7 +48,7 @@ public:
uint8_t* request_buffer(uint32_t pid, uint32_t len); uint8_t* request_buffer(uint32_t pid, uint32_t len);
void deallocate(uint8_t* payload_buffer_ptr); void deallocate(uint8_t* payload_buffer_ptr);
void push_pdu(uint32_t pid, uint8_t *buff, uint32_t nof_bytes); void push_pdu(uint32_t pid, uint8_t *buff, uint32_t nof_bytes, uint32_t tstamp);
void push_pdu_temp_crnti(uint8_t *buff, uint32_t nof_bytes); void push_pdu_temp_crnti(uint8_t *buff, uint32_t nof_bytes);
void set_uecrid_callback(bool (*callback)(void*, uint64_t), void *arg); void set_uecrid_callback(bool (*callback)(void*, uint64_t), void *arg);

@ -117,10 +117,10 @@ void demux::push_pdu_temp_crnti(uint8_t *buff, uint32_t nof_bytes)
* This function enqueues the packet and returns quicly because ACK * This function enqueues the packet and returns quicly because ACK
* deadline is important here. * deadline is important here.
*/ */
void demux::push_pdu(uint32_t pid, uint8_t *buff, uint32_t nof_bytes) void demux::push_pdu(uint32_t pid, uint8_t *buff, uint32_t nof_bytes, uint32_t tstamp)
{ {
if (pid < NOF_HARQ_PID) { if (pid < NOF_HARQ_PID) {
return pdus.push(buff, nof_bytes); return pdus.push(buff, nof_bytes, tstamp);
} else if (pid == NOF_HARQ_PID) { } else if (pid == NOF_HARQ_PID) {
/* Demultiplexing of MAC PDU associated with SI-RNTI. The PDU passes through /* Demultiplexing of MAC PDU associated with SI-RNTI. The PDU passes through
* the MAC in transparent mode. * the MAC in transparent mode.

@ -300,7 +300,7 @@ void dl_harq_entity::dl_harq_process::tb_decoded(bool ack_)
harq_entity->pcap->write_dl_sirnti(payload_buffer_ptr, cur_grant.n_bytes, ack, cur_grant.tti); harq_entity->pcap->write_dl_sirnti(payload_buffer_ptr, cur_grant.n_bytes, ack, cur_grant.tti);
} }
Debug("Delivering PDU=%d bytes to Dissassemble and Demux unit (BCCH)\n", cur_grant.n_bytes); Debug("Delivering PDU=%d bytes to Dissassemble and Demux unit (BCCH)\n", cur_grant.n_bytes);
harq_entity->demux_unit->push_pdu(pid, payload_buffer_ptr, cur_grant.n_bytes); harq_entity->demux_unit->push_pdu(pid, payload_buffer_ptr, cur_grant.n_bytes, cur_grant.tti);
} else { } else {
if (harq_entity->pcap) { if (harq_entity->pcap) {
harq_entity->pcap->write_dl_crnti(payload_buffer_ptr, cur_grant.n_bytes, cur_grant.rnti, ack, cur_grant.tti); harq_entity->pcap->write_dl_crnti(payload_buffer_ptr, cur_grant.n_bytes, cur_grant.rnti, ack, cur_grant.tti);
@ -311,10 +311,10 @@ void dl_harq_entity::dl_harq_process::tb_decoded(bool ack_)
harq_entity->demux_unit->push_pdu_temp_crnti(payload_buffer_ptr, cur_grant.n_bytes); harq_entity->demux_unit->push_pdu_temp_crnti(payload_buffer_ptr, cur_grant.n_bytes);
} else { } else {
Debug("Delivering PDU=%d bytes to Dissassemble and Demux unit\n", cur_grant.n_bytes); Debug("Delivering PDU=%d bytes to Dissassemble and Demux unit\n", cur_grant.n_bytes);
harq_entity->demux_unit->push_pdu(pid, payload_buffer_ptr, cur_grant.n_bytes); harq_entity->demux_unit->push_pdu(pid, payload_buffer_ptr, cur_grant.n_bytes, cur_grant.tti);
// Compute average number of retransmissions per packet // Compute average number of retransmissions per packet
harq_entity->average_retx = SRSLTE_VEC_CMA((float) n_retx, harq_entity->average_retx, harq_entity->nof_pkts++); harq_entity->average_retx = SRSLTE_VEC_CMA((float) n_retx, harq_entity->average_retx, harq_entity->nof_pkts++);
} }
} }
} }

Loading…
Cancel
Save