]> git.hungrycats.org Git - linux/commitdiff
[PATCH] ppc64: ISA device tree node refcount fix
authorPaul Mackerras <paulus@samba.org>
Mon, 2 Aug 2004 03:10:22 +0000 (20:10 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Mon, 2 Aug 2004 03:10:22 +0000 (20:10 -0700)
Moves a misplaced of_node_put().  In the existing code, the node in
question is used just after its refcount is decremented.

Signed-off-by: John Rose <johnrose@austin.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/ppc64/kernel/pSeries_pci.c

index 73d5b7ea50e4b56e1cf652373f039d39c4cadea6..a04037bba2200a86df8cb1c275efec47d0532d96 100644 (file)
@@ -284,10 +284,10 @@ static void __init pci_process_bridge_OF_ranges(struct pci_controller *hose,
                                isa_dn = of_find_node_by_type(NULL, "isa");
                                if (isa_dn) {
                                        isa_io_base = pci_io_base;
-                                       of_node_put(isa_dn);
                                        pci_process_ISA_OF_ranges(isa_dn,
                                                hose->io_base_phys,
                                                hose->io_base_virt);
+                                       of_node_put(isa_dn);
                                         /* Allow all IO */
                                         io_page_mask = -1;
                                }