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
746fb828
Commit
746fb828
authored
Sep 03, 2020
by
Raphael Defosseux
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/NR_UE_get_Qm_dl_fix' into develop_integration_2020_w36
parents
2dcf50a5
15a376fa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
70 additions
and
7 deletions
+70
-7
openair2/LAYER2/NR_MAC_COMMON/nr_mac_common.c
openair2/LAYER2/NR_MAC_COMMON/nr_mac_common.c
+68
-4
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
+2
-3
No files found.
openair2/LAYER2/NR_MAC_COMMON/nr_mac_common.c
View file @
746fb828
...
...
@@ -1616,92 +1616,156 @@ uint16_t Table_61412[28][2] = {{2,30},{2,40},{2,50},{2,64},{2,78},{2,99},{2,120}
uint8_t
nr_get_Qm_dl
(
uint8_t
Imcs
,
uint8_t
table_idx
)
{
switch
(
table_idx
)
{
case
0
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 0 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51311
[
Imcs
][
0
]);
break
;
case
1
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 1 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_51312
[
Imcs
][
0
]);
break
;
case
2
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 2 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51313
[
Imcs
][
0
]);
break
;
default:
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
1,3
])
\n
"
,
table_idx
);
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
0,2
])
\n
"
,
table_idx
);
}
}
uint32_t
nr_get_code_rate_dl
(
uint8_t
Imcs
,
uint8_t
table_idx
)
{
switch
(
table_idx
)
{
case
0
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 0 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51311
[
Imcs
][
1
]);
break
;
case
1
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 1 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_51312
[
Imcs
][
1
]);
break
;
case
2
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 2 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51313
[
Imcs
][
1
]);
break
;
default:
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
1,3
])
\n
"
,
table_idx
);
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
0,2
])
\n
"
,
table_idx
);
}
}
uint8_t
nr_get_Qm_ul
(
uint8_t
Imcs
,
uint8_t
table_idx
)
{
switch
(
table_idx
)
{
case
0
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 0 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51311
[
Imcs
][
0
]);
break
;
case
1
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 1 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_51312
[
Imcs
][
0
]);
break
;
case
2
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 2 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51313
[
Imcs
][
0
]);
break
;
case
3
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 3 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_61411
[
Imcs
][
0
]);
break
;
case
4
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 4 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_61412
[
Imcs
][
0
]);
break
;
default:
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
1,2
])
\n
"
,
table_idx
);
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
0,4
])
\n
"
,
table_idx
);
}
}
uint32_t
nr_get_code_rate_ul
(
uint8_t
Imcs
,
uint8_t
table_idx
)
{
switch
(
table_idx
)
{
case
0
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 0 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51311
[
Imcs
][
1
]);
break
;
case
1
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 1 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_51312
[
Imcs
][
1
]);
break
;
case
2
:
if
(
Imcs
>
28
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 2 (expected range [0,28])
\n
"
,
Imcs
);
Imcs
=
28
;
}
return
(
Table_51313
[
Imcs
][
1
]);
break
;
case
3
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 3 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_61411
[
Imcs
][
1
]);
break
;
case
4
:
if
(
Imcs
>
27
)
{
LOG_E
(
MAC
,
"Invalid MCS index %d for MCS table 4 (expected range [0,27])
\n
"
,
Imcs
);
Imcs
=
27
;
}
return
(
Table_61412
[
Imcs
][
1
]);
break
;
default:
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
1,2
])
\n
"
,
table_idx
);
AssertFatal
(
0
,
"Invalid MCS table index %d (expected in range [
0,4
])
\n
"
,
table_idx
);
}
}
...
...
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
View file @
746fb828
...
...
@@ -3801,9 +3801,8 @@ void nr_ue_process_mac_pdu(module_id_t module_idP,
}
pdu_ptr
+=
(
mac_subheader_len
+
mac_ce_len
+
mac_sdu_len
);
pdu_len
-=
(
mac_subheader_len
+
mac_ce_len
+
mac_sdu_len
);
if
(
pdu_len
<
0
)
//AssertFatal(pdu_len >= 0, "[MAC] nr_ue_process_mac_pdu, residual mac pdu length %d < 0!, mac_pdu_len %d, mac_sdu_len %d, mac_ce_len %d, mac_subheader_len %d\n",
LOG_E
(
MAC
,
"nr_ue_process_mac_pdu, residual mac pdu length %d < 0!, mac_pdu_len %d, mac_sdu_len %d, mac_ce_len %d, mac_subheader_len %d
\n
"
,
pdu_len
,
mac_pdu_len
,
mac_sdu_len
,
mac_ce_len
,
mac_sdu_len
);
if
(
pdu_len
<
0
)
LOG_E
(
MAC
,
"[MAC] nr_ue_process_mac_pdu, residual mac pdu length %d < 0!
\n
"
,
pdu_len
);
}
}
...
...
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