diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2006-08-28 14:43:25 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-09-26 20:43:53 -0400 |
commit | b19441af185559118e8247382ea4f2f76ebffc6d (patch) | |
tree | 5b687d2a0052b38fa5d32abeec75374b4aa8830e /drivers/pci/hotplug | |
parent | 660a0e8fdf85f30b1e5f6905a78361476094eb7c (diff) |
PCI: fix __must_check warnings
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci/hotplug')
-rw-r--r-- | drivers/pci/hotplug/fakephp.c | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/drivers/pci/hotplug/fakephp.c b/drivers/pci/hotplug/fakephp.c index dd2b762777c4..05a4f0f90186 100644 --- a/drivers/pci/hotplug/fakephp.c +++ b/drivers/pci/hotplug/fakephp.c | |||
@@ -176,7 +176,9 @@ static void pci_rescan_slot(struct pci_dev *temp) | |||
176 | struct pci_bus *bus = temp->bus; | 176 | struct pci_bus *bus = temp->bus; |
177 | struct pci_dev *dev; | 177 | struct pci_dev *dev; |
178 | int func; | 178 | int func; |
179 | int retval; | ||
179 | u8 hdr_type; | 180 | u8 hdr_type; |
181 | |||
180 | if (!pci_read_config_byte(temp, PCI_HEADER_TYPE, &hdr_type)) { | 182 | if (!pci_read_config_byte(temp, PCI_HEADER_TYPE, &hdr_type)) { |
181 | temp->hdr_type = hdr_type & 0x7f; | 183 | temp->hdr_type = hdr_type & 0x7f; |
182 | if (!pci_find_slot(bus->number, temp->devfn)) { | 184 | if (!pci_find_slot(bus->number, temp->devfn)) { |
@@ -185,8 +187,12 @@ static void pci_rescan_slot(struct pci_dev *temp) | |||
185 | dbg("New device on %s function %x:%x\n", | 187 | dbg("New device on %s function %x:%x\n", |
186 | bus->name, temp->devfn >> 3, | 188 | bus->name, temp->devfn >> 3, |
187 | temp->devfn & 7); | 189 | temp->devfn & 7); |
188 | pci_bus_add_device(dev); | 190 | retval = pci_bus_add_device(dev); |
189 | add_slot(dev); | 191 | if (retval) |
192 | dev_err(&dev->dev, "error adding " | ||
193 | "device, continuing.\n"); | ||
194 | else | ||
195 | add_slot(dev); | ||
190 | } | 196 | } |
191 | } | 197 | } |
192 | /* multifunction device? */ | 198 | /* multifunction device? */ |
@@ -205,8 +211,12 @@ static void pci_rescan_slot(struct pci_dev *temp) | |||
205 | dbg("New device on %s function %x:%x\n", | 211 | dbg("New device on %s function %x:%x\n", |
206 | bus->name, temp->devfn >> 3, | 212 | bus->name, temp->devfn >> 3, |
207 | temp->devfn & 7); | 213 | temp->devfn & 7); |
208 | pci_bus_add_device(dev); | 214 | retval = pci_bus_add_device(dev); |
209 | add_slot(dev); | 215 | if (retval) |
216 | dev_err(&dev->dev, "error adding " | ||
217 | "device, continuing.\n"); | ||
218 | else | ||
219 | add_slot(dev); | ||
210 | } | 220 | } |
211 | } | 221 | } |
212 | } | 222 | } |