[Skiboot] [PATCH 1/3] hdata: Don't use printf
Oliver O'Halloran
oohall at gmail.com
Mon May 15 18:20:48 AEST 2017
Using printf() here results in the output going into the stdout stream
when running the hdata_to_dt test. This results in an invalid dtb output
so lets not do that.
Signed-off-by: Oliver O'Halloran <oohall at gmail.com>
---
hdata/iohub.c | 3 ++-
hdata/paca.c | 4 ++--
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/hdata/iohub.c b/hdata/iohub.c
index 0e7ef65f9101..c0b9bf802efb 100644
--- a/hdata/iohub.c
+++ b/hdata/iohub.c
@@ -380,7 +380,8 @@ static struct dt_node *io_add_p9(const struct cechub_io_hub *hub,
return NULL;
}
- printf("IOHUB: PHB4 active bridge mask %x\n", (u32) hub->fab_br0_pdt);
+ prlog(PR_DEBUG, "IOHUB: PHB4 active bridge mask %x\n",
+ (u32) hub->fab_br0_pdt);
/* Create PBCQs */
io_add_phb4(hub, sp_iohubs, xscom, 0, 1, 0);
diff --git a/hdata/paca.c b/hdata/paca.c
index 1938d4affbeb..eaad0d4de432 100644
--- a/hdata/paca.c
+++ b/hdata/paca.c
@@ -49,7 +49,7 @@ static struct dt_node *add_cpu_node(struct dt_node *cpus,
no = be32_to_cpu(id->process_interrupt_line);
ve_flags = be32_to_cpu(id->verify_exists_flags);
- printf("CPU[%i]: PIR=%i RES=%i %s %s(%u threads)\n",
+ prlog(PR_INFO, "CPU[%i]: PIR=%i RES=%i %s %s(%u threads)\n",
paca_index(paca), be32_to_cpu(id->pir), no,
ve_flags & CPU_ID_PACA_RESERVED
? "**RESERVED**" : cpu_state(ve_flags),
@@ -251,7 +251,7 @@ static bool __paca_parse(void)
okay = false;
}
- printf("CPU[%i]: PIR=%i RES=%i %s\n",
+ prlog(PR_INFO, "CPU[%i]: PIR=%i RES=%i %s\n",
paca_index(paca), be32_to_cpu(id->pir),
be32_to_cpu(id->process_interrupt_line),
okay ? "OK" : "UNAVAILABLE");
--
2.9.3
More information about the Skiboot
mailing list