diff mbox series

[06/51] test-ipmi-hiomap: Dump unexpected IPMI messages

Message ID 20190215065708.6086-7-andrew@aj.id.au
State Changes Requested
Headers show
Series ipmi-hiomap: Tests and fixes for event handling | expand

Commit Message

Andrew Jeffery Feb. 15, 2019, 6:56 a.m. UTC
These indicate an implementation bug or broken scenario. Either way it's
helpful to know what arrived given it wasn't expected.

Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
---
 libflash/test/test-ipmi-hiomap.c | 3 +++
 1 file changed, 3 insertions(+)
diff mbox series

Patch

diff --git a/libflash/test/test-ipmi-hiomap.c b/libflash/test/test-ipmi-hiomap.c
index 19e0cbf5c846..e2330fe85486 100644
--- a/libflash/test/test-ipmi-hiomap.c
+++ b/libflash/test/test-ipmi-hiomap.c
@@ -146,6 +146,9 @@  void ipmi_queue_msg_sync(struct ipmi_msg *msg)
 		assert(ctx->cursor->p->type == scenario_cmd);
 		cmd = &ctx->cursor->p->c;
 	} else {
+		printf("Got unexpected request:\n");
+		for (ssize_t i = 0; i < msg->req_size; i++)
+			printf("msg->data[%zd]: 0x%02x\n", i, msg->data[i]);
 		assert(false);
 	}