bug.h: Add WARN_RATELIMIT
authorJoe Perches <joe@perches.com>
Sat, 21 May 2011 07:48:39 +0000 (07:48 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 23 May 2011 21:37:43 +0000 (17:37 -0400)
commitb3eec79b0776e5340a3db75b34953977c7e5086e
tree33f6c56a27e8503fa2881632f35c80618a00a888
parent8efa885406359af300d46910642b50ca82c0fe47
bug.h: Add WARN_RATELIMIT

Add a generic mechanism to ratelimit WARN(foo, fmt, ...) messages
using a hidden per call site static struct ratelimit_state.

Also add an __WARN_RATELIMIT variant to be able to use a specific
struct ratelimit_state.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/asm-generic/bug.h