diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-08-21 07:28:24 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-08-21 07:28:24 -0400 |
commit | 470fba7ebe60ad9185056b080b331abad24b4df9 (patch) | |
tree | f83bc13d97adaf5dd0e0f1d6a157b890f868577f /net/core/utils.c | |
parent | 7225e75144b9718cbbe1820d9c011c809d5773fd (diff) | |
parent | 6a55617ed5d1aa62b850de2cf66f5ede2eef4825 (diff) |
Merge branch 'linus' into x86/doc
Diffstat (limited to 'net/core/utils.c')
-rw-r--r-- | net/core/utils.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/core/utils.c b/net/core/utils.c index 8031eb59054e..72e0ebe964a0 100644 --- a/net/core/utils.c +++ b/net/core/utils.c | |||
@@ -31,17 +31,16 @@ | |||
31 | #include <asm/system.h> | 31 | #include <asm/system.h> |
32 | #include <asm/uaccess.h> | 32 | #include <asm/uaccess.h> |
33 | 33 | ||
34 | int net_msg_cost __read_mostly = 5*HZ; | ||
35 | int net_msg_burst __read_mostly = 10; | ||
36 | int net_msg_warn __read_mostly = 1; | 34 | int net_msg_warn __read_mostly = 1; |
37 | EXPORT_SYMBOL(net_msg_warn); | 35 | EXPORT_SYMBOL(net_msg_warn); |
38 | 36 | ||
37 | DEFINE_RATELIMIT_STATE(net_ratelimit_state, 5 * HZ, 10); | ||
39 | /* | 38 | /* |
40 | * All net warning printk()s should be guarded by this function. | 39 | * All net warning printk()s should be guarded by this function. |
41 | */ | 40 | */ |
42 | int net_ratelimit(void) | 41 | int net_ratelimit(void) |
43 | { | 42 | { |
44 | return __printk_ratelimit(net_msg_cost, net_msg_burst); | 43 | return __ratelimit(&net_ratelimit_state); |
45 | } | 44 | } |
46 | EXPORT_SYMBOL(net_ratelimit); | 45 | EXPORT_SYMBOL(net_ratelimit); |
47 | 46 | ||