diff options
author | H. Peter Anvin <hpa@linux.intel.com> | 2013-04-20 12:16:44 -0400 |
---|---|---|
committer | H. Peter Anvin <hpa@linux.intel.com> | 2013-04-20 12:16:44 -0400 |
commit | f53f292eeaa234615c31a1306babe703fc4263f2 (patch) | |
tree | 707b0933a20f7dc05495e974243a23b5c9f8c918 /include/linux/printk.h | |
parent | 15b9c359f288b09003cb70f7ed204affc0c6614d (diff) | |
parent | a9499fa7cd3fd4824a7202d00c766b269fa3bda6 (diff) |
Merge remote-tracking branch 'efi/chainsaw' into x86/efi
Resolved Conflicts:
drivers/firmware/efivars.c
fs/efivarsfs/file.c
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'include/linux/printk.h')
-rw-r--r-- | include/linux/printk.h | 44 |
1 files changed, 41 insertions, 3 deletions
diff --git a/include/linux/printk.h b/include/linux/printk.h index 9afc01e5a0a6..822171fcb1c8 100644 --- a/include/linux/printk.h +++ b/include/linux/printk.h | |||
@@ -98,9 +98,6 @@ int no_printk(const char *fmt, ...) | |||
98 | extern asmlinkage __printf(1, 2) | 98 | extern asmlinkage __printf(1, 2) |
99 | void early_printk(const char *fmt, ...); | 99 | void early_printk(const char *fmt, ...); |
100 | 100 | ||
101 | extern int printk_needs_cpu(int cpu); | ||
102 | extern void printk_tick(void); | ||
103 | |||
104 | #ifdef CONFIG_PRINTK | 101 | #ifdef CONFIG_PRINTK |
105 | asmlinkage __printf(5, 0) | 102 | asmlinkage __printf(5, 0) |
106 | int vprintk_emit(int facility, int level, | 103 | int vprintk_emit(int facility, int level, |
@@ -137,6 +134,8 @@ extern int printk_delay_msec; | |||
137 | extern int dmesg_restrict; | 134 | extern int dmesg_restrict; |
138 | extern int kptr_restrict; | 135 | extern int kptr_restrict; |
139 | 136 | ||
137 | extern void wake_up_klogd(void); | ||
138 | |||
140 | void log_buf_kexec_setup(void); | 139 | void log_buf_kexec_setup(void); |
141 | void __init setup_log_buf(int early); | 140 | void __init setup_log_buf(int early); |
142 | #else | 141 | #else |
@@ -165,6 +164,10 @@ static inline bool printk_timed_ratelimit(unsigned long *caller_jiffies, | |||
165 | return false; | 164 | return false; |
166 | } | 165 | } |
167 | 166 | ||
167 | static inline void wake_up_klogd(void) | ||
168 | { | ||
169 | } | ||
170 | |||
168 | static inline void log_buf_kexec_setup(void) | 171 | static inline void log_buf_kexec_setup(void) |
169 | { | 172 | { |
170 | } | 173 | } |
@@ -255,6 +258,15 @@ extern void dump_stack(void) __cold; | |||
255 | printk_once(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__) | 258 | printk_once(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__) |
256 | #define pr_cont_once(fmt, ...) \ | 259 | #define pr_cont_once(fmt, ...) \ |
257 | printk_once(KERN_CONT pr_fmt(fmt), ##__VA_ARGS__) | 260 | printk_once(KERN_CONT pr_fmt(fmt), ##__VA_ARGS__) |
261 | |||
262 | #if defined(DEBUG) | ||
263 | #define pr_devel_once(fmt, ...) \ | ||
264 | printk_once(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__) | ||
265 | #else | ||
266 | #define pr_devel_once(fmt, ...) \ | ||
267 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__) | ||
268 | #endif | ||
269 | |||
258 | /* If you are writing a driver, please use dev_dbg instead */ | 270 | /* If you are writing a driver, please use dev_dbg instead */ |
259 | #if defined(DEBUG) | 271 | #if defined(DEBUG) |
260 | #define pr_debug_once(fmt, ...) \ | 272 | #define pr_debug_once(fmt, ...) \ |
@@ -298,6 +310,15 @@ extern void dump_stack(void) __cold; | |||
298 | #define pr_info_ratelimited(fmt, ...) \ | 310 | #define pr_info_ratelimited(fmt, ...) \ |
299 | printk_ratelimited(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__) | 311 | printk_ratelimited(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__) |
300 | /* no pr_cont_ratelimited, don't do that... */ | 312 | /* no pr_cont_ratelimited, don't do that... */ |
313 | |||
314 | #if defined(DEBUG) | ||
315 | #define pr_devel_ratelimited(fmt, ...) \ | ||
316 | printk_ratelimited(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__) | ||
317 | #else | ||
318 | #define pr_devel_ratelimited(fmt, ...) \ | ||
319 | no_printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__) | ||
320 | #endif | ||
321 | |||
301 | /* If you are writing a driver, please use dev_dbg instead */ | 322 | /* If you are writing a driver, please use dev_dbg instead */ |
302 | #if defined(DEBUG) | 323 | #if defined(DEBUG) |
303 | #define pr_debug_ratelimited(fmt, ...) \ | 324 | #define pr_debug_ratelimited(fmt, ...) \ |
@@ -321,8 +342,13 @@ extern void hex_dump_to_buffer(const void *buf, size_t len, | |||
321 | extern void print_hex_dump(const char *level, const char *prefix_str, | 342 | extern void print_hex_dump(const char *level, const char *prefix_str, |
322 | int prefix_type, int rowsize, int groupsize, | 343 | int prefix_type, int rowsize, int groupsize, |
323 | const void *buf, size_t len, bool ascii); | 344 | const void *buf, size_t len, bool ascii); |
345 | #if defined(CONFIG_DYNAMIC_DEBUG) | ||
346 | #define print_hex_dump_bytes(prefix_str, prefix_type, buf, len) \ | ||
347 | dynamic_hex_dump(prefix_str, prefix_type, 16, 1, buf, len, true) | ||
348 | #else | ||
324 | extern void print_hex_dump_bytes(const char *prefix_str, int prefix_type, | 349 | extern void print_hex_dump_bytes(const char *prefix_str, int prefix_type, |
325 | const void *buf, size_t len); | 350 | const void *buf, size_t len); |
351 | #endif /* defined(CONFIG_DYNAMIC_DEBUG) */ | ||
326 | #else | 352 | #else |
327 | static inline void print_hex_dump(const char *level, const char *prefix_str, | 353 | static inline void print_hex_dump(const char *level, const char *prefix_str, |
328 | int prefix_type, int rowsize, int groupsize, | 354 | int prefix_type, int rowsize, int groupsize, |
@@ -336,4 +362,16 @@ static inline void print_hex_dump_bytes(const char *prefix_str, int prefix_type, | |||
336 | 362 | ||
337 | #endif | 363 | #endif |
338 | 364 | ||
365 | #if defined(CONFIG_DYNAMIC_DEBUG) | ||
366 | #define print_hex_dump_debug(prefix_str, prefix_type, rowsize, \ | ||
367 | groupsize, buf, len, ascii) \ | ||
368 | dynamic_hex_dump(prefix_str, prefix_type, rowsize, \ | ||
369 | groupsize, buf, len, ascii) | ||
370 | #else | ||
371 | #define print_hex_dump_debug(prefix_str, prefix_type, rowsize, \ | ||
372 | groupsize, buf, len, ascii) \ | ||
373 | print_hex_dump(KERN_DEBUG, prefix_str, prefix_type, rowsize, \ | ||
374 | groupsize, buf, len, ascii) | ||
375 | #endif /* defined(CONFIG_DYNAMIC_DEBUG) */ | ||
376 | |||
339 | #endif | 377 | #endif |