hwspinlock: ignore disabled device
Do not wait for hwspinlock device registration if it is not available for use. Acked-by: Suman Anna <s-anna@ti.com> Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
This commit is contained in:
parent
d4d98bba3e
commit
fbd7330c9f
|
@ -333,6 +333,11 @@ int of_hwspin_lock_get_id(struct device_node *np, int index)
|
|||
if (ret)
|
||||
return ret;
|
||||
|
||||
if (!of_device_is_available(args.np)) {
|
||||
ret = -ENOENT;
|
||||
goto out;
|
||||
}
|
||||
|
||||
/* Find the hwspinlock device: we need its base_id */
|
||||
ret = -EPROBE_DEFER;
|
||||
rcu_read_lock();
|
||||
|
|
Loading…
Reference in New Issue