Commit c8c9f9a3de2c50c876b1068dd41f9a06c5749f80

Authored by Herbert Xu
Committed by David S. Miller
1 parent 364c6badde

[NET] ppp: Remove unnecessary pskb_may_pull

In ppp_receive_nonmp_frame, we call pskb_may_pull(skb, skb->len) if the
tailroom is >= 124.  This is pointless because this pskb_may_pull is only
needed if the skb is non-linear.  However, if it is non-linear then the
tailroom would be zero.

So it can be safely removed.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>

Showing 1 changed file with 0 additions and 2 deletions Side-by-side Diff

drivers/net/ppp_generic.c
... ... @@ -1609,8 +1609,6 @@
1609 1609 kfree_skb(skb);
1610 1610 skb = ns;
1611 1611 }
1612   - else if (!pskb_may_pull(skb, skb->len))
1613   - goto err;
1614 1612 else
1615 1613 skb->ip_summed = CHECKSUM_NONE;
1616 1614