Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

tools/bootconfig: Remove unneeded error message silencer

Remove error message silent knob, we don't need it anymore
because we can check if there is a bootconfig by checking
the magic word.
If there is a magic word, but failed to load a bootconfig
from initrd, there is a real problem.

Link: http://lkml.kernel.org/r/158220113256.26565.14264598654427773104.stgit@devnote2

Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>

authored by

Masami Hiramatsu and committed by
Steven Rostedt (VMware)
15e95037 85c46b78

+1 -12
+1 -4
tools/bootconfig/include/linux/printk.h
··· 4 4 5 5 #include <stdio.h> 6 6 7 - /* controllable printf */ 8 - extern int pr_output; 9 - #define printk(fmt, ...) \ 10 - (pr_output ? printf(fmt, ##__VA_ARGS__) : 0) 7 + #define printk(fmt, ...) printf(fmt, ##__VA_ARGS__) 11 8 12 9 #define pr_err printk 13 10 #define pr_warn printk
-8
tools/bootconfig/main.c
··· 14 14 #include <linux/kernel.h> 15 15 #include <linux/bootconfig.h> 16 16 17 - int pr_output = 1; 18 - 19 17 static int xbc_show_array(struct xbc_node *node) 20 18 { 21 19 const char *val; ··· 225 227 return -errno; 226 228 } 227 229 228 - /* 229 - * Suppress error messages in xbc_init() because it can be just a 230 - * data which concidentally matches the size and checksum footer. 231 - */ 232 - pr_output = 0; 233 230 size = load_xbc_from_initrd(fd, &buf); 234 - pr_output = 1; 235 231 if (size < 0) { 236 232 ret = size; 237 233 pr_err("Failed to load a boot config from initrd: %d\n", ret);