xref: /freebsd/sys/contrib/dev/athk/ath11k/reg.h (revision 28348caeee6ee98251b0aaa026e8d52b5032e92c)
1dd4f32aeSBjoern A. Zeeb /* SPDX-License-Identifier: BSD-3-Clause-Clear */
2dd4f32aeSBjoern A. Zeeb /*
3dd4f32aeSBjoern A. Zeeb  * Copyright (c) 2019 The Linux Foundation. All rights reserved.
4dd4f32aeSBjoern A. Zeeb  */
5dd4f32aeSBjoern A. Zeeb 
6dd4f32aeSBjoern A. Zeeb #ifndef ATH11K_REG_H
7dd4f32aeSBjoern A. Zeeb #define ATH11K_REG_H
8dd4f32aeSBjoern A. Zeeb 
9dd4f32aeSBjoern A. Zeeb #include <linux/kernel.h>
10dd4f32aeSBjoern A. Zeeb #include <net/regulatory.h>
11dd4f32aeSBjoern A. Zeeb 
12dd4f32aeSBjoern A. Zeeb struct ath11k_base;
13dd4f32aeSBjoern A. Zeeb struct ath11k;
14dd4f32aeSBjoern A. Zeeb 
15dd4f32aeSBjoern A. Zeeb /* DFS regdomains supported by Firmware */
16dd4f32aeSBjoern A. Zeeb enum ath11k_dfs_region {
17dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_UNSET,
18dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_FCC,
19dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_ETSI,
20dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_MKK,
21dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_CN,
22dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_KR,
23dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_MKK_N,
24dd4f32aeSBjoern A. Zeeb 	ATH11K_DFS_REG_UNDEF,
25dd4f32aeSBjoern A. Zeeb };
26dd4f32aeSBjoern A. Zeeb 
27dd4f32aeSBjoern A. Zeeb /* ATH11K Regulatory API's */
28dd4f32aeSBjoern A. Zeeb void ath11k_reg_init(struct ath11k *ar);
29dd4f32aeSBjoern A. Zeeb void ath11k_reg_free(struct ath11k_base *ab);
30dd4f32aeSBjoern A. Zeeb void ath11k_regd_update_work(struct work_struct *work);
31dd4f32aeSBjoern A. Zeeb struct ieee80211_regdomain *
32dd4f32aeSBjoern A. Zeeb ath11k_reg_build_regd(struct ath11k_base *ab,
33dd4f32aeSBjoern A. Zeeb 		      struct cur_regulatory_info *reg_info, bool intersect);
34dd4f32aeSBjoern A. Zeeb int ath11k_regd_update(struct ath11k *ar);
35*28348caeSBjoern A. Zeeb int ath11k_reg_update_chan_list(struct ath11k *ar, bool wait);
36dd4f32aeSBjoern A. Zeeb #endif
37