summaryrefslogtreecommitdiff
path: root/hif
diff options
context:
space:
mode:
authorDustin Brown <dustinb@codeaurora.org>2017-09-07 14:24:30 -0700
committersnandini <snandini@codeaurora.org>2017-10-05 16:11:29 -0700
commit0d7163dbd4961de93eb423836415e80de6d43872 (patch)
tree9ed6b289292205090e652f92b2f5ac120a285d06 /hif
parent6e26c9c1f87bae6490bc16f2f66d19739d70af30 (diff)
downloadqca-wfi-host-cmn-0d7163dbd4961de93eb423836415e80de6d43872.tar.gz
qcacmn: Log failures to prevent PCIe power collapse
Currently there is no indication when calls into pld_wlan_pm_control fail. Add an error log in such situations to improve debugging. Change-Id: Ic061a1735878930a5ab55711da58f8bad1a6a8a6 CRs-Fixed: 2119173
Diffstat (limited to 'hif')
-rw-r--r--hif/src/pcie/if_pci.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/hif/src/pcie/if_pci.c b/hif/src/pcie/if_pci.c
index c14b3e502..4e56d0809 100644
--- a/hif/src/pcie/if_pci.c
+++ b/hif/src/pcie/if_pci.c
@@ -2718,10 +2718,15 @@ static void hif_runtime_prevent_linkdown(struct hif_softc *scn, bool flag)
*/
void hif_pci_prevent_linkdown(struct hif_softc *scn, bool flag)
{
- HIF_DBG("wlan: %s pcie power collapse",
- (flag ? "disable" : "enable"));
+ int errno;
+
+ HIF_DBG("wlan: %s pcie power collapse", flag ? "disable" : "enable");
hif_runtime_prevent_linkdown(scn, flag);
- pld_wlan_pm_control(scn->qdf_dev->dev, flag);
+
+ errno = pld_wlan_pm_control(scn->qdf_dev->dev, flag);
+ if (errno)
+ HIF_ERROR("%s: Failed pld_wlan_pm_control; errno %d",
+ __func__, errno);
}
#else
void hif_pci_prevent_linkdown(struct hif_softc *scn, bool flag)