diff options
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-eeprom.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-eeprom.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-eeprom.c b/drivers/net/wireless/iwlwifi/iwl-eeprom.c index 47a56bc1cd12..768d0ee276f7 100644 --- a/drivers/net/wireless/iwlwifi/iwl-eeprom.c +++ b/drivers/net/wireless/iwlwifi/iwl-eeprom.c | |||
@@ -834,3 +834,28 @@ const struct iwl_channel_info *iwl_get_channel_info(const struct iwl_priv *priv, | |||
834 | 834 | ||
835 | return NULL; | 835 | return NULL; |
836 | } | 836 | } |
837 | |||
838 | void iwl_rf_config(struct iwl_priv *priv) | ||
839 | { | ||
840 | u16 radio_cfg; | ||
841 | |||
842 | radio_cfg = iwl_eeprom_query16(priv, EEPROM_RADIO_CONFIG); | ||
843 | |||
844 | /* write radio config values to register */ | ||
845 | if (EEPROM_RF_CFG_TYPE_MSK(radio_cfg) <= EEPROM_RF_CONFIG_TYPE_MAX) { | ||
846 | iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG, | ||
847 | EEPROM_RF_CFG_TYPE_MSK(radio_cfg) | | ||
848 | EEPROM_RF_CFG_STEP_MSK(radio_cfg) | | ||
849 | EEPROM_RF_CFG_DASH_MSK(radio_cfg)); | ||
850 | IWL_INFO(priv, "Radio type=0x%x-0x%x-0x%x\n", | ||
851 | EEPROM_RF_CFG_TYPE_MSK(radio_cfg), | ||
852 | EEPROM_RF_CFG_STEP_MSK(radio_cfg), | ||
853 | EEPROM_RF_CFG_DASH_MSK(radio_cfg)); | ||
854 | } else | ||
855 | WARN_ON(1); | ||
856 | |||
857 | /* set CSR_HW_CONFIG_REG for uCode use */ | ||
858 | iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG, | ||
859 | CSR_HW_IF_CONFIG_REG_BIT_RADIO_SI | | ||
860 | CSR_HW_IF_CONFIG_REG_BIT_MAC_SI); | ||
861 | } | ||