• Eric Dumazet's avatar
    net: gro: enable fast path for more cases · c7583e9f
    Eric Dumazet authored
    Currently the so-called GRO fast path is only enabled for
    napi_frags_skb() callers.
    
    After the prior patch, we no longer have to clear frag0 whenever
    we pulled bytes to skb->head.
    
    We therefore can initialize frag0 to skb->data so that GRO
    fast path can be used in the following additional cases:
    
    - Drivers using header split (populating skb->data with headers,
      and having payload in one or more page fragments).
    
    - Drivers not using any page frag (entire packet is in skb->data)
    
    Add a likely() in skb_gro_may_pull() to help the compiler
    to generate better code if possible.
    Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
    Acked-by: default avatarPaolo Abeni <pabeni@redhat.com>
    Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
    c7583e9f
gro.h 13.1 KB