diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/kernel.h | 3 | ||||
-rw-r--r-- | include/linux/ratelimit.h | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h index 3305f33201b..21d0d822c71 100644 --- a/include/linux/kernel.h +++ b/include/linux/kernel.h | |||
@@ -240,7 +240,8 @@ asmlinkage int vprintk(const char *fmt, va_list args) | |||
240 | asmlinkage int printk(const char * fmt, ...) | 240 | asmlinkage int printk(const char * fmt, ...) |
241 | __attribute__ ((format (printf, 1, 2))) __cold; | 241 | __attribute__ ((format (printf, 1, 2))) __cold; |
242 | 242 | ||
243 | extern int printk_ratelimit(void); | 243 | extern int __printk_ratelimit(const char *func); |
244 | #define printk_ratelimit() __printk_ratelimit(__func__) | ||
244 | extern bool printk_timed_ratelimit(unsigned long *caller_jiffies, | 245 | extern bool printk_timed_ratelimit(unsigned long *caller_jiffies, |
245 | unsigned int interval_msec); | 246 | unsigned int interval_msec); |
246 | 247 | ||
diff --git a/include/linux/ratelimit.h b/include/linux/ratelimit.h index 187bc16c1f1..668cf1bef03 100644 --- a/include/linux/ratelimit.h +++ b/include/linux/ratelimit.h | |||
@@ -25,6 +25,7 @@ struct ratelimit_state { | |||
25 | .burst = burst_init, \ | 25 | .burst = burst_init, \ |
26 | } | 26 | } |
27 | 27 | ||
28 | extern int __ratelimit(struct ratelimit_state *rs); | 28 | extern int ___ratelimit(struct ratelimit_state *rs, const char *func); |
29 | #define __ratelimit(state) ___ratelimit(state, __func__) | ||
29 | 30 | ||
30 | #endif /* _LINUX_RATELIMIT_H */ | 31 | #endif /* _LINUX_RATELIMIT_H */ |