diff options
author | Dmitry Osipenko <digetx@gmail.com> | 2020-01-06 04:34:12 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-01-09 18:21:58 +0300 |
commit | f1f0c7516708370de234ef1490da1298168e32ac (patch) | |
tree | bc6fc52fdb6560a90f7afbcb43dd9d91adf47b88 /drivers/usb/phy | |
parent | 92bd2ef26c5d804a21ada9d4e2d353e3e2e215ab (diff) | |
download | linux-f1f0c7516708370de234ef1490da1298168e32ac.tar.xz |
usb: phy: tegra: Keep CPU interrupts enabled
There is no good reason for disabling of CPU interrupts in order to
protect the utmip_pad_count modification.
Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
Link: https://lore.kernel.org/r/20200106013416.9604-17-digetx@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/phy')
-rw-r--r-- | drivers/usb/phy/phy-tegra-usb.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/usb/phy/phy-tegra-usb.c b/drivers/usb/phy/phy-tegra-usb.c index 1b9667b0aa11..037e8eee737d 100644 --- a/drivers/usb/phy/phy-tegra-usb.c +++ b/drivers/usb/phy/phy-tegra-usb.c @@ -310,7 +310,6 @@ static int utmip_pad_power_on(struct tegra_usb_phy *phy) { struct tegra_utmip_config *config = phy->config; void __iomem *base = phy->pad_regs; - unsigned long flags; u32 val; int err; @@ -318,7 +317,7 @@ static int utmip_pad_power_on(struct tegra_usb_phy *phy) if (err) return err; - spin_lock_irqsave(&utmip_pad_lock, flags); + spin_lock(&utmip_pad_lock); if (utmip_pad_count++ == 0) { val = readl_relaxed(base + UTMIP_BIAS_CFG0); @@ -336,7 +335,7 @@ static int utmip_pad_power_on(struct tegra_usb_phy *phy) writel_relaxed(val, base + UTMIP_BIAS_CFG0); } - spin_unlock_irqrestore(&utmip_pad_lock, flags); + spin_unlock(&utmip_pad_lock); clk_disable_unprepare(phy->pad_clk); @@ -346,7 +345,6 @@ static int utmip_pad_power_on(struct tegra_usb_phy *phy) static int utmip_pad_power_off(struct tegra_usb_phy *phy) { void __iomem *base = phy->pad_regs; - unsigned long flags; u32 val; int ret; @@ -354,7 +352,7 @@ static int utmip_pad_power_off(struct tegra_usb_phy *phy) if (ret) return ret; - spin_lock_irqsave(&utmip_pad_lock, flags); + spin_lock(&utmip_pad_lock); if (!utmip_pad_count) { dev_err(phy->u_phy.dev, "UTMIP pad already powered off\n"); @@ -368,7 +366,7 @@ static int utmip_pad_power_off(struct tegra_usb_phy *phy) writel_relaxed(val, base + UTMIP_BIAS_CFG0); } ulock: - spin_unlock_irqrestore(&utmip_pad_lock, flags); + spin_unlock(&utmip_pad_lock); clk_disable_unprepare(phy->pad_clk); |