From: Linas Vepstas Date: Fri, 2 Nov 2007 20:14:28 +0000 (-0500) Subject: PCI: pcie portdriver: initialize returned value X-Git-Tag: v2.6.24-rc4~77^2~3 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=bf164410d08dc83df416e3a6a43ab29bf88890ed;p=linux-2.6-omap-h63xx.git PCI: pcie portdriver: initialize returned value The pcie protdrv status can be returned uninitialized, if there are no children under a device. This leads to bad responses downstream. Fix this. Signed-off-by: Linas Vepstas Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/pci/pcie/portdrv_pci.c b/drivers/pci/pcie/portdrv_pci.c index df383645e36..26057f98f72 100644 --- a/drivers/pci/pcie/portdrv_pci.c +++ b/drivers/pci/pcie/portdrv_pci.c @@ -217,7 +217,7 @@ static int slot_reset_iter(struct device *device, void *data) static pci_ers_result_t pcie_portdrv_slot_reset(struct pci_dev *dev) { - pci_ers_result_t status; + pci_ers_result_t status = PCI_ERS_RESULT_NONE; int retval; /* If fatal, restore cfg space for possible link reset at upstream */