forked from luck/tmp_suning_uos_patched
nl80211: trivial: Remove redundant loop
cfg80211_assign_cookie already checks & prevents a 0 from being returned, so the explicit loop is unnecessary. Signed-off-by: Denis Kenzior <denkenz@gmail.com> Link: https://lore.kernel.org/r/20191008164350.2836-1-denkenz@gmail.com Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
2ce113de31
commit
2fd351a877
|
@ -8227,10 +8227,8 @@ static int nl80211_start_sched_scan(struct sk_buff *skb,
|
|||
/* leave request id zero for legacy request
|
||||
* or if driver does not support multi-scheduled scan
|
||||
*/
|
||||
if (want_multi && rdev->wiphy.max_sched_scan_reqs > 1) {
|
||||
while (!sched_scan_req->reqid)
|
||||
sched_scan_req->reqid = cfg80211_assign_cookie(rdev);
|
||||
}
|
||||
if (want_multi && rdev->wiphy.max_sched_scan_reqs > 1)
|
||||
sched_scan_req->reqid = cfg80211_assign_cookie(rdev);
|
||||
|
||||
err = rdev_sched_scan_start(rdev, dev, sched_scan_req);
|
||||
if (err)
|
||||
|
|
Loading…
Reference in New Issue
Block a user