cfg80211: use list_move_tail instead of list_del/list_add_tail
Using list_move_tail() instead of list_del() + list_add_tail(). Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
committed by
Johannes Berg
parent
0ef24e528f
commit
00a9ac4c01
@ -1932,8 +1932,7 @@ static void restore_regulatory_settings(bool reset_user)
|
|||||||
if (reg_request->initiator !=
|
if (reg_request->initiator !=
|
||||||
NL80211_REGDOM_SET_BY_USER)
|
NL80211_REGDOM_SET_BY_USER)
|
||||||
continue;
|
continue;
|
||||||
list_del(®_request->list);
|
list_move_tail(®_request->list, &tmp_reg_req_list);
|
||||||
list_add_tail(®_request->list, &tmp_reg_req_list);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
spin_unlock(®_requests_lock);
|
spin_unlock(®_requests_lock);
|
||||||
@ -1992,8 +1991,7 @@ static void restore_regulatory_settings(bool reset_user)
|
|||||||
"into the queue\n",
|
"into the queue\n",
|
||||||
reg_request->alpha2[0],
|
reg_request->alpha2[0],
|
||||||
reg_request->alpha2[1]);
|
reg_request->alpha2[1]);
|
||||||
list_del(®_request->list);
|
list_move_tail(®_request->list, ®_requests_list);
|
||||||
list_add_tail(®_request->list, ®_requests_list);
|
|
||||||
}
|
}
|
||||||
spin_unlock(®_requests_lock);
|
spin_unlock(®_requests_lock);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user