* [PATCH iproute2-next] Revert "tc: pie: change maximum integer value of tc_pie_xstats->prob"
@ 2020-03-10 18:15 Leslie Monis
2020-03-10 18:30 ` David Ahern
0 siblings, 1 reply; 2+ messages in thread
From: Leslie Monis @ 2020-03-10 18:15 UTC (permalink / raw)
To: Linux NetDev
Cc: David Ahern, Stephen Hemminger, Mohit P . Tahiliani,
Gautam Ramakrishnan, Eric Dumazet
This reverts commit 92cfe3260e9110c3d33627847b6eaa153664c79c.
Kernel commit 3f95f55eb55d ("net: sched: pie: change tc_pie_xstats->prob")
removes the need to change the maximum integer value of
tc_pie_stats->prob here.
Suggested-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Leslie Monis <lesliemonis@gmail.com>
---
tc/q_pie.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tc/q_pie.c b/tc/q_pie.c
index e6939652..709a78b4 100644
--- a/tc/q_pie.c
+++ b/tc/q_pie.c
@@ -223,9 +223,9 @@ static int pie_print_xstats(struct qdisc_util *qu, FILE *f,
st = RTA_DATA(xstats);
- /* prob is returned as a fracion of (2^56 - 1) */
+ /* prob is returned as a fracion of maximum integer value */
print_float(PRINT_ANY, "prob", " prob %lg",
- (double)st->prob / (double)(UINT64_MAX >> 8));
+ (double)st->prob / (double)UINT64_MAX);
print_uint(PRINT_JSON, "delay", NULL, st->delay);
print_string(PRINT_FP, NULL, " delay %s", sprint_time(st->delay, b1));
--
2.17.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH iproute2-next] Revert "tc: pie: change maximum integer value of tc_pie_xstats->prob"
2020-03-10 18:15 [PATCH iproute2-next] Revert "tc: pie: change maximum integer value of tc_pie_xstats->prob" Leslie Monis
@ 2020-03-10 18:30 ` David Ahern
0 siblings, 0 replies; 2+ messages in thread
From: David Ahern @ 2020-03-10 18:30 UTC (permalink / raw)
To: Leslie Monis, Linux NetDev
Cc: Stephen Hemminger, Mohit P . Tahiliani, Gautam Ramakrishnan,
Eric Dumazet
On 3/10/20 12:15 PM, Leslie Monis wrote:
> This reverts commit 92cfe3260e9110c3d33627847b6eaa153664c79c.
>
> Kernel commit 3f95f55eb55d ("net: sched: pie: change tc_pie_xstats->prob")
> removes the need to change the maximum integer value of
> tc_pie_stats->prob here.
>
> Suggested-by: Eric Dumazet <edumazet@google.com>
> Signed-off-by: Leslie Monis <lesliemonis@gmail.com>
> ---
> tc/q_pie.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tc/q_pie.c b/tc/q_pie.c
> index e6939652..709a78b4 100644
> --- a/tc/q_pie.c
> +++ b/tc/q_pie.c
> @@ -223,9 +223,9 @@ static int pie_print_xstats(struct qdisc_util *qu, FILE *f,
>
> st = RTA_DATA(xstats);
>
> - /* prob is returned as a fracion of (2^56 - 1) */
> + /* prob is returned as a fracion of maximum integer value */
> print_float(PRINT_ANY, "prob", " prob %lg",
> - (double)st->prob / (double)(UINT64_MAX >> 8));
> + (double)st->prob / (double)UINT64_MAX);
> print_uint(PRINT_JSON, "delay", NULL, st->delay);
> print_string(PRINT_FP, NULL, " delay %s", sprint_time(st->delay, b1));
>
>
applied to iproute2-next. Thanks
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-03-10 18:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-10 18:15 [PATCH iproute2-next] Revert "tc: pie: change maximum integer value of tc_pie_xstats->prob" Leslie Monis
2020-03-10 18:30 ` David Ahern
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).