[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5543074B.6020209@plumgrid.com>
Date: Thu, 30 Apr 2015 21:55:39 -0700
From: Alexei Starovoitov <ast@...mgrid.com>
To: Eric Dumazet <eric.dumazet@...il.com>
CC: "David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>, netdev@...r.kernel.org
Subject: Re: [PATCH v2 net-next] pktgen: introduce 'rx' mode
On 4/30/15 9:46 PM, Eric Dumazet wrote:
> On Thu, 2015-04-30 at 18:18 -0700, Alexei Starovoitov wrote:
>
>> + local_bh_disable();
>> + atomic_add(burst, &skb->users);
>
> this atomic_add() could be done before local_bh_disable()
ok
>> + break;
>
> after a break; you don't need the 'else', and therefore can save one
> tab/ indent level.
yes. good point.
>> + } else {
>> + /* skb was 'freed' by stack, so clean few
>> + * bits and reuse it
>> + */
>> + skb->tc_verd = 0; /* reset reclass/redir ttl */
>
> tc_verd needs CONFIG_NET_CLS_ACT
great catch! thanks
> You could put the out: label here, and remove one local_bh_enable()
> before "goto out;"
sure. why not.
Thanks for the thorough review!
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists