summaryrefslogtreecommitdiffstats
path: root/net/batman-adv/vis.c
diff options
context:
space:
mode:
authorMarek Lindner <lindner_marek@yahoo.de>2011-12-20 19:30:40 +0800
committerMarek Lindner <lindner_marek@yahoo.de>2012-02-17 02:50:20 +0800
commit032b7969f8874d5ddc65691cd3d008beffd2a09e (patch)
tree73a0e8bdd4dcf0f1dc3407b17df0424106027f9d /net/batman-adv/vis.c
parentea3d2fd1b11fb3ef8706a48ece0a49a61bcd08bc (diff)
downloadlinux-032b7969f8874d5ddc65691cd3d008beffd2a09e.tar.bz2
batman-adv: convert time_after instances to has_timed_out
To increase readability the has_timed_out() functions has been introduced. This patch converts existing time_after() calls to use this wrapper function (if applicable). This patch also converts all timeouts to miliseconds to be consistent. Signed-off-by: Marek Lindner <lindner_marek@yahoo.de> Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Diffstat (limited to 'net/batman-adv/vis.c')
-rw-r--r--net/batman-adv/vis.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/batman-adv/vis.c b/net/batman-adv/vis.c
index ac7e66100590..4f4b2a0c2d7b 100644
--- a/net/batman-adv/vis.c
+++ b/net/batman-adv/vis.c
@@ -714,8 +714,7 @@ static void purge_vis_packets(struct bat_priv *bat_priv)
if (info == bat_priv->my_vis_info)
continue;
- if (time_after(jiffies,
- info->first_seen + VIS_TIMEOUT * HZ)) {
+ if (has_timed_out(info->first_seen, VIS_TIMEOUT)) {
hlist_del(node);
send_list_del(info);
kref_put(&info->refcount, free_info);