summaryrefslogtreecommitdiff
path: root/net/wireless
diff options
context:
space:
mode:
authorzhong jiang <zhongjiang@huawei.com>2018-09-08 19:21:28 +0800
committerJohannes Berg <johannes.berg@intel.com>2018-10-02 09:56:29 +0200
commitd25d062f55c6dc1a0d82dbebadf99924751a41b2 (patch)
treee3d6ef73f36acd8e447f2996a0d29cc4c19ba4cc /net/wireless
parent024926def6ca95819442699fbecc1fe376253fb9 (diff)
cfg80211: remove unnecessary null pointer check in cfg80211_netdev_notifier_call
The iterator in list_for_each_entry_safe is never null, therefore, remove the redundant null pointer check. Signed-off-by: zhong jiang <zhongjiang@huawei.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless')
-rw-r--r--net/wireless/core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/wireless/core.c b/net/wireless/core.c
index a88551f3bc43..4d5215e6b534 100644
--- a/net/wireless/core.c
+++ b/net/wireless/core.c
@@ -1238,7 +1238,7 @@ static int cfg80211_netdev_notifier_call(struct notifier_block *nb,
list_for_each_entry_safe(pos, tmp,
&rdev->sched_scan_req_list, list) {
- if (WARN_ON(pos && pos->dev == wdev->netdev))
+ if (WARN_ON(pos->dev == wdev->netdev))
cfg80211_stop_sched_scan_req(rdev, pos, false);
}