summaryrefslogtreecommitdiffstats
path: root/cf-fsi-test.c
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2018-06-11 20:59:24 +1000
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2018-06-11 20:59:24 +1000
commitea4e9490301b774cfc01ed92d7566d899ba7e7eb (patch)
treeeee45b10a76d77ea1883020778cd09e70572175a /cf-fsi-test.c
parent1b05374650ed9da9eb14154490b490caf62b99bc (diff)
downloadcf-fsi-ea4e9490301b774cfc01ed92d7566d899ba7e7eb.tar.gz
cf-fsi-ea4e9490301b774cfc01ed92d7566d899ba7e7eb.zip
Add marker at end of traces
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'cf-fsi-test.c')
-rw-r--r--cf-fsi-test.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/cf-fsi-test.c b/cf-fsi-test.c
index bf209f3..5d05051 100644
--- a/cf-fsi-test.c
+++ b/cf-fsi-test.c
@@ -566,10 +566,15 @@ static void dump_stuff(void)
ntohl(readl(sysreg + SRAM_BASE + INT_CNT)));
for (i = 0; trace_enabled && i < 128; i++) {
- printf("%02x ", readb(sysreg + SRAM_BASE + TRACEBUF + i));
+ uint8_t v = readb(sysreg + SRAM_BASE + TRACEBUF + i);
+ printf("%02x ", v);
if ((i % 16) == 15)
printf("\n");
+ if (v == TR_END)
+ break;
}
+ if (i % 16)
+ printf("\n");
}
static int do_command(uint32_t op)
OpenPOWER on IntegriCloud