From d3d87568bb4db2d71166eb8662b6907080c69db4 Mon Sep 17 00:00:00 2001 From: Paul Gortmaker Date: Sun, 20 Mar 2011 20:37:55 -0400 Subject: [PATCH] of: more devtree_lock needs to be taken irqsave Tip commit a87f354dbe174dc43a93844f2d3bc7dd990ffb32 makes most of the locking of irqsave type -- but since this function was in a different file in 33 vs. 34, it was inadvertently treated differently. Signed-off-by: Paul Gortmaker diff --git a/drivers/of/base.c b/drivers/of/base.c index ff25043..8381c14 100644 --- a/drivers/of/base.c +++ b/drivers/of/base.c @@ -696,13 +696,14 @@ EXPORT_SYMBOL_GPL(of_modalias_node); struct device_node *of_find_node_by_phandle(phandle handle) { struct device_node *np; + unsigned long flags; - raw_spin_lock(&devtree_lock); + raw_spin_lock_irqsave(&devtree_lock, flags); for (np = allnodes; np; np = np->allnext) if (np->phandle == handle) break; of_node_get(np); - raw_spin_unlock(&devtree_lock); + raw_spin_unlock_irqrestore(&devtree_lock, flags); return np; } EXPORT_SYMBOL(of_find_node_by_phandle); -- 1.7.1.1