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
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
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
OpenXG
OpenXG-RAN
Commits
a21b6e0f
Commit
a21b6e0f
authored
Sep 27, 2021
by
francescomani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update get_pdsch_to_harq_feedback
parent
68f6047c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
59 additions
and
21 deletions
+59
-21
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_primitives.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_primitives.c
+51
-16
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
+8
-5
No files found.
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_primitives.c
View file @
a21b6e0f
...
...
@@ -2045,34 +2045,61 @@ uint8_t nr_get_tpc(int target, uint8_t cqi, int incr) {
void
get_pdsch_to_harq_feedback
(
int
Mod_idP
,
int
UE_id
,
int
bwp_id
,
NR_SearchSpace__searchSpaceType_PR
ss_type
,
int
*
max_fb_time
,
uint8_t
*
pdsch_to_harq_feedback
)
{
int
bwp_id
=
1
;
NR_UE_info_t
*
UE_info
=
&
RC
.
nrmac
[
Mod_idP
]
->
UE_info
;
NR_CellGroupConfig_t
*
CellGroup
=
UE_info
->
CellGroup
[
UE_id
];
NR_BWP_Downlink_t
*
bwp
=
NULL
;
NR_BWP_Uplink_t
*
ubwp
=
NULL
;
if
(
CellGroup
&&
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
downlinkBWP_ToAddModList
)
bwp
=
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
downlinkBWP_ToAddModList
->
list
.
array
[
bwp_id
-
1
];
if
(
CellGroup
&&
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
uplinkBWP_ToAddModList
)
ubwp
=
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
uplinkBWP_ToAddModList
->
list
.
array
[
bwp_id
-
1
];
NR_BWP_DownlinkDedicated_t
*
bwpd
=
NULL
;
NR_BWP_UplinkDedicated_t
*
ubwpd
=
NULL
;
if
(
ss_type
==
NR_SearchSpace__searchSpaceType_PR_ue_Specific
)
{
AssertFatal
(
CellGroup
!=
NULL
,
"Cellgroup is not defined for UE_id %d
\n
"
,
UE_id
);
AssertFatal
(
CellGroup
->
spCellConfig
!=
NULL
,
"Cellgroup->spCellConfig is null
\n
"
);
AssertFatal
(
CellGroup
->
spCellConfig
->
spCellConfigDedicated
!=
NULL
,
"CellGroup->spCellConfig->spCellConfigDedicated is null
\n
"
);
}
if
(
bwp_id
>
0
)
{
AssertFatal
(
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
downlinkBWP_ToAddModList
!=
NULL
,
"CellGroup->spCellConfig->spCellConfigDedicated->downlinkBWP_ToAddModList is null
\n
"
);
AssertFatal
(
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
uplinkBWP_ToAddModList
!=
NULL
,
"CellGroup->spCellConfig->spCellConfigDedicated->uplinkConfig->uplinkBWP_ToAddModList is null
\n
"
);
AssertFatal
(
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
downlinkBWP_ToAddModList
->
list
.
count
>=
bwp_id
,
"CellGroup->spCellConfig->spCellConfigDedicated->downlinkBWP_ToAddModList->list.count %d < bwp_id %d
\n
"
,
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
downlinkBWP_ToAddModList
->
list
.
count
,
bwp_id
);
AssertFatal
(
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
uplinkBWP_ToAddModList
->
list
.
count
>=
bwp_id
,
"CellGroup->spCellConfig->spCellConfigDedicated->uplinkConfig->uplinkBWP_ToAddModList->list.count %d < bwp_id %d
\n
"
,
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
uplinkBWP_ToAddModList
->
list
.
count
,
bwp_id
);
bwpd
=
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
downlinkBWP_ToAddModList
->
list
.
array
[
bwp_id
-
1
]
->
bwp_Dedicated
;
ubwpd
=
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
uplinkBWP_ToAddModList
->
list
.
array
[
bwp_id
-
1
]
->
bwp_Dedicated
;
}
else
if
(
CellGroup
)
{
// this is an initialBWP
AssertFatal
((
bwpd
=
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
initialDownlinkBWP
)
!=
NULL
,
"CellGroup->spCellConfig->spCellConfigDedicated->initialDownlinkBWP is null
\n
"
);
AssertFatal
((
ubwpd
=
CellGroup
->
spCellConfig
->
spCellConfigDedicated
->
uplinkConfig
->
initialUplinkBWP
)
!=
NULL
,
"CellGroup->spCellConfig->spCellConfigDedicated->uplnikConfig->initialUplinkBWP is null
\n
"
);
}
NR_SearchSpace_t
*
ss
=
NULL
;
// common search type uses DCI format 1_0
if
(
ss_type
==
NR_SearchSpace__searchSpaceType_PR_common
)
{
for
(
int
i
=
0
;
i
<
8
;
i
++
)
for
(
int
i
=
0
;
i
<
8
;
i
++
)
{
pdsch_to_harq_feedback
[
i
]
=
i
+
1
;
if
(
pdsch_to_harq_feedback
[
i
]
>*
max_fb_time
)
*
max_fb_time
=
pdsch_to_harq_feedback
[
i
];
}
}
else
{
// searching for a ue specific search space
int
found
=
0
;
for
(
int
i
=
0
;
i
<
bwp
->
bwp_Dedicated
->
pdcch_Config
->
choice
.
setup
->
searchSpacesToAddModList
->
list
.
count
;
i
++
)
{
ss
=
bwp
->
bwp_Dedicated
->
pdcch_Config
->
choice
.
setup
->
searchSpacesToAddModList
->
list
.
array
[
i
];
AssertFatal
(
bwpd
->
pdcch_Config
!=
NULL
,
"bwpd->pdcch_Config is null
\n
"
);
AssertFatal
(
bwpd
->
pdcch_Config
->
choice
.
setup
->
searchSpacesToAddModList
!=
NULL
,
"bwpd->pdcch_Config->choice.setup->searchSpacesToAddModList is null
\n
"
);
for
(
int
i
=
0
;
i
<
bwpd
->
pdcch_Config
->
choice
.
setup
->
searchSpacesToAddModList
->
list
.
count
;
i
++
)
{
ss
=
bwpd
->
pdcch_Config
->
choice
.
setup
->
searchSpacesToAddModList
->
list
.
array
[
i
];
AssertFatal
(
ss
->
controlResourceSetId
!=
NULL
,
"ss->controlResourceSetId is null
\n
"
);
AssertFatal
(
ss
->
searchSpaceType
!=
NULL
,
"ss->searchSpaceType is null
\n
"
);
if
(
ss
->
searchSpaceType
->
present
==
ss_type
)
{
...
...
@@ -2084,13 +2111,20 @@ void get_pdsch_to_harq_feedback(int Mod_idP,
if
(
ss
->
searchSpaceType
->
choice
.
ue_Specific
->
dci_Formats
==
NR_SearchSpace__searchSpaceType__ue_Specific__dci_Formats_formats0_0_And_1_0
)
{
for
(
int
i
=
0
;
i
<
8
;
i
++
)
for
(
int
i
=
0
;
i
<
8
;
i
++
)
{
pdsch_to_harq_feedback
[
i
]
=
i
+
1
;
if
(
pdsch_to_harq_feedback
[
i
]
>*
max_fb_time
)
*
max_fb_time
=
pdsch_to_harq_feedback
[
i
];
}
}
else
{
if
(
ubwp
->
bwp_Dedicated
->
pucch_Config
->
choice
.
setup
->
dl_DataToUL_ACK
!=
NULL
)
{
for
(
int
i
=
0
;
i
<
8
;
i
++
)
pdsch_to_harq_feedback
[
i
]
=
*
ubwp
->
bwp_Dedicated
->
pucch_Config
->
choice
.
setup
->
dl_DataToUL_ACK
->
list
.
array
[
i
];
AssertFatal
(
ubwpd
!=
NULL
,
"ubwpd shouldn't be null here
\n
"
);
if
(
ubwpd
->
pucch_Config
->
choice
.
setup
->
dl_DataToUL_ACK
!=
NULL
)
{
for
(
int
i
=
0
;
i
<
8
;
i
++
)
{
pdsch_to_harq_feedback
[
i
]
=
*
ubwpd
->
pucch_Config
->
choice
.
setup
->
dl_DataToUL_ACK
->
list
.
array
[
i
];
if
(
pdsch_to_harq_feedback
[
i
]
>*
max_fb_time
)
*
max_fb_time
=
pdsch_to_harq_feedback
[
i
];
}
}
else
AssertFatal
(
0
==
1
,
"There is no allocated dl_DataToUL_ACK for pdsch to harq feedback
\n
"
);
...
...
@@ -2099,6 +2133,7 @@ void get_pdsch_to_harq_feedback(int Mod_idP,
}
void
nr_csirs_scheduling
(
int
Mod_idP
,
frame_t
frame
,
sub_frame_t
slot
,
...
...
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
View file @
a21b6e0f
...
...
@@ -200,15 +200,18 @@ void nr_csi_meas_reporting(int Mod_idP,
frame_t
frameP
,
sub_frame_t
slotP
);
int
nr_acknack_scheduling
(
int
Mod_idP
,
int
UE_id
,
frame_t
frameP
,
sub_frame_t
slotP
,
int
r_pucch
);
int
nr_acknack_scheduling
(
int
mod_id
,
int
UE_id
,
frame_t
frame
,
sub_frame_t
slot
,
int
r_pucch
,
int
is_common
);
void
get_pdsch_to_harq_feedback
(
int
Mod_idP
,
int
UE_id
,
int
bwp_id
,
NR_SearchSpace__searchSpaceType_PR
ss_type
,
int
*
max_fb_time
,
uint8_t
*
pdsch_to_harq_feedback
);
void
nr_configure_css_dci_initial
(
nfapi_nr_dl_tti_pdcch_pdu_rel15_t
*
pdcch_pdu
,
...
...
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