===================================================================
@@ -1207,6 +1207,7 @@ int pci_power_up(struct pci_dev *dev)
if (PCI_POSSIBLE_ERROR(pmcsr)) {
pci_err(dev, "Unable to change power state from %s to D0, device inaccessible\n",
pci_power_name(dev->current_state));
+ dev->current_state = PCI_D3cold;
return -EIO;
}
@@ -1335,6 +1336,7 @@ static int pci_set_low_power_state(struc
pci_err(dev, "Unable to change power state from %s to %s, device inaccessible\n",
pci_power_name(dev->current_state),
pci_power_name(state));
+ dev->current_state = PCI_D3cold;
return -EIO;
}