This commit was manufactured by cvs2svn to create tag
[linux-2.6.git] / drivers / net / 8139too.c
index 51e56c4..a9ca6ae 100644 (file)
@@ -567,6 +567,7 @@ struct rtl8139_private {
        void *mmio_addr;
        int drv_flags;
        struct pci_dev *pci_dev;
+       u32 pci_state[16];
        u32 msg_enable;
        struct net_device_stats stats;
        unsigned char *rx_ring;
@@ -598,11 +599,12 @@ struct rtl8139_private {
 MODULE_AUTHOR ("Jeff Garzik <jgarzik@pobox.com>");
 MODULE_DESCRIPTION ("RealTek RTL-8139 Fast Ethernet driver");
 MODULE_LICENSE("GPL");
+MODULE_VERSION(DRV_VERSION);
 
-module_param(multicast_filter_limit, int, 0);
-module_param_array(media, int, NULL, 0);
-module_param_array(full_duplex, int, NULL, 0);
-module_param(debug, int, 0);
+MODULE_PARM (multicast_filter_limit, "i");
+MODULE_PARM (media, "1-" __MODULE_STRING(MAX_UNITS) "i");
+MODULE_PARM (full_duplex, "1-" __MODULE_STRING(MAX_UNITS) "i");
+MODULE_PARM (debug, "i");
 MODULE_PARM_DESC (debug, "8139too bitmapped message enable number");
 MODULE_PARM_DESC (multicast_filter_limit, "8139too maximum number of filtered multicast addresses");
 MODULE_PARM_DESC (media, "8139too: Bits 4+9: force full duplex, bit 5: 100Mbps");
@@ -2588,7 +2590,7 @@ static int rtl8139_suspend (struct pci_dev *pdev, u32 state)
        void *ioaddr = tp->mmio_addr;
        unsigned long flags;
 
-       pci_save_state (pdev);
+       pci_save_state (pdev, tp->pci_state);
 
        if (!netif_running (dev))
                return 0;
@@ -2616,8 +2618,9 @@ static int rtl8139_suspend (struct pci_dev *pdev, u32 state)
 static int rtl8139_resume (struct pci_dev *pdev)
 {
        struct net_device *dev = pci_get_drvdata (pdev);
+       struct rtl8139_private *tp = dev->priv;
 
-       pci_restore_state (pdev);
+       pci_restore_state (pdev, tp->pci_state);
        if (!netif_running (dev))
                return 0;
        pci_set_power_state (pdev, 0);