summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorMax Krummenacher <max.krummenacher@toradex.com>2014-06-23 17:22:22 +0200
committerMax Krummenacher <max.krummenacher@toradex.com>2014-06-23 17:22:22 +0200
commitb5d9cf67a9593c07ab9d74f1d5cf83a497d577a4 (patch)
tree474b580e36604cb5043940664a806b516e0f8104 /drivers
parent67a4ed359a71a0bd1342b745413336736ef9f841 (diff)
pci-imx6.c: fix BUG, scheduling while atomic
Depending on the preemptive settings 'usleep_range' are called in code where this is not allowed. Use udelay instead of usleep_range BUG: scheduling while atomic: swapper/0/1/0x00000002
Diffstat (limited to 'drivers')
-rw-r--r--drivers/pci/host/pci-imx6.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/pci/host/pci-imx6.c b/drivers/pci/host/pci-imx6.c
index ba8f1e6212aa..b434d6228430 100644
--- a/drivers/pci/host/pci-imx6.c
+++ b/drivers/pci/host/pci-imx6.c
@@ -449,7 +449,8 @@ static void imx6_pcie_reset_phy(struct pcie_port *pp)
PHY_RX_OVRD_IN_LO_RX_PLL_EN);
pcie_phy_write(pp->dbi_base, PHY_RX_OVRD_IN_LO, temp);
- usleep_range(2000, 3000);
+ /* BUG: scheduling while atomic: swapper/0/1/0x00000002, use udelay instead of usleep_range*/
+ udelay(2000);
pcie_phy_read(pp->dbi_base, PHY_RX_OVRD_IN_LO, &temp);
temp &= ~(PHY_RX_OVRD_IN_LO_RX_DATA_EN |
@@ -491,7 +492,8 @@ static int imx6_pcie_link_up(struct pcie_port *pp)
* Wait a little bit, then re-check if the link finished
* the training.
*/
- usleep_range(1000, 2000);
+ /* BUG: scheduling while atomic: swapper/0/1/0x00000002, use udelay instead of usleep_range*/
+ udelay(1000);
}
/*
* From L0, initiate MAC entry to gen2 if EP/RC supports gen2.