git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
vserver 1.9.5.x5
[linux-2.6.git]
/
drivers
/
net
/
tulip
/
de2104x.c
diff --git
a/drivers/net/tulip/de2104x.c
b/drivers/net/tulip/de2104x.c
index
71fc3d0
..
ad41876
100644
(file)
--- a/
drivers/net/tulip/de2104x.c
+++ b/
drivers/net/tulip/de2104x.c
@@
-56,9
+56,10
@@
KERN_INFO DRV_NAME " PCI Ethernet driver v" DRV_VERSION " (" DRV_RELDATE ")\n";
MODULE_AUTHOR("Jeff Garzik <jgarzik@pobox.com>");
MODULE_DESCRIPTION("Intel/Digital 21040/1 series PCI Ethernet driver");
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Jeff Garzik <jgarzik@pobox.com>");
MODULE_DESCRIPTION("Intel/Digital 21040/1 series PCI Ethernet driver");
MODULE_LICENSE("GPL");
+MODULE_VERSION(DRV_VERSION);
static int debug = -1;
static int debug = -1;
-
MODULE_PARM (debug, "i"
);
+
module_param (debug, int, 0
);
MODULE_PARM_DESC (debug, "de2104x bitmapped message enable number");
/* Set the copy breakpoint for the copy-only-tiny-buffer Rx structure. */
MODULE_PARM_DESC (debug, "de2104x bitmapped message enable number");
/* Set the copy breakpoint for the copy-only-tiny-buffer Rx structure. */
@@
-69,7
+70,7
@@
static int rx_copybreak = 1518;
#else
static int rx_copybreak = 100;
#endif
#else
static int rx_copybreak = 100;
#endif
-
MODULE_PARM (rx_copybreak, "i"
);
+
module_param (rx_copybreak, int, 0
);
MODULE_PARM_DESC (rx_copybreak, "de2104x Breakpoint at which Rx packets are copied");
#define PFX DRV_NAME ": "
MODULE_PARM_DESC (rx_copybreak, "de2104x Breakpoint at which Rx packets are copied");
#define PFX DRV_NAME ": "
@@
-287,7
+288,7
@@
struct de_private {
unsigned tx_tail;
unsigned rx_tail;
unsigned tx_tail;
unsigned rx_tail;
- void *regs;
+ void
__iomem
*regs;
struct net_device *dev;
spinlock_t lock;
struct net_device *dev;
spinlock_t lock;
@@
-1208,8
+1209,7
@@
static void de_adapter_wake (struct de_private *de)
pci_write_config_dword(de->pdev, PCIPM, pmctl);
/* de4x5.c delays, so we do too */
pci_write_config_dword(de->pdev, PCIPM, pmctl);
/* de4x5.c delays, so we do too */
- current->state = TASK_UNINTERRUPTIBLE;
- schedule_timeout(msecs_to_jiffies(10));
+ msleep(10);
}
}
}
}
@@
-1703,6
+1703,7
@@
static void __init de21040_get_mac_address (struct de_private *de)
value = dr32(ROMCmd);
while (value < 0 && --boguscnt > 0);
de->dev->dev_addr[i] = value;
value = dr32(ROMCmd);
while (value < 0 && --boguscnt > 0);
de->dev->dev_addr[i] = value;
+ udelay(1);
if (boguscnt <= 0)
printk(KERN_WARNING PFX "timeout reading 21040 MAC address byte %u\n", i);
}
if (boguscnt <= 0)
printk(KERN_WARNING PFX "timeout reading 21040 MAC address byte %u\n", i);
}
@@
-1735,11
+1736,11
@@
static void __init de21040_get_media_info(struct de_private *de)
}
/* Note: this routine returns extra data bits for size detection. */
}
/* Note: this routine returns extra data bits for size detection. */
-static unsigned __init tulip_read_eeprom(void *regs, int location, int addr_len)
+static unsigned __init tulip_read_eeprom(void
__iomem
*regs, int location, int addr_len)
{
int i;
unsigned retval = 0;
{
int i;
unsigned retval = 0;
- void *ee_addr = regs + ROMCmd;
+ void
__iomem
*ee_addr = regs + ROMCmd;
int read_cmd = location | (EE_READ_CMD << addr_len);
writel(EE_ENB & ~EE_CS, ee_addr);
int read_cmd = location | (EE_READ_CMD << addr_len);
writel(EE_ENB & ~EE_CS, ee_addr);
@@
-1932,7
+1933,7
@@
static int __devinit de_init_one (struct pci_dev *pdev,
struct net_device *dev;
struct de_private *de;
int rc;
struct net_device *dev;
struct de_private *de;
int rc;
- void *regs;
+ void
__iomem
*regs;
long pciaddr;
static int board_idx = -1;
long pciaddr;
static int board_idx = -1;
@@
-1959,8
+1960,6
@@
static int __devinit de_init_one (struct pci_dev *pdev,
dev->tx_timeout = de_tx_timeout;
dev->watchdog_timeo = TX_TIMEOUT;
dev->tx_timeout = de_tx_timeout;
dev->watchdog_timeo = TX_TIMEOUT;
- dev->irq = pdev->irq;
-
de = dev->priv;
de->de21040 = ent->driver_data == 0 ? 1 : 0;
de->pdev = pdev;
de = dev->priv;
de->de21040 = ent->driver_data == 0 ? 1 : 0;
de->pdev = pdev;
@@
-1996,6
+1995,8
@@
static int __devinit de_init_one (struct pci_dev *pdev,
goto err_out_res;
}
goto err_out_res;
}
+ dev->irq = pdev->irq;
+
/* obtain and check validity of PCI I/O address */
pciaddr = pci_resource_start(pdev, 1);
if (!pciaddr) {
/* obtain and check validity of PCI I/O address */
pciaddr = pci_resource_start(pdev, 1);
if (!pciaddr) {