Re: [RFC][PATCH] printk: Fixup the nmi printk mess

Steven Rostedt
2015-06-10T15:53:32Z

On Wed, 10 Jun 2015 14:55:09 +0200
Peter Zijlstra <peterz@infradead.org> wrote:

> diff --git a/include/linux/printk.h b/include/linux/printk.h
> index 9b30871c9149..ebe017327e6e 100644
> --- a/include/linux/printk.h
> +++ b/include/linux/printk.h
> @@ -120,7 +120,15 @@ static inline __printf(1, 2) __cold
> void early_printk(const char *s, ...) { }
> #endif
>
> -typedef int(*printk_func_t)(const char *fmt, va_list args);
> +#ifdef CONFIG_PRINTK_NMI
> +extern void printk_init(void);
> +extern void printk_nmi_enter(void);
> +extern void printk_nmi_exit(void);
> +#else
> +static inline void printk_init(void) { }
> +static inline void printk_nmi_enter(void) { }
> +static inline void printk_nmi_exit(void) { }
> +#endif /* HAVE_NMI */

#endif /* PRINTK_NMI */

-- Steve

>
> #ifdef CONFIG_PRINTK
> asmlinkage __printf(5, 0)
> diff --git a/init/Kconfig b/init/Kconfig
> index b999fa381bf9..fe9a439c8843 100644