* [KJ] [PATCH 10/21] polling loops: change exit condition to
@ 2005-12-04 0:18 Marcin Slusarz
0 siblings, 0 replies; only message in thread
From: Marcin Slusarz @ 2005-12-04 0:18 UTC (permalink / raw)
To: kernel-janitors
ISDN SUBSYSTEM
P: Karsten Keil
M: kkeil@suse.de
P: Kai Germaschewski
M: kai.germaschewski@gmx.de
Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
diff -upr -X linux-2.6.15-rc4/Documentation/dontdiff linux-2.6.15-rc4-orig/drivers/isdn/hysdn/boardergo.c linux-2.6.15-rc4/drivers/isdn/hysdn/boardergo.c
--- linux-2.6.15-rc4-orig/drivers/isdn/hysdn/boardergo.c 2005-11-20 16:53:15.000000000 +0100
+++ linux-2.6.15-rc4/drivers/isdn/hysdn/boardergo.c 2005-12-03 16:53:10.000000000 +0100
@@ -329,14 +329,16 @@ static int
ergo_waitpofready(struct HYSDN_CARD *card)
{
tErgDpram *dpr = card->dpram; /* pointer to DPRAM structure */
- int timecnt = 10000 / 50; /* timeout is 10 secs max. */
+ unsigned long end_time;
ulong flags;
int msg_size;
int i;
if (card->debug_flags & LOG_POF_CARD)
hysdn_addlog(card, "ERGO: waiting for pof ready");
- while (timecnt--) {
+
+ end_time = jiffies + msecs_to_jiffies(10000); /* timeout is 10 secs max. */
+ while (time_before(jiffies, end_time)) {
/* wait until timeout */
if (dpr->ToPcFlag) {
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-12-04 0:18 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-12-04 0:18 [KJ] [PATCH 10/21] polling loops: change exit condition to Marcin Slusarz
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.