diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2019-10-23 06:26:33 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2019-10-23 06:26:33 -0400 |
commit | 13b86bc4cd648eae69fdcf3d04b2750c76350053 (patch) | |
tree | d495a635f013aacf2053364a066d83a176328784 /drivers/amba | |
parent | e969c860d56345b2c2efd2bf2b6d8c716bdc1468 (diff) | |
parent | 39f4d441048444f38fcfcfb1aa3102c030544e86 (diff) | |
download | linux-13b86bc4cd648eae69fdcf3d04b2750c76350053.tar.gz linux-13b86bc4cd648eae69fdcf3d04b2750c76350053.tar.bz2 linux-13b86bc4cd648eae69fdcf3d04b2750c76350053.zip |
Merge tag 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm
:Pull ARM fixes from Russell King:
- fix for alignment faults under high memory pressure
- use u32 for ARM instructions in fault handler
- mark functions that must always be inlined with __always_inline
- fix for nommu XIP
- fix ARMv7M switch to handler mode in reboot path
- fix the recently introduced AMBA reset control error paths
* tag 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm:
ARM: 8926/1: v7m: remove register save to stack before svc
ARM: 8914/1: NOMMU: Fix exc_ret for XIP
ARM: 8908/1: add __always_inline to functions called from __get_user_check()
ARM: mm: alignment: use "u32" for 32-bit instructions
ARM: mm: fix alignment handler faults under memory pressure
drivers/amba: fix reset control error handling
Diffstat (limited to 'drivers/amba')
-rw-r--r-- | drivers/amba/bus.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c index f39f075abff9..fe1523664816 100644 --- a/drivers/amba/bus.c +++ b/drivers/amba/bus.c @@ -409,9 +409,11 @@ static int amba_device_try_add(struct amba_device *dev, struct resource *parent) */ rstc = of_reset_control_array_get_optional_shared(dev->dev.of_node); if (IS_ERR(rstc)) { - if (PTR_ERR(rstc) != -EPROBE_DEFER) - dev_err(&dev->dev, "Can't get amba reset!\n"); - return PTR_ERR(rstc); + ret = PTR_ERR(rstc); + if (ret != -EPROBE_DEFER) + dev_err(&dev->dev, "can't get reset: %d\n", + ret); + goto err_reset; } reset_control_deassert(rstc); reset_control_put(rstc); @@ -472,6 +474,12 @@ static int amba_device_try_add(struct amba_device *dev, struct resource *parent) release_resource(&dev->res); err_out: return ret; + + err_reset: + amba_put_disable_pclk(dev); + iounmap(tmp); + dev_pm_domain_detach(&dev->dev, true); + goto err_release; } /* |