@@ -70,21 +70,21 @@ void cell_harq_repository<IsDl>::handle_harq_ack_timeout(harq_type& h, slot_poin
7070 // Only in non-NTN case, we log a warning.
7171 if (h.ack_on_timeout ) {
7272 // Case: Not all HARQ-ACKs were received, but at least one positive ACK was received.
73- logger.debug (" ue ={} h_id={}: Setting {} HARQ to \" ACKed\" state. Cause: HARQ-ACK wait timeout ({} slots) was "
73+ logger.debug (" rnti ={} h_id={}: Setting {} HARQ to \" ACKed\" state. Cause: HARQ-ACK wait timeout ({} slots) was "
7474 " reached with still missing PUCCH HARQ-ACKs. However, one positive ACK was received." ,
75- h.ue_idx ,
75+ h.rnti ,
7676 h.h_id ,
7777 IsDl ? " DL" : " UL" ,
7878 h.slot_ack_timeout - h.slot_ack );
7979 } else {
8080 // At least one of the expected ACKs went missing and we haven't received any positive ACK.
81- logger.warning (
82- " ue={} h_id={}: Discarding {} HARQ. Cause: HARQ-ACK wait timeout ({} slots) was reached, but there are still "
83- " missing HARQ-ACKs and none of the received ones are positive." ,
84- h. ue_idx ,
85- h.h_id ,
86- IsDl ? " DL" : " UL" ,
87- h.slot_ack_timeout - h.slot_ack );
81+ logger.warning (" rnti={} h_id={}: Discarding {} HARQ. Cause: HARQ-ACK wait timeout ({} slots) was reached, but "
82+ " there are still "
83+ " missing HARQ-ACKs and none of the received ones are positive." ,
84+ h. rnti ,
85+ h.h_id ,
86+ IsDl ? " DL" : " UL" ,
87+ h.slot_ack_timeout - h.slot_ack );
8888 }
8989
9090 // Report timeout with NACK.
@@ -103,6 +103,7 @@ unsigned cell_harq_repository<IsDl>::get_harq_ref_idx(const harq_type& h) const
103103
104104template <bool IsDl>
105105typename cell_harq_repository<IsDl>::harq_type* cell_harq_repository<IsDl>::alloc_harq(du_ue_index_t ue_idx,
106+ rnti_t rnti,
106107 slot_point sl_tx,
107108 slot_point sl_ack,
108109 unsigned max_nof_harq_retxs)
@@ -124,6 +125,7 @@ typename cell_harq_repository<IsDl>::harq_type* cell_harq_repository<IsDl>::allo
124125
125126 // Set allocated HARQ common params.
126127 h.ue_idx = ue_idx;
128+ h.rnti = rnti;
127129 h.h_id = h_id;
128130 h.status = harq_state_t ::waiting_ack;
129131 h.slot_tx = sl_tx;
@@ -174,16 +176,16 @@ void cell_harq_repository<IsDl>::handle_ack(harq_type& h, bool ack)
174176{
175177 if (not ack and h.nof_retxs >= h.max_nof_harq_retxs ) {
176178 if (h.retxs_cancelled ) {
177- logger.info (
178- " ue={} h_id={}: Discarding {} HARQ process TB with tbs={}. Cause: Retxs for this HARQ process were cancelled" ,
179- h. ue_idx ,
180- h.h_id ,
181- IsDl ? " DL" : " UL" ,
182- h.prev_tx_params .tbs_bytes );
179+ logger.info (" rnti={} h_id={}: Discarding {} HARQ process TB with tbs={}. Cause: Retxs for this HARQ process were "
180+ " cancelled" ,
181+ h. rnti ,
182+ h.h_id ,
183+ IsDl ? " DL" : " UL" ,
184+ h.prev_tx_params .tbs_bytes );
183185 } else {
184186 logger.info (
185- " ue ={} h_id={}: Discarding {} HARQ process TB with tbs={}. Cause: Maximum number of reTxs {} exceeded" ,
186- h.ue_idx ,
187+ " rnti ={} h_id={}: Discarding {} HARQ process TB with tbs={}. Cause: Maximum number of reTxs {} exceeded" ,
188+ h.rnti ,
187189 h.h_id ,
188190 IsDl ? " DL" : " UL" ,
189191 h.prev_tx_params .tbs_bytes ,
@@ -223,7 +225,7 @@ template <bool IsDl>
223225bool cell_harq_repository<IsDl>::handle_new_retx(harq_type& h, slot_point sl_tx, slot_point sl_ack)
224226{
225227 if (h.status != harq_state_t ::pending_retx) {
226- logger.warning (" ue ={} h_id={}: Attempt of retx in a HARQ process that has no pending retx" , h.ue_idx , h.h_id );
228+ logger.warning (" rnti ={} h_id={}: Attempt of retx in a HARQ process that has no pending retx" , h.rnti , h.h_id );
227229 return false ;
228230 }
229231
@@ -338,12 +340,13 @@ void cell_harq_manager::destroy_ue(du_ue_index_t ue_idx)
338340}
339341
340342harq_utils::dl_harq_process_impl* cell_harq_manager::new_dl_tx (du_ue_index_t ue_idx,
343+ rnti_t rnti,
341344 slot_point pdsch_slot,
342345 unsigned k1,
343346 unsigned max_harq_nof_retxs,
344347 uint8_t harq_bit_idx)
345348{
346- dl_harq_process_impl* h = dl.alloc_harq (ue_idx, pdsch_slot, pdsch_slot + k1, max_harq_nof_retxs);
349+ dl_harq_process_impl* h = dl.alloc_harq (ue_idx, rnti, pdsch_slot, pdsch_slot + k1, max_harq_nof_retxs);
347350 if (h == nullptr ) {
348351 return nullptr ;
349352 }
@@ -359,9 +362,9 @@ harq_utils::dl_harq_process_impl* cell_harq_manager::new_dl_tx(du_ue_index_t ue_
359362}
360363
361364harq_utils::ul_harq_process_impl*
362- cell_harq_manager::new_ul_tx (du_ue_index_t ue_idx, slot_point pusch_slot, unsigned max_harq_nof_retxs)
365+ cell_harq_manager::new_ul_tx (du_ue_index_t ue_idx, rnti_t rnti, slot_point pusch_slot, unsigned max_harq_nof_retxs)
363366{
364- ul_harq_process_impl* h = ul.alloc_harq (ue_idx, pusch_slot, pusch_slot, max_harq_nof_retxs);
367+ ul_harq_process_impl* h = ul.alloc_harq (ue_idx, rnti, pusch_slot, pusch_slot, max_harq_nof_retxs);
365368 if (h == nullptr ) {
366369 return nullptr ;
367370 }
@@ -400,7 +403,7 @@ dl_harq_process_impl::status_update cell_harq_manager::dl_ack_info(harq_utils::d
400403
401404 if (h.status != harq_state_t ::waiting_ack) {
402405 // If the HARQ process is not expecting an HARQ-ACK, it means that it has already been ACKed/NACKed.
403- logger.warning (" ue ={} h_id={}: ACK arrived for inactive DL HARQ" , h.ue_idx , h.h_id );
406+ logger.warning (" rnti ={} h_id={}: ACK arrived for inactive DL HARQ" , h.rnti , h.h_id );
404407 return status_update::error;
405408 }
406409
@@ -437,7 +440,7 @@ int cell_harq_manager::ul_crc_info(harq_utils::ul_harq_process_impl& h, bool ack
437440{
438441 if (h.status != harq_state_t ::waiting_ack) {
439442 // HARQ is not expecting CRC info.
440- logger.warning (" ue ={} h_id={}: CRC arrived for UL HARQ not expecting it" , h.ue_idx , h.h_id );
443+ logger.warning (" rnti ={} h_id={}: CRC arrived for UL HARQ not expecting it" , h.rnti , h.h_id );
441444 return -1 ;
442445 }
443446
@@ -533,6 +536,11 @@ void ul_harq_process_view::save_grant_params(const ul_harq_sched_context& ctx, c
533536
534537// UE HARQ entity.
535538
539+ unique_ue_harq_entity::unique_ue_harq_entity (cell_harq_manager* mgr, du_ue_index_t ue_idx, rnti_t crnti_) :
540+ cell_harq_mgr(mgr), ue_index(ue_idx), crnti(crnti_)
541+ {
542+ }
543+
536544unique_ue_harq_entity::unique_ue_harq_entity (unique_ue_harq_entity&& other) noexcept :
537545 cell_harq_mgr(other.cell_harq_mgr), ue_index(other.ue_index)
538546{
@@ -570,7 +578,7 @@ void unique_ue_harq_entity::reset()
570578std::optional<dl_harq_process_view>
571579unique_ue_harq_entity::alloc_dl_harq (slot_point sl_tx, unsigned k1, unsigned max_harq_nof_retxs, unsigned harq_bit_idx)
572580{
573- dl_harq_process_impl* h = cell_harq_mgr->new_dl_tx (ue_index, sl_tx, k1, max_harq_nof_retxs, harq_bit_idx);
581+ dl_harq_process_impl* h = cell_harq_mgr->new_dl_tx (ue_index, crnti, sl_tx, k1, max_harq_nof_retxs, harq_bit_idx);
574582 if (h == nullptr ) {
575583 return std::nullopt ;
576584 }
@@ -579,7 +587,7 @@ unique_ue_harq_entity::alloc_dl_harq(slot_point sl_tx, unsigned k1, unsigned max
579587
580588std::optional<ul_harq_process_view> unique_ue_harq_entity::alloc_ul_harq (slot_point sl_tx, unsigned max_harq_nof_retxs)
581589{
582- ul_harq_process_impl* h = cell_harq_mgr->new_ul_tx (ue_index, sl_tx, max_harq_nof_retxs);
590+ ul_harq_process_impl* h = cell_harq_mgr->new_ul_tx (ue_index, crnti, sl_tx, max_harq_nof_retxs);
583591 if (h == nullptr ) {
584592 return std::nullopt ;
585593 }
0 commit comments