mirror of
https://github.com/team-infusion-developers/android_kernel_samsung_msm8976.git
synced 2024-11-07 04:09:21 +00:00
msm: pcie: do not recover link for unexpected case
For some situations where linkdown event should not happen, recovering link by bus driver alone will be out of sync. Thus, avoid recovering the link in this kind of situation and only show error notification. Change-Id: I260583e3b4431029dfd4fc33d67bc86c3acfe6e7 Signed-off-by: Yan He <yanhe@codeaurora.org>
This commit is contained in:
parent
1d3124ad0c
commit
09f0b0a174
1 changed files with 2 additions and 14 deletions
|
@ -207,7 +207,6 @@ static irqreturn_t handle_wake_irq(int irq, void *data)
|
|||
|
||||
static void handle_linkdown_func(struct work_struct *work)
|
||||
{
|
||||
int ret;
|
||||
struct msm_pcie_dev_t *dev = container_of(work, struct msm_pcie_dev_t,
|
||||
handle_linkdown_work);
|
||||
|
||||
|
@ -254,22 +253,11 @@ static void handle_linkdown_func(struct work_struct *work)
|
|||
}
|
||||
}
|
||||
} else {
|
||||
PCIE_DBG(
|
||||
"PCIe: No registration for linkdown of RC%d; so recover the link by RC\n",
|
||||
pr_err(
|
||||
"PCIe: Client driver does not have registration and this linkdown of RC%d should never happen.\n",
|
||||
dev->rc_idx);
|
||||
|
||||
msm_pcie_disable(dev, PM_EXPT | PM_PIPE_CLK | PM_CLK | PM_VREG);
|
||||
ret = msm_pcie_recover_link(dev);
|
||||
|
||||
if (ret) {
|
||||
pr_err(
|
||||
"PCIe:failed to enable RC%d again upon linkdown.\n",
|
||||
dev->rc_idx);
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
|
||||
out:
|
||||
dev->handling_linkdown--;
|
||||
if (dev->handling_linkdown < 0)
|
||||
pr_err("PCIe:handling_linkdown for RC%d is %d\n",
|
||||
|
|
Loading…
Reference in a new issue