Re: arca-1-against-pre-2.1.127-3

Finn Arne Gangstad (finnag@guardian.no)
Mon, 2 Nov 1998 10:04:34 +0100 (MET)


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/