lkml.org 
[lkml]   [1998]   [Nov]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: arca-1-against-pre-2.1.127-3


On Mon, 2 Nov 1998, Andrea Arcangeli wrote:

> I just put out a new arca-6 with a more high level (and fixed) approch to
> check if the timer is pending.
>
> Here the interesting part of the new patch. Tell me if you don' t like it:
> [...]
> +}
> +
> +extern inline int timer_pending(struct timer_list * timer)
> +{
> + return timer->prev || timer->next;
> }

The correct way to check if a timer is pending is to check timer->prev.
There is no reason to also check timer->next, so I suggest something like

extern inline int timer_pending(struct timer_list * timer)
{
return timer->prev != 0;
}
- Finn Arne


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:45    [from the cache]
©2003-2011 Jasper Spaans