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
lizhongxiao
OpenXG-RAN
Commits
8edacded
Commit
8edacded
authored
Apr 13, 2021
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
UL Scheduler: Check vrb_map_UL against symb map
parent
e04affbc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
16 deletions
+25
-16
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_phytest.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_phytest.c
+14
-13
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_ulsch.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_ulsch.c
+11
-3
No files found.
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_phytest.c
View file @
8edacded
...
...
@@ -426,13 +426,26 @@ bool nr_ul_preprocessor_phytest(module_id_t module_id, frame_t frame, sub_frame_
if
(
!
is_xlsch_in_slot
(
ulsch_slot_bitmap
,
sched_slot
))
return
false
;
const
long
f
=
sched_ctrl
->
search_space
->
searchSpaceType
->
choice
.
ue_Specific
->
dci_Formats
;
const
int
dci_format
=
f
?
NR_UL_DCI_FORMAT_0_1
:
NR_UL_DCI_FORMAT_0_0
;
const
uint8_t
num_dmrs_cdm_grps_no_data
=
1
;
/* we want to avoid a lengthy deduction of DMRS and other parameters in
* every TTI if we can save it, so check whether dci_format, TDA, or
* num_dmrs_cdm_grps_no_data has changed and only then recompute */
NR_pusch_semi_static_t
*
ps
=
&
sched_ctrl
->
pusch_semi_static
;
if
(
ps
->
time_domain_allocation
!=
tda
||
ps
->
dci_format
!=
dci_format
||
ps
->
num_dmrs_cdm_grps_no_data
!=
num_dmrs_cdm_grps_no_data
)
nr_set_pusch_semi_static
(
scc
,
sched_ctrl
->
active_ubwp
,
dci_format
,
tda
,
num_dmrs_cdm_grps_no_data
,
ps
);
uint16_t
rbStart
=
0
;
uint16_t
rbSize
=
target_ul_bw
;
uint16_t
*
vrb_map_UL
=
&
RC
.
nrmac
[
module_id
]
->
common_channels
[
CC_id
].
vrb_map_UL
[
sched_slot
*
MAX_BWP_SIZE
];
const
uint16_t
symb
=
((
1
<<
ps
->
nrOfSymbols
)
-
1
)
<<
ps
->
startSymbolIndex
;
for
(
int
i
=
rbStart
;
i
<
rbStart
+
rbSize
;
++
i
)
{
if
(
vrb_map_UL
[
i
]
)
{
if
(
(
vrb_map_UL
[
i
]
&
symb
)
!=
0
)
{
LOG_E
(
MAC
,
"%s(): %4d.%2d RB %d is already reserved, cannot schedule UE
\n
"
,
__func__
,
...
...
@@ -466,18 +479,6 @@ bool nr_ul_preprocessor_phytest(module_id_t module_id, frame_t frame, sub_frame_
}
UE_info
->
num_pdcch_cand
[
UE_id
][
cid
]
++
;
const
long
f
=
sched_ctrl
->
search_space
->
searchSpaceType
->
choice
.
ue_Specific
->
dci_Formats
;
const
int
dci_format
=
f
?
NR_UL_DCI_FORMAT_0_1
:
NR_UL_DCI_FORMAT_0_0
;
const
uint8_t
num_dmrs_cdm_grps_no_data
=
1
;
/* we want to avoid a lengthy deduction of DMRS and other parameters in
* every TTI if we can save it, so check whether dci_format, TDA, or
* num_dmrs_cdm_grps_no_data has changed and only then recompute */
NR_pusch_semi_static_t
*
ps
=
&
sched_ctrl
->
pusch_semi_static
;
if
(
ps
->
time_domain_allocation
!=
tda
||
ps
->
dci_format
!=
dci_format
||
ps
->
num_dmrs_cdm_grps_no_data
!=
num_dmrs_cdm_grps_no_data
)
nr_set_pusch_semi_static
(
scc
,
sched_ctrl
->
active_ubwp
,
dci_format
,
tda
,
num_dmrs_cdm_grps_no_data
,
ps
);
const
int
mcs
=
target_ul_mcs
;
NR_sched_pusch_t
*
sched_pusch
=
&
sched_ctrl
->
sched_pusch
;
sched_pusch
->
mcs
=
mcs
;
...
...
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_ulsch.c
View file @
8edacded
...
...
@@ -1023,16 +1023,24 @@ bool nr_fr1_ulsch_preprocessor(module_id_t module_id, frame_t frame, sub_frame_t
sched_ctrl
->
sched_pusch
.
frame
=
sched_frame
;
}
/* Change vrb_map_UL to rballoc_mask */
/* Change vrb_map_UL to rballoc_mask: check which symbols per RB (in
* vrb_map_UL) overlap with the "default" tda and exclude those RBs.
* Calculate largest contiguous RBs */
uint16_t
*
vrb_map_UL
=
&
RC
.
nrmac
[
module_id
]
->
common_channels
[
CC_id
].
vrb_map_UL
[
sched_slot
*
MAX_BWP_SIZE
];
const
uint16_t
bwpSize
=
NRRIV2BW
(
sched_ctrl
->
active_ubwp
->
bwp_Common
->
genericParameters
.
locationAndBandwidth
,
MAX_BWP_SIZE
);
const
struct
NR_PUSCH_TimeDomainResourceAllocationList
*
tdaList
=
sched_ctrl
->
active_ubwp
->
bwp_Common
->
pusch_ConfigCommon
->
choice
.
setup
->
pusch_TimeDomainAllocationList
;
const
int
startSymbolAndLength
=
tdaList
->
list
.
array
[
tda
]
->
startSymbolAndLength
;
int
startSymbolIndex
,
nrOfSymbols
;
SLIV2SL
(
startSymbolAndLength
,
&
startSymbolIndex
,
&
nrOfSymbols
);
const
uint16_t
symb
=
((
1
<<
nrOfSymbols
)
-
1
)
<<
startSymbolIndex
;
int
st
=
0
,
e
=
0
,
len
=
0
;
for
(
int
i
=
0
;
i
<
bwpSize
;
i
++
)
{
while
(
vrb_map_UL
[
i
]
==
1
)
while
(
(
vrb_map_UL
[
i
]
&
symb
)
!=
0
&&
i
<
bwpSize
)
i
++
;
st
=
i
;
while
(
vrb_map_UL
[
i
]
==
0
)
while
(
(
vrb_map_UL
[
i
]
&
symb
)
==
0
&&
i
<
bwpSize
)
i
++
;
if
(
i
-
st
>
len
)
{
len
=
i
-
st
;
...
...
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