netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Auke Kok <auke-jan.h.kok@intel.com>
To: jeff@garzik.org
Cc: netdev@vger.kernel.org, akpm@linux-foundation.org, andi@firstfloor.org
Subject: [PATCH 4/6] e1000e: Use time_after to account for jiffies wrapping
Date: Fri, 10 Aug 2007 13:00:57 -0700	[thread overview]
Message-ID: <20070810200057.21509.18676.stgit@localhost.localdomain> (raw)
In-Reply-To: <20070810200038.21509.77815.stgit@localhost.localdomain>

Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
---

 drivers/net/e1000e/ethtool.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/e1000e/ethtool.c b/drivers/net/e1000e/ethtool.c
index d184116..d14cc4b 100644
--- a/drivers/net/e1000e/ethtool.c
+++ b/drivers/net/e1000e/ethtool.c
@@ -1411,7 +1411,7 @@ static int e1000_run_loopback_test(struct e1000_adapter *adapter)
 			 * enough time to complete the receives, if it's
 			 * exceeded, break and error off
 			 */
-		} while (good_cnt < 64 && jiffies < (time + 20));
+		} while ((good_cnt < 64) && !time_after(jiffies, time + 20));
 		if (good_cnt != 64) {
 			ret_val = 13; /* ret_val is the same as mis-compare */
 			break;

  parent reply	other threads:[~2007-08-10 20:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-10 20:00 [PATCH 1/6] e1000e: Fix header includes [v2] Auke Kok
2007-08-10 20:00 ` [PATCH 2/6] e1000e: remove namespace collisions with e1000 Auke Kok
2007-08-14  5:13   ` Jeff Garzik
2007-08-14 16:41     ` Rick Jones
2007-08-14 21:22       ` Kok, Auke
2007-08-10 20:00 ` [PATCH 3/6] e1000e: Use dma_alloc_coherent where possible Auke Kok
2007-08-10 20:00 ` Auke Kok [this message]
2007-08-10 20:01 ` [PATCH 5/6] e1000e: error handling for pci_map_single calls Auke Kok
2007-08-14  5:15   ` Jeff Garzik
2007-08-10 20:01 ` [PATCH 6/6] e1000e: Remove two compile warnings Auke Kok
2007-08-14  5:11 ` [PATCH 1/6] e1000e: Fix header includes [v2] Jeff Garzik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070810200057.21509.18676.stgit@localhost.localdomain \
    --to=auke-jan.h.kok@intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=andi@firstfloor.org \
    --cc=jeff@garzik.org \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).