test: Use ut_asserteq_mem() where possible
Quite a few tests still use ut_assertok(memcmp(...)) and variants. Modify
them to use the macro designed for this purpose.
Suggested-by: Wolfgang Wallner <wolfgang.wallner@br-automation.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Wolfgang Wallner <wolfgang.wallner@br-automation.com>
diff --git a/test/dm/sf.c b/test/dm/sf.c
index 7805af7..55b8d15 100644
--- a/test/dm/sf.c
+++ b/test/dm/sf.c
@@ -35,7 +35,7 @@
dst = map_sysmem(0x20000 + full_size, full_size);
ut_assertok(spi_flash_read_dm(dev, 0, size, dst));
- ut_assertok(memcmp(src, dst, size));
+ ut_asserteq_mem(src, dst, size);
/* Erase */
ut_assertok(spi_flash_erase_dm(dev, 0, size));
@@ -48,7 +48,7 @@
src[i] = i;
ut_assertok(spi_flash_write_dm(dev, 0, size, src));
ut_assertok(spi_flash_read_dm(dev, 0, size, dst));
- ut_assertok(memcmp(src, dst, size));
+ ut_asserteq_mem(src, dst, size);
/* Try the write-protect stuff */
ut_assertok(uclass_first_device_err(UCLASS_SPI_EMUL, &emul));