summaryrefslogtreecommitdiff
path: root/net/ipv4/fou.c
diff options
context:
space:
mode:
authorTom Herbert <tom@herbertland.com>2015-08-20 03:07:34 +0300
committerDavid S. Miller <davem@davemloft.net>2015-08-24 01:59:56 +0300
commit270136613bf7306e2b83457628e2b2f6c6be3989 (patch)
tree3793bb86b081a9c2a6811e1c4c2118484111c25b /net/ipv4/fou.c
parent58ce31cca1ffe057f4744c3f671e3e84606d3d4a (diff)
downloadlinux-270136613bf7306e2b83457628e2b2f6c6be3989.tar.xz
fou: Do WARN_ON_ONCE in gue_gro_receive for bad proto callbacks
Do WARN_ON_ONCE instead of WARN_ON in gue_gro_receive when the offload callcaks are bad (either don't exist or gro_receive is not specified). Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/fou.c')
-rw-r--r--net/ipv4/fou.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/fou.c b/net/ipv4/fou.c
index eb11f9506894..2d1646cff057 100644
--- a/net/ipv4/fou.c
+++ b/net/ipv4/fou.c
@@ -347,7 +347,7 @@ static struct sk_buff **gue_gro_receive(struct sk_buff **head,
rcu_read_lock();
offloads = NAPI_GRO_CB(skb)->is_ipv6 ? inet6_offloads : inet_offloads;
ops = rcu_dereference(offloads[guehdr->proto_ctype]);
- if (WARN_ON(!ops || !ops->callbacks.gro_receive))
+ if (WARN_ON_ONCE(!ops || !ops->callbacks.gro_receive))
goto out_unlock;
pp = ops->callbacks.gro_receive(head, skb);