diff options
Diffstat (limited to 'include/linux/kernel.h')
| -rw-r--r-- | include/linux/kernel.h | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h index 792bf0aa779b..f9cd7a513f9c 100644 --- a/include/linux/kernel.h +++ b/include/linux/kernel.h | |||
| @@ -46,6 +46,9 @@ extern const char linux_proc_banner[]; | |||
| 46 | #define DIV_ROUND_UP(n,d) (((n) + (d) - 1) / (d)) | 46 | #define DIV_ROUND_UP(n,d) (((n) + (d) - 1) / (d)) |
| 47 | #define roundup(x, y) ((((x) + ((y) - 1)) / (y)) * (y)) | 47 | #define roundup(x, y) ((((x) + ((y) - 1)) / (y)) * (y)) |
| 48 | 48 | ||
| 49 | #define _RET_IP_ (unsigned long)__builtin_return_address(0) | ||
| 50 | #define _THIS_IP_ ({ __label__ __here; __here: (unsigned long)&&__here; }) | ||
| 51 | |||
| 49 | #ifdef CONFIG_LBD | 52 | #ifdef CONFIG_LBD |
| 50 | # include <asm/div64.h> | 53 | # include <asm/div64.h> |
| 51 | # define sector_div(a, b) do_div(a, b) | 54 | # define sector_div(a, b) do_div(a, b) |
| @@ -184,9 +187,6 @@ asmlinkage int vprintk(const char *fmt, va_list args) | |||
| 184 | __attribute__ ((format (printf, 1, 0))); | 187 | __attribute__ ((format (printf, 1, 0))); |
| 185 | asmlinkage int printk(const char * fmt, ...) | 188 | asmlinkage int printk(const char * fmt, ...) |
| 186 | __attribute__ ((format (printf, 1, 2))) __cold; | 189 | __attribute__ ((format (printf, 1, 2))) __cold; |
| 187 | extern int log_buf_get_len(void); | ||
| 188 | extern int log_buf_read(int idx); | ||
| 189 | extern int log_buf_copy(char *dest, int idx, int len); | ||
| 190 | 190 | ||
| 191 | extern int printk_ratelimit_jiffies; | 191 | extern int printk_ratelimit_jiffies; |
| 192 | extern int printk_ratelimit_burst; | 192 | extern int printk_ratelimit_burst; |
| @@ -202,9 +202,6 @@ static inline int vprintk(const char *s, va_list args) { return 0; } | |||
| 202 | static inline int printk(const char *s, ...) | 202 | static inline int printk(const char *s, ...) |
| 203 | __attribute__ ((format (printf, 1, 2))); | 203 | __attribute__ ((format (printf, 1, 2))); |
| 204 | static inline int __cold printk(const char *s, ...) { return 0; } | 204 | static inline int __cold printk(const char *s, ...) { return 0; } |
| 205 | static inline int log_buf_get_len(void) { return 0; } | ||
| 206 | static inline int log_buf_read(int idx) { return 0; } | ||
| 207 | static inline int log_buf_copy(char *dest, int idx, int len) { return 0; } | ||
| 208 | static inline int printk_ratelimit(void) { return 0; } | 205 | static inline int printk_ratelimit(void) { return 0; } |
| 209 | static inline int __printk_ratelimit(int ratelimit_jiffies, \ | 206 | static inline int __printk_ratelimit(int ratelimit_jiffies, \ |
| 210 | int ratelimit_burst) { return 0; } | 207 | int ratelimit_burst) { return 0; } |
| @@ -213,7 +210,7 @@ static inline bool printk_timed_ratelimit(unsigned long *caller_jiffies, \ | |||
| 213 | { return false; } | 210 | { return false; } |
| 214 | #endif | 211 | #endif |
| 215 | 212 | ||
| 216 | extern void __attribute__((format(printf, 1, 2))) | 213 | extern void asmlinkage __attribute__((format(printf, 1, 2))) |
| 217 | early_printk(const char *fmt, ...); | 214 | early_printk(const char *fmt, ...); |
| 218 | 215 | ||
| 219 | unsigned long int_sqrt(unsigned long); | 216 | unsigned long int_sqrt(unsigned long); |
