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
promise
OpenXG-RAN
Commits
b5fc8a48
Commit
b5fc8a48
authored
Nov 07, 2020
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
UL_tti_req_ahead: pre-set slot and frame
parent
56604957
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
2 deletions
+33
-2
openair2/LAYER2/NR_MAC_gNB/config.c
openair2/LAYER2/NR_MAC_gNB/config.c
+13
-0
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
+12
-0
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_ulsch.c
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_ulsch.c
+8
-2
No files found.
openair2/LAYER2/NR_MAC_gNB/config.c
View file @
b5fc8a48
...
@@ -309,6 +309,7 @@ void config_common(int Mod_idP, int pdsch_AntennaPorts, NR_ServingCellConfigComm
...
@@ -309,6 +309,7 @@ void config_common(int Mod_idP, int pdsch_AntennaPorts, NR_ServingCellConfigComm
extern
uint16_t
sl_ahead
;
int
rrc_mac_config_req_gNB
(
module_id_t
Mod_idP
,
int
rrc_mac_config_req_gNB
(
module_id_t
Mod_idP
,
int
ssb_SubcarrierOffset
,
int
ssb_SubcarrierOffset
,
int
pdsch_AntennaPorts
,
int
pdsch_AntennaPorts
,
...
@@ -328,6 +329,18 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
...
@@ -328,6 +329,18 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
RC
.
nrmac
[
Mod_idP
]
->
UL_tti_req_ahead
[
0
]
=
calloc
(
num_slots_per_tdd
,
sizeof
(
nfapi_nr_ul_tti_request_t
));
RC
.
nrmac
[
Mod_idP
]
->
UL_tti_req_ahead
[
0
]
=
calloc
(
num_slots_per_tdd
,
sizeof
(
nfapi_nr_ul_tti_request_t
));
AssertFatal
(
RC
.
nrmac
[
Mod_idP
]
->
UL_tti_req_ahead
[
0
],
AssertFatal
(
RC
.
nrmac
[
Mod_idP
]
->
UL_tti_req_ahead
[
0
],
"could not allocate memory for RC.nrmac[]->UL_tti_req_ahead[]
\n
"
);
"could not allocate memory for RC.nrmac[]->UL_tti_req_ahead[]
\n
"
);
/* fill in slot/frame numbers: slot is fixed, frame will be updated by
* scheduler */
for
(
int
i
=
0
;
i
<
num_slots_per_tdd
;
++
i
)
{
nfapi_nr_ul_tti_request_t
*
req
=
&
RC
.
nrmac
[
Mod_idP
]
->
UL_tti_req_ahead
[
0
][
i
];
/* consider that scheduler runs sl_ahead: the first sl_ahead slots are
* already "in the past" and thus we put frame 1 instead of 0! Note that
* variable sl_ahead seems to not be correctly initialized, but I leave
* it for information purposes here (the fix would always put 0, what
* happens now, too) */
req
->
SFN
=
i
<
sl_ahead
;
req
->
Slot
=
i
;
}
LOG_I
(
MAC
,
"Configuring common parameters from NR ServingCellConfig
\n
"
);
LOG_I
(
MAC
,
"Configuring common parameters from NR ServingCellConfig
\n
"
);
...
...
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
View file @
b5fc8a48
...
@@ -92,9 +92,13 @@ void clear_nr_nfapi_information(gNB_MAC_INST * gNB,
...
@@ -92,9 +92,13 @@ void clear_nr_nfapi_information(gNB_MAC_INST * gNB,
int
CC_idP
,
int
CC_idP
,
frame_t
frameP
,
frame_t
frameP
,
sub_frame_t
slotP
){
sub_frame_t
slotP
){
NR_ServingCellConfigCommon_t
*
scc
=
gNB
->
common_channels
->
ServingCellConfigCommon
;
const
int
num_slots
=
slots_per_frame
[
*
scc
->
ssbSubcarrierSpacing
];
nfapi_nr_dl_tti_request_t
*
DL_req
=
&
gNB
->
DL_req
[
0
];
nfapi_nr_dl_tti_request_t
*
DL_req
=
&
gNB
->
DL_req
[
0
];
nfapi_nr_ul_tti_request_t
*
UL_tti_req
=
&
gNB
->
UL_tti_req
[
0
];
nfapi_nr_ul_tti_request_t
*
UL_tti_req
=
&
gNB
->
UL_tti_req
[
0
];
nfapi_nr_ul_tti_request_t
*
future_ul_tti_req
=
&
gNB
->
UL_tti_req_ahead
[
CC_idP
][(
slotP
+
num_slots
-
1
)
%
num_slots
];
nfapi_nr_ul_dci_request_t
*
UL_dci_req
=
&
gNB
->
UL_dci_req
[
0
];
nfapi_nr_ul_dci_request_t
*
UL_dci_req
=
&
gNB
->
UL_dci_req
[
0
];
nfapi_nr_tx_data_request_t
*
TX_req
=
&
gNB
->
TX_req
[
0
];
nfapi_nr_tx_data_request_t
*
TX_req
=
&
gNB
->
TX_req
[
0
];
...
@@ -119,6 +123,14 @@ void clear_nr_nfapi_information(gNB_MAC_INST * gNB,
...
@@ -119,6 +123,14 @@ void clear_nr_nfapi_information(gNB_MAC_INST * gNB,
UL_tti_req
[
CC_idP
].
n_ulcch
=
0
;
UL_tti_req
[
CC_idP
].
n_ulcch
=
0
;
UL_tti_req
[
CC_idP
].
n_group
=
0
;
UL_tti_req
[
CC_idP
].
n_group
=
0
;
/* advance last round's future UL_tti_req to be ahead of current frame/slot */
future_ul_tti_req
->
SFN
=
(
slotP
==
0
?
frameP
:
frameP
+
1
)
%
1024
;
/* future_ul_tti_req->Slot is fixed! */
future_ul_tti_req
->
n_pdus
=
0
;
future_ul_tti_req
->
n_ulsch
=
0
;
future_ul_tti_req
->
n_ulcch
=
0
;
future_ul_tti_req
->
n_group
=
0
;
TX_req
[
CC_idP
].
Number_of_PDUs
=
0
;
TX_req
[
CC_idP
].
Number_of_PDUs
=
0
;
}
}
...
...
openair2/LAYER2/NR_MAC_gNB/gNB_scheduler_ulsch.c
View file @
b5fc8a48
...
@@ -539,8 +539,14 @@ void nr_schedule_ulsch(module_id_t module_id,
...
@@ -539,8 +539,14 @@ void nr_schedule_ulsch(module_id_t module_id,
/* PUSCH in a later slot, but corresponding DCI now! */
/* PUSCH in a later slot, but corresponding DCI now! */
nfapi_nr_ul_tti_request_t
*
future_ul_tti_req
=
&
RC
.
nrmac
[
module_id
]
->
UL_tti_req_ahead
[
0
][
sched_slot
];
nfapi_nr_ul_tti_request_t
*
future_ul_tti_req
=
&
RC
.
nrmac
[
module_id
]
->
UL_tti_req_ahead
[
0
][
sched_slot
];
future_ul_tti_req
->
SFN
=
sched_frame
;
AssertFatal
(
future_ul_tti_req
->
SFN
==
sched_frame
future_ul_tti_req
->
Slot
=
sched_slot
;
&&
future_ul_tti_req
->
Slot
==
sched_slot
,
"%d.%d future UL_tti_req's frame.slot %d.%d does not match PUSCH %d.%d
\n
"
,
frame
,
slot
,
future_ul_tti_req
->
SFN
,
future_ul_tti_req
->
Slot
,
sched_frame
,
sched_slot
);
nfapi_nr_ul_dci_request_t
*
ul_dci_req
=
&
RC
.
nrmac
[
module_id
]
->
UL_dci_req
[
0
];
nfapi_nr_ul_dci_request_t
*
ul_dci_req
=
&
RC
.
nrmac
[
module_id
]
->
UL_dci_req
[
0
];
ul_dci_req
->
SFN
=
frame
;
ul_dci_req
->
SFN
=
frame
;
ul_dci_req
->
Slot
=
slot
;
ul_dci_req
->
Slot
=
slot
;
...
...
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