diff options
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-7000.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-8000.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-hw.h | 4 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-config.h | 5 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/mvm/nvm.c | 1 |
5 files changed, 8 insertions, 6 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-7000.c b/drivers/net/wireless/iwlwifi/iwl-7000.c index f73de239cdc1..48730064da73 100644 --- a/drivers/net/wireless/iwlwifi/iwl-7000.c +++ b/drivers/net/wireless/iwlwifi/iwl-7000.c | |||
@@ -98,7 +98,7 @@ | |||
98 | #define NVM_HW_SECTION_NUM_FAMILY_7000 0 | 98 | #define NVM_HW_SECTION_NUM_FAMILY_7000 0 |
99 | 99 | ||
100 | static const struct iwl_base_params iwl7000_base_params = { | 100 | static const struct iwl_base_params iwl7000_base_params = { |
101 | .eeprom_size = OTP_LOW_IMAGE_SIZE, | 101 | .eeprom_size = OTP_LOW_IMAGE_SIZE_FAMILY_7000, |
102 | .num_of_queues = IWLAGN_NUM_QUEUES, | 102 | .num_of_queues = IWLAGN_NUM_QUEUES, |
103 | .pll_cfg_val = 0, | 103 | .pll_cfg_val = 0, |
104 | .shadow_ram_support = true, | 104 | .shadow_ram_support = true, |
diff --git a/drivers/net/wireless/iwlwifi/iwl-8000.c b/drivers/net/wireless/iwlwifi/iwl-8000.c index f5bd82b88592..b26b68ce8205 100644 --- a/drivers/net/wireless/iwlwifi/iwl-8000.c +++ b/drivers/net/wireless/iwlwifi/iwl-8000.c | |||
@@ -85,7 +85,7 @@ | |||
85 | #define NVM_HW_SECTION_NUM_FAMILY_8000 10 | 85 | #define NVM_HW_SECTION_NUM_FAMILY_8000 10 |
86 | 86 | ||
87 | static const struct iwl_base_params iwl8000_base_params = { | 87 | static const struct iwl_base_params iwl8000_base_params = { |
88 | .eeprom_size = OTP_LOW_IMAGE_SIZE, | 88 | .eeprom_size = OTP_LOW_IMAGE_SIZE_FAMILY_8000, |
89 | .num_of_queues = IWLAGN_NUM_QUEUES, | 89 | .num_of_queues = IWLAGN_NUM_QUEUES, |
90 | .pll_cfg_val = 0, | 90 | .pll_cfg_val = 0, |
91 | .shadow_ram_support = true, | 91 | .shadow_ram_support = true, |
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-hw.h b/drivers/net/wireless/iwlwifi/iwl-agn-hw.h index 7f37fb86837b..04a483d38659 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-hw.h +++ b/drivers/net/wireless/iwlwifi/iwl-agn-hw.h | |||
@@ -102,9 +102,7 @@ | |||
102 | 102 | ||
103 | /* EEPROM */ | 103 | /* EEPROM */ |
104 | #define IWLAGN_EEPROM_IMG_SIZE 2048 | 104 | #define IWLAGN_EEPROM_IMG_SIZE 2048 |
105 | /* OTP */ | 105 | |
106 | /* lower blocks contain EEPROM image and calibration data */ | ||
107 | #define OTP_LOW_IMAGE_SIZE (2 * 512 * sizeof(u16)) /* 2 KB */ | ||
108 | /* high blocks contain PAPD data */ | 106 | /* high blocks contain PAPD data */ |
109 | #define OTP_HIGH_IMAGE_SIZE_6x00 (6 * 512 * sizeof(u16)) /* 6 KB */ | 107 | #define OTP_HIGH_IMAGE_SIZE_6x00 (6 * 512 * sizeof(u16)) /* 6 KB */ |
110 | #define OTP_HIGH_IMAGE_SIZE_1000 (0x200 * sizeof(u16)) /* 1024 bytes */ | 108 | #define OTP_HIGH_IMAGE_SIZE_1000 (0x200 * sizeof(u16)) /* 1024 bytes */ |
diff --git a/drivers/net/wireless/iwlwifi/iwl-config.h b/drivers/net/wireless/iwlwifi/iwl-config.h index 7ce82d9c7222..b73eac9428a7 100644 --- a/drivers/net/wireless/iwlwifi/iwl-config.h +++ b/drivers/net/wireless/iwlwifi/iwl-config.h | |||
@@ -193,6 +193,11 @@ struct iwl_ht_params { | |||
193 | #define EEPROM_6000_REG_BAND_24_HT40_CHANNELS 0x80 | 193 | #define EEPROM_6000_REG_BAND_24_HT40_CHANNELS 0x80 |
194 | #define EEPROM_REGULATORY_BAND_NO_HT40 0 | 194 | #define EEPROM_REGULATORY_BAND_NO_HT40 0 |
195 | 195 | ||
196 | /* lower blocks contain EEPROM image and calibration data */ | ||
197 | #define OTP_LOW_IMAGE_SIZE (2 * 512 * sizeof(u16)) /* 2 KB */ | ||
198 | #define OTP_LOW_IMAGE_SIZE_FAMILY_7000 (4 * 512 * sizeof(u16)) /* 4 KB */ | ||
199 | #define OTP_LOW_IMAGE_SIZE_FAMILY_8000 (32 * 512 * sizeof(u16)) /* 32 KB */ | ||
200 | |||
196 | struct iwl_eeprom_params { | 201 | struct iwl_eeprom_params { |
197 | const u8 regulatory_bands[7]; | 202 | const u8 regulatory_bands[7]; |
198 | bool enhanced_txpower; | 203 | bool enhanced_txpower; |
diff --git a/drivers/net/wireless/iwlwifi/mvm/nvm.c b/drivers/net/wireless/iwlwifi/mvm/nvm.c index cf2d09f53782..4092422cb849 100644 --- a/drivers/net/wireless/iwlwifi/mvm/nvm.c +++ b/drivers/net/wireless/iwlwifi/mvm/nvm.c | |||
@@ -463,7 +463,6 @@ int iwl_nvm_init(struct iwl_mvm *mvm) | |||
463 | /* Read From FW NVM */ | 463 | /* Read From FW NVM */ |
464 | IWL_DEBUG_EEPROM(mvm->trans->dev, "Read from NVM\n"); | 464 | IWL_DEBUG_EEPROM(mvm->trans->dev, "Read from NVM\n"); |
465 | 465 | ||
466 | /* TODO: find correct NVM max size for a section */ | ||
467 | nvm_buffer = kmalloc(mvm->cfg->base_params->eeprom_size, | 466 | nvm_buffer = kmalloc(mvm->cfg->base_params->eeprom_size, |
468 | GFP_KERNEL); | 467 | GFP_KERNEL); |
469 | if (!nvm_buffer) | 468 | if (!nvm_buffer) |