[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20080318192242.GA6206@ens-lyon.fr>
Date: Tue, 18 Mar 2008 20:22:42 +0100
From: Benoit Boissinot <benoit.boissinot@...-lyon.org>
To: netdev@...r.kernel.org
Cc: yoshfuji@...ux-ipv6.org
Subject: Re: [PATCH] [IPv6] [trivial] convert to mod_timer
On Tue, Mar 18, 2008 at 01:42:35PM +0100, Benoit Boissinot wrote:
> Convert addrconf_verify to mod_timer
after some reflexion, this patch is probably wrong, since
addrconf_verify is called from outside the timer too.
sorry,
Benoit
>
> Signed-off-by: Benoit Boissinot <benoit.boissinot@...-lyon.org>
>
> diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
> index 101e0e7..5d0e404 100644
> --- a/net/ipv6/addrconf.c
> +++ b/net/ipv6/addrconf.c
> @@ -2922,8 +2943,6 @@ static void addrconf_verify(unsigned long foo)
> now = jiffies;
> next = now + ADDR_CHECK_FREQUENCY;
>
> - del_timer(&addr_chk_timer);
> -
> for (i=0; i < IN6_ADDR_HSIZE; i++) {
>
> restart:
> @@ -3013,8 +3032,7 @@ restart:
> read_unlock(&addrconf_hash_lock);
> }
>
> - addr_chk_timer.expires = time_before(next, jiffies + HZ) ? jiffies + HZ : next;
> - add_timer(&addr_chk_timer);
> + mod_timer(&addr_chk_timer, time_before(next, jiffies + HZ) ? jiffies + HZ : next);
> spin_unlock_bh(&addrconf_verify_lock);
> }
>
>
> --
> :wq
--
:wq
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists