From: Roland Stigge <stigge@antcom.de>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: netdev@vger.kernel.org, David Miller <davem@davemloft.net>
Subject: Re: [PATCH] net: lpc_eth: no need to reserve 8 extra bytes in rx skb
Date: Wed, 04 Apr 2012 00:54:19 +0200 [thread overview]
Message-ID: <4F7B7F9B.3050503@antcom.de> (raw)
In-Reply-To: <1333490531.18626.336.camel@edumazet-glaptop>
Hi Eric,
On 04/04/12 00:02, Eric Dumazet wrote:
> Probably a leftover from ancient code...
...
> --- a/drivers/net/ethernet/nxp/lpc_eth.c
> +++ b/drivers/net/ethernet/nxp/lpc_eth.c
> @@ -990,10 +990,10 @@ static int __lpc_handle_recv(struct net_device *ndev, int budget)
> ndev->stats.rx_errors++;
> } else {
> /* Packet is good */
> - skb = dev_alloc_skb(len + 8);
> - if (!skb)
> + skb = dev_alloc_skb(len);
I remember this issue from the discussion, a note from Ben Hutchings
actually, where there was a further "skb_reserve(skb, 8);" in the "else"
case below. Looks like I only removed the skb_reserve().
Can't find this review from you - I hope there are no other issues left?
(Was I on CC?)
> + if (!skb) {
> ndev->stats.rx_dropped++;
> - else {
> + } else {
Why add curly braces around a single statement?
Thanks,
Roland
next prev parent reply other threads:[~2012-04-03 22:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-03 22:02 [PATCH] net: lpc_eth: no need to reserve 8 extra bytes in rx skb Eric Dumazet
2012-04-03 22:54 ` Roland Stigge [this message]
2012-04-03 22:58 ` David Miller
2012-04-03 23:42 ` Roland Stigge
2012-04-04 22:09 ` David Miller
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=4F7B7F9B.3050503@antcom.de \
--to=stigge@antcom.de \
--cc=davem@davemloft.net \
--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.