Commit 6d413e2c authored by cig's avatar cig

Bugfix returning null pointer to prach resources

parent 3bb1407e
...@@ -109,7 +109,6 @@ void nr_get_prach_resources(module_id_t mod_id, ...@@ -109,7 +109,6 @@ void nr_get_prach_resources(module_id_t mod_id,
// // - available SSB with SS-RSRP above rsrp-ThresholdSSB: SSB selection // // - available SSB with SS-RSRP above rsrp-ThresholdSSB: SSB selection
// // - availalbe CSI-RS with CSI-RSRP above rsrp-ThresholdCSI-RS: CSI-RS selection // // - availalbe CSI-RS with CSI-RSRP above rsrp-ThresholdCSI-RS: CSI-RS selection
// prach_resources->ra_PreambleIndex = rach_ConfigDedicated->ra_PreambleIndex; // prach_resources->ra_PreambleIndex = rach_ConfigDedicated->ra_PreambleIndex;
// return;
// } // }
//////////* Contention-based RA preamble selection *////////// //////////* Contention-based RA preamble selection *//////////
...@@ -503,8 +502,6 @@ void nr_ue_get_rach(NR_PRACH_RESOURCES_t *prach_resources, ...@@ -503,8 +502,6 @@ void nr_ue_get_rach(NR_PRACH_RESOURCES_t *prach_resources,
for (int j = 0; j < (TBS_bytes - offset); j++) for (int j = 0; j < (TBS_bytes - offset); j++)
payload[offset + j] = 0; // mac_pdu[offset + j] = 0; payload[offset + j] = 0; // mac_pdu[offset + j] = 0;
} }
return;
} }
} else { // RACH is active } else { // RACH is active
...@@ -603,13 +600,11 @@ void nr_ue_get_rach(NR_PRACH_RESOURCES_t *prach_resources, ...@@ -603,13 +600,11 @@ void nr_ue_get_rach(NR_PRACH_RESOURCES_t *prach_resources,
mac->RA_tx_subframe = nr_tti_tx; mac->RA_tx_subframe = nr_tti_tx;
// Fill in preamble and PRACH resources // Fill in preamble and PRACH resources
nr_get_prach_resources(mod_id, CC_id, gNB_id, nr_tti_tx, 0, prach_resources, NULL); nr_get_prach_resources(mod_id, CC_id, gNB_id, nr_tti_tx, 0, prach_resources, NULL);
return;
} }
} }
} else if (UE_mode == PUSCH) { } else if (UE_mode == PUSCH) {
LOG_D(MAC, "[UE %d] FATAL: Should not have checked for RACH in PUSCH yet ...", mod_id); LOG_D(MAC, "[UE %d] FATAL: Should not have checked for RACH in PUSCH yet ...", mod_id);
AssertFatal(1 == 0, ""); AssertFatal(1 == 0, "");
} }
prach_resources = NULL;
return; return;
} }
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