Commit b875f855 authored by Romain Beurdouche's avatar Romain Beurdouche

fix(nr_dlsch): symbol offset calculation

There was an indexing error in the calculation of the symbol offset `re_beginning_of_symbol`.
The symbol was tested to hold PTRS or DMRS based on the index of the
first symbol processed in the task and not based on the index of the
symbol as it should be.
Then PDSCH generation was not working properly for more than one symbol
per task.
parent bad2ae87
......@@ -743,12 +743,12 @@ static int do_one_dlsch(unsigned char *input_ptr, PHY_VARS_gNB *gNB, NR_gNB_DLSC
rdata->dlPtrsSymPos = dlPtrsSymPos;
rdata->n_ptrs = n_ptrs;
rdata->beam_nb = beam_nb;
for (int s = 0; s < rdata->numSymbols; s++) {
rdata->re_beginning_of_symbol[l_symbol + s] = re_beginning_of_symbol;
for (int s = l_symbol; s < l_symbol + rdata->numSymbols; s++) {
rdata->re_beginning_of_symbol[s] = re_beginning_of_symbol;
re_beginning_of_symbol += rel15->rbSize * NR_NB_SC_PER_RB;
if (n_ptrs > 0 && is_ptrs_symbol(l_symbol, dlPtrsSymPos)) {
if (n_ptrs > 0 && is_ptrs_symbol(s, dlPtrsSymPos)) {
re_beginning_of_symbol -= n_ptrs;
} else if (rel15->dlDmrsSymbPos & (1 << l_symbol)) {
} else if (rel15->dlDmrsSymbPos & (1 << s)) {
re_beginning_of_symbol -= n_dmrs;
}
}
......
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