diff mbox series

Quieten console output on boot

Message ID 20180604060935.7346-1-stewart@linux.ibm.com
State Accepted
Headers show
Series Quieten console output on boot | expand

Commit Message

Stewart Smith June 4, 2018, 6:09 a.m. UTC
We print out a whole bunch of things on boot, most of which aren't
interesting, so we should *not* print them instead.

Printing things like what CPUs we found and what PCI devices we found
*are* useful, so continue to do that. But we don't need to splat out
a bunch of things that are always going to be true.

Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
---
 core/console.c       | 2 +-
 core/nvram.c         | 4 ++--
 hdata/spira.c        | 2 +-
 hw/bt.c              | 2 +-
 hw/lpc-uart.c        | 2 +-
 hw/nx-compress.c     | 2 +-
 hw/slw.c             | 2 +-
 hw/vas.c             | 2 +-
 hw/xscom.c           | 6 +++---
 libstb/secureboot.c  | 4 ++--
 libstb/trustedboot.c | 2 +-
 11 files changed, 15 insertions(+), 15 deletions(-)

Comments

Stewart Smith June 5, 2018, 5:59 a.m. UTC | #1
Stewart Smith <stewart@linux.ibm.com> writes:
> We print out a whole bunch of things on boot, most of which aren't
> interesting, so we should *not* print them instead.
>
> Printing things like what CPUs we found and what PCI devices we found
> *are* useful, so continue to do that. But we don't need to splat out
> a bunch of things that are always going to be true.

Merged to master as of 1b86a92b6cb66ca9a1968e57afd8e6d76c417523
diff mbox series

Patch

diff --git a/core/console.c b/core/console.c
index e8256758927a..0e9bc4593cc2 100644
--- a/core/console.c
+++ b/core/console.c
@@ -338,7 +338,7 @@  void init_opal_console(void)
 		opal_con_driver = &dummy_opal_con;
 	}
 
-	prlog(PR_NOTICE, "OPAL: Using %s\n", opal_con_driver->name);
+	prlog(PR_INFO, "OPAL: Using %s\n", opal_con_driver->name);
 
 	if (opal_con_driver->init)
 		opal_con_driver->init();
diff --git a/core/nvram.c b/core/nvram.c
index 1c3cdfaf4d93..c2158216a91b 100644
--- a/core/nvram.c
+++ b/core/nvram.c
@@ -170,9 +170,9 @@  void nvram_init(void)
 		prerror("NVRAM: Error %d retrieving nvram info\n", rc);
 		return;
 	}
-	printf("NVRAM: Size is %d KB\n", nvram_size >> 10);
+	prlog(PR_INFO, "NVRAM: Size is %d KB\n", nvram_size >> 10);
 	if (nvram_size > 0x100000) {
-		printf("NVRAM: Cropping to 1MB !\n");
+		prlog(PR_WARNING, "NVRAM: Cropping to 1MB !\n");
 		nvram_size = 0x100000;
 	}
 
diff --git a/hdata/spira.c b/hdata/spira.c
index b3894672efea..d459df7c8cec 100644
--- a/hdata/spira.c
+++ b/hdata/spira.c
@@ -1631,7 +1631,7 @@  static void fixup_spira(void)
 	if (!HDIF_check(&spiras->hdr, SPIRAS_HDIF_SIG))
 		return;
 
-	prlog(PR_NOTICE, "SPIRA-S found.\n");
+	prlog(PR_DEBUG, "SPIRA-S found.\n");
 
 	spira.ntuples.sp_subsys = spiras->ntuples.sp_subsys;
 	spira.ntuples.ipl_parms = spiras->ntuples.ipl_parms;
diff --git a/hw/bt.c b/hw/bt.c
index ce87e2bcf791..338a9da58635 100644
--- a/hw/bt.c
+++ b/hw/bt.c
@@ -657,7 +657,7 @@  void bt_init(void)
 	list_head_init(&bt.msgq);
 	bt.queue_len = 0;
 
-	prlog(PR_NOTICE, "Interface initialized, IO 0x%04x\n", bt.base_addr);
+	prlog(PR_INFO, "Interface initialized, IO 0x%04x\n", bt.base_addr);
 
 	ipmi_register_backend(&bt_backend);
 
diff --git a/hw/lpc-uart.c b/hw/lpc-uart.c
index 74a86b1342ca..365bf3e27094 100644
--- a/hw/lpc-uart.c
+++ b/hw/lpc-uart.c
@@ -605,7 +605,7 @@  void early_uart_init(void)
 
 	if (uart_init_hw(baud, clk)) {
 		set_console(&uart_con_driver);
-		prlog(PR_NOTICE, "UART: Using UART at %p\n", mmio_uart_base);
+		prlog(PR_DEBUG, "UART: Using UART at %p\n", mmio_uart_base);
 	} else {
 		prerror("UART: Early init failed!");
 		mmio_uart_base = NULL;
diff --git a/hw/nx-compress.c b/hw/nx-compress.c
index 161870dac59e..62fb0edef77f 100644
--- a/hw/nx-compress.c
+++ b/hw/nx-compress.c
@@ -281,7 +281,7 @@  void nx_create_compress_node(struct dt_node *node)
 	if (dt_node_is_compatible(node, "ibm,power9-nx")) {
 		u64 cfg_mmio, cfg_txwc, cfg_uctrl, cfg_dma;
 
-		printf("Found ibm,power9-nx\n");
+		prlog(PR_DEBUG, "Found ibm,power9-nx\n");
 		cfg_mmio = pb_base + NX_P9_UMAC_VAS_MMIO_BAR;
 		cfg_dma = pb_base + NX_P9_DMA_VAS_MMIO_BAR;
 		cfg_txwc = pb_base + NX_P9_UMAC_TX_WINDOW_CONTEXT_BAR;
diff --git a/hw/slw.c b/hw/slw.c
index 49bcd839915f..0612290289ae 100644
--- a/hw/slw.c
+++ b/hw/slw.c
@@ -1012,7 +1012,7 @@  void add_cpu_idle_state_properties(void)
 			}
 		}
 
-		prlog(PR_NOTICE, "SLW: Enabling: %s\n", states[i].name);
+		prlog(PR_INFO, "SLW: Enabling: %s\n", states[i].name);
 
 		/*
 		 * If a state is supported add each of its property
diff --git a/hw/vas.c b/hw/vas.c
index d8c2b380124b..376e42d499c1 100644
--- a/hw/vas.c
+++ b/hw/vas.c
@@ -466,7 +466,7 @@  static int init_vas_inst(struct dt_node *np, bool enable)
 
 	create_mm_dt_node(chip);
 
-	prlog(PR_NOTICE, "VAS: Initialized chip %d\n", chip->id);
+	prlog(PR_INFO, "VAS: Initialized chip %d\n", chip->id);
 	return 0;
 
 }
diff --git a/hw/xscom.c b/hw/xscom.c
index 05012780aafe..05b2c14f02ca 100644
--- a/hw/xscom.c
+++ b/hw/xscom.c
@@ -814,7 +814,7 @@  static void xscom_init_chip_info(struct proc_chip *chip)
 		default:
 			rev = 0;
 		}
-		printf("P9 DD%i.%i%d detected\n", 0xf & (chip->ec_level >> 4),
+		prlog(PR_INFO,"P9 DD%i.%i%d detected\n", 0xf & (chip->ec_level >> 4),
 		       chip->ec_level & 0xf, rev);
 		chip->ec_rev = rev;
 	}
@@ -900,9 +900,9 @@  void xscom_init(void)
 			chip_name = chip_names[chip->type];
 
 		/* We keep a "CHIP" prefix to make the log more user-friendly */
-		prlog(PR_NOTICE, "CHIP: Chip ID %04x type: %s DD%x.%x\n",
+		prlog(PR_NOTICE, "CHIP: Chip ID %04x type: %s DD%x.%x%d\n",
 		      gcid, chip_name, chip->ec_level >> 4,
-		      chip->ec_level & 0xf);
+		      chip->ec_level & 0xf, chip->ec_rev);
 		prlog(PR_DEBUG, "XSCOM: Base address: 0x%llx\n", chip->xscom_base);
 	}
 
diff --git a/libstb/secureboot.c b/libstb/secureboot.c
index 348acf57c489..4f6a301d5e67 100644
--- a/libstb/secureboot.c
+++ b/libstb/secureboot.c
@@ -102,14 +102,14 @@  void secureboot_init(void)
 		return;
 	}
 
-	prlog(PR_NOTICE, "Found %s\n", compat);
+	prlog(PR_DEBUG, "Found %s\n", compat);
 
 	if (nvram_query_eq("force-secure-mode", "always")) {
 		secure_mode = true;
 		prlog(PR_NOTICE, "secure mode on (FORCED by nvram)\n");
 	} else {
 		secure_mode = dt_has_node_property(node, "secure-enabled", NULL);
-		prlog(PR_NOTICE, "secure mode %s\n",
+		prlog(PR_INFO, "secure mode %s\n",
 		      secure_mode ? "on" : "off");
 	}
 
diff --git a/libstb/trustedboot.c b/libstb/trustedboot.c
index 151e4e167e65..8fa11790f993 100644
--- a/libstb/trustedboot.c
+++ b/libstb/trustedboot.c
@@ -106,7 +106,7 @@  void trustedboot_init(void)
 		prlog(PR_NOTICE, "trusted mode on (FORCED by nvram)\n");
 	} else {
 		trusted_mode = dt_has_node_property(node, "trusted-enabled", NULL);
-		prlog(PR_NOTICE, "trusted mode %s\n",
+		prlog(PR_INFO, "trusted mode %s\n",
 		      trusted_mode ? "on" : "off");
 	}