aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/oaknet.c
diff options
context:
space:
mode:
authorMarcelo Feitoza Parisi <marcelo@feitoza.com.br>2006-01-09 21:37:15 -0500
committerJeff Garzik <jgarzik@pobox.com>2006-01-17 07:59:23 -0500
commitff5688ae1cedfb175b5ed0f319d03ad2e5ee005d (patch)
treeeca0d41b3eefc833238591e0100a8136f21269a7 /drivers/net/oaknet.c
parente03d72b99e4027504ada134bf1804d6ea792b206 (diff)
[PATCH] drivers/net/*: use time_after() and friends
They deal with wrapping correctly and are nicer to read. Also make jiffies-holding variables unsigned long. Signed-off-by: Marcelo Feitoza Parisi <marcelo@feitoza.com.br> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Diffstat (limited to 'drivers/net/oaknet.c')
-rw-r--r--drivers/net/oaknet.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/oaknet.c b/drivers/net/oaknet.c
index 62167a29debe..d0f686d6eaaa 100644
--- a/drivers/net/oaknet.c
+++ b/drivers/net/oaknet.c
@@ -20,6 +20,7 @@
20#include <linux/netdevice.h> 20#include <linux/netdevice.h>
21#include <linux/etherdevice.h> 21#include <linux/etherdevice.h>
22#include <linux/init.h> 22#include <linux/init.h>
23#include <linux/jiffies.h>
23 24
24#include <asm/board.h> 25#include <asm/board.h>
25#include <asm/io.h> 26#include <asm/io.h>
@@ -606,7 +607,7 @@ retry:
606#endif 607#endif
607 608
608 while ((ei_ibp(base + EN0_ISR) & ENISR_RDC) == 0) { 609 while ((ei_ibp(base + EN0_ISR) & ENISR_RDC) == 0) {
609 if (jiffies - start > OAKNET_WAIT) { 610 if (time_after(jiffies, start + OAKNET_WAIT)) {
610 printk("%s: timeout waiting for Tx RDC.\n", dev->name); 611 printk("%s: timeout waiting for Tx RDC.\n", dev->name);
611 oaknet_reset_8390(dev); 612 oaknet_reset_8390(dev);
612 NS8390_init(dev, TRUE); 613 NS8390_init(dev, TRUE);