net: rate-limit warn-bad-offload splats.
Subsystems (2)
PATCH 1/1 net: rate-limit warn-bad-offload splats.
From: Ben Greear <[email protected]>
If one does do something unfortunate and allow a bad offload bug into the kernel, this the skb_warn_bad_offload can effectively live-lock the system, filling the logs with the same error over and over.
Add rate limitation to this so that box remains otherwise functional in this case.
--- net/core/dev.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)
net/core/dev.c +3 -0
@@ -2165,6 +2165,9 @@ static void skb_warn_bad_offload(const struct sk_buff *skb)struct net_device *dev = skb->dev;const char *driver ="" ; +if (!net_ratelimit ()) +return ; +if (dev && dev->dev.parent) driver =dev_driver_string (dev->dev.parent);
Signature · 1 line
1.7.3.4
From: [email protected]
Date: Fri, 19 Apr 2013 13:45:52 -0700
Quoted 8 lines
From: Ben Greear <[email protected]>
If one does do something unfortunate and allow a bad offload bug into the kernel, this the
skb_warn_bad_offloadcan effectively live-lock the system, filling the logs with the same error over and over.
Quoted 4 lines
Add rate limitation to this so that box remains otherwise functional in this case.
Signed-off-by Ben Greear <[email protected]>
Applied, thanks Ben.