Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG UE
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 UE
Commits
396dc962
Commit
396dc962
authored
Nov 07, 2020
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
PUCCH scheduling: allocate in UL_tti_req_ahead
parent
d8c3554d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
50 additions
and
42 deletions
+50
-42
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
+2
-2
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_uci.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_uci.c
+48
-40
No files found.
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
View file @
396dc962
...
...
@@ -457,8 +457,6 @@ void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
nr_schedule_ulsch
(
module_idP
,
frame
,
slot
,
num_slots_per_tdd
,
nr_ulmix_slots
,
ulsch_in_slot_bitmap
);
}
nr_schedule_pusch
(
module_idP
,
frame
,
slot
);
if
(
UE_info
->
active
[
UE_id
]
&&
(
is_xlsch_in_slot
(
dlsch_in_slot_bitmap
,
slot
%
num_slots_per_tdd
))
&&
slot
<
10
)
{
...
...
@@ -471,6 +469,8 @@ void gNB_dlsch_ulsch_scheduler(module_id_t module_idP,
if
(
UE_info
->
active
[
UE_id
])
nr_schedule_pucch
(
module_idP
,
UE_id
,
nr_ulmix_slots
,
frame
,
slot
);
nr_schedule_pusch
(
module_idP
,
frame
,
slot
);
stop_meas
(
&
RC
.
nrmac
[
module_idP
]
->
eNB_scheduler
);
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_gNB_DLSCH_ULSCH_SCHEDULER
,
VCD_FUNCTION_OUT
);
...
...
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_uci.c
View file @
396dc962
...
...
@@ -39,51 +39,59 @@ void nr_schedule_pucch(int Mod_idP,
int
nr_ulmix_slots
,
frame_t
frameP
,
sub_frame_t
slotP
)
{
uint16_t
O_csi
,
O_ack
,
O_uci
;
uint8_t
O_sr
=
0
;
// no SR in PUCCH implemented for now
NR_ServingCellConfigCommon_t
*
scc
=
RC
.
nrmac
[
Mod_idP
]
->
common_channels
->
ServingCellConfigCommon
;
NR_UE_info_t
*
UE_info
=
&
RC
.
nrmac
[
Mod_idP
]
->
UE_info
;
AssertFatal
(
UE_info
->
active
[
UE_id
],
"Cannot find UE_id %d is not active
\n
"
,
UE_id
);
NR_CellGroupConfig_t
*
secondaryCellGroup
=
UE_info
->
secondaryCellGroup
[
UE_id
];
int
bwp_id
=
1
;
NR_BWP_Uplink_t
*
ubwp
=
secondaryCellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
uplinkBWP_ToAddModList
->
list
.
array
[
bwp_id
-
1
];
nfapi_nr_ul_tti_request_t
*
UL_tti_req
=
&
RC
.
nrmac
[
Mod_idP
]
->
UL_tti_req
[
0
];
NR_sched_pucch
*
curr_pucch
;
for
(
int
k
=
0
;
k
<
nr_ulmix_slots
;
k
++
)
{
for
(
int
l
=
0
;
l
<
2
;
l
++
)
{
curr_pucch
=
&
UE_info
->
UE_sched_ctrl
[
UE_id
].
sched_pucch
[
k
][
l
];
O_ack
=
curr_pucch
->
dai_c
;
O_csi
=
curr_pucch
->
csi_bits
;
O_uci
=
O_ack
+
O_csi
+
O_sr
;
if
((
O_uci
>
0
)
&&
(
frameP
==
curr_pucch
->
frame
)
&&
(
slotP
==
curr_pucch
->
ul_slot
))
{
UL_tti_req
->
SFN
=
curr_pucch
->
frame
;
UL_tti_req
->
Slot
=
curr_pucch
->
ul_slot
;
UL_tti_req
->
pdus_list
[
UL_tti_req
->
n_pdus
].
pdu_type
=
NFAPI_NR_UL_CONFIG_PUCCH_PDU_TYPE
;
UL_tti_req
->
pdus_list
[
UL_tti_req
->
n_pdus
].
pdu_size
=
sizeof
(
nfapi_nr_pucch_pdu_t
);
nfapi_nr_pucch_pdu_t
*
pucch_pdu
=
&
UL_tti_req
->
pdus_list
[
UL_tti_req
->
n_pdus
].
pucch_pdu
;
memset
(
pucch_pdu
,
0
,
sizeof
(
nfapi_nr_pucch_pdu_t
));
UL_tti_req
->
n_pdus
+=
1
;
LOG_D
(
MAC
,
"Scheduling pucch reception for frame %d slot %d with (%d, %d, %d) (SR ACK, CSI) bits
\n
"
,
frameP
,
slotP
,
O_sr
,
O_ack
,
curr_pucch
->
csi_bits
);
nr_configure_pucch
(
pucch_pdu
,
scc
,
ubwp
,
UE_info
->
rnti
[
UE_id
],
curr_pucch
->
resource_indicator
,
O_csi
,
O_ack
,
O_sr
);
memset
((
void
*
)
&
UE_info
->
UE_sched_ctrl
[
UE_id
].
sched_pucch
[
k
][
l
],
0
,
sizeof
(
NR_sched_pucch
));
}
NR_sched_pucch
*
curr_pucch
=
&
UE_info
->
UE_sched_ctrl
[
UE_id
].
sched_pucch
[
k
][
l
];
const
uint16_t
O_ack
=
curr_pucch
->
dai_c
;
const
uint16_t
O_csi
=
curr_pucch
->
csi_bits
;
const
uint8_t
O_sr
=
0
;
// no SR in PUCCH implemented for now
if
(
O_ack
+
O_csi
+
O_sr
==
0
||
frameP
!=
curr_pucch
->
frame
||
slotP
!=
curr_pucch
->
ul_slot
)
continue
;
nfapi_nr_ul_tti_request_t
*
future_ul_tti_req
=
&
RC
.
nrmac
[
Mod_idP
]
->
UL_tti_req_ahead
[
0
][
curr_pucch
->
ul_slot
];
AssertFatal
(
future_ul_tti_req
->
SFN
==
curr_pucch
->
frame
&&
future_ul_tti_req
->
Slot
==
curr_pucch
->
ul_slot
,
"future UL_tti_req's frame.slot %d.%d does not match PUCCH %d.%d
\n
"
,
future_ul_tti_req
->
SFN
,
future_ul_tti_req
->
Slot
,
curr_pucch
->
frame
,
curr_pucch
->
ul_slot
);
future_ul_tti_req
->
pdus_list
[
future_ul_tti_req
->
n_pdus
].
pdu_type
=
NFAPI_NR_UL_CONFIG_PUCCH_PDU_TYPE
;
future_ul_tti_req
->
pdus_list
[
future_ul_tti_req
->
n_pdus
].
pdu_size
=
sizeof
(
nfapi_nr_pucch_pdu_t
);
nfapi_nr_pucch_pdu_t
*
pucch_pdu
=
&
future_ul_tti_req
->
pdus_list
[
future_ul_tti_req
->
n_pdus
].
pucch_pdu
;
memset
(
pucch_pdu
,
0
,
sizeof
(
nfapi_nr_pucch_pdu_t
));
future_ul_tti_req
->
n_pdus
+=
1
;
LOG_D
(
MAC
,
"%4d.%2d Scheduling pucch reception in %4d.%2d: bits SR %d, ACK %d, CSI %d, k %d l %d
\n
"
,
frameP
,
slotP
,
curr_pucch
->
frame
,
curr_pucch
->
ul_slot
,
O_sr
,
O_ack
,
O_csi
,
k
,
l
);
NR_ServingCellConfigCommon_t
*
scc
=
RC
.
nrmac
[
Mod_idP
]
->
common_channels
->
ServingCellConfigCommon
;
nr_configure_pucch
(
pucch_pdu
,
scc
,
UE_info
->
UE_sched_ctrl
[
UE_id
].
active_ubwp
,
UE_info
->
rnti
[
UE_id
],
curr_pucch
->
resource_indicator
,
O_csi
,
O_ack
,
O_sr
);
memset
(
&
UE_info
->
UE_sched_ctrl
[
UE_id
].
sched_pucch
[
k
][
l
],
0
,
sizeof
(
NR_sched_pucch
));
}
}
}
...
...
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