]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
S2io: Fix crash when resetting adapter
authorRamkrishna Vepa <ram.vepa@neterion.com>
Thu, 26 Jul 2007 02:40:33 +0000 (19:40 -0700)
committerJeff Garzik <jeff@garzik.org>
Mon, 30 Jul 2007 19:56:04 +0000 (15:56 -0400)
- Removed the call to pci_set_power_state to reset the adapter as it was resulting
  in system crash on some platforms.

(Resending; Removed HTML sections in the patch)

Signed-off-by: Santosh Rastapur <santosh.rastapur@neterion.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/net/s2io.c

index 5c0f80830939f1d223f6eb9c906ffa379e177c95..9fd465b9f8534f500b035eba2f4a6b9548e4c5a2 100644 (file)
@@ -3382,23 +3382,8 @@ static void s2io_reset(struct s2io_nic * sp)
        /* Back up  the PCI-X CMD reg, dont want to lose MMRBC, OST settings */
        pci_read_config_word(sp->pdev, PCIX_COMMAND_REGISTER, &(pci_cmd));
 
-       if (sp->device_type == XFRAME_II_DEVICE) {
-               int ret;
-               ret = pci_set_power_state(sp->pdev, 3);
-               if (!ret)
-                       ret = pci_set_power_state(sp->pdev, 0);
-               else {
-                       DBG_PRINT(ERR_DBG,"%s PME based SW_Reset failed!\n",
-                                       __FUNCTION__);
-                       goto old_way;
-               }
-               msleep(20);
-               goto new_way;
-       }
-old_way:
        val64 = SW_RESET_ALL;
        writeq(val64, &bar0->sw_reset);
-new_way:
        if (strstr(sp->product_name, "CX4")) {
                msleep(750);
        }