Lines Matching refs:ch_idx

332 static u32 iwl_get_channel_flags(u8 ch_num, int ch_idx, enum nl80211_band band,  in iwl_get_channel_flags()  argument
343 if ((ch_idx - NUM_2GHZ_CHANNELS) % 2 == 0) in iwl_get_channel_flags()
383 static enum nl80211_band iwl_nl80211_band_from_channel_idx(int ch_idx) in iwl_nl80211_band_from_channel_idx() argument
385 if (ch_idx >= NUM_2GHZ_CHANNELS + NUM_5GHZ_CHANNELS) { in iwl_nl80211_band_from_channel_idx()
389 if (ch_idx >= NUM_2GHZ_CHANNELS) in iwl_nl80211_band_from_channel_idx()
402 int ch_idx; in iwl_init_channel_map() local
420 for (ch_idx = 0; ch_idx < num_of_ch; ch_idx++) { in iwl_init_channel_map()
422 iwl_nl80211_band_from_channel_idx(ch_idx); in iwl_init_channel_map()
426 __le32_to_cpup((const __le32 *)nvm_ch_flags + ch_idx); in iwl_init_channel_map()
429 __le16_to_cpup((const __le16 *)nvm_ch_flags + ch_idx); in iwl_init_channel_map()
454 nvm_chan[ch_idx], ch_flags); in iwl_init_channel_map()
461 channel->hw_value = nvm_chan[ch_idx]; in iwl_init_channel_map()
477 channel->flags = iwl_get_channel_flags(nvm_chan[ch_idx], in iwl_init_channel_map()
478 ch_idx, band, in iwl_init_channel_map()
1611 int ch_idx, u16 nvm_flags, in iwl_nvm_get_regdom_bw_flags() argument
1617 if (ch_idx < NUM_2GHZ_CHANNELS && in iwl_nvm_get_regdom_bw_flags()
1619 if (nvm_chan[ch_idx] <= LAST_2GHZ_HT_PLUS) in iwl_nvm_get_regdom_bw_flags()
1621 if (nvm_chan[ch_idx] >= FIRST_2GHZ_HT_MINUS) in iwl_nvm_get_regdom_bw_flags()
1623 } else if (ch_idx < NUM_2GHZ_CHANNELS + NUM_5GHZ_CHANNELS && in iwl_nvm_get_regdom_bw_flags()
1625 if ((ch_idx - NUM_2GHZ_CHANNELS) % 2 == 0) in iwl_nvm_get_regdom_bw_flags()
1675 if (ch_idx >= NUM_2GHZ_CHANNELS) { in iwl_nvm_get_regdom_bw_flags()
1728 int ch_idx; in iwl_parse_nvm_mcc_info() local
1776 for (ch_idx = 0; ch_idx < num_of_ch; ch_idx++) { in iwl_parse_nvm_mcc_info()
1778 iwl_nl80211_band_from_channel_idx(ch_idx); in iwl_parse_nvm_mcc_info()
1780 ch_flags = (u16)__le32_to_cpup(channels + ch_idx); in iwl_parse_nvm_mcc_info()
1781 center_freq = ieee80211_channel_to_frequency(nvm_chan[ch_idx], in iwl_parse_nvm_mcc_info()
1787 nvm_chan[ch_idx], ch_flags); in iwl_parse_nvm_mcc_info()
1791 reg_rule_flags = iwl_nvm_get_regdom_bw_flags(nvm_chan, ch_idx, in iwl_parse_nvm_mcc_info()
1796 if (ch_idx == 0 || prev_reg_rule_flags != reg_rule_flags || in iwl_parse_nvm_mcc_info()
1825 nvm_chan[ch_idx], ch_flags); in iwl_parse_nvm_mcc_info()