From: Michal Kazior Date: Thu, 17 Oct 2013 18:21:11 +0000 (-0700) Subject: cfg80211: fix DFS channel recovery timeout X-Git-Tag: firefly_0821_release~176^2~4570^2~3^2^2~308^2~1 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=c532a58b0fb4b2b3309e6b87bafb44f36808aa6f;p=firefly-linux-kernel-4.4.55.git cfg80211: fix DFS channel recovery timeout The timeout was not properly converted from msecs to jiffies. As a result channel transition to NL80211_DFS_USABLE was delayed depending on CONFIG_HZ configuration, e.g. HZ=100 would delay the NOP from 30 minutes to 300 minutes. Signed-off-by: Michal Kazior Signed-off-by: Johannes Berg --- diff --git a/net/wireless/mlme.c b/net/wireless/mlme.c index 8d49c1ce3dea..edfe6de00e7b 100644 --- a/net/wireless/mlme.c +++ b/net/wireless/mlme.c @@ -707,8 +707,8 @@ void cfg80211_dfs_channels_update_work(struct work_struct *work) if (c->dfs_state != NL80211_DFS_UNAVAILABLE) continue; - timeout = c->dfs_state_entered + - IEEE80211_DFS_MIN_NOP_TIME_MS; + timeout = c->dfs_state_entered + msecs_to_jiffies( + IEEE80211_DFS_MIN_NOP_TIME_MS); if (time_after_eq(jiffies, timeout)) { c->dfs_state = NL80211_DFS_USABLE;