X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fnet%2Foaknet.c;h=702e3e95612aeb6d7fec76a6d02c148971ca8e17;hb=refs%2Fheads%2Fvserver;hp=62167a29debe304a4913e3027fbdf5127c6ac8d4;hpb=76828883507a47dae78837ab5dec5a5b4513c667;p=linux-2.6.git diff --git a/drivers/net/oaknet.c b/drivers/net/oaknet.c index 62167a29d..702e3e956 100644 --- a/drivers/net/oaknet.c +++ b/drivers/net/oaknet.c @@ -9,7 +9,7 @@ * on-board the IBM PowerPC "Oak" evaluation board. Adapted from the * various other 8390 drivers written by Donald Becker and Paul Gortmaker. * - * Additional inspiration from the "tcd8390.c" driver from TiVo, Inc. + * Additional inspiration from the "tcd8390.c" driver from TiVo, Inc. * and "enetLib.c" from IBM. * */ @@ -20,6 +20,7 @@ #include #include #include +#include #include #include @@ -97,7 +98,7 @@ static int __init oaknet_init(void) int ret = -ENOMEM; struct net_device *dev; #if 0 - unsigned long ioaddr = OAKNET_IO_BASE; + unsigned long ioaddr = OAKNET_IO_BASE; #else unsigned long ioaddr = ioremap(OAKNET_IO_BASE, OAKNET_IO_SIZE); #endif @@ -200,7 +201,7 @@ static int __init oaknet_init(void) ret = register_netdev(dev); if (ret) goto out_irq; - + oaknet_devs = dev; return 0; @@ -446,8 +447,8 @@ oaknet_block_input(struct net_device *dev, int count, struct sk_buff *skb, * Input(s): * *dev - Pointer to the device structure for this driver. * count - Number of bytes to be transferred. - * *buf - - * start_page - + * *buf - + * start_page - * * Output(s): * N/A @@ -583,7 +584,7 @@ retry: * This was for the ALPHA version only, but enough people have * been encountering problems so it is still here. */ - + { /* DMA termination address check... */ int addr, tries = 20; @@ -606,14 +607,14 @@ retry: #endif while ((ei_ibp(base + EN0_ISR) & ENISR_RDC) == 0) { - if (jiffies - start > OAKNET_WAIT) { + if (time_after(jiffies, start + OAKNET_WAIT)) { printk("%s: timeout waiting for Tx RDC.\n", dev->name); oaknet_reset_8390(dev); NS8390_init(dev, TRUE); break; } } - + ei_obp(ENISR_RDC, base + EN0_ISR); /* Ack intr. */ ei_status.dmaing &= ~0x01; }