summaryrefslogtreecommitdiff
path: root/include/linux/netdevice.h
diff options
context:
space:
mode:
authorSteffen Klassert <steffen.klassert@secunet.com>2017-02-15 11:39:39 +0300
committerSteffen Klassert <steffen.klassert@secunet.com>2017-02-15 11:39:39 +0300
commit5f114163f2f5eb2edbb49c4d3e0b405c7a8a7e2a (patch)
tree6b47a6960f8928ec997ef99a5f1ef23e0b59a298 /include/linux/netdevice.h
parentb0fcee825c0ad05057a97d1f4685e1b9e9d00c53 (diff)
downloadlinux-5f114163f2f5eb2edbb49c4d3e0b405c7a8a7e2a.tar.xz
net: Add a skb_gro_flush_final helper.
Add a skb_gro_flush_final helper to prepare for consuming skbs in call_gro_receive. We will extend this helper to not touch the skb if the skb is consumed by a gro callback with a followup patch. We need this to handle the upcomming IPsec ESP callbacks as they reinject the skb to the napi_gro_receive asynchronous. The handler is used in all gro_receive functions that can call the ESP gro handlers. Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Diffstat (limited to 'include/linux/netdevice.h')
-rw-r--r--include/linux/netdevice.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 58afbd1cc659..f9da3acfee9a 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -2661,6 +2661,11 @@ static inline void skb_gro_remcsum_cleanup(struct sk_buff *skb,
remcsum_unadjust((__sum16 *)ptr, grc->delta);
}
+static inline void skb_gro_flush_final(struct sk_buff *skb, struct sk_buff **pp, int flush)
+{
+ NAPI_GRO_CB(skb)->flush |= flush;
+}
+
static inline int dev_hard_header(struct sk_buff *skb, struct net_device *dev,
unsigned short type,
const void *daddr, const void *saddr,