diff options
Diffstat (limited to 'drivers/pci/iov.c')
-rw-r--r-- | drivers/pci/iov.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/pci/iov.c b/drivers/pci/iov.c index bafd2bbcaf65..f8720afe0537 100644 --- a/drivers/pci/iov.c +++ b/drivers/pci/iov.c | |||
@@ -48,12 +48,7 @@ static struct pci_bus *virtfn_add_bus(struct pci_bus *bus, int busnr) | |||
48 | return NULL; | 48 | return NULL; |
49 | 49 | ||
50 | pci_bus_insert_busn_res(child, busnr, busnr); | 50 | pci_bus_insert_busn_res(child, busnr, busnr); |
51 | child->dev.parent = bus->bridge; | 51 | bus->is_added = 1; |
52 | rc = pci_bus_add_child(child); | ||
53 | if (rc) { | ||
54 | pci_remove_bus(child); | ||
55 | return NULL; | ||
56 | } | ||
57 | 52 | ||
58 | return child; | 53 | return child; |
59 | } | 54 | } |
@@ -123,8 +118,6 @@ static int virtfn_add(struct pci_dev *dev, int id, int reset) | |||
123 | virtfn->is_virtfn = 1; | 118 | virtfn->is_virtfn = 1; |
124 | 119 | ||
125 | rc = pci_bus_add_device(virtfn); | 120 | rc = pci_bus_add_device(virtfn); |
126 | if (rc) | ||
127 | goto failed1; | ||
128 | sprintf(buf, "virtfn%u", id); | 121 | sprintf(buf, "virtfn%u", id); |
129 | rc = sysfs_create_link(&dev->dev.kobj, &virtfn->dev.kobj, buf); | 122 | rc = sysfs_create_link(&dev->dev.kobj, &virtfn->dev.kobj, buf); |
130 | if (rc) | 123 | if (rc) |