DORMANTno replies

[PATCH v2] ARM: amba: adapt to regulator probe deferral change

From: Shawn Guo <hidden>
Date: 2012-04-02 07:14:43
Subsystem: arm primecell bus support, the rest · Maintainers: Russell King, Linus Torvalds

The commit 04bf301 (regulator: Support driver probe deferral) changes
regulator_get() and regulator_register() to return -EPROBE_DEFER
instead of -ENODEV.  Adapt amba bus driver to the change, otherwise
amba_probe() will fail on the platforms that do not have "vcore"
regulator device.

It fixes the boot failure on i.mx28 which uses amba-pl011 as serial
console.

Signed-off-by: Shawn Guo <redacted>
Reviwed-by: Mark Brown [off-list ref]
---
Changes since v1:
 * Revert the comment change

 drivers/amba/bus.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c
index 01c2cf4..380995e 100644
--- a/drivers/amba/bus.c
+++ b/drivers/amba/bus.c
@@ -363,7 +363,7 @@ static int amba_get_enable_vcore(struct amba_device *pcdev)
 
 	if (IS_ERR(vcore)) {
 		/* It is OK not to supply a vcore regulator */
-		if (PTR_ERR(vcore) == -ENODEV)
+		if (PTR_ERR(vcore) == -EPROBE_DEFER)
 			return 0;
 		return PTR_ERR(vcore);
 	}
-- 
1.7.5.4
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help