Diff between 62b8a7686842c1e8cdd2eccdb7bd00eb1b5030b2 and 2fe3089a7b715ab6070258ac2036717208688184

Changed Files

File Additions Deletions Status
android/hal-map-client.c +11 -1 modified

Full Patch

diff --git a/android/hal-map-client.c b/android/hal-map-client.c
index 533b793..8255d2b 100644
--- a/android/hal-map-client.c
+++ b/android/hal-map-client.c
@@ -17,6 +17,7 @@
 
 #include <stdlib.h>
 #include <stdbool.h>
+#include <string.h>
 
 #include "hal-log.h"
 #include "hal.h"
@@ -99,7 +100,16 @@ static const struct hal_ipc_handler ev_handlers[] = {
 
 static bt_status_t get_remote_mas_instances(bt_bdaddr_t *bd_addr)
 {
-	return BT_STATUS_UNSUPPORTED;
+	struct hal_cmd_map_client_get_instances cmd;
+
+	if (!interface_ready())
+		return BT_STATUS_NOT_READY;
+
+	memcpy(cmd.bdaddr, bd_addr, sizeof(*bd_addr));
+
+	return hal_ipc_cmd(HAL_SERVICE_ID_MAP_CLIENT,
+				HAL_OP_MAP_CLIENT_GET_INSTANCES, sizeof(cmd),
+				&cmd, NULL, NULL, NULL);
 }
 
 static bt_status_t init(btmce_callbacks_t *callbacks)