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
c4706eda
Commit
c4706eda
authored
Jan 25, 2024
by
Ejaz Ahmed
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added further logs
parent
28f2129d
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
14 deletions
+19
-14
openair2/LAYER2/NR_MAC_UE/nr_slsch_scheduler.c
openair2/LAYER2/NR_MAC_UE/nr_slsch_scheduler.c
+1
-1
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
+18
-13
No files found.
openair2/LAYER2/NR_MAC_UE/nr_slsch_scheduler.c
View file @
c4706eda
...
...
@@ -69,7 +69,7 @@ bool nr_schedule_slsch(NR_UE_MAC_INST_t *mac, int frameP,int slotP, nr_sci_pdu_t
sci2_pdu
->
rv_index
=
0
;
sci2_pdu
->
source_id
=
0x12
;
sci2_pdu
->
dest_id
=
0xabcd
;
sci2_pdu
->
harq_feedback
=
1
;
sci2_pdu
->
harq_feedback
=
0
;
sci2_pdu
->
cast_type
=
1
;
if
(
format2
==
NR_SL_SCI_FORMAT_2C
||
format2
==
NR_SL_SCI_FORMAT_2A
)
sci2_pdu
->
csi_req
=
1
;
...
...
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
View file @
c4706eda
...
...
@@ -3266,7 +3266,7 @@ bool nr_ue_sl_pssch_scheduler(NR_UE_MAC_INST_t *mac,
if ((slot % 10) != 6) return false;
*/
LOG_
D
(
NR_MAC
,
"[UE%d] SL-PSSCH SCHEDULER: Frame:SLOT %d:%d, slot_type:%d
\n
"
,
LOG_
I
(
NR_MAC
,
"[UE%d] SL-PSSCH SCHEDULER: Frame:SLOT %d:%d, slot_type:%d
\n
"
,
sl_ind
->
module_id
,
frame
,
slot
,
sl_ind
->
slot_type
);
uint16_t
slsch_pdu_length_max
;
...
...
@@ -3543,7 +3543,7 @@ void nr_ue_sidelink_scheduler(nr_sidelink_indication_t *sl_ind) {
}
NR_UE_MAC_INST_t
*
mac
=
get_mac_inst
(
mod_id
);
LOG_
I
(
NR_MAC
,
"frame: %d, slot %d, slot type: %d, harq feedback %d
\n
"
,
frame
,
slot
,
sl_ind
->
slot_type
,
mac
->
sci_pdu_rx
.
harq_feedback
);
LOG_
D
(
NR_MAC
,
"frame: %d, slot %d, slot type: %d, harq feedback %d
\n
"
,
frame
,
slot
,
sl_ind
->
slot_type
,
mac
->
sci_pdu_rx
.
harq_feedback
);
sl_nr_ue_mac_params_t
*
sl_mac
=
mac
->
SL_MAC_PARAMS
;
sl_nr_phy_config_request_t
*
sl_cfg
=
&
sl_mac
->
sl_phy_config
.
sl_config_req
;
...
...
@@ -3571,6 +3571,8 @@ void nr_ue_sidelink_scheduler(nr_sidelink_indication_t *sl_ind) {
// Check if PSBCH slot and PSBCH should be transmitted or Received
is_psbch_slot
=
nr_ue_sl_psbch_scheduler
(
sl_ind
,
sl_mac
,
&
rx_config
,
&
tx_config
,
&
tti_action
);
if
(
is_psbch_slot
)
LOG_I
(
NR_MAC
,
"frame %d, slot %d slot type PSBCH %d
\n
"
,
frame
,
slot
,
sl_ind
->
slot_type
);
bool
tx_allowed
=
true
,
rx_allowed
=
true
;
if
(
mac
->
sl_tx_res_pool
&&
mac
->
sl_tx_res_pool
->
ext1
&&
mac
->
sl_tx_res_pool
->
ext1
->
sl_TimeResource_r16
)
{
...
...
@@ -3587,25 +3589,27 @@ void nr_ue_sidelink_scheduler(nr_sidelink_indication_t *sl_ind) {
}
if
(
sl_ind
->
slot_type
==
SIDELINK_SLOT_TYPE_TX
||
sl_ind
->
phy_data
==
NULL
)
rx_allowed
=
false
;
LOG_D
(
NR_MAC
,
"sync_ref %d, slot_rx %d, rx_allowed %d, psbch slot %d
\n
"
,
get_nrUE_params
()
->
sync_ref
,
sl_ind
->
slot_rx
,
rx_allowed
,
!
is_psbch_slot
);
if
(
get_nrUE_params
()
->
sync_ref
&&
rx_allowed
&&
!
is_psbch_slot
)
{
NR_SL_PSFCH_Config_r16_t
*
sl_psfch_config
=
mac
->
sl_rx_res_pool
->
sl_PSFCH_Config_r16
->
choice
.
setup
;
const
uint8_t
psfch_periods
[]
=
{
0
,
1
,
2
,
4
};
long
psfch_period
=
(
sl_psfch_config
->
sl_PSFCH_Period_r16
)
?
psfch_periods
[
*
sl_psfch_config
->
sl_PSFCH_Period_r16
]
:
0
;
if
(
slot
%
psfch_period
==
0
)
{
LOG_D
(
NR_MAC
,
"Scheduling PSFCH RX processing slot %d, sync_ref %d
\n
"
,
slot
,
get_nrUE_params
()
->
sync_ref
);
nr_ue_sl_psfch_rx_scheduler
(
mac
,
sl_ind
,
mac
->
sl_bwp
->
sl_BWP_Generic_r16
,
mac
->
sl_rx_res_pool
,
&
rx_config
,
&
tti_action
);
}
}
//
if (get_nrUE_params()->sync_ref && rx_allowed && !is_psbch_slot) {
//
NR_SL_PSFCH_Config_r16_t *sl_psfch_config = mac->sl_rx_res_pool->sl_PSFCH_Config_r16->choice.setup;
//
const uint8_t psfch_periods[] = {0,1,2,4};
//
long psfch_period = (sl_psfch_config->sl_PSFCH_Period_r16)
//
? psfch_periods[*sl_psfch_config->sl_PSFCH_Period_r16] : 0;
//
if (slot%psfch_period == 0) {
//
LOG_D(NR_MAC,"Scheduling PSFCH RX processing slot %d, sync_ref %d\n",slot,get_nrUE_params()->sync_ref);
//
nr_ue_sl_psfch_rx_scheduler(mac, sl_ind, mac->sl_bwp->sl_BWP_Generic_r16, mac->sl_rx_res_pool, &rx_config, &tti_action);
//
}
//
}
if
(((
get_nrUE_params
()
->
sync_ref
&&
sl_ind
->
slot_rx
>
9
)
||
(
!
get_nrUE_params
()
->
sync_ref
&&
sl_ind
->
slot_rx
<
10
))
&&
rx_allowed
&&
!
is_psbch_slot
)
{
LOG_I
(
NR_MAC
,
"frame %d, slot %d slot type %d
\n
"
,
frame
,
slot
,
sl_ind
->
slot_type
);
LOG_D
(
NR_MAC
,
"Scheduling PSCCH RX processing slot %d, sync_ref %d
\n
"
,
slot
,
get_nrUE_params
()
->
sync_ref
);
nr_ue_sl_pscch_rx_scheduler
(
sl_ind
,
mac
->
sl_bwp
,
mac
->
sl_rx_res_pool
,
&
rx_config
,
&
tti_action
);
}
if
(
!
is_psbch_slot
&&
tx_allowed
)
{
//Check if reserved slot or a sidelink resource configured in Rx/Tx resource pool timeresource bitmap
nr_ue_sl_pssch_scheduler
(
mac
,
sl_ind
,
mac
->
sl_bwp
,
mac
->
sl_tx_res_pool
,
&
tx_config
,
&
tti_action
);
LOG_I
(
NR_MAC
,
"frame %d, slot %d slot type %d
\n
"
,
frame
,
slot
,
sl_ind
->
slot_type
);
}
// FIXIT: harq_feedback value has issue, more often it is displaying as zero
if
(
sl_ind
->
slot_type
==
SIDELINK_SLOT_TYPE_TX
&&
mac
->
sci_pdu_rx
.
harq_feedback
)
{
...
...
@@ -3624,6 +3628,7 @@ void nr_ue_sidelink_scheduler(nr_sidelink_indication_t *sl_ind) {
if
(
current_harq
->
is_active
)
{
LOG_D
(
NR_MAC
,
"harq pid %d, sl_ind->frame_tx %d, sl_ind->slot_tx %d, frame %d, slot %d
\n
"
,
harq_pid
,
sl_ind
->
frame_tx
,
sl_ind
->
slot_tx
,
frame
,
slot
);
if
(
current_harq
->
feedback_slot
==
slot
&&
current_harq
->
feedback_frame
==
frame
&&
current_harq
->
is_active
)
{
LOG_I
(
NR_MAC
,
"frame %d, slot %d slot type tx feedback
\n
"
,
frame
,
slot
);
LOG_D
(
NR_MAC
,
"Scheduling PSFCH transmission at frame %d slot %d for harq_pid %d
\n
"
,
current_harq
->
feedback_frame
,
current_harq
->
feedback_slot
,
harq_pid
);
nr_ue_sl_psfch_scheduler
(
mac
,
sl_ind
,
mac
->
sl_bwp
,
mac
->
sl_tx_res_pool
,
&
tx_config
,
&
tti_action
);
current_harq
->
is_active
=
false
;
...
...
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