Subject: Re: [PATCH net-next] net_sched: psched_ratecfg_precompute() improvements

From: Ben Greear <[email-masked]>
Date: Thu, 06 Jun 2013 13:37:55 -0700

On 06/06/2013 01:27 PM, Eric Dumazet wrote:
> From: Eric Dumazet <[email-masked]>
>
> Before allowing 64bits bytes rates, refactor
> psched_ratecfg_precompute() to get better comments
> and increased accuracy.
>
> Signed-off-by: Eric Dumazet <[email-masked]>
> ---
>   include/net/sch_generic.h |    4 +--
>   net/sched/sch_generic.c   |   42 ++++++++++++++++--------------------
>   2 files changed, 21 insertions(+), 25 deletions(-)
>
> diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h
> index e7f4e21..e788397 100644
> --- a/include/net/sch_generic.h
> +++ b/include/net/sch_generic.h
> @@ -679,7 +679,7 @@ static inline struct sk_buff *skb_act_clone(struct sk_buff *skb, gfp_t gfp_mask,
>   #endif
>
>   struct psched_ratecfg {
> -	u64	rate_bps;
> +	u64	rate_bps; /* bytes per second */

Seems like rate_bytes_ps would be better..rate_bps is going to
be easily confused with bits-per-second...

Ben

-- 
Ben Greear <[email-masked]>
Candela Technologies Inc  http://www.candelatech.com