[PATCH 3/3] android/hal: Unregister Bluetooth on cleanup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx>

---
 This is more like RFC. Shall we send this event or this will be cleaned up itself.

 android/hal-bluetooth.c |    7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/android/hal-bluetooth.c b/android/hal-bluetooth.c
index 8cd4327..4bf1183 100644
--- a/android/hal-bluetooth.c
+++ b/android/hal-bluetooth.c
@@ -379,11 +379,18 @@ static int disable(void)
 
 static void cleanup(void)
 {
+	struct hal_cmd_register_module cmd;
+
 	DBG("");
 
 	if (!interface_ready())
 		return;
 
+	cmd.service_id = HAL_SERVICE_ID_BLUETOOTH;
+
+	hal_ipc_cmd(HAL_SERVICE_ID_CORE, HAL_OP_UNREGISTER_MODULE,
+					sizeof(cmd), &cmd, NULL, NULL, NULL);
+
 	hal_ipc_cleanup();
 
 	bt_hal_cbacks = NULL;
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux