Path: blob/master/drivers/net/wireless/realtek/rtw88/regd.h
25924 views
/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */1/* Copyright(c) 2018-2019 Realtek Corporation2*/34#ifndef __RTW_REGD_H_5#define __RTW_REGD_H_67#define IEEE80211_CHAN_NO_IBSS IEEE80211_CHAN_NO_IR8#define IEEE80211_CHAN_PASSIVE_SCAN IEEE80211_CHAN_NO_IR9enum rtw_chplan_id {10RTW_CHPLAN_ETSI1_NULL = 0x21,11RTW_CHPLAN_WORLD_ETSI1 = 0x26,12RTW_CHPLAN_MKK1_MKK1 = 0x27,13RTW_CHPLAN_IC1_IC2 = 0x2B,14RTW_CHPLAN_WORLD_CHILE1 = 0x2D,15RTW_CHPLAN_WORLD_FCC3 = 0x30,16RTW_CHPLAN_WORLD_FCC5 = 0x32,17RTW_CHPLAN_FCC1_FCC7 = 0x34,18RTW_CHPLAN_WORLD_ETSI2 = 0x35,19RTW_CHPLAN_WORLD_ETSI3 = 0x36,20RTW_CHPLAN_ETSI1_ETSI12 = 0x3D,21RTW_CHPLAN_KCC1_KCC2 = 0x3E,22RTW_CHPLAN_ETSI1_ETSI4 = 0x42,23RTW_CHPLAN_FCC1_NCC3 = 0x44,24RTW_CHPLAN_WORLD_ACMA1 = 0x45,25RTW_CHPLAN_WORLD_ETSI6 = 0x47,26RTW_CHPLAN_WORLD_ETSI7 = 0x48,27RTW_CHPLAN_WORLD_ETSI8 = 0x49,28RTW_CHPLAN_KCC1_KCC3 = 0x4B,29RTW_CHPLAN_WORLD_ETSI10 = 0x51,30RTW_CHPLAN_WORLD_ETSI14 = 0x59,31RTW_CHPLAN_FCC2_FCC7 = 0x61,32RTW_CHPLAN_FCC2_FCC1 = 0x62,33RTW_CHPLAN_WORLD_ETSI15 = 0x63,34RTW_CHPLAN_WORLD_FCC7 = 0x73,35RTW_CHPLAN_FCC2_FCC17 = 0x74,36RTW_CHPLAN_WORLD_ETSI20 = 0x75,37RTW_CHPLAN_FCC2_FCC11 = 0x76,38RTW_CHPLAN_REALTEK_DEFINE = 0x7f,39};4041struct country_code_to_enum_rd {42u16 countrycode;43const char *iso_name;44};4546enum country_code_type {47COUNTRY_CODE_FCC = 0,48COUNTRY_CODE_IC = 1,49COUNTRY_CODE_ETSI = 2,50COUNTRY_CODE_SPAIN = 3,51COUNTRY_CODE_FRANCE = 4,52COUNTRY_CODE_MKK = 5,53COUNTRY_CODE_MKK1 = 6,54COUNTRY_CODE_ISRAEL = 7,55COUNTRY_CODE_TELEC = 8,56COUNTRY_CODE_MIC = 9,57COUNTRY_CODE_GLOBAL_DOMAIN = 10,58COUNTRY_CODE_WORLD_WIDE_13 = 11,59COUNTRY_CODE_TELEC_NETGEAR = 12,60COUNTRY_CODE_WORLD_WIDE_13_5G_ALL = 13,6162/* new channel plan above this */63COUNTRY_CODE_MAX64};6566int rtw_regd_init(struct rtw_dev *rtwdev);67int rtw_regd_hint(struct rtw_dev *rtwdev);68u8 rtw_regd_get(struct rtw_dev *rtwdev);69bool rtw_regd_has_alt(u8 regd, u8 *regd_alt);70bool rtw_regd_srrc(struct rtw_dev *rtwdev);7172#endif737475