[ 3.5.y.z extended stable ] Patch "net: rate-limit warn-bad-offload splats." has been added to staging queue
Luis Henriques
luis.henriques at canonical.com
Wed May 1 23:35:12 UTC 2013
This is a note to let you know that I have just added a patch titled
net: rate-limit warn-bad-offload splats.
to the linux-3.5.y-queue branch of the 3.5.y.z extended stable tree
which can be found at:
http://kernel.ubuntu.com/git?p=ubuntu/linux.git;a=shortlog;h=refs/heads/linux-3.5.y-queue
If you, or anyone else, feels it should not be added to this tree, please
reply to this email.
For more information about the 3.5.y.z tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable
Thanks.
-Luis
------
>From a6f1fa3ce26418b261ad49aa0eb8d9f501feb207 Mon Sep 17 00:00:00 2001
From: Ben Greear <greearb at candelatech.com>
Date: Fri, 19 Apr 2013 10:45:52 +0000
Subject: [PATCH] net: rate-limit warn-bad-offload splats.
commit c846ad9b880ece01bb4d8d07ba917734edf0324f upstream.
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.
Signed-off-by: Ben Greear <greearb at candelatech.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Luis Henriques <luis.henriques at canonical.com>
---
net/core/dev.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/net/core/dev.c b/net/core/dev.c
index 196bc5f..ba9d7a7 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -1893,6 +1893,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);
--
1.8.1.2
More information about the kernel-team
mailing list