Commit ded3618f authored by Jaroslava Fiedlerova's avatar Jaroslava Fiedlerova

Merge remote-tracking branch 'origin/NR_UE_fix_wrong_use_asn_sequence_del'...

Merge remote-tracking branch 'origin/NR_UE_fix_wrong_use_asn_sequence_del' into integration_2024_w13
parents 4d25ee95 4a3beb0b
......@@ -779,11 +779,8 @@ static void configure_logicalChannelBearer(NR_UE_MAC_INST_t *mac,
if (id == mac->lc_ordered_list.array[j]->lcid)
break;
}
if (j < mac->lc_ordered_list.count) {
nr_lcordered_info_t *lc_info = mac->lc_ordered_list.array[j];
asn_sequence_del(&mac->lc_ordered_list, j, 0);
free(lc_info);
}
if (j < mac->lc_ordered_list.count)
asn_sequence_del(&mac->lc_ordered_list, j, 1);
else
LOG_E(NR_MAC, "Element not present in the list, impossible to release\n");
}
......@@ -1302,10 +1299,10 @@ static void configure_dedicated_BWP_dl(NR_UE_MAC_INST_t *mac, int bwp_id, NR_BWP
}
if (dl_dedicated->pdcch_Config) {
if (dl_dedicated->pdcch_Config->present == NR_SetupRelease_PDCCH_Config_PR_release) {
for (int i = 0; pdcch->list_Coreset.count; i++)
asn_sequence_del(&pdcch->list_Coreset, i, 1);
for (int i = 0; pdcch->list_SS.count; i++)
asn_sequence_del(&pdcch->list_SS, i, 1);
for (int i = pdcch->list_Coreset.count; i > 0 ; i--)
asn_sequence_del(&pdcch->list_Coreset, i - 1, 1);
for (int i = pdcch->list_SS.count; i > 0 ; i--)
asn_sequence_del(&pdcch->list_SS, i - 1, 1);
}
if (dl_dedicated->pdcch_Config->present == NR_SetupRelease_PDCCH_Config_PR_setup)
configure_ss_coreset(pdcch, dl_dedicated->pdcch_Config->choice.setup);
......@@ -2060,10 +2057,10 @@ void release_dl_BWP(NR_UE_MAC_INST_t *mac, int index)
NR_BWP_PDCCH_t *pdcch = &mac->config_BWP_PDCCH[bwp_id];
release_common_ss_cset(pdcch);
for (int i = 0; pdcch->list_Coreset.count; i++)
asn_sequence_del(&pdcch->list_Coreset, i, 1);
for (int i = 0; pdcch->list_SS.count; i++)
asn_sequence_del(&pdcch->list_SS, i, 1);
for (int i = pdcch->list_Coreset.count; i > 0 ; i--)
asn_sequence_del(&pdcch->list_Coreset, i - 1, 1);
for (int i = pdcch->list_SS.count; i > 0 ; i--)
asn_sequence_del(&pdcch->list_SS, i - 1, 1);
}
void release_ul_BWP(NR_UE_MAC_INST_t *mac, int index)
......
......@@ -231,11 +231,8 @@ void release_mac_configuration(NR_UE_MAC_INST_t *mac,
asn1cFreeStruc(asn_DEF_NR_ControlResourceSet, mac->coreset0);
asn1cFreeStruc(asn_DEF_NR_SI_SchedulingInfo, mac->si_SchedulingInfo);
asn1cFreeStruc(asn_DEF_NR_TDD_UL_DL_ConfigCommon, mac->tdd_UL_DL_ConfigurationCommon);
for (int i = 0; i < mac->lc_ordered_list.count; i++) {
nr_lcordered_info_t *lc_info = mac->lc_ordered_list.array[i];
asn_sequence_del(&mac->lc_ordered_list, i, 0);
free(lc_info);
}
for (int i = mac->lc_ordered_list.count; i > 0 ; i--)
asn_sequence_del(&mac->lc_ordered_list, i - 1, 1);
}
asn1cFreeStruc(asn_DEF_NR_CrossCarrierSchedulingConfig, sc->crossCarrierSchedulingConfig);
......@@ -263,10 +260,10 @@ void release_mac_configuration(NR_UE_MAC_INST_t *mac,
// release dedicated BWP0 config
NR_UE_DL_BWP_t *bwp = mac->dl_BWPs.array[0];
NR_BWP_PDCCH_t *pdcch = &mac->config_BWP_PDCCH[0];
for (int i = 0; pdcch->list_Coreset.count; i++)
asn_sequence_del(&pdcch->list_Coreset, i, 1);
for (int i = 0; pdcch->list_SS.count; i++)
asn_sequence_del(&pdcch->list_SS, i, 1);
for (int i = pdcch->list_Coreset.count; i > 0 ; i--)
asn_sequence_del(&pdcch->list_Coreset, i - 1, 1);
for (int i = pdcch->list_SS.count; i > 0 ; i--)
asn_sequence_del(&pdcch->list_SS, i - 1, 1);
asn1cFreeStruc(asn_DEF_NR_PDSCH_Config, bwp->pdsch_Config);
NR_UE_UL_BWP_t *ubwp = mac->ul_BWPs.array[0];
asn1cFreeStruc(asn_DEF_NR_PUCCH_Config, ubwp->pucch_Config);
......
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