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
alex037yang
OpenXG-RAN
Commits
b74c668d
Commit
b74c668d
authored
Dec 12, 2017
by
shahab SHARIAT BAGHERI
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug zero division for pdcp stats
parent
b7a16618
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
openair2/LAYER2/PDCP_v10.1.0/pdcp.c
openair2/LAYER2/PDCP_v10.1.0/pdcp.c
+7
-2
No files found.
openair2/LAYER2/PDCP_v10.1.0/pdcp.c
View file @
b74c668d
...
...
@@ -928,7 +928,9 @@ void pdcp_update_stats(const protocol_ctxt_t* const ctxt_pP){
Pdcp_stats_tx_rate_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
Pdcp_stats_tx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
];
// unit: bit/s
Pdcp_stats_tx_throughput_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
Pdcp_stats_tx_bytes_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
*
8
;
Pdcp_stats_tx_aiat_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
(
uint32_t
)(
Pdcp_stats_tx_aiat_tmp_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
/
Pdcp_stats_tx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]);
if
(
Pdcp_stats_tx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
>
0
){
Pdcp_stats_tx_aiat_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
(
Pdcp_stats_tx_aiat_tmp_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
/
Pdcp_stats_tx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]);
}
Pdcp_stats_tx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
0
;
Pdcp_stats_tx_bytes_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
0
;
...
...
@@ -937,7 +939,10 @@ void pdcp_update_stats(const protocol_ctxt_t* const ctxt_pP){
// rx stats
Pdcp_stats_rx_rate_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
Pdcp_stats_rx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
];
Pdcp_stats_rx_goodput_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
Pdcp_stats_rx_bytes_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
*
8
;
Pdcp_stats_rx_aiat_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
(
uint32_t
)(
Pdcp_stats_rx_aiat_tmp_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
/
Pdcp_stats_rx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]);
if
(
Pdcp_stats_rx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
>
0
){
Pdcp_stats_rx_aiat_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
(
Pdcp_stats_rx_aiat_tmp_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
/
Pdcp_stats_rx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]);
}
Pdcp_stats_rx_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
0
;
Pdcp_stats_rx_bytes_s
[
ctxt_pP
->
module_id
][
pdcp_uid
][
rb_id
]
=
0
;
...
...
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