summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwadesong <wadesong@codeaurora.org>2017-09-04 15:55:43 +0800
committersnandini <snandini@codeaurora.org>2017-09-14 03:42:11 -0700
commit2b5386c7eb10688c5fe22dea009f807da88bf221 (patch)
tree53461409c29875273ef8752c6718df8cde09f8ea
parent037b96ea4b62de58b36607e7eeec9301fd88960c (diff)
qcacld-3.0: Enable SDIO based WLAN self-recovery
WLAN self-recovery based on SDIO bus is currently missing in CLD3.x, resulting in crash injection to TF card taking no effect during some special case. Add the recovery feature back to CLD3.x based on the same logics in CLD2.0 Change-Id: I719b77ac9679a0449863a94b47ad22233bc9b574 CRs-fixed: 2103969
-rw-r--r--core/pld/src/pld_common.c1
-rw-r--r--core/pld/src/pld_sdio.h11
2 files changed, 12 insertions, 0 deletions
diff --git a/core/pld/src/pld_common.c b/core/pld/src/pld_common.c
index 2aac2b9fd839..1bcce437ea57 100644
--- a/core/pld/src/pld_common.c
+++ b/core/pld/src/pld_common.c
@@ -662,6 +662,7 @@ void pld_device_self_recovery(struct device *dev)
case PLD_BUS_TYPE_SNOC:
break;
case PLD_BUS_TYPE_SDIO:
+ pld_sdio_device_self_recovery(dev);
break;
default:
pr_err("Invalid device type\n");
diff --git a/core/pld/src/pld_sdio.h b/core/pld/src/pld_sdio.h
index d87f950621e0..07ae0de3a73e 100644
--- a/core/pld/src/pld_sdio.h
+++ b/core/pld/src/pld_sdio.h
@@ -19,6 +19,9 @@
#ifndef __PLD_SDIO_H__
#define __PLD_SDIO_H__
+#ifdef CONFIG_PLD_SDIO_CNSS
+#include <net/cnss.h>
+#endif
#include "pld_common.h"
#ifdef MULTI_IF_NAME
@@ -113,6 +116,11 @@ static inline bool pld_sdio_is_fw_dump_skipped(void)
{
return cnss_get_restart_level() == CNSS_RESET_SUBSYS_COUPLED;
}
+
+static inline void pld_sdio_device_self_recovery(struct device *dev)
+{
+ cnss_common_device_self_recovery(dev);
+}
#else
static inline void *pld_sdio_get_virt_ramdump_mem(struct device *dev,
unsigned long *size)
@@ -128,6 +136,9 @@ static inline bool pld_sdio_is_fw_dump_skipped(void)
return false;
}
+static inline void pld_sdio_device_self_recovery(struct device *dev)
+{
+}
#endif
void *pld_hif_sdio_get_virt_ramdump_mem(struct device *dev,
unsigned long *size);