summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2011-05-21 07:48:40 +0000
committerDavid S. Miller <davem@davemloft.net>2011-05-23 17:37:43 -0400
commit6c4a5cb219520c7bc937ee186ca53f03733bd09f (patch)
treed7975f40b55a2aecdf30723ed78bcfa43b415e06 /net
parentb3eec79b0776e5340a3db75b34953977c7e5086e (diff)
net: filter: Use WARN_RATELIMIT
A mis-configured filter can spam the logs with lots of stack traces. Rate-limit the warnings and add printout of the bogus filter information. Original-patch-by: Ben Greear <greearb@candelatech.com> Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/core/filter.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/core/filter.c b/net/core/filter.c
index 0eb8c4466eaa..0e3622f1dcb1 100644
--- a/net/core/filter.c
+++ b/net/core/filter.c
@@ -350,7 +350,9 @@ load_b:
continue;
}
default:
- WARN_ON(1);
+ WARN_RATELIMIT(1, "Unknown code:%u jt:%u tf:%u k:%u\n",
+ fentry->code, fentry->jt,
+ fentry->jf, fentry->k);
return 0;
}
}