Merge remote-tracking branch 'grant/devicetree/next' into for-3.14
authorRob Herring <robh@kernel.org>
Fri, 17 Jan 2014 22:01:27 +0000 (16:01 -0600)
committerRob Herring <robh@kernel.org>
Fri, 17 Jan 2014 22:01:27 +0000 (16:01 -0600)
1  2 
drivers/of/irq.c

diff --combined drivers/of/irq.c
@@@ -165,7 -165,6 +165,6 @@@ int of_irq_parse_raw(const __be32 *addr
                if (of_get_property(ipar, "interrupt-controller", NULL) !=
                                NULL) {
                        pr_debug(" -> got it !\n");
-                       of_node_put(old);
                        return 0;
                }
  
                                goto fail;
                        }
  
 +                      if (!of_device_is_available(newpar))
 +                              match = 0;
 +
                        /* Get #interrupt-cells and #address-cells of new
                         * parent
                         */
                 * Successfully parsed an interrrupt-map translation; copy new
                 * interrupt specifier into the out_irq structure
                 */
-               of_node_put(out_irq->np);
-               out_irq->np = of_node_get(newpar);
+               out_irq->np = newpar;
  
                match_array = imap - newaddrsize - newintsize;
                for (i = 0; i < newintsize; i++)
        }
   fail:
        of_node_put(ipar);
-       of_node_put(out_irq->np);
        of_node_put(newpar);
  
        return -EINVAL;
@@@ -441,8 -435,7 +438,8 @@@ void __init of_irq_init(const struct of
        INIT_LIST_HEAD(&intc_parent_list);
  
        for_each_matching_node(np, matches) {
 -              if (!of_find_property(np, "interrupt-controller", NULL))
 +              if (!of_find_property(np, "interrupt-controller", NULL) ||
 +                              !of_device_is_available(np))
                        continue;
                /*
                 * Here, we allocate and populate an intc_desc with the node