From: Marcelo Feitoza Parisi <[EMAIL PROTECTED]>
Use of the time_before() macro, defined at linux/jiffies.h, which deal
with wrapping correctly and are nicer to read.
Signed-off-by: Marcelo Feitoza Parisi <[EMAIL PROTECTED]>
Signed-off-by: Domen Puncer <[EMAIL PROTECTED]>
---
seeq8005.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
Index: quilt/drivers/net/seeq8005.c
===================================================================
--- quilt.orig/drivers/net/seeq8005.c
+++ quilt/drivers/net/seeq8005.c
@@ -699,7 +699,7 @@ static void hardware_send_packet(struct
int ioaddr = dev->base_addr;
int status = inw(SEEQ_STATUS);
int transmit_ptr = 0;
- int tmp;
+ unsigned long tmp;
if (net_debug>4) {
printk("%s: send 0x%04x\n",dev->name,length);
@@ -724,7 +724,8 @@ static void hardware_send_packet(struct
/* drain FIFO */
tmp = jiffies;
- while ( (((status=inw(SEEQ_STATUS)) & SEEQSTAT_FIFO_EMPTY) == 0) &&
(jiffies - tmp < HZ))
+ while ( (((status=inw(SEEQ_STATUS)) & SEEQSTAT_FIFO_EMPTY) == 0)
+ && time_before(jiffies, tmp + HZ))
mb();
/* doit ! */
--
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html