Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Michael Black
OpenXG-RAN
Commits
cbe2da1c
Commit
cbe2da1c
authored
Mar 31, 2021
by
Raymond Knopp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OAI UE and eNB SA configuration up to reception of SIB1 and configuration of UE L1/L2 stack
parent
df05672a
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
40 additions
and
44 deletions
+40
-44
openair1/PHY/NR_TRANSPORT/nr_dlsch.c
openair1/PHY/NR_TRANSPORT/nr_dlsch.c
+2
-1
openair1/PHY/NR_TRANSPORT/nr_dlsch_coding.c
openair1/PHY/NR_TRANSPORT/nr_dlsch_coding.c
+1
-1
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
+3
-2
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_demodulation.c
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_demodulation.c
+18
-20
openair2/LAYER2/NR_MAC_UE/config_ue.c
openair2/LAYER2/NR_MAC_UE/config_ue.c
+2
-1
openair2/LAYER2/NR_MAC_UE/nr_ue_dci_configuration.c
openair2/LAYER2/NR_MAC_UE/nr_ue_dci_configuration.c
+1
-1
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
+6
-11
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
+1
-1
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_bch.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_bch.c
+3
-3
openair2/RRC/NR_UE/rrc_UE.c
openair2/RRC/NR_UE/rrc_UE.c
+3
-3
No files found.
openair1/PHY/NR_TRANSPORT/nr_dlsch.c
View file @
cbe2da1c
...
...
@@ -82,11 +82,12 @@ void nr_pdsch_codeword_scrambling_optim(uint8_t *in,
s
=
lte_gold_generic
(
&
x1
,
&
x2
,
1
);
#if defined(__AVX2__)
for
(
int
i
=
0
;
i
<
((
size
>>
5
)
+
((
size
&
0x1f
)
>
0
?
1
:
0
));
i
++
)
{
in32
=
_mm256_movemask_epi8
(
_mm256_slli_epi16
(((
__m256i
*
)
in
)[
i
],
7
));
out
[
i
]
=
(
in32
^
s
);
//
printf("in[%d] %x => %x\n",i,in32,out[i]);
//printf("in[%d] %x => %x\n",i,in32,out[i]);
s
=
lte_gold_generic
(
&
x1
,
&
x2
,
0
);
}
#elif defined(__SSE4__)
...
...
openair1/PHY/NR_TRANSPORT/nr_dlsch_coding.c
View file @
cbe2da1c
...
...
@@ -290,7 +290,7 @@ int nr_dlsch_encoding(PHY_VARS_gNB *gNB,
}
G
=
nr_get_G
(
nb_rb
,
nb_symb_sch
,
nb_re_dmrs
,
length_dmrs
,
mod_order
,
rel15
->
nrOfLayers
);
LOG_D
(
PHY
,
"dlsch coding A %d G %d
mod_order %d
\n
"
,
A
,
G
,
mod_order
);
LOG_D
(
PHY
,
"dlsch coding A %d G %d
(nb_rb %d, nb_symb_sch %d, nb_re_dmrs %d, length_dmrs %d, mod_order %d mod_order %d)
\n
"
,
A
,
G
,
nb_rb
,
nb_symb_sch
,
nb_re_dmrs
,
length_dmrs
,
mod_order
);
if
(
A
>
3824
)
{
// Add 24-bit crc (polynomial A) to payload
...
...
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
View file @
cbe2da1c
...
...
@@ -589,6 +589,8 @@ uint32_t nr_dlsch_decoding(PHY_VARS_NR_UE *phy_vars_ue,
else
{
LOG_D
(
PHY
,
"CRC NOT OK
\n\033
[0m"
);
ret
=
1
+
dlsch
->
max_ldpc_iterations
;
dump_nrdlsch
(
phy_vars_ue
,
0
,
nr_slot_rx
,
&
E
,
0
,
0
);
exit
(
-
1
);
}
...
...
@@ -702,7 +704,7 @@ uint32_t nr_dlsch_decoding(PHY_VARS_NR_UE *phy_vars_ue,
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_DLSCH_COMBINE_SEG
,
VCD_FUNCTION_OUT
);
dlsch
->
last_iteration_cnt
=
ret
;
log_dump
(
PHY
,
harq_process
->
b
,
60
,
LOG_DUMP_CHAR
,
"nrue pdsch rx frame %d %d: "
,
frame
,
nr_slot_rx
);
//
log_dump(PHY, harq_process->b, 60, LOG_DUMP_CHAR,"nrue pdsch rx frame %d %d: ", frame, nr_slot_rx );
return
(
ret
);
}
...
...
@@ -1123,7 +1125,6 @@ uint32_t nr_dlsch_decoding_mthread(PHY_VARS_NR_UE *phy_vars_ue,
ret
=
2
;
}
else
{
LOG_D
(
PHY
,
"CRC NOK
\n
"
);
ret
=
1
+
dlsch
->
max_ldpc_iterations
;
}
...
...
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_demodulation.c
View file @
cbe2da1c
...
...
@@ -3367,10 +3367,8 @@ static int nr_dlsch_llr(NR_UE_PDSCH **pdsch_vars,
}
//==============================================================================================
#ifdef USER_MODE
void
dump_dlsch2
(
PHY_VARS_UE
*
ue
,
uint8_t
gNB_id
,
uint8_t
nr_slot_rx
,
unsigned
int
*
coded_bits_per_codeword
,
int
round
,
unsigned
char
harq_pid
)
void
dump_nrdlsch
(
PHY_VARS_NR_UE
*
ue
,
uint8_t
gNB_id
,
uint8_t
nr_slot_rx
,
unsigned
int
*
coded_bits_per_codeword
,
int
round
,
unsigned
char
harq_pid
)
{
unsigned
int
nsymb
=
(
ue
->
frame_parms
.
Ncp
==
0
)
?
14
:
12
;
char
fname
[
32
],
vname
[
32
];
...
...
@@ -3378,50 +3376,50 @@ void dump_dlsch2(PHY_VARS_UE *ue,uint8_t gNB_id,uint8_t nr_slot_rx,unsigned int
snprintf
(
fname
,
32
,
"dlsch%d_rxF_r%d_ext0.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_rxF_r%d_ext0"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
rxdataF_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
rxdataF_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
if
(
ue
->
frame_parms
.
nb_antennas_rx
>
1
)
{
snprintf
(
fname
,
32
,
"dlsch%d_rxF_r%d_ext1.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_rxF_r%d_ext1"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
rxdataF_ext
[
1
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
rxdataF_ext
[
1
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
}
snprintf
(
fname
,
32
,
"dlsch%d_ch_r%d_ext00.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_ch_r%d_ext00"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_estimates_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_estimates_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
if
(
ue
->
transmission_mode
[
gNB_id
]
==
7
){
snprintf
(
fname
,
32
,
"dlsch%d_bf_ch_r%d.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_bf_ch_r%d"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_bf_ch_estimates
[
0
],
512
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_bf_ch_estimates
[
0
],
512
*
nsymb
,
1
,
1
);
//write_output(fname,vname,phy_vars_ue->lte_ue_pdsch_vars[gNB_id]->dl_bf_ch_estimates[0],512,1,1);
snprintf
(
fname
,
32
,
"dlsch%d_bf_ch_r%d_ext00.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_bf_ch_r%d_ext00"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_bf_ch_estimates_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_bf_ch_estimates_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
}
if
(
ue
->
frame_parms
.
nb_antennas_rx
==
2
)
{
snprintf
(
fname
,
32
,
"dlsch%d_ch_r%d_ext01.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_ch_r%d_ext01"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_estimates_ext
[
1
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_estimates_ext
[
1
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
}
if
(
ue
->
frame_parms
.
nb_antenna_ports_gNB
==
2
)
{
snprintf
(
fname
,
32
,
"dlsch%d_ch_r%d_ext10.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_ch_r%d_ext10"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_estimates_ext
[
2
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_estimates_ext
[
2
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
if
(
ue
->
frame_parms
.
nb_antennas_rx
==
2
)
{
snprintf
(
fname
,
32
,
"dlsch%d_ch_r%d_ext11.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_ch_r%d_ext11"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_estimates_ext
[
3
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_estimates_ext
[
3
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
}
}
snprintf
(
fname
,
32
,
"dlsch%d_rxF_r%d_uespec0.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_rxF_r%d_uespec0"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
rxdataF_uespec_pilots
[
0
],
12
*
N_RB_DL
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
rxdataF_uespec_pilots
[
0
],
12
*
N_RB_DL
,
1
,
1
);
/*
write_output("dlsch%d_ch_ext01.m","dl01_ch0_ext",pdsch_vars[gNB_id]->dl_ch_estimates_ext[1],12*N_RB_DL*nsymb,1,1);
...
...
@@ -3431,35 +3429,35 @@ void dump_dlsch2(PHY_VARS_UE *ue,uint8_t gNB_id,uint8_t nr_slot_rx,unsigned int
snprintf
(
fname
,
32
,
"dlsch%d_r%d_rho.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl_rho_r%d_%d"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_rho_ext
[
harq_pid
][
round
][
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_rho_ext
[
harq_pid
][
round
][
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
snprintf
(
fname
,
32
,
"dlsch%d_r%d_rho2.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl_rho2_r%d_%d"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_rho2_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_rho2_ext
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
snprintf
(
fname
,
32
,
"dlsch%d_rxF_r%d_comp0.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_rxF_r%d_comp0"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
rxdataF_comp0
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
rxdataF_comp0
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
if
(
ue
->
frame_parms
.
nb_antenna_ports_gNB
==
2
)
{
snprintf
(
fname
,
32
,
"dlsch%d_rxF_r%d_comp1.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_rxF_r%d_comp1"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
rxdataF_comp1
[
harq_pid
][
round
][
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
rxdataF_comp1
[
harq_pid
][
round
][
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
}
snprintf
(
fname
,
32
,
"dlsch%d_rxF_r%d_llr.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_r%d_llr"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
llr
[
0
],
coded_bits_per_codeword
[
0
],
1
,
0
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
llr
[
0
],
coded_bits_per_codeword
[
0
],
1
,
0
);
snprintf
(
fname
,
32
,
"dlsch%d_r%d_mag1.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_r%d_mag1"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_mag0
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_mag0
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
snprintf
(
fname
,
32
,
"dlsch%d_r%d_mag2.m"
,
gNB_id
,
round
);
snprintf
(
vname
,
32
,
"dl%d_r%d_mag2"
,
gNB_id
,
round
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
proc
->
thread_id
][
gNB_id
]
->
dl_ch_magb0
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
write_output
(
fname
,
vname
,
ue
->
pdsch_vars
[
0
][
gNB_id
]
->
dl_ch_magb0
[
0
],
12
*
N_RB_DL
*
nsymb
,
1
,
1
);
// printf("log2_maxh = %d\n",ue->pdsch_vars[gNB_id]->log2_maxh);
}
#endif
#ifdef DEBUG_DLSCH_DEMOD
/*
...
...
openair2/LAYER2/NR_MAC_UE/config_ue.c
View file @
cbe2da1c
...
...
@@ -347,7 +347,7 @@ void config_common_ue(NR_UE_MAC_INST_t *mac,
cfg
->
carrier_config
.
uplink_bandwidth
=
config_bandwidth
(
scc_SIB
->
uplinkConfigCommon
->
frequencyInfoUL
.
scs_SpecificCarrierList
.
list
.
array
[
0
]
->
subcarrierSpacing
,
scc_SIB
->
uplinkConfigCommon
->
frequencyInfoUL
.
scs_SpecificCarrierList
.
list
.
array
[
0
]
->
carrierBandwidth
,
*
scc_SIB
->
uplinkConfigCommon
->
frequencyInfoUL
.
frequencyBandList
->
list
.
array
[
0
]
->
freqBandIndicatorNR
);
scc_SIB
->
uplinkConfigCommon
->
frequencyInfoUL
.
frequencyBandList
==
NULL
?
*
scc_SIB
->
downlinkConfigCommon
.
frequencyInfoDL
.
frequencyBandList
.
list
.
array
[
0
]
->
freqBandIndicatorNR
:
*
scc_SIB
->
uplinkConfigCommon
->
frequencyInfoUL
.
frequencyBandList
->
list
.
array
[
0
]
->
freqBandIndicatorNR
);
if
(
scc_SIB
->
uplinkConfigCommon
->
frequencyInfoUL
.
absoluteFrequencyPointA
==
NULL
)
...
...
@@ -708,6 +708,7 @@ int nr_rrc_mac_config_req_ue(
mac
->
scc_SIB
=
sccP
;
LOG_I
(
MAC
,
"Keeping ServingCellConfigCommonSIB
\n
"
);
config_common_ue
(
mac
,
module_id
,
cc_idP
);
}
if
(
scell_group_config
!=
NULL
){
mac
->
cg
=
cell_group_config
;
...
...
openair2/LAYER2/NR_MAC_UE/nr_ue_dci_configuration.c
View file @
cbe2da1c
...
...
@@ -87,7 +87,7 @@ void config_dci_pdu(NR_UE_MAC_INST_t *mac, fapi_nr_dl_config_dci_dl_pdu_rel15_t
initialDownlinkBWP
=
scc
!=
NULL
?
scc
->
downlinkConfigCommon
->
initialDownlinkBWP
:
&
scc_SIB
->
downlinkConfigCommon
.
initialDownlinkBWP
;
initialUplinkBWP
=
scc
!=
NULL
?
scc
->
uplinkConfigCommon
->
initialUplinkBWP
:
&
scc_SIB
->
uplinkConfigCommon
->
initialUplinkBWP
;
bwp_Common
=
mac
->
DLbwp
[
bwp_id
-
1
]
->
bwp_Common
;
bwp_Common
=
bwp_id
>
0
?
mac
->
DLbwp
[
bwp_id
-
1
]
->
bwp_Common
:
NULL
;
}
NR_SearchSpace_t
*
ss
;
...
...
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
View file @
cbe2da1c
...
...
@@ -466,14 +466,9 @@ int8_t nr_ue_process_dci(module_id_t module_id, int cc_id, uint8_t gNB_index, fr
fapi_nr_dl_config_request_t
*
dl_config
=
&
mac
->
dl_config_request
;
uint8_t
is_Msg3
=
0
;
uint16_t
n_RB_DLBWP
;
if
(
mac
->
scc
!=
NULL
||
mac
->
scc_SIB
!=
NULL
)
{
AssertFatal
(
mac
->
DLbwp
[
0
]
!=
NULL
,
"DLbwp[0] should not be zero here!
\n
"
);
AssertFatal
(
mac
->
ULbwp
[
0
]
!=
NULL
,
"DLbwp[0] should not be zero here!
\n
"
);
n_RB_DLBWP
=
(
ra
->
ra_state
==
WAIT_RAR
||
ra
->
ra_state
==
WAIT_CONTENTION_RESOLUTION
)
?
NRRIV2BW
(
mac
->
scc
->
downlinkConfigCommon
->
initialDownlinkBWP
->
genericParameters
.
locationAndBandwidth
,
MAX_BWP_SIZE
)
:
NRRIV2BW
(
mac
->
DLbwp
[
0
]
->
bwp_Common
->
genericParameters
.
locationAndBandwidth
,
MAX_BWP_SIZE
);
}
else
n_RB_DLBWP
=
mac
->
type0_PDCCH_CSS_config
.
num_rbs
;
uint16_t
n_RB_DLBWP
=
(
mac
->
cg
)
?
NRRIV2BW
(
mac
->
DLbwp
[
0
]
->
bwp_Common
->
genericParameters
.
locationAndBandwidth
,
MAX_BWP_SIZE
)
:
mac
->
type0_PDCCH_CSS_config
.
num_rbs
;
LOG_D
(
MAC
,
"In %s: Processing received DCI format %s (DL BWP %d)
\n
"
,
__FUNCTION__
,
dci_formats
[
dci_format
],
n_RB_DLBWP
);
...
...
@@ -636,7 +631,7 @@ int8_t nr_ue_process_dci(module_id_t module_id, int cc_id, uint8_t gNB_index, fr
dl_config
->
dl_config_list
[
dl_config
->
number_pdus
].
dlsch_config_pdu
.
rnti
=
rnti
;
fapi_nr_dl_config_dlsch_pdu_rel15_t
*
dlsch_config_pdu_1_0
=
&
dl_config
->
dl_config_list
[
dl_config
->
number_pdus
].
dlsch_config_pdu
.
dlsch_config_rel15
;
NR_PDSCH_Config_t
*
pdsch_config
=
(
mac
->
scc
!=
NULL
||
mac
->
scc_SIB
!=
NULL
)
?
mac
->
DLbwp
[
0
]
->
bwp_Dedicated
->
pdsch_Config
->
choice
.
setup
:
NULL
;
NR_PDSCH_Config_t
*
pdsch_config
=
(
mac
->
cg
)
?
mac
->
DLbwp
[
0
]
->
bwp_Dedicated
->
pdsch_Config
->
choice
.
setup
:
NULL
;
uint16_t
BWPSize
=
0
;
if
(
rnti
==
SI_RNTI
)
{
...
...
@@ -739,7 +734,7 @@ int8_t nr_ue_process_dci(module_id_t module_id, int cc_id, uint8_t gNB_index, fr
dlsch_config_pdu_1_0
->
pucch_resource_id
=
dci
->
pucch_resource_indicator
;
// Sanity check for pucch_resource_indicator value received to check for false DCI.
valid
=
0
;
if
(
mac
->
scc
||
mac
->
scc_SIB
)
{
if
(
mac
->
cg
)
{
pucch_res_set_cnt
=
mac
->
ULbwp
[
0
]
->
bwp_Dedicated
->
pucch_Config
->
choice
.
setup
->
resourceSetToAddModList
->
list
.
count
;
for
(
int
id
=
0
;
id
<
pucch_res_set_cnt
;
id
++
)
{
if
(
dlsch_config_pdu_1_0
->
pucch_resource_id
<
mac
->
ULbwp
[
0
]
->
bwp_Dedicated
->
pucch_Config
->
choice
.
setup
->
resourceSetToAddModList
->
list
.
array
[
id
]
->
resourceList
.
list
.
count
)
{
...
...
@@ -755,7 +750,7 @@ int8_t nr_ue_process_dci(module_id_t module_id, int cc_id, uint8_t gNB_index, fr
}
/* PDSCH_TO_HARQ_FEEDBACK_TIME_IND (only if CRC scrambled by C-RNTI or CS-RNTI or new-RNTI)*/
if
(
mac
->
scc
||
mac
->
scc_SIB
)
{
if
(
mac
->
cg
)
{
dlsch_config_pdu_1_0
->
pdsch_to_harq_feedback_time_ind
=
mac
->
ULbwp
[
mac
->
UL_BWP_Id
-
1
]
->
bwp_Dedicated
->
pucch_Config
->
choice
.
setup
->
dl_DataToUL_ACK
->
list
.
array
[
dci
->
pdsch_to_harq_feedback_timing_indicator
.
val
][
0
];
}
LOG_D
(
MAC
,
"(nr_ue_procedures.c) rnti = %x dl_config->number_pdus = %d
\n
"
,
...
...
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
View file @
cbe2da1c
...
...
@@ -833,7 +833,7 @@ NR_UE_L2_STATE_t nr_ue_scheduler(nr_downlink_indication_t *dl_info, nr_uplink_in
fill_dci_search_candidates
(
ss0
,
rel15
);
dl_config
->
number_pdus
=
1
;
LOG_
I
(
MAC
,
"Calling fill_scheduled_response, type0_pdcch, num_pdus %d
\n
"
,
dl_config
->
number_pdus
);
LOG_
D
(
MAC
,
"Calling fill_scheduled_response, type0_pdcch, num_pdus %d
\n
"
,
dl_config
->
number_pdus
);
fill_scheduled_response
(
&
scheduled_response
,
dl_config
,
NULL
,
NULL
,
mod_id
,
cc_id
,
rx_frame
,
rx_slot
,
dl_info
->
thread_id
);
if
(
mac
->
if_module
!=
NULL
&&
mac
->
if_module
->
scheduled_response
!=
NULL
)
mac
->
if_module
->
scheduled_response
(
&
scheduled_response
);
...
...
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_bch.c
View file @
cbe2da1c
...
...
@@ -301,7 +301,7 @@ void schedule_control_sib1(module_id_t module_id,
TBS
=
nr_compute_tbs
(
nr_get_Qm_dl
(
gNB_mac
->
sched_ctrlCommon
->
mcs
,
gNB_mac
->
sched_ctrlCommon
->
mcsTableIdx
),
nr_get_code_rate_dl
(
gNB_mac
->
sched_ctrlCommon
->
mcs
,
gNB_mac
->
sched_ctrlCommon
->
mcsTableIdx
),
rbSize
,
nrOfSymbols
,
N_PRB_DMRS
*
dmrs_length
,
0
,
0
,
1
)
>>
3
;
}
while
(
rbSize
<
bwpSize
&&
!
vrb_map
[
rbStart
+
rbSize
]
&&
TBS
<
gNB_mac
->
sched_ctrlCommon
->
num_total_bytes
);
}
while
(
rbS
tart
+
rbS
ize
<
bwpSize
&&
!
vrb_map
[
rbStart
+
rbSize
]
&&
TBS
<
gNB_mac
->
sched_ctrlCommon
->
num_total_bytes
);
gNB_mac
->
sched_ctrlCommon
->
rbSize
=
rbSize
;
gNB_mac
->
sched_ctrlCommon
->
rbStart
=
0
;
...
...
@@ -380,7 +380,7 @@ void nr_fill_nfapi_dl_sib1_pdu(int Mod_idP,
pdsch_pdu_rel15
->
nrOfLayers
=
1
;
pdsch_pdu_rel15
->
transmissionScheme
=
0
;
pdsch_pdu_rel15
->
refPoint
=
1
;
pdsch_pdu_rel15
->
dmrsConfigType
=
gNB_mac
->
sched_ctrlCommon
->
active_bwp
->
bwp_Dedicated
->
pdsch_Config
->
choice
.
setup
->
dmrs_DownlinkForPDSCH_MappingTypeA
->
choice
.
setup
->
dmrs_Type
==
NULL
?
0
:
1
;
pdsch_pdu_rel15
->
dmrsConfigType
=
0
;
pdsch_pdu_rel15
->
dlDmrsScramblingId
=
*
scc
->
physCellId
;
pdsch_pdu_rel15
->
SCID
=
0
;
pdsch_pdu_rel15
->
numDmrsCdmGrpsNoData
=
gNB_mac
->
sched_ctrlCommon
->
numDmrsCdmGrpsNoData
;
...
...
@@ -395,7 +395,7 @@ void nr_fill_nfapi_dl_sib1_pdu(int Mod_idP,
pdsch_pdu_rel15
->
StartSymbolIndex
=
StartSymbolIndex
;
pdsch_pdu_rel15
->
NrOfSymbols
=
NrOfSymbols
;
pdsch_pdu_rel15
->
dlDmrsSymbPos
=
fill_dmrs_mask
(
bwp
->
bwp_Dedicated
->
pdsch_Config
->
choice
.
setup
,
scc
->
dmrs_TypeA_Position
,
pdsch_pdu_rel15
->
NrOfSymbols
,
pdsch_pdu_rel15
->
StartSymbolIndex
);
pdsch_pdu_rel15
->
dlDmrsSymbPos
=
fill_dmrs_mask
(
NULL
,
scc
->
dmrs_TypeA_Position
,
pdsch_pdu_rel15
->
NrOfSymbols
,
pdsch_pdu_rel15
->
StartSymbolIndex
);
LOG_D
(
MAC
,
"dlDmrsSymbPos = 0x%x
\n
"
,
pdsch_pdu_rel15
->
dlDmrsSymbPos
);
...
...
openair2/RRC/NR_UE/rrc_UE.c
View file @
cbe2da1c
...
...
@@ -1143,7 +1143,7 @@ int8_t nr_rrc_ue_decode_NR_BCCH_DL_SCH_Message(
NR_SIB1_t
*
sib1
=
NR_UE_rrc_inst
[
module_id
].
sib1
[
gNB_index
];
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_UE_DECODE_BCCH
,
VCD_FUNCTION_IN
);
if
(((
NR_UE_rrc_inst
[
module_id
].
Info
[
gNB_index
].
SIStatus
&
1
)
==
1
)
&&
// SIB1 received
if
(((
NR_UE_rrc_inst
[
module_id
].
Info
[
gNB_index
].
SIStatus
&
1
)
==
1
)
&&
sib1
->
si_SchedulingInfo
&&
// SIB1 received
(
NR_UE_rrc_inst
[
module_id
].
Info
[
gNB_index
].
SIcnt
==
sib1
->
si_SchedulingInfo
->
schedulingInfoList
.
list
.
count
))
{
// to prevent memory bloating
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_UE_DECODE_BCCH
,
VCD_FUNCTION_OUT
);
...
...
@@ -1194,16 +1194,16 @@ int8_t nr_rrc_ue_decode_NR_BCCH_DL_SCH_Message(
// FIXME: improve condition for the RA trigger
// Check for on-demand not broadcasted SI
check_requested_SI_List
(
module_id
,
NR_UE_rrc_inst
[
module_id
].
requested_SI_List
,
*
sib1
);
if
(
nr_rrc_get_state
(
module_id
)
=
=
RRC_STATE_IDLE_NR
)
{
if
(
nr_rrc_get_state
(
module_id
)
<
=
RRC_STATE_IDLE_NR
)
{
NR_UE_rrc_inst
[
module_id
].
ra_trigger
=
INITIAL_ACCESS_FROM_RRC_IDLE
;
// TODO: remove flag after full RA procedures implemented
// get_softmodem_params()->do_ra = 1;
nr_rrc_set_state
(
module_id
,
RRC_STATE_IDLE_NR
);
}
// take ServingCellConfigCommon and configure L1/L2
NR_UE_rrc_inst
[
module_id
].
servingCellConfigCommonSIB
=
sib1
->
servingCellConfigCommon
;
nr_rrc_mac_config_req_ue
(
module_id
,
0
,
0
,
NULL
,
sib1
->
servingCellConfigCommon
,
NULL
,
NULL
);
nr_rrc_ue_generate_ra_msg
(
module_id
,
gNB_index
);
AssertFatal
(
1
==
0
,
"Exiting here
\n
"
);
}
else
{
LOG_E
(
NR_RRC
,
"SIB1 not decoded
\n
"
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment