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
spbro
OpenXG-RAN
Commits
348343be
Commit
348343be
authored
Sep 13, 2019
by
Florian Kaltenberger
Committed by
Florian Kaltenberger
Sep 20, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
the gNB scheduler now schedules both UL and DL
parent
04ea6a48
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
60 additions
and
118 deletions
+60
-118
executables/nr-gnb.c
executables/nr-gnb.c
+3
-4
executables/nr-ue.c
executables/nr-ue.c
+2
-2
openair1/PHY/NR_TRANSPORT/nr_dlsch_tools.c
openair1/PHY/NR_TRANSPORT/nr_dlsch_tools.c
+1
-1
openair1/PHY/NR_TRANSPORT/nr_ulsch_decoding.c
openair1/PHY/NR_TRANSPORT/nr_ulsch_decoding.c
+8
-7
openair1/PHY/NR_TRANSPORT/nr_ulsch_demodulation.c
openair1/PHY/NR_TRANSPORT/nr_ulsch_demodulation.c
+2
-2
openair1/SCHED_NR/phy_procedures_nr_gNB.c
openair1/SCHED_NR/phy_procedures_nr_gNB.c
+13
-6
openair1/SCHED_NR/sched_nr.h
openair1/SCHED_NR/sched_nr.h
+1
-1
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
+21
-90
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
+3
-1
openair2/NR_PHY_INTERFACE/NR_IF_Module.c
openair2/NR_PHY_INTERFACE/NR_IF_Module.c
+4
-2
targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf
.../GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf
+2
-2
No files found.
executables/nr-gnb.c
View file @
348343be
...
...
@@ -193,10 +193,6 @@ static inline int rxtx(PHY_VARS_gNB *gNB,int frame_rx, int slot_rx, int frame_tx
// UE-specific RX processing for subframe n
if (nfapi_mode == 0 || nfapi_mode == 1) */
if
(
slot_rx
==
NR_UPLINK_SLOT
||
gNB
->
frame_parms
.
frame_type
==
FDD
)
{
nfapi_nr_ul_config_ulsch_pdu_rel15_t
*
ulsch_pdu_rel15
=
&
gNB
->
ulsch
[
1
][
0
]
->
harq_processes
[
0
]
->
ulsch_pdu
.
ulsch_pdu_rel15
;
phy_procedures_gNB_uespec_RX
(
gNB
,
frame_rx
,
slot_rx
,
ulsch_pdu_rel15
->
start_symbol
,
ulsch_pdu_rel15
->
start_symbol
+
ulsch_pdu_rel15
->
number_symbols
);
}
pthread_mutex_lock
(
&
gNB
->
UL_INFO_mutex
);
gNB
->
UL_INFO
.
frame
=
frame_rx
;
...
...
@@ -216,6 +212,9 @@ static inline int rxtx(PHY_VARS_gNB *gNB,int frame_rx, int slot_rx, int frame_tx
if
(
oai_exit
)
return
(
-
1
);
//if (slot_rx == NR_UPLINK_SLOT || gNB->frame_parms.frame_type == FDD)
phy_procedures_gNB_uespec_RX
(
gNB
,
frame_rx
,
slot_rx
);
if
(
get_thread_parallel_conf
()
!=
PARALLEL_RU_L1_TRX_SPLIT
)
{
phy_procedures_gNB_TX
(
gNB
,
frame_tx
,
slot_tx
,
1
);
}
...
...
executables/nr-ue.c
View file @
348343be
...
...
@@ -699,7 +699,7 @@ void *UE_thread(void *arg) {
slot_nr
*
UE
->
frame_parms
.
samples_per_slot
];
for
(
int
i
=
0
;
i
<
UE
->
frame_parms
.
nb_antennas_tx
;
i
++
)
txp
[
i
]
=
(
void
*
)
&
UE
->
common_vars
.
txdata
[
i
][((
curMsg
->
proc
.
nr_tti_rx
+
2
)
%
nb_slot_frame
)
*
UE
->
frame_parms
.
samples_per_slot
];
txp
[
i
]
=
(
void
*
)
&
UE
->
common_vars
.
txdata
[
i
][((
curMsg
->
proc
.
nr_tti_rx
+
4
)
%
nb_slot_frame
)
*
UE
->
frame_parms
.
samples_per_slot
];
int
readBlockSize
,
writeBlockSize
;
...
...
@@ -725,7 +725,7 @@ void *UE_thread(void *arg) {
AssertFatal
(
writeBlockSize
==
UE
->
rfdevice
.
trx_write_func
(
&
UE
->
rfdevice
,
timestamp
+
(
2
*
UE
->
frame_parms
.
samples_per_slot
)
-
(
4
*
UE
->
frame_parms
.
samples_per_slot
)
-
UE
->
frame_parms
.
ofdm_symbol_size
-
UE
->
frame_parms
.
nb_prefix_samples0
-
openair0_cfg
[
0
].
tx_sample_advance
,
txp
,
...
...
openair1/PHY/NR_TRANSPORT/nr_dlsch_tools.c
View file @
348343be
...
...
@@ -316,7 +316,7 @@ void nr_fill_ulsch(PHY_VARS_gNB *gNB,
nfapi_nr_pusch_pdu_t
*
ulsch_pdu
)
{
int
ulsch_id
=
find_nr_ulsch
(
ulsch_pdu
->
rnti
,
gNB
,
SEARCH_EXIST
);
int
ulsch_id
=
find_nr_ulsch
(
ulsch_pdu
->
rnti
,
gNB
,
SEARCH_EXIST
_OR_FREE
);
AssertFatal
(
(
ulsch_id
>=
0
)
&&
(
ulsch_id
<
NUMBER_OF_NR_ULSCH_MAX
),
"illegal or no ulsch_id found!!! rnti %04x ulsch_id %d
\n
"
,
ulsch_pdu
->
rnti
,
ulsch_id
);
...
...
openair1/PHY/NR_TRANSPORT/nr_ulsch_decoding.c
View file @
348343be
...
...
@@ -48,6 +48,7 @@
#include "common/utils/LOG/log.h"
#include <syscall.h>
//#define DEBUG_ULSCH_DECODING
#define gNB_DEBUG_TRACE
#define OAI_UL_LDPC_MAX_NUM_LLR 27000//26112 // NR_LDPC_NCOL_BG1*NR_LDPC_ZMAX = 68*384
#define PRINT_CRC_CHECK
...
...
@@ -298,7 +299,7 @@ uint32_t nr_ulsch_decoding(PHY_VARS_gNB *phy_vars_gNB,
#endif
NR_gNB_ULSCH_t
*
ulsch
=
phy_vars_gNB
->
ulsch
[
UE_id
+
1
][
0
];
NR_gNB_ULSCH_t
*
ulsch
=
phy_vars_gNB
->
ulsch
[
UE_id
][
0
];
NR_UL_gNB_HARQ_t
*
harq_process
=
ulsch
->
harq_processes
[
harq_pid
];
nfapi_nr_ul_config_ulsch_pdu_rel15_t
*
nfapi_ulsch_pdu_rel15
=
&
harq_process
->
ulsch_pdu
.
ulsch_pdu_rel15
;
...
...
@@ -643,9 +644,9 @@ uint32_t nr_ulsch_decoding(PHY_VARS_gNB *phy_vars_gNB,
if
(
err_flag
==
1
)
{
#if gNB_DEBUG_TRACE
LOG_I
(
PHY
,
"[gNB %d] ULSCH: Setting NAK for SFN/SF %d/%d (pid %d, status %d, round %d, TBS %d
, mcs %d
) Kr %d r %d harq_process->round %d
\n
"
,
phy_vars_gNB
->
Mod_id
,
frame
,
nr_tti_rx
,
harq_pid
,
harq_process
->
status
,
harq_process
->
round
,
harq_process
->
TBS
,
harq_process
->
mcs
,
Kr
,
r
,
harq_process
->
round
);
#if
def
gNB_DEBUG_TRACE
LOG_I
(
PHY
,
"[gNB %d] ULSCH: Setting NAK for SFN/SF %d/%d (pid %d, status %d, round %d, TBS %d) Kr %d r %d harq_process->round %d
\n
"
,
phy_vars_gNB
->
Mod_id
,
frame
,
nr_tti_rx
,
harq_pid
,
harq_process
->
status
,
harq_process
->
round
,
harq_process
->
TBS
,
Kr
,
r
,
harq_process
->
round
);
#endif
// harq_process->harq_ack.ack = 0;
...
...
@@ -671,9 +672,9 @@ uint32_t nr_ulsch_decoding(PHY_VARS_gNB *phy_vars_gNB,
}
else
{
#if gNB_DEBUG_TRACE
LOG_I
(
PHY
,
"[gNB %d] ULSCH: Setting ACK for nr_tti_rx %d TBS %d
mcs %d nb_rb %d harq_process->round %d
\n
"
,
phy_vars_gNB
->
Mod_id
,
nr_tti_rx
,
harq_process
->
TBS
,
harq_process
->
mcs
,
harq_process
->
nb_rb
,
harq_process
->
round
);
#if
def
gNB_DEBUG_TRACE
LOG_I
(
PHY
,
"[gNB %d] ULSCH: Setting ACK for nr_tti_rx %d TBS %d
\n
"
,
phy_vars_gNB
->
Mod_id
,
nr_tti_rx
,
harq_process
->
TBS
);
#endif
harq_process
->
status
=
SCH_IDLE
;
...
...
openair1/PHY/NR_TRANSPORT/nr_ulsch_demodulation.c
View file @
348343be
...
...
@@ -973,7 +973,7 @@ void nr_rx_pusch(PHY_VARS_gNB *gNB,
uint8_t
first_symbol_flag
,
aarx
,
aatx
,
pilots
;
// pilots, a flag to indicate DMRS REs in current symbol
NR_DL_FRAME_PARMS
*
frame_parms
=
&
gNB
->
frame_parms
;
nfapi_nr_ul_config_ulsch_pdu_rel15_t
*
rel15_ul
=
&
gNB
->
ulsch
[
UE_id
+
1
][
0
]
->
harq_processes
[
harq_pid
]
->
ulsch_pdu
.
ulsch_pdu_rel15
;
nfapi_nr_ul_config_ulsch_pdu_rel15_t
*
rel15_ul
=
&
gNB
->
ulsch
[
UE_id
][
0
]
->
harq_processes
[
harq_pid
]
->
ulsch_pdu
.
ulsch_pdu_rel15
;
uint32_t
nb_re_pusch
,
bwp_start_subcarrier
;
int
avgs
;
int
avg
[
4
];
...
...
@@ -1026,7 +1026,7 @@ void nr_rx_pusch(PHY_VARS_gNB *gNB,
nr_ulsch_scale_channel
(
gNB
->
pusch_vars
[
UE_id
]
->
ul_ch_estimates_ext
,
frame_parms
,
gNB
->
ulsch
[
UE_id
+
1
],
gNB
->
ulsch
[
UE_id
],
symbol
,
pilots
,
rel15_ul
->
number_rbs
);
...
...
openair1/SCHED_NR/phy_procedures_nr_gNB.c
View file @
348343be
...
...
@@ -214,7 +214,7 @@ void nr_ulsch_procedures(PHY_VARS_gNB *gNB, int frame_rx, int slot_rx, int UE_id
nfapi_nr_ul_config_ulsch_pdu
*
rel15_ul
=
&
gNB
->
ulsch
[
UE_id
][
0
]
->
harq_processes
[
harq_pid
]
->
ulsch_pdu
;
nfapi_nr_ul_config_ulsch_pdu_rel15_t
*
nfapi_ulsch_pdu_rel15
=
&
rel15_ul
->
ulsch_pdu_rel15
;
//
uint8_t ret;
uint8_t
ret
;
uint32_t
G
;
int
Nid_cell
=
0
;
// [hna] shouldn't be a local variable (should be signaled)
...
...
@@ -239,8 +239,7 @@ void nr_ulsch_procedures(PHY_VARS_gNB *gNB, int frame_rx, int slot_rx, int UE_id
//--------------------- ULSCH decoding ---------------------
//----------------------------------------------------------
//ret = nr_ulsch_decoding(gNB,
nr_ulsch_decoding
(
gNB
,
ret
=
nr_ulsch_decoding
(
gNB
,
UE_id
,
gNB
->
pusch_vars
[
UE_id
]
->
llr
,
frame_parms
,
...
...
@@ -250,8 +249,10 @@ void nr_ulsch_procedures(PHY_VARS_gNB *gNB, int frame_rx, int slot_rx, int UE_id
harq_pid
,
0
);
// if (ret > ulsch_gNB->max_ldpc_iterations)
// n_errors++;
if
(
ret
>
gNB
->
ulsch
[
UE_id
][
0
]
->
max_ldpc_iterations
)
LOG_I
(
PHY
,
"ULSCH in error
\n
"
);
else
LOG_I
(
PHY
,
"ULSCH received ok
\n
"
);
}
...
...
@@ -343,21 +344,27 @@ void phy_procedures_gNB_common_RX(PHY_VARS_gNB *gNB, int frame_rx, int slot_rx)
}
void
phy_procedures_gNB_uespec_RX
(
PHY_VARS_gNB
*
gNB
,
int
frame_rx
,
int
slot_rx
,
uint8_t
symbol_start
,
uint8_t
symbol_end
)
{
void
phy_procedures_gNB_uespec_RX
(
PHY_VARS_gNB
*
gNB
,
int
frame_rx
,
int
slot_rx
)
{
nfapi_nr_ul_tti_request_t
*
UL_tti_req
=
&
gNB
->
UL_tti_req
;
int
num_pusch_pdu
=
UL_tti_req
->
n_pdus
;
LOG_I
(
PHY
,
"phy_procedures_gNB_uespec_RX frame %d, slot %d, num_pusch_pdu %d
\n
"
,
frame_rx
,
slot_rx
,
num_pusch_pdu
);
for
(
int
i
=
0
;
i
<
num_pusch_pdu
;
i
++
)
{
switch
(
UL_tti_req
->
pdus_list
[
i
].
pdu_type
)
{
case
NFAPI_NR_UL_CONFIG_PUSCH_PDU_TYPE
:
{
LOG_I
(
PHY
,
"frame %d, slot %d, Got NFAPI_NR_UL_CONFIG_PUSCH_PDU_TYPE
\n
"
,
frame_rx
,
slot_rx
);
nfapi_nr_pusch_pdu_t
*
pusch_pdu
=
&
UL_tti_req
->
pdus_list
[
0
].
pusch_pdu
;
nr_fill_ulsch
(
gNB
,
frame_rx
,
slot_rx
,
pusch_pdu
);
uint8_t
UE_id
=
find_nr_ulsch
(
pusch_pdu
->
rnti
,
gNB
,
SEARCH_EXIST
);
uint8_t
harq_pid
=
pusch_pdu
->
pusch_data
.
harq_process_id
;
uint8_t
symbol_start
=
pusch_pdu
->
start_symbol_index
;
uint8_t
symbol_end
=
symbol_start
+
pusch_pdu
->
nr_of_symbols
;
for
(
uint8_t
symbol
=
symbol_start
;
symbol
<
symbol_end
;
symbol
++
)
{
nr_rx_pusch
(
gNB
,
UE_id
,
frame_rx
,
slot_rx
,
symbol
,
harq_pid
);
...
...
openair1/SCHED_NR/sched_nr.h
View file @
348343be
...
...
@@ -38,7 +38,7 @@ nr_slot_t nr_slot_select (nfapi_nr_config_request_t *cfg, unsigned char slot);
void
nr_set_ssb_first_subcarrier
(
nfapi_nr_config_request_t
*
cfg
,
NR_DL_FRAME_PARMS
*
fp
);
void
phy_procedures_gNB_TX
(
PHY_VARS_gNB
*
gNB
,
int
frame_tx
,
int
slot_tx
,
int
do_meas
);
void
phy_procedures_gNB_common_RX
(
PHY_VARS_gNB
*
gNB
,
int
frame_rx
,
int
slot_rx
);
void
phy_procedures_gNB_uespec_RX
(
PHY_VARS_gNB
*
gNB
,
int
frame_rx
,
int
slot_rx
,
uint8_t
symbol_start
,
uint8_t
symbol_end
);
void
phy_procedures_gNB_uespec_RX
(
PHY_VARS_gNB
*
gNB
,
int
frame_rx
,
int
slot_rx
);
void
nr_common_signal_procedures
(
PHY_VARS_gNB
*
gNB
,
int
frame
,
int
slot
);
void
nr_feptx_ofdm
(
RU_t
*
ru
,
int
frame_tx
,
int
tti_tx
);
void
nr_feptx_ofdm_2thread
(
RU_t
*
ru
,
int
frame_tx
,
int
tti_tx
);
...
...
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
View file @
348343be
...
...
@@ -294,9 +294,12 @@ void copy_nr_ulreq(module_id_t module_idP, frame_t frameP, sub_frame_t slotP)
}
*/
void
gNB_dlsch_ulsch_scheduler
(
module_id_t
module_idP
,
frame_t
frameP
,
sub_frame_t
slotP
){
void
gNB_dlsch_ulsch_scheduler
(
module_id_t
module_idP
,
frame_t
frame_rxP
,
sub_frame_t
slot_rxP
,
frame_t
frame_txP
,
sub_frame_t
slot_txP
){
protocol_ctxt_t
ctxt
;
int
CC_id
,
i
=
-
1
;
...
...
@@ -308,8 +311,8 @@ void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
start_meas
(
&
RC
.
nrmac
[
module_idP
]
->
eNB_scheduler
);
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_ENB_DLSCH_ULSCH_SCHEDULER
,
VCD_FUNCTION_IN
);
RC
.
nrmac
[
module_idP
]
->
frame
=
frameP
;
RC
.
nrmac
[
module_idP
]
->
slot
=
slotP
;
RC
.
nrmac
[
module_idP
]
->
frame
=
frame
_rx
P
;
RC
.
nrmac
[
module_idP
]
->
slot
=
slot
_rx
P
;
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
...
...
@@ -319,7 +322,7 @@ void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
memset
(
cc
[
CC_id
].
vrb_map
,
0
,
100
);
memset
(
cc
[
CC_id
].
vrb_map_UL
,
0
,
100
);
clear_nr_nfapi_information
(
RC
.
nrmac
[
module_idP
],
CC_id
,
frame
P
,
slot
P
);
clear_nr_nfapi_information
(
RC
.
nrmac
[
module_idP
],
CC_id
,
frame
_txP
,
slot_tx
P
);
}
// refresh UE list based on UEs dropped by PHY in previous subframe
...
...
@@ -333,16 +336,16 @@ void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
if
(
nr_is_dci_opportunity
(
search_space
,
coreset
,
frameP
,
slotP
,
frame
_tx
P
,
slot
_tx
P
,
*
cfg
))
nr_schedule_uss_dlsch_phytest
(
module_idP
,
frame
P
,
slot
P
);
nr_schedule_uss_dlsch_phytest
(
module_idP
,
frame
_txP
,
slot_tx
P
);
rnti
=
UE_RNTI
(
module_idP
,
i
);
CC_id
=
UE_PCCID
(
module_idP
,
i
);
//int spf = get_spf(cfg);
if
(((
frame
P
&
127
)
==
0
)
&&
(
slot
P
==
0
))
{
if
(((
frame
_txP
&
127
)
==
0
)
&&
(
slot_tx
P
==
0
))
{
LOG_I
(
MAC
,
"UE rnti %x : %s, PHR %d dB DL CQI %d PUSCH SNR %d PUCCH SNR %d
\n
"
,
rnti
,
...
...
@@ -354,107 +357,35 @@ void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
(
UE_list
->
UE_sched_ctrl
[
i
].
pucch1_snr
[
CC_id
]
-
128
)
/
2
);
}
RC
.
gNB
[
module_idP
][
CC_id
]
->
pusch_stats_bsr
[
i
][
to_absslot
(
cfg
,
frameP
,
slotP
)]
=
-
63
;
if
(
i
==
UE_list
->
head
)
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME
(
VCD_SIGNAL_DUMPER_VARIABLES_UE0_BSR
,
RC
.
gNB
[
module_idP
][
CC_id
]
->
pusch_stats_bsr
[
i
][
to_absslot
(
cfg
,
frameP
,
slotP
)]);
// increment this, it is cleared when we receive an sdu
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
ul_inactivity_timer
++
;
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
cqi_req_timer
++
;
LOG_D
(
MAC
,
"UE %d/%x : ul_inactivity %d, cqi_req %d
\n
"
,
i
,
rnti
,
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
ul_inactivity_timer
,
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
cqi_req_timer
);
//check_nr_ul_failure(module_idP, CC_id, i, frameP, subframeP);
if
(
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
ue_reestablishment_reject_timer
>
0
)
{
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
ue_reestablishment_reject_timer
++
;
if
(
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
ue_reestablishment_reject_timer
>=
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
ue_reestablishment_reject_timer_thres
)
{
RC
.
nrmac
[
module_idP
]
->
UE_list
.
UE_sched_ctrl
[
i
].
ue_reestablishment_reject_timer
=
0
;
for
(
int
ue_id_l
=
0
;
ue_id_l
<
MAX_MOBILES_PER_GNB
;
ue_id_l
++
)
{
if
(
reestablish_rnti_map
[
ue_id_l
][
0
]
==
rnti
)
{
// clear currentC-RNTI from map
reestablish_rnti_map
[
ue_id_l
][
0
]
=
0
;
reestablish_rnti_map
[
ue_id_l
][
1
]
=
0
;
break
;
}
}
// Note: This should not be done in the MAC!
for
(
int
ii
=
0
;
ii
<
MAX_MOBILES_PER_GNB
;
ii
++
)
{
NR_gNB_ULSCH_t
*
ulsch
=
RC
.
gNB
[
module_idP
][
CC_id
]
->
ulsch
[
ii
][
0
];
if
((
ulsch
!=
NULL
)
&&
(
ulsch
->
rnti
==
rnti
)){
LOG_W
(
MAC
,
"TODO: clean_eNb_ulsch UE %x
\n
"
,
rnti
);
clean_gNB_ulsch
(
ulsch
);
}
}
for
(
int
ii
=
0
;
ii
<
MAX_MOBILES_PER_GNB
;
ii
++
)
{
NR_gNB_DLSCH_t
*
dlsch
=
RC
.
gNB
[
module_idP
][
CC_id
]
->
dlsch
[
ii
][
0
];
if
((
dlsch
!=
NULL
)
&&
(
dlsch
->
rnti
==
rnti
)){
LOG_W
(
MAC
,
"TODO: clean_eNb_dlsch UE %x
\n
"
,
rnti
);
clean_gNB_dlsch
(
dlsch
);
}
}
/*
for(int j = 0; j < 10; j++){
nfapi_ul_config_request_body_t *ul_req_tmp = NULL;
ul_req_tmp = &RC.nrmac[module_idP]->UL_req_tmp[CC_id][j].ul_config_request_body;
if(ul_req_tmp){
int pdu_number = ul_req_tmp->number_of_pdus;
for(int pdu_index = pdu_number-1; pdu_index >= 0; pdu_index--){
if(ul_req_tmp->ul_config_pdu_list[pdu_index].ulsch_pdu.ulsch_pdu_rel8.rnti == rnti){
LOG_I(MAC, "remove UE %x from ul_config_pdu_list %d/%d\n", rnti, pdu_index, pdu_number);
if(pdu_index < pdu_number -1){
memcpy(&ul_req_tmp->ul_config_pdu_list[pdu_index], &ul_req_tmp->ul_config_pdu_list[pdu_index+1], (pdu_number-1-pdu_index) * sizeof(nfapi_ul_config_request_pdu_t));
}
ul_req_tmp->number_of_pdus--;
}
}
}
}
rrc_mac_remove_ue(module_idP,rnti);
*/
}
}
//END if (RC.nrmac[module_idP]->UE_list.UE_sched_ctrl[i].ue_reestablishment_reject_timer > 0)
}
//END if (UE_list->active[i])
}
//END for (i = 0; i < MAX_MOBILES_PER_GNB; i++)
PROTOCOL_CTXT_SET_BY_MODULE_ID
(
&
ctxt
,
module_idP
,
ENB_FLAG_YES
,
NOT_A_RNTI
,
frame
P
,
slot
P
,
module_idP
);
PROTOCOL_CTXT_SET_BY_MODULE_ID
(
&
ctxt
,
module_idP
,
ENB_FLAG_YES
,
NOT_A_RNTI
,
frame
_txP
,
slot_tx
P
,
module_idP
);
pdcp_run
(
&
ctxt
);
//rrc_rx_tx(&ctxt, CC_id);
// This schedules MIB
if
((
slot
P
==
0
)
&&
(
frame
P
&
7
)
==
0
){
schedule_nr_mib
(
module_idP
,
frame
P
,
slot
P
);
if
((
slot
_txP
==
0
)
&&
(
frame_tx
P
&
7
)
==
0
){
schedule_nr_mib
(
module_idP
,
frame
_txP
,
slot_tx
P
);
}
// Phytest scheduling
if
(
slotP
==
2
)
nr_schedule_uss_ulsch_phytest
(
module_idP
,
frame
P
,
slot
P
);
if
(
slot
_rx
P
==
2
)
nr_schedule_uss_ulsch_phytest
(
module_idP
,
frame
_rxP
,
slot_rx
P
);
if
(
slotP
==
1
)
nr_schedule_uss_dlsch_phytest
(
module_idP
,
frame
P
,
slot
P
);
if
(
slot
_tx
P
==
1
)
nr_schedule_uss_dlsch_phytest
(
module_idP
,
frame
_txP
,
slot_tx
P
);
/*
// Allocate CCEs for good after scheduling is done
for (CC_id = 0; CC_id < MAX_NUM_CCs; CC_id++)
allocate_CCEs(module_idP, CC_id, subframeP, 0);
*/
stop_meas
(
&
RC
.
nrmac
[
module_idP
]
->
eNB_scheduler
);
*/
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_ENB_DLSCH_ULSCH_SCHEDULER
,
VCD_FUNCTION_OUT
);
}
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
View file @
348343be
...
...
@@ -64,7 +64,9 @@ void clear_nr_nfapi_information(gNB_MAC_INST * gNB,
frame_t
frameP
,
sub_frame_t
subframeP
);
void
gNB_dlsch_ulsch_scheduler
(
module_id_t
module_idP
,
frame_t
frameP
,
sub_frame_t
subframeP
);
void
gNB_dlsch_ulsch_scheduler
(
module_id_t
module_idP
,
frame_t
frame_txP
,
sub_frame_t
slot_txP
,
frame_t
frame_rxP
,
sub_frame_t
slot_rxP
);
void
schedule_nr_mib
(
module_id_t
module_idP
,
frame_t
frameP
,
sub_frame_t
subframeP
);
...
...
openair2/NR_PHY_INTERFACE/NR_IF_Module.c
View file @
348343be
...
...
@@ -312,8 +312,10 @@ void NR_UL_indication(NR_UL_IND_t *UL_info)
int
spf
=
get_spf
(
cfg
);
gNB_dlsch_ulsch_scheduler
(
module_id
,
(
UL_info
->
frame
+
((
UL_info
->
slot
>
(
spf
-
1
-
sf_ahead
))
?
1
:
0
))
%
1024
,
(
UL_info
->
slot
+
sf_ahead
)
%
spf
);
UL_info
->
frame
,
UL_info
->
slot
,
(
UL_info
->
frame
+
((
UL_info
->
slot
>
(
spf
-
1
-
sf_ahead
))
?
1
:
0
))
%
1024
,
(
UL_info
->
slot
+
sf_ahead
)
%
spf
);
ifi
->
CC_mask
=
0
;
...
...
targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf
View file @
348343be
...
...
@@ -284,9 +284,9 @@ NETWORK_CONTROLLER :
global_log_verbosity
=
"medium"
;
hw_log_level
=
"info"
;
hw_log_verbosity
=
"medium"
;
phy_log_level
=
"
info
"
;
phy_log_level
=
"
debug
"
;
phy_log_verbosity
=
"medium"
;
mac_log_level
=
"
info
"
;
mac_log_level
=
"
debug
"
;
mac_log_verbosity
=
"high"
;
rlc_log_level
=
"info"
;
rlc_log_verbosity
=
"medium"
;
...
...
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