Diff between ad5813bcd5fbc724782db9a56c4dfcbc2b19e98e and cfcbbf8f86282bfbf3c4c23aa3ac495b2cb31f48

Changed Files

File Additions Deletions Status
android/hal-a2dp.c +7 -2 modified

Full Patch

diff --git a/android/hal-a2dp.c b/android/hal-a2dp.c
index 50a36fb..e9fadb7 100644
--- a/android/hal-a2dp.c
+++ b/android/hal-a2dp.c
@@ -113,14 +113,19 @@ static bt_status_t init(btav_callbacks_t *callbacks)
 
 static void cleanup()
 {
+	struct hal_cmd_unregister_module cmd;
+
 	DBG("");
 
 	if (!interface_ready())
 		return;
 
-	/* TODO: disable service */
-
 	cbs = NULL;
+
+	cmd.service_id = HAL_SERVICE_ID_A2DP;
+
+	hal_ipc_cmd(HAL_SERVICE_ID_CORE, HAL_OP_UNREGISTER_MODULE,
+					sizeof(cmd), &cmd, 0, NULL, NULL);
 }
 
 static btav_interface_t iface = {