Print out Device Disconnect Reason 28/198828/2
authorAnupam Roy <anupam.r@samsung.com>
Wed, 30 Jan 2019 06:41:28 +0000 (12:11 +0530)
committerPyun DoHyun <dh79.pyun@samsung.com>
Thu, 7 Feb 2019 23:35:27 +0000 (23:35 +0000)
Change-Id: I048a5db2b231c91decd43e079a0e91ce7488f2cc
Signed-off-by: Anupam Roy <anupam.r@samsung.com>
src/bluetooth-common.c

index 6f62ed5..87e3b73 100644 (file)
@@ -746,6 +746,8 @@ static int __bt_get_bt_device_connection_info_s(bt_device_connection_info_s **de
                break;
        }
 
+       BT_INFO("Disconnect reason from FRWK[0x%x]", source->disc_reason);
+
        switch (source->disc_reason) {
 /* After ACR for BT_DEVICE_DISCONNECT_REASON_AUTH_FAILED, will enable this code */
 #if 0
@@ -754,6 +756,7 @@ static int __bt_get_bt_device_connection_info_s(bt_device_connection_info_s **de
                break;
 #endif
        case (int)BLUETOOTH_ERROR_CONNECTION_TIMEOUT:
+               BT_INFO("Disconnected due to Timeout");
                (*dest)->disconn_reason = BT_DEVICE_DISCONNECT_REASON_TIMEOUT;
                break;
        case (int)BLUETOOTH_ERROR_REMOTE_USER_TERM:
@@ -769,6 +772,7 @@ static int __bt_get_bt_device_connection_info_s(bt_device_connection_info_s **de
                break;
        }
 
+       BT_INFO("Disconnected reason to app [0x%x]", (*dest)->disconn_reason);
        return BT_ERROR_NONE;
 }