diff options
author | pramod kotreshappa <pramodk@codeaurora.org> | 2014-03-03 13:04:11 -0800 |
---|---|---|
committer | Linux Build Service Account <lnxbuild@localhost> | 2014-11-04 08:25:15 -0700 |
commit | f60b040f251caeec9d7039e932d3334a779de1bd (patch) | |
tree | 528e8c79dc22c0d3c5e850cb92083c36d52c0a0e /jni | |
parent | 7b45008cda18a76cbb35b7b2d0b64706d30091e1 (diff) | |
download | android_packages_apps_Bluetooth-f60b040f251caeec9d7039e932d3334a779de1bd.tar.gz android_packages_apps_Bluetooth-f60b040f251caeec9d7039e932d3334a779de1bd.tar.bz2 android_packages_apps_Bluetooth-f60b040f251caeec9d7039e932d3334a779de1bd.zip |
Bluetooth: Fix for BT fails to turn on in PDT test
Fix for BT fails to turn on after several hours of PDT test
Issue is due to disable timeout, host fails to get the wack ACK from
the SoC during BT turn of. Adding ssr cleanup routine in disable
timout routine
CRs-Fixed: 614585
Change-Id: Ia32da9426f976ddc71f0ad740312222b4b646c94
Diffstat (limited to 'jni')
-rw-r--r-- | jni/com_android_bluetooth_btservice_AdapterService.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/jni/com_android_bluetooth_btservice_AdapterService.cpp b/jni/com_android_bluetooth_btservice_AdapterService.cpp index 11a510563..7d54b5b21 100644 --- a/jni/com_android_bluetooth_btservice_AdapterService.cpp +++ b/jni/com_android_bluetooth_btservice_AdapterService.cpp @@ -797,6 +797,19 @@ static bool cleanupNative(JNIEnv *env, jobject obj) { return JNI_TRUE; } +static bool ssrcleanupNative(JNIEnv *env, jobject obj) { + ALOGV("%s:",__FUNCTION__); + + jboolean result = JNI_FALSE; + if (!sBluetoothInterface) return result; + + sBluetoothInterface->ssrcleanup(); + ALOGI("%s: return from cleanup",__FUNCTION__); + + env->DeleteGlobalRef(sJniCallbacksObj); + return JNI_TRUE; +} + static jboolean enableNative(JNIEnv* env, jobject obj) { ALOGV("%s:",__FUNCTION__); @@ -1286,6 +1299,7 @@ static JNINativeMethod sMethods[] = { {"classInitNative", "()V", (void *) classInitNative}, {"initNative", "()Z", (void *) initNative}, {"cleanupNative", "()V", (void*) cleanupNative}, + {"ssrcleanupNative", "()V", (void*) ssrcleanupNative}, {"enableNative", "()Z", (void*) enableNative}, {"disableNative", "()Z", (void*) disableNative}, {"setAdapterPropertyNative", "(I[B)Z", (void*) setAdapterPropertyNative}, |