Commit ee74d996 authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller

tun: do not arm flow_gc_timer in tun_flow_init()

Timer is properly armed on demand from tun_flow_update(),
so there is no need to arm it at tun init.
Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 81d98fa4
...@@ -1197,8 +1197,6 @@ static void tun_flow_init(struct tun_struct *tun) ...@@ -1197,8 +1197,6 @@ static void tun_flow_init(struct tun_struct *tun)
tun->ageing_time = TUN_FLOW_EXPIRE; tun->ageing_time = TUN_FLOW_EXPIRE;
setup_timer(&tun->flow_gc_timer, tun_flow_cleanup, (unsigned long)tun); setup_timer(&tun->flow_gc_timer, tun_flow_cleanup, (unsigned long)tun);
mod_timer(&tun->flow_gc_timer,
round_jiffies_up(jiffies + tun->ageing_time));
} }
static void tun_flow_uninit(struct tun_struct *tun) static void tun_flow_uninit(struct tun_struct *tun)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment