| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Copyright (C) 2006 Benjamin Herrenschmidt, IBM Corp. |
|---|
| 3 | 4 | * <benh@kernel.crashing.org> |
|---|
| 4 | 5 | * and Arnd Bergmann, IBM Corp. |
|---|
| 5 | | - * |
|---|
| 6 | | - * This program is free software; you can redistribute it and/or |
|---|
| 7 | | - * modify it under the terms of the GNU General Public License |
|---|
| 8 | | - * as published by the Free Software Foundation; either version |
|---|
| 9 | | - * 2 of the License, or (at your option) any later version. |
|---|
| 10 | | - * |
|---|
| 11 | 6 | */ |
|---|
| 12 | 7 | |
|---|
| 13 | 8 | #undef DEBUG |
|---|
| .. | .. |
|---|
| 67 | 62 | /* Init pci_dn data structures */ |
|---|
| 68 | 63 | pci_devs_phb_init_dynamic(phb); |
|---|
| 69 | 64 | |
|---|
| 70 | | - /* Create EEH devices for the PHB */ |
|---|
| 71 | | - eeh_dev_phb_init_dynamic(phb); |
|---|
| 72 | | - |
|---|
| 73 | | - /* Register devices with EEH */ |
|---|
| 74 | | - if (dev->dev.of_node->child) |
|---|
| 75 | | - eeh_add_device_tree_early(PCI_DN(dev->dev.of_node)); |
|---|
| 65 | + /* Create EEH PE for the PHB */ |
|---|
| 66 | + eeh_phb_pe_create(phb); |
|---|
| 76 | 67 | |
|---|
| 77 | 68 | /* Scan the bus */ |
|---|
| 78 | 69 | pcibios_scan_phb(phb); |
|---|
| .. | .. |
|---|
| 85 | 76 | */ |
|---|
| 86 | 77 | pcibios_claim_one_bus(phb->bus); |
|---|
| 87 | 78 | |
|---|
| 88 | | - /* Finish EEH setup */ |
|---|
| 89 | | - eeh_add_device_tree_late(phb->bus); |
|---|
| 90 | | - |
|---|
| 91 | 79 | /* Add probed PCI devices to the device model */ |
|---|
| 92 | 80 | pci_bus_add_devices(phb->bus); |
|---|
| 93 | | - |
|---|
| 94 | | - /* sysfs files should only be added after devices are added */ |
|---|
| 95 | | - eeh_add_sysfs_files(phb->bus); |
|---|
| 96 | 81 | |
|---|
| 97 | 82 | return 0; |
|---|
| 98 | 83 | } |
|---|