summaryrefslogtreecommitdiffstats
path: root/drivers/pci/of.c
diff options
context:
space:
mode:
authorLinus Torvalds2011-08-19 19:02:37 +0200
committerLinus Torvalds2011-08-19 19:02:37 +0200
commit0c3bef612881ee6216a36952ffaabfc35b83545c (patch)
tree46e69e46d557c319ff3f261f37f1c184eaa9b844 /drivers/pci/of.c
parentMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc (diff)
parentPCI: OF: Don't crash when bridge parent is NULL. (diff)
downloadkernel-qcow2-linux-0c3bef612881ee6216a36952ffaabfc35b83545c.tar.gz
kernel-qcow2-linux-0c3bef612881ee6216a36952ffaabfc35b83545c.tar.xz
kernel-qcow2-linux-0c3bef612881ee6216a36952ffaabfc35b83545c.zip
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6: PCI: OF: Don't crash when bridge parent is NULL. PCI: export pcie_bus_configure_settings symbol PCI: code and comments cleanup PCI: make cardbus-bridge resources optional PCI: make SRIOV resources optional PCI : ability to relocate assigned pci-resources PCI: honor child buses add_size in hot plug configuration PCI: Set PCI-E Max Payload Size on fabric
Diffstat (limited to 'drivers/pci/of.c')
-rw-r--r--drivers/pci/of.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/of.c b/drivers/pci/of.c
index c94d37ec55c8..f0929934bb7a 100644
--- a/drivers/pci/of.c
+++ b/drivers/pci/of.c
@@ -55,7 +55,7 @@ struct device_node * __weak pcibios_get_phb_of_node(struct pci_bus *bus)
*/
if (bus->bridge->of_node)
return of_node_get(bus->bridge->of_node);
- if (bus->bridge->parent->of_node)
+ if (bus->bridge->parent && bus->bridge->parent->of_node)
return of_node_get(bus->bridge->parent->of_node);
return NULL;
}