]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - drivers/pci/pcie/aer/aerdrv.c
PCI aerdrv: use correct bit defines and add 2ms delay to aer_root_reset
[net-next-2.6.git] / drivers / pci / pcie / aer / aerdrv.c
index aa495ad9bbd4b98ae78cac3623ff5bb9b9eeee69..7a711ee314b7f6a6c3da38b4b47082c859e8dfa2 100644 (file)
@@ -244,11 +244,17 @@ static pci_ers_result_t aer_root_reset(struct pci_dev *dev)
 
        /* Assert Secondary Bus Reset */
        pci_read_config_word(dev, PCI_BRIDGE_CONTROL, &p2p_ctrl);
-       p2p_ctrl |= PCI_CB_BRIDGE_CTL_CB_RESET;
+       p2p_ctrl |= PCI_BRIDGE_CTL_BUS_RESET;
        pci_write_config_word(dev, PCI_BRIDGE_CONTROL, p2p_ctrl);
 
+       /*
+        * we should send hot reset message for 2ms to allow it time to
+        * propogate to all downstream ports
+        */
+       msleep(2);
+
        /* De-assert Secondary Bus Reset */
-       p2p_ctrl &= ~PCI_CB_BRIDGE_CTL_CB_RESET;
+       p2p_ctrl &= ~PCI_BRIDGE_CTL_BUS_RESET;
        pci_write_config_word(dev, PCI_BRIDGE_CONTROL, p2p_ctrl);
 
        /*