diff options
author | Hamad Kadmany <hkadmany@codeaurora.org> | 2015-06-10 18:31:23 +0300 |
---|---|---|
committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 19:57:51 -0700 |
commit | 3de46377e100c6b7d561b251a193e886a951d5dd (patch) | |
tree | 625dada9bade001cea9b92de306f8f048975ce4d /drivers | |
parent | 572c609c0a6807acfd8bbb8483585ce41b494eb1 (diff) |
msm_11ad: Add delay between chip power-on to PCIe init
Delay is required to wait for the PCIe endpoint to become
stable after power on before de-assertion of PERST to
the endpoint by PCIe root complex.
Change-Id: Ib064e936fa0540646e6751d7c3b739c0beb48e60
Signed-off-by: Hamad Kadmany <hkadmany@codeaurora.org>
Signed-off-by: Maya Erez <merez@codeaurora.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/platform/msm/msm_11ad/msm_11ad.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/platform/msm/msm_11ad/msm_11ad.c b/drivers/platform/msm/msm_11ad/msm_11ad.c index 2b6295bef849..5d965aa0a8fd 100644 --- a/drivers/platform/msm/msm_11ad/msm_11ad.c +++ b/drivers/platform/msm/msm_11ad/msm_11ad.c @@ -19,6 +19,7 @@ #include <linux/msm-bus.h> #include <linux/iommu.h> #include <linux/version.h> +#include <linux/delay.h> #include "wil_platform.h" #include "msm_11ad.h" @@ -28,6 +29,8 @@ #define SMMU_BASE 0x10000000 /* Device address range base */ #define SMMU_SIZE 0x40000000 /* Device address range size */ +#define WIGIG_ENABLE_DELAY 10 + struct device; static const char * const gpio_en_name = "qcom,wigig-en"; @@ -106,6 +109,8 @@ static int ops_resume(void *handle) pcidev = ctx->pcidev; gpio_direction_output(ctx->gpio_en, 1); + msleep(WIGIG_ENABLE_DELAY); + rc = msm_pcie_pm_control(MSM_PCIE_RESUME, pcidev->bus->number, pcidev, NULL, 0); if (rc) { @@ -228,6 +233,9 @@ static int msm_11ad_probe(struct platform_device *pdev) gpio_en_name); goto out_set; } + + msleep(WIGIG_ENABLE_DELAY); + /* enumerate it on PCIE */ rc = msm_pcie_enumerate(ctx->rc_index); if (rc < 0) { |