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
zzha zzha
OpenXG-RAN
Commits
37d112f5
Commit
37d112f5
authored
Feb 11, 2021
by
kn.raju
Committed by
Robert Schmidt
Feb 12, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check that resources are free for Msg2/RAR
parent
13e719d7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
5 deletions
+17
-5
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_RA.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_RA.c
+17
-5
No files found.
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_RA.c
View file @
37d112f5
...
...
@@ -825,6 +825,19 @@ void nr_generate_Msg2(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
if
((
ra
->
Msg2_frame
==
frameP
)
&&
(
ra
->
Msg2_slot
==
slotP
))
{
uint16_t
*
vrb_map
=
cc
[
CC_id
].
vrb_map
;
int
rbStart
=
0
,
rbSize
=
6
;
for
(
int
i
=
0
;
(
i
<
rbSize
)
&&
(
rbStart
<=
(
dci10_bw
-
rbSize
));
i
++
)
{
if
(
vrb_map
[
rbStart
+
i
])
{
rbStart
+=
i
;
i
=
0
;
}
}
if
(
rbStart
>
(
dci10_bw
-
rbSize
))
{
LOG_E
(
MAC
,
"%s(): cannot find free vrb_map for RA RNTI %04x!
\n
"
,
__func__
,
ra
->
RA_rnti
);
return
;
}
nfapi_nr_dl_tti_request_body_t
*
dl_req
=
&
nr_mac
->
DL_req
[
CC_id
].
dl_tti_request_body
;
// Checking if the DCI allocation is feasible in current subframe: we might
// need to need up to two (PDCCH + PDSCH) messages, so check that we can
...
...
@@ -924,8 +937,8 @@ void nr_generate_Msg2(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
pdsch_pdu_rel15
->
numDmrsCdmGrpsNoData
=
2
;
pdsch_pdu_rel15
->
dmrsPorts
=
1
;
pdsch_pdu_rel15
->
resourceAlloc
=
1
;
pdsch_pdu_rel15
->
rbStart
=
0
;
pdsch_pdu_rel15
->
rbSize
=
6
;
pdsch_pdu_rel15
->
rbStart
=
rbStart
;
pdsch_pdu_rel15
->
rbSize
=
rbSize
;
pdsch_pdu_rel15
->
VRBtoPRBMapping
=
0
;
// non interleaved
for
(
int
i
=
0
;
i
<
bwp
->
bwp_Common
->
pdsch_ConfigCommon
->
choice
.
setup
->
pdsch_TimeDomainAllocationList
->
list
.
count
;
i
++
)
{
...
...
@@ -1025,9 +1038,8 @@ void nr_generate_Msg2(module_id_t module_idP, int CC_id, frame_t frameP, sub_fra
T_BUFFER
(
&
tx_req
->
TLVs
[
0
].
value
.
direct
[
0
],
tx_req
->
TLVs
[
0
].
length
));
/* mark the corresponding RBs as used */
uint16_t
*
vrb_map
=
cc
[
CC_id
].
vrb_map
;
for
(
int
rb
=
0
;
rb
<
pdsch_pdu_rel15
->
rbSize
;
rb
++
)
vrb_map
[
rb
+
pdsch_pdu_rel15
->
rbStart
]
=
1
;
for
(
int
rb
=
0
;
rb
<
rbSize
;
rb
++
)
vrb_map
[
rb
+
rbStart
]
=
1
;
}
}
...
...
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