All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ v1 1/2] test-micp: Fix endianess error
@ 2023-11-29 16:30 Luiz Augusto von Dentz
  2023-11-29 16:30 ` [PATCH BlueZ v1 2/2] shared/vcp: Fix endianess errors Luiz Augusto von Dentz
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Luiz Augusto von Dentz @ 2023-11-29 16:30 UTC (permalink / raw)
  To: linux-bluetooth

From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>

On big endian the followin error can be observed:

MICP/CL/CGGIT/SER/BV-01-C - init
MICP/CL/CGGIT/SER/BV-01-C - setup
MICP/CL/CGGIT/SER/BV-01-C - setup complete
MICP/CL/CGGIT/SER/BV-01-C - run
micp_write_value handle: 3
**
ERROR:src/shared/tester.c:954:test_io_recv: assertion failed:
(memcmp(buf, iov->iov_base, len) == 0)
Bail out! ERROR:src/shared/tester.c:954:test_io_recv: assertion failed:
(memcmp(buf, iov->iov_base, len) == 0)
Aborted
---
 unit/test-micp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/unit/test-micp.c b/unit/test-micp.c
index e2975c298ec5..a7fc7fb321bd 100644
--- a/unit/test-micp.c
+++ b/unit/test-micp.c
@@ -147,7 +147,7 @@ static void micp_write_value(struct bt_micp *micp, void *user_data)
 	struct bt_mics *mics = micp_get_mics(micp);
 	uint16_t	value_handle;
 	int ret;
-	const uint16_t value = 0x0001;
+	uint16_t value = cpu_to_le16(0x0001);
 
 	gatt_db_attribute_get_char_data(mics->ms, NULL, &value_handle,
 							NULL, NULL, NULL);
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-11-29 22:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-29 16:30 [PATCH BlueZ v1 1/2] test-micp: Fix endianess error Luiz Augusto von Dentz
2023-11-29 16:30 ` [PATCH BlueZ v1 2/2] shared/vcp: Fix endianess errors Luiz Augusto von Dentz
2023-11-29 17:37 ` [BlueZ,v1,1/2] test-micp: Fix endianess error bluez.test.bot
2023-11-29 22:40 ` [PATCH BlueZ v1 1/2] " patchwork-bot+bluetooth

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.