diff options
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/console/console.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/include/console/console.h b/src/include/console/console.h index 369ce5be00..e5b753e8b6 100644 --- a/src/include/console/console.h +++ b/src/include/console/console.h @@ -63,8 +63,8 @@ asmlinkage void console_init(void); int console_log_level(int msg_level); void do_putchar(unsigned char byte); -#define printk(LEVEL, fmt, args...) \ - do { do_printk(LEVEL, fmt, ##args); } while (0) +#define printk(LEVEL, fmt, args...) do_printk(LEVEL, fmt, ##args) +#define vprintk(LEVEL, fmt, args) do_vprintk(LEVEL, fmt, args) enum { CONSOLE_LOG_NONE = 0, CONSOLE_LOG_FAST, CONSOLE_LOG_ALL }; @@ -84,14 +84,15 @@ static inline int get_console_loglevel(void) static inline void console_init(void) {} static inline int console_log_level(int msg_level) { return 0; } static inline void printk(int LEVEL, const char *fmt, ...) {} +static inline void vprintk(int LEVEL, const char *fmt, va_list args) {} static inline void do_putchar(unsigned char byte) {} #endif -int vprintk(int msg_level, const char *fmt, va_list args); - int do_printk(int msg_level, const char *fmt, ...) __attribute__((format(printf, 2, 3))); +int do_vprintk(int msg_level, const char *fmt, va_list args); + #endif /* !__ROMCC__ */ #endif /* CONSOLE_CONSOLE_H_ */ |