1 /* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
2  * Copyright(c) 2019-2020  Realtek Corporation
3  */
4 #ifndef __RTW89_UTIL_H__
5 #define __RTW89_UTIL_H__
6 
7 #include "core.h"
8 
9 #define rtw89_iterate_vifs_bh(rtwdev, iterator, data)                          \
10 	ieee80211_iterate_active_interfaces_atomic((rtwdev)->hw,               \
11 			IEEE80211_IFACE_ITER_NORMAL, iterator, data)
12 
13 /* call this function with rtwdev->mutex is held */
14 #define rtw89_for_each_rtwvif(rtwdev, rtwvif)				       \
15 	list_for_each_entry(rtwvif, &(rtwdev)->rtwvifs_list, list)
16 
17 #endif
18