On Tue, 27 Aug 2019 01:15:16 +0200
Davide Caratti <dcara...@redhat.com> wrote:

> diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c
> index 11c03cf4aa74..c89b787785a1 100644
> --- a/net/sched/sch_generic.c
> +++ b/net/sched/sch_generic.c
> @@ -688,12 +688,14 @@ static void pfifo_fast_reset(struct Qdisc *qdisc)
>                       kfree_skb(skb);
>       }
>  
> -     for_each_possible_cpu(i) {
> -             struct gnet_stats_queue *q = per_cpu_ptr(qdisc->cpu_qstats, i);
> +     if (qdisc_is_percpu_stats(qdisc))

This needs curly brackets, as the block has multiple lines (for coding
style only).

> +             for_each_possible_cpu(i) {
> +                     struct gnet_stats_queue *q =
> +                             per_cpu_ptr(qdisc->cpu_qstats, i);

And you could split declaration and assignment here, it takes two lines
anyway and becomes more readable.

-- 
Stefano

Reply via email to