[PATCH] of: Fix locking when calling of_get_next_available_child()

Stephen Warren swarren at wwwdotorg.org
Tue Feb 12 10:26:46 EST 2013


On 02/11/2013 03:19 PM, Grant Likely wrote:
> of_get_next_available_child() obtains the devtree_lock and then calls
> of_device_is_available() which also attempts to claim the lock. This is
> obviously incorrect and causes a deadlock on boot. Fix issue by adding
> an variant of of_device_is_available() which doesn't obtain the lock.

This patch forgets to update __of_device_is_available() to call
__of_get_property() rather than of_get_property() and hence doesn't
actually solve the problem.

You might want to make __of_device_is_available() static too.


More information about the devicetree-discuss mailing list