From: Alexei Starovoitov <ast@plumgrid.com>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: "David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
netdev@vger.kernel.org
Subject: Re: [PATCH v2 net-next] pktgen: introduce 'rx' mode
Date: Thu, 30 Apr 2015 21:55:39 -0700 [thread overview]
Message-ID: <5543074B.6020209@plumgrid.com> (raw)
In-Reply-To: <1430455610.3711.118.camel@edumazet-glaptop2.roam.corp.google.com>
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!
prev parent reply other threads:[~2015-05-01 4:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-01 1:18 [PATCH v2 net-next] pktgen: introduce 'rx' mode Alexei Starovoitov
2015-05-01 4:46 ` Eric Dumazet
2015-05-01 4:55 ` Alexei Starovoitov [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5543074B.6020209@plumgrid.com \
--to=ast@plumgrid.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=eric.dumazet@gmail.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.