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
Michael Black
OpenXG-RAN
Commits
41e2b21d
Commit
41e2b21d
authored
Nov 15, 2021
by
mjoang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change missing mutex init per review.
parent
d0488b5d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
6 deletions
+5
-6
openair2/LAYER2/NR_MAC_UE/config_ue.c
openair2/LAYER2/NR_MAC_UE/config_ue.c
+2
-0
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
+3
-6
No files found.
openair2/LAYER2/NR_MAC_UE/config_ue.c
View file @
41e2b21d
...
...
@@ -660,6 +660,8 @@ int nr_rrc_mac_config_req_ue(
if
(
mac
->
scc_SIB
->
tdd_UL_DL_ConfigurationCommon
->
pattern1
.
nrofUplinkSymbols
>
0
)
num_slots_ul
++
;
LOG_I
(
MAC
,
"Initializing ul_config_request. num_slots_ul = %d
\n
"
,
num_slots_ul
);
mac
->
ul_config_request
=
(
fapi_nr_ul_config_request_t
*
)
calloc
(
num_slots_ul
,
sizeof
(
fapi_nr_ul_config_request_t
));
for
(
int
i
=
0
;
i
<
num_slots_ul
;
i
++
)
pthread_mutex_init
(
&
(
mac
->
ul_config_request
[
i
].
mutex_ul_config
),
NULL
);
// Setup the SSB to Rach Occasions mapping according to the config
build_ssb_to_ro_map
(
mac
);
//->scc, mac->phy_config.config_req.cell_config.frame_duplex_type);
mac
->
if_module
->
phy_config_request
(
&
mac
->
phy_config
);
...
...
openair2/LAYER2/NR_MAC_UE/nr_ue_scheduler.c
View file @
41e2b21d
...
...
@@ -948,7 +948,6 @@ NR_UE_L2_STATE_t nr_ue_scheduler(nr_downlink_indication_t *dl_info, nr_uplink_in
if
(
ul_config
){
pthread_mutex_lock
(
&
ul_config
->
mutex_ul_config
);
if
((
ul_info
->
slot_tx
==
ul_config
->
slot
&&
ul_info
->
frame_tx
==
ul_config
->
sfn
)
&&
ul_config
->
number_pdus
>
0
){
pthread_mutex_unlock
(
&
ul_config
->
mutex_ul_config
);
LOG_D
(
NR_MAC
,
"In %s:[%d.%d]: number of UL PDUs: %d with UL transmission in [%d.%d]
\n
"
,
__FUNCTION__
,
frame_tx
,
slot_tx
,
ul_config
->
number_pdus
,
ul_config
->
sfn
,
ul_config
->
slot
);
...
...
@@ -959,7 +958,6 @@ NR_UE_L2_STATE_t nr_ue_scheduler(nr_downlink_indication_t *dl_info, nr_uplink_in
tx_req
.
sfn
=
frame_tx
;
tx_req
.
number_of_pdus
=
0
;
pthread_mutex_lock
(
&
ul_config
->
mutex_ul_config
);
for
(
int
j
=
0
;
j
<
ul_config
->
number_pdus
;
j
++
)
{
uint8_t
*
ulsch_input_buffer
=
&
(
ulsch_input_buffer_array
[
tx_req
.
number_of_pdus
][
MAX_ULSCH_PAYLOAD_BYTES
]);
...
...
@@ -1020,16 +1018,15 @@ NR_UE_L2_STATE_t nr_ue_scheduler(nr_downlink_indication_t *dl_info, nr_uplink_in
}
}
}
pthread_mutex_unlock
(
&
ul_config
->
mutex_ul_config
);
pthread_mutex_unlock
(
&
ul_config
->
mutex_ul_config
);
// avoid double lock
fill_scheduled_response
(
&
scheduled_response
,
NULL
,
ul_config
,
&
tx_req
,
mod_id
,
cc_id
,
rx_frame
,
rx_slot
,
ul_info
->
thread_id
);
if
(
mac
->
if_module
!=
NULL
&&
mac
->
if_module
->
scheduled_response
!=
NULL
){
mac
->
if_module
->
scheduled_response
(
&
scheduled_response
);
}
pthread_mutex_lock
(
&
ul_config
->
mutex_ul_config
);
}
else
{
pthread_mutex_unlock
(
&
ul_config
->
mutex_ul_config
);
}
pthread_mutex_unlock
(
&
ul_config
->
mutex_ul_config
);
}
}
...
...
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