Making Intel WiFi Link 1000 usable in 2.6.31
Hi,
A few distributions would like to enable the new 1000 series Intel wireless hardware (Intel WiFi Link 1000BGN) in their next releases that are based on 2.6.31. This hardware is not usable in 2.6.31, but it can be enabled in this kernel with the addition of five patches.
Until now we have been providing the distributions with this list of patches to do their own backporting.
Since this seems to be a general problem for distributions and users alike, is it possible to consider these enabling patches for inclusion into 2.6.31?
Here is the list:
commit cc0f555d511a5fe9d4519334c8f674a1dbab9e3a
Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:16 2009 -0700
iwlwifi: Handle new firmware file with ucode build number in header
commit cce53aa347c1e023d967b1cb1aa393c725aedba5
Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:22 2009 -0700
iwlwifi: update 1000 series API version to match firmware
commit 02c06e4abc0680afd31bf481a803541556757fb6
Author: Wey-Yi Guy <[email protected]> Date: Fri Jul 17 09:30:14 2009 -0700
iwlagn: modify digital SVR for 1000
commit 415e49936b4b29b34c2fb561eeab867d41fc43a6
Author: Wey-Yi Guy <[email protected]> Date: Thu Aug 13 13:30:54 2009 -0700
iwlwifi: traverse linklist to find the valid OTP block
commit f7ea097d9b4e61a816c041c92548aad7c7ed7915
Author: Reinette Chatre <[email protected]> Date: Fri Jul 24 11:13:12 2009 -0700
iwlagn: fix null pointer access during ucode load on 1000
Thank you very much
Reinette
Quoted 40 lines · reinette chatre
Hi,
A few distributions would like to enable the new 1000 series Intel wireless hardware (Intel WiFi Link 1000BGN) in their next releases that are based on 2.6.31. This hardware is not usable in 2.6.31, but it can be enabled in this kernel with the addition of five patches.
Until now we have been providing the distributions with this list of patches to do their own backporting.
Since this seems to be a general problem for distributions and users alike, is it possible to consider these enabling patches for inclusion into 2.6.31?
Here is the list:
commit
cc0f555d511a5fe9d4519334c8f674a1dbab9e3aAuthor: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:16 2009 -0700iwlwifi: Handle new firmware file with ucode build number in header
commit
cce53aa347c1e023d967b1cb1aa393c725aedba5Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:22 2009 -0700iwlwifi: update 1000 series API version to match firmware
commit
02c06e4abc0680afd31bf481a803541556757fb6Author: Wey-Yi Guy <[email protected]> Date: Fri Jul 17 09:30:14 2009 -0700iwlagn: modify digital SVR for 1000
commit
415e49936b4b29b34c2fb561eeab867d41fc43a6Author: Wey-Yi Guy <[email protected]> Date: Thu Aug 13 13:30:54 2009 -0700iwlwifi: traverse linklist to find the valid OTP block
Quoted 7 lines
commit
f7ea097d9b4e61a816c041c92548aad7c7ed7915Author: Reinette Chatre <[email protected]> Date: Fri Jul 24 11:13:12 2009 -0700iwlagn: fix null pointer access during ucode load on 1000
Thank you very much
Is this the order in which they should be applied?
thanks,
greg k-h
Quoted 30 lines · Greg KH
Quoted 29 lines · reinette chatre
commit
cc0f555d511a5fe9d4519334c8f674a1dbab9e3aAuthor: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:16 2009 -0700iwlwifi: Handle new firmware file with ucode build number in header
commit
cce53aa347c1e023d967b1cb1aa393c725aedba5Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:22 2009 -0700iwlwifi: update 1000 series API version to match firmware
commit
02c06e4abc0680afd31bf481a803541556757fb6Author: Wey-Yi Guy <[email protected]> Date: Fri Jul 17 09:30:14 2009 -0700iwlagn: modify digital SVR for 1000
commit
415e49936b4b29b34c2fb561eeab867d41fc43a6Author: Wey-Yi Guy <[email protected]> Date: Thu Aug 13 13:30:54 2009 -0700iwlwifi: traverse linklist to find the valid OTP block
commit
f7ea097d9b4e61a816c041c92548aad7c7ed7915Author: Reinette Chatre <[email protected]> Date: Fri Jul 24 11:13:12 2009 -0700
Quoted 5 lines
Quoted 3 lines
iwlagn: fix null pointer access during ucode load on 1000
Thank you very much
Is this the order in which they should be applied?
This is the correct order, but the last two patches need to be ported to 2.6.31. I will send out new versions.
Reinette
Quoted 29 lines · Greg KH
Quoted 28 lines · reinette chatre
commit
cc0f555d511a5fe9d4519334c8f674a1dbab9e3aAuthor: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:16 2009 -0700iwlwifi: Handle new firmware file with ucode build number in header
commit
cce53aa347c1e023d967b1cb1aa393c725aedba5Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:22 2009 -0700iwlwifi: update 1000 series API version to match firmware
commit
02c06e4abc0680afd31bf481a803541556757fb6Author: Wey-Yi Guy <[email protected]> Date: Fri Jul 17 09:30:14 2009 -0700iwlagn: modify digital SVR for 1000
commit
415e49936b4b29b34c2fb561eeab867d41fc43a6Author: Wey-Yi Guy <[email protected]> Date: Thu Aug 13 13:30:54 2009 -0700iwlwifi: traverse linklist to find the valid OTP block
commit
f7ea097d9b4e61a816c041c92548aad7c7ed7915Author: Reinette Chatre <[email protected]> Date: Fri Jul 24 11:13:12 2009 -0700
Quoted 5 lines
Quoted 3 lines
iwlagn: fix null pointer access during ucode load on 1000
Thank you very much
Is this the order in which they should be applied?
The first three patches from this list can be applied directly from linux-2.6 in the order they appear here. That is:
commit cc0f555d511a5fe9d4519334c8f674a1dbab9e3a
Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:16 2009 -0700
iwlwifi: Handle new firmware file with ucode build number in header
commit cce53aa347c1e023d967b1cb1aa393c725aedba5
Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:22 2009 -0700
iwlwifi: update 1000 series API version to match firmware
commit 02c06e4abc0680afd31bf481a803541556757fb6
Author: Wey-Yi Guy <[email protected]> Date: Fri Jul 17 09:30:14 2009 -0700
iwlagn: modify digital SVR for 1000
The fourth patch needed backporting and is attached.
After doing the backporting I determined that the fifth patch is not needed.
Thank you very much for taking these patches
Reinette
Quoted 1 line
From
07c88863a94534f36668ed543555e020c949990eMon Sep 17 00:00:00 2001
From: Wey-Yi Guy <[email protected]>
Date: Thu, 13 Aug 2009 13:30:54 -0700
Subject: [PATCH] iwlwifi: traverse linklist to find the valid OTP block
For devices using OTP memory, EEPROM image can start from any one of the OTP blocks. If shadow RAM is disabled, we need to traverse link list to find the last valid block, then start the EEPROM image reading.
If OTP is not full, the valid block is the block _before_ the last block on the link list; the last block on the link list is the empty block ready for next OTP refresh/update.
If OTP is full, then the last block is the valid block to be used for configure the device.
--- drivers/net/wireless/iwlwifi/iwl-1000.c | 4 +- drivers/net/wireless/iwlwifi/iwl-6000.c | 20 +++- drivers/net/wireless/iwlwifi/iwl-core.h | 4 + drivers/net/wireless/iwlwifi/iwl-dev.h | 12 ++ drivers/net/wireless/iwlwifi/iwl-eeprom.c | 185 +++++++++++++++++++++++------ drivers/net/wireless/iwlwifi/iwl-eeprom.h | 10 ++- 6 files changed, 192 insertions(+), 43 deletions(-)
drivers/net/wireless/iwlwifi/iwl-1000.c +3 -1
@@ -62,12 +62,14 @@ struct iwl_cfg iwl1000_bgn_cfg = { .ucode_api_min = IWL1000_UCODE_API_MIN, .sku = IWL_SKU_G|IWL_SKU_N, .ops = &iwl5000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_A, .valid_rx_ant = ANT_AB, .need_pll_cfg = true, + .max_ll_items = OTP_MAX_LL_ITEMS_1000, + .shadow_ram_support = false, };
drivers/net/wireless/iwlwifi/iwl-6000.c +15 -5
@@ -82,13 +82,15 @@ struct iwl_cfg iwl6000_2ag_cfg = { .ucode_api_min = IWL6000_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_BC, .valid_rx_ant = ANT_BC, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6000_2agn_cfg = {
@@ -98,13 +100,15 @@ struct iwl_cfg iwl6000_2agn_cfg = { .ucode_api_min = IWL6000_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_AB, .valid_rx_ant = ANT_AB, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6050_2agn_cfg = {
@@ -114,13 +118,15 @@ struct iwl_cfg iwl6050_2agn_cfg = { .ucode_api_min = IWL6050_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_AB, .valid_rx_ant = ANT_AB, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6000_3agn_cfg = {
@@ -130,13 +136,15 @@ struct iwl_cfg iwl6000_3agn_cfg = { .ucode_api_min = IWL6000_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_ABC, .valid_rx_ant = ANT_ABC, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6050_3agn_cfg = {
@@ -146,13 +154,15 @@ struct iwl_cfg iwl6050_3agn_cfg = { .ucode_api_min = IWL6050_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_ABC, .valid_rx_ant = ANT_ABC, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };MODULE_FIRMWARE (IWL6000_MODULE_FIRMWARE (IWL6000_UCODE_API_MAX ));
drivers/net/wireless/iwlwifi/iwl-core.h +4 -0
@@ -207,6 +207,8 @@ struct iwl_mod_params {* filename is constructed as fw_name_pre<api>.ucode. * @ucode_api_max: Highest version of uCode API supported by driver. * @ucode_api_min: Lowest version of uCode API supported by driver. +* @max_ll_items: max number of OTP blocks +* @shadow_ram_support: shadow support for OTP memory * * We enable the driver to be backward compatible wrt API version. The * driver specifies which APIs it supports (with @ucode_api_max being the
@@ -243,6 +245,8 @@ struct iwl_cfg {u8 valid_rx_ant;bool need_pll_cfg;bool use_isr_legacy; +const u16 max_ll_items; +const bool shadow_ram_support; };/***************************
drivers/net/wireless/iwlwifi/iwl-dev.h +12 -0
@@ -835,6 +835,18 @@ enum iwl_nvm_type { NVM_DEVICE_TYPE_OTP, }; +/* +* Two types of OTP memory access modes +* IWL_OTP_ACCESS_ABSOLUTE - absolute address mode, +* based on physical memory addressing +* IWL_OTP_ACCESS_RELATIVE - relative address mode, +* based on logical memory addressing +*/ +enum iwl_access_mode { +IWL_OTP_ACCESS_ABSOLUTE , +IWL_OTP_ACCESS_RELATIVE , +}; +/* interrupt statistics */ struct isr_statistics {u32 hw;
drivers/net/wireless/iwlwifi/iwl-eeprom.c +150 -35
222 lines not on this page · raw message
drivers/net/wireless/iwlwifi/iwl-eeprom.h +8 -2
@@ -180,8 +180,14 @@ struct iwl_eeprom_channel {#define EEPROM_5050_EEPROM_VERSION (0x21E)/* OTP */ -#define OTP_LOWER_BLOCKS_TOTAL (3) -#define OTP_BLOCK_SIZE (0x400) +/* lower blocks contain EEPROM image and calibration data */ +#define OTP_LOW_IMAGE_SIZE (2 * 512 * sizeof(u16))/* 2 KB */ +/* high blocks contain PAPD data */ +#define OTP_HIGH_IMAGE_SIZE_6x00 (6 * 512 * sizeof(u16))/* 6 KB */ +#define OTP_HIGH_IMAGE_SIZE_1000 (0x200 * sizeof(u16))/* 1024 bytes */ +#define OTP_MAX_LL_ITEMS_1000 (3)/* OTP blocks for 1000 */ +#define OTP_MAX_LL_ITEMS_6x00 (4)/* OTP blocks for 6x00 */ +#define OTP_MAX_LL_ITEMS_6x50 (7)/* OTP blocks for 6x50 */ /* 2.4 GHz */ extern const u8 iwl_eeprom_band_1[14 ];
Signature · 1 line
1.5.6.3
Quoted 58 lines · reinette chatre
Quoted 29 lines · Greg KH
Quoted 28 lines · reinette chatre
commit
cc0f555d511a5fe9d4519334c8f674a1dbab9e3aAuthor: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:16 2009 -0700iwlwifi: Handle new firmware file with ucode build number in header
commit
cce53aa347c1e023d967b1cb1aa393c725aedba5Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:22 2009 -0700iwlwifi: update 1000 series API version to match firmware
commit
02c06e4abc0680afd31bf481a803541556757fb6Author: Wey-Yi Guy <[email protected]> Date: Fri Jul 17 09:30:14 2009 -0700iwlagn: modify digital SVR for 1000
commit
415e49936b4b29b34c2fb561eeab867d41fc43a6Author: Wey-Yi Guy <[email protected]> Date: Thu Aug 13 13:30:54 2009 -0700iwlwifi: traverse linklist to find the valid OTP block
commit
f7ea097d9b4e61a816c041c92548aad7c7ed7915Author: Reinette Chatre <[email protected]> Date: Fri Jul 24 11:13:12 2009 -0700Quoted 5 lines
Quoted 3 lines
iwlagn: fix null pointer access during ucode load on 1000
Thank you very much
Is this the order in which they should be applied?
The first three patches from this list can be applied directly from linux-2.6 in the order they appear here. That is:
commit
cc0f555d511a5fe9d4519334c8f674a1dbab9e3aAuthor: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:16 2009 -0700iwlwifi: Handle new firmware file with ucode build number in header
commit
cce53aa347c1e023d967b1cb1aa393c725aedba5Author: Jay Sternberg <[email protected]> Date: Fri Jul 17 09:30:22 2009 -0700iwlwifi: update 1000 series API version to match firmware
commit
02c06e4abc0680afd31bf481a803541556757fb6Author: Wey-Yi Guy <[email protected]> Date: Fri Jul 17 09:30:14 2009 -0700iwlagn: modify digital SVR for 1000
Quoted 6 lines
The fourth patch needed backporting and is attached.
After doing the backporting I determined that the fifth patch is not needed.
Thank you very much for taking these patches
Ok, I've taken all of these, but wow, those are big patches, much larger than we normally take for the -stable tree.
I don't want to have to do this again please.
thanks,
greg k-h
patch iwlwifi-traverse-linklist-to-find-the-valid-otp-block.patch added to 2.6.31-stable tree
In reply to reinette chatreThis is a note to let you know that we have just queued up the patch titled
Subject: iwlwifi: traverse linklist to find the valid OTP block
to the 2.6.31-stable tree. Its filename is
iwlwifi-traverse-linklist-to-find-the-valid-otp-block.patch
A git repo of this tree can be found at
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
Quoted 1 line
From [email protected] Thu Oct 1 15:42:57 2009
From: Wey-Yi Guy <[email protected]>
Date: Wed, 30 Sep 2009 15:36:15 -0700
Subject: iwlwifi: traverse linklist to find the valid OTP block
To: Greg KH <[email protected]>
Cc: "[email protected]" <[email protected]>, "[email protected]" <[email protected]>
Message-ID: <1254350175.26521.1662.camel@rc-desk>
From: Wey-Yi Guy <[email protected]>
commit 415e49936b4b29b34c2fb561eeab867d41fc43a6 upstream.
For devices using OTP memory, EEPROM image can start from any one of the OTP blocks. If shadow RAM is disabled, we need to traverse link list to find the last valid block, then start the EEPROM image reading.
If OTP is not full, the valid block is the block _before_ the last block on the link list; the last block on the link list is the empty block ready for next OTP refresh/update.
If OTP is full, then the last block is the valid block to be used for configure the device.
--- drivers/net/wireless/iwlwifi/iwl-1000.c | 4 drivers/net/wireless/iwlwifi/iwl-6000.c | 20 ++- drivers/net/wireless/iwlwifi/iwl-core.h | 4 drivers/net/wireless/iwlwifi/iwl-dev.h | 12 + drivers/net/wireless/iwlwifi/iwl-eeprom.c | 185 ++++++++++++++++++++++++------ drivers/net/wireless/iwlwifi/iwl-eeprom.h | 10 + 6 files changed, 192 insertions(+), 43 deletions(-)
drivers/net/wireless/iwlwifi/iwl-1000.c +3 -1
@@ -62,12 +62,14 @@ struct iwl_cfg iwl1000_bgn_cfg = { .ucode_api_min = IWL1000_UCODE_API_MIN, .sku = IWL_SKU_G|IWL_SKU_N, .ops = &iwl5000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_A, .valid_rx_ant = ANT_AB, .need_pll_cfg = true, + .max_ll_items = OTP_MAX_LL_ITEMS_1000, + .shadow_ram_support = false, };
drivers/net/wireless/iwlwifi/iwl-6000.c +15 -5
@@ -82,13 +82,15 @@ struct iwl_cfg iwl6000_2ag_cfg = { .ucode_api_min = IWL6000_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_BC, .valid_rx_ant = ANT_BC, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6000_2agn_cfg = {
@@ -98,13 +100,15 @@ struct iwl_cfg iwl6000_2agn_cfg = { .ucode_api_min = IWL6000_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_AB, .valid_rx_ant = ANT_AB, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6050_2agn_cfg = {
@@ -114,13 +118,15 @@ struct iwl_cfg iwl6050_2agn_cfg = { .ucode_api_min = IWL6050_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_AB, .valid_rx_ant = ANT_AB, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6000_3agn_cfg = {
@@ -130,13 +136,15 @@ struct iwl_cfg iwl6000_3agn_cfg = { .ucode_api_min = IWL6000_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_ABC, .valid_rx_ant = ANT_ABC, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };struct iwl_cfg iwl6050_3agn_cfg = {
@@ -146,13 +154,15 @@ struct iwl_cfg iwl6050_3agn_cfg = { .ucode_api_min = IWL6050_UCODE_API_MIN, .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, .ops = &iwl6000_ops, - .eeprom_size = IWL_5000_EEPROM_IMG_SIZE, + .eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_ver = EEPROM_5000_EEPROM_VERSION, .eeprom_calib_ver = EEPROM_5000_TX_POWER_VERSION, .mod_params = &iwl50_mod_params, .valid_tx_ant = ANT_ABC, .valid_rx_ant = ANT_ABC, .need_pll_cfg = false, + .max_ll_items = OTP_MAX_LL_ITEMS_6x00, + .shadow_ram_support = true, };MODULE_FIRMWARE (IWL6000_MODULE_FIRMWARE (IWL6000_UCODE_API_MAX ));
drivers/net/wireless/iwlwifi/iwl-core.h +4 -0
@@ -207,6 +207,8 @@ struct iwl_mod_params {* filename is constructed as fw_name_pre<api>.ucode. * @ucode_api_max: Highest version of uCode API supported by driver. * @ucode_api_min: Lowest version of uCode API supported by driver. +* @max_ll_items: max number of OTP blocks +* @shadow_ram_support: shadow support for OTP memory * * We enable the driver to be backward compatible wrt API version. The * driver specifies which APIs it supports (with @ucode_api_max being the
@@ -243,6 +245,8 @@ struct iwl_cfg {u8 valid_rx_ant;bool need_pll_cfg;bool use_isr_legacy; +const u16 max_ll_items; +const bool shadow_ram_support; };/***************************
drivers/net/wireless/iwlwifi/iwl-dev.h +12 -0
@@ -835,6 +835,18 @@ enum iwl_nvm_type { NVM_DEVICE_TYPE_OTP, }; +/* +* Two types of OTP memory access modes +* IWL_OTP_ACCESS_ABSOLUTE - absolute address mode, +* based on physical memory addressing +* IWL_OTP_ACCESS_RELATIVE - relative address mode, +* based on logical memory addressing +*/ +enum iwl_access_mode { +IWL_OTP_ACCESS_ABSOLUTE , +IWL_OTP_ACCESS_RELATIVE , +}; +/* interrupt statistics */ struct isr_statistics {u32 hw;
drivers/net/wireless/iwlwifi/iwl-eeprom.c +150 -35
222 lines not on this page · raw message
drivers/net/wireless/iwlwifi/iwl-eeprom.h +8 -2
@@ -180,8 +180,14 @@ struct iwl_eeprom_channel {#define EEPROM_5050_EEPROM_VERSION (0x21E)/* OTP */ -#define OTP_LOWER_BLOCKS_TOTAL (3) -#define OTP_BLOCK_SIZE (0x400) +/* lower blocks contain EEPROM image and calibration data */ +#define OTP_LOW_IMAGE_SIZE (2 * 512 * sizeof(u16))/* 2 KB */ +/* high blocks contain PAPD data */ +#define OTP_HIGH_IMAGE_SIZE_6x00 (6 * 512 * sizeof(u16))/* 6 KB */ +#define OTP_HIGH_IMAGE_SIZE_1000 (0x200 * sizeof(u16))/* 1024 bytes */ +#define OTP_MAX_LL_ITEMS_1000 (3)/* OTP blocks for 1000 */ +#define OTP_MAX_LL_ITEMS_6x00 (4)/* OTP blocks for 6x00 */ +#define OTP_MAX_LL_ITEMS_6x50 (7)/* OTP blocks for 6x50 */ /* 2.4 GHz */ extern const u8 iwl_eeprom_band_1[14 ];
Patches currently in stable-queue which might be from [email protected] are
queue-2.6.31/iwlagn-modify-digital-svr-for-1000.patch queue-2.6.31/iwlwifi-traverse-linklist-to-find-the-valid-otp-block.patch queue-2.6.31/iwlwifi-fix-unloading-driver-while-scanning.patch
Quoted 4 lines · Greg KH
Ok, I've taken all of these, but wow, those are big patches, much larger than we normally take for the -stable tree.
I don't want to have to do this again please.
ack.
Thank you very much
Reinette