]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: ipset: use setup_timer() and mod_timer().
authorJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Thu, 10 Nov 2016 11:32:07 +0000 (12:32 +0100)
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Thu, 10 Nov 2016 12:28:49 +0000 (13:28 +0100)
commit14cdd61d38c6c102585b18e330448d165ddc2097
tree3847b2efdf25758fab18806570b16acdc7038ca8
parentdc9b646c03677aebbf8dd1756fdd93d838df5af2
netfilter: ipset: use setup_timer() and mod_timer().

Use setup_timer() and instead of init_timer(), being the preferred way
of setting up a timer.

Also, quoting the mod_timer() function comment:
-> mod_timer() is a more efficient way to update the expire field of an
   active timer (if the timer is inactive it will be activated).

Use setup_timer() and mod_timer() to setup and arm a timer, making the
code compact and easier to read.

Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com>
Signed-off-by: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
net/netfilter/ipset/ip_set_bitmap_gen.h
net/netfilter/ipset/ip_set_hash_gen.h
net/netfilter/ipset/ip_set_list_set.c