Message ID | 20190506040029.9215-1-oohall@gmail.com |
---|---|
State | Accepted |
Headers | show |
Series | hw/phb4: Make pci-tracing print at PR_NOTICE | expand |
Context | Check | Description |
---|---|---|
snowpatch_ozlabs/apply_patch | success | Successfully applied on branch master (e6e70ea51c6594290602e76102149ee6dcfc66ee) |
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot | success | Test snowpatch/job/snowpatch-skiboot on branch master |
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot-dco | success | Signed-off-by present |
"Oliver O'Halloran" <oohall@gmail.com> writes: > When pci-tracing is enabled we print each trace status message and the > final trace status at PR_ERROR. The final status messages are similar to > those printed when we fail to train in the non-pci-tracing path and this > has resulted in spurious op-test failures. > > This patch reduces the log-level of the tracing message to PR_NOTICE so > they're not accidently interpreted as actual error messages. PR_NOTICE > messages are still printed to the console during boot. > > Signed-off-by: Oliver O'Halloran <oohall@gmail.com> > --- > hw/phb4.c | 11 +++++++---- > 1 file changed, 7 insertions(+), 4 deletions(-) Merged to master as of 76c569ca3000861b97635402741faa4f87641c3a
diff --git a/hw/phb4.c b/hw/phb4.c index 3b0ebfba886b..740924a6fa9e 100644 --- a/hw/phb4.c +++ b/hw/phb4.c @@ -137,6 +137,9 @@ static void phb4_init_hw(struct phb4 *p); #define PHBINF(p, fmt, a...) prlog(PR_INFO, "PHB#%04x[%d:%d]: " fmt, \ (p)->phb.opal_id, (p)->chip_id, \ (p)->index, ## a) +#define PHBNOTICE(p, fmt, a...) prlog(PR_NOTICE, "PHB#%04x[%d:%d]: " fmt, \ + (p)->phb.opal_id, (p)->chip_id, \ + (p)->index, ## a) #define PHBERR(p, fmt, a...) prlog(PR_ERR, "PHB#%04x[%d:%d]: " fmt, \ (p)->phb.opal_id, (p)->chip_id, \ (p)->index, ## a) @@ -2385,7 +2388,7 @@ static void phb4_train_info(struct phb4 *p, uint64_t reg, unsigned long time) default: snprintf(s, sizeof(s), "%sunvalid", s); } - PHBERR(p, "%s\n", s); + PHBNOTICE(p, "%s\n", s); } static void phb4_dump_pec_err_regs(struct phb4 *p) @@ -2663,15 +2666,15 @@ static void phb4_training_trace(struct phb4 *p) reglast = reg; if (!phb4_check_reg(p, reg)) { - PHBERR(p, "TRACE: PHB fence waiting link.\n"); + PHBNOTICE(p, "TRACE: PHB fence waiting link.\n"); break; } if (reg & PHB_PCIE_DLP_TL_LINKACT) { - PHBERR(p, "TRACE: Link trained.\n"); + PHBNOTICE(p, "TRACE: Link trained.\n"); break; } if ((now - start) > secs_to_tb(3)) { - PHBERR(p, "TRACE: Timeout waiting for link up.\n"); + PHBNOTICE(p, "TRACE: Timeout waiting for link up.\n"); break; } }
When pci-tracing is enabled we print each trace status message and the final trace status at PR_ERROR. The final status messages are similar to those printed when we fail to train in the non-pci-tracing path and this has resulted in spurious op-test failures. This patch reduces the log-level of the tracing message to PR_NOTICE so they're not accidently interpreted as actual error messages. PR_NOTICE messages are still printed to the console during boot. Signed-off-by: Oliver O'Halloran <oohall@gmail.com> --- hw/phb4.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-)