wlan: Crash device only if gSsrPanicOnFailure is enabled
When vos_start()/vos_stop() fails driver crashes device.
This behaviour is not acceptable in certain user testcase, for
example when testing is done without IRIS card.
On vos_start()/vos_stop() failure, crash device only if ini param,
gSsrPanicOnFailure is enabled.
Change-Id: I8c48ce4edcf48f62ff7ba9c58e4e4feb480e00d5
CRs-Fixed: 975491
diff --git a/CORE/HDD/src/wlan_hdd_early_suspend.c b/CORE/HDD/src/wlan_hdd_early_suspend.c
index 9841344..906aa37 100644
--- a/CORE/HDD/src/wlan_hdd_early_suspend.c
+++ b/CORE/HDD/src/wlan_hdd_early_suspend.c
@@ -399,7 +399,8 @@
hddLog(VOS_TRACE_LEVEL_ERROR, "%s: vos_stop return failed %d",
__func__, vosStatus);
VOS_ASSERT(0);
- VOS_BUG(0);
+ if (isSsrPanicOnFailure())
+ VOS_BUG(0);
}
pHddCtx->hdd_ps_state = eHDD_SUSPEND_DEEP_SLEEP;
@@ -439,7 +440,8 @@
{
VOS_TRACE(VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_ERROR,
"%s: Failed in vos_start",__func__);
- VOS_BUG(0);
+ if (isSsrPanicOnFailure())
+ VOS_BUG(0);
goto err_deep_sleep;
}
@@ -2235,7 +2237,8 @@
if ( !VOS_IS_STATUS_SUCCESS( vosStatus ) )
{
hddLog(VOS_TRACE_LEVEL_FATAL,"%s: vos_start failed",__func__);
- VOS_BUG(0);
+ if (isSsrPanicOnFailure())
+ VOS_BUG(0);
goto err_vosclose;
}
diff --git a/CORE/HDD/src/wlan_hdd_main.c b/CORE/HDD/src/wlan_hdd_main.c
index adeeba3..ef0a520 100755
--- a/CORE/HDD/src/wlan_hdd_main.c
+++ b/CORE/HDD/src/wlan_hdd_main.c
@@ -8903,7 +8903,8 @@
VOS_TRACE( VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_FATAL,
"%s: Failed to stop VOSS",__func__);
VOS_ASSERT( VOS_IS_STATUS_SUCCESS( vosStatus ) );
- VOS_BUG(0);
+ if (isSsrPanicOnFailure())
+ VOS_BUG(0);
}
//This requires pMac access, Call this before vos_close().
@@ -10308,7 +10309,8 @@
if ( !VOS_IS_STATUS_SUCCESS( status ) )
{
hddLog(VOS_TRACE_LEVEL_FATAL,"%s: vos_start failed",__func__);
- VOS_BUG(0);
+ if (isSsrPanicOnFailure())
+ VOS_BUG(0);
goto err_vosclose;
}