Subject: Re: [PATCH v2 net-next] pktgen: introduce 'rx' mode

From: Alexei Starovoitov <[email-masked]>
Date: Thu, 30 Apr 2015 21:55:39 -0700

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!