iwl3945: replaces iwl3945_priv with iwl_priv
The patch replaces iwl3945_priv to iwl_priv. It adds 3945 specific
data members to iwl_priv.
Signed-off-by: Abhijeet Kolekar <abhijeet.kolekar@intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h
index 9904406..5cc6c5e 100644
--- a/drivers/net/wireless/iwlwifi/iwl-dev.h
+++ b/drivers/net/wireless/iwlwifi/iwl-dev.h
@@ -40,6 +40,7 @@
#include "iwl-eeprom.h"
#include "iwl-4965-hw.h"
#include "iwl-3945-hw.h"
+#include "iwl-3945-led.h"
#include "iwl-csr.h"
#include "iwl-prph.h"
#include "iwl-debug.h"
@@ -835,7 +836,7 @@
struct ieee80211_supported_band bands[IEEE80211_NUM_BANDS];
-#ifdef CONFIG_IWLAGN_SPECTRUM_MEASUREMENT
+#if defined(CONFIG_IWLAGN_SPECTRUM_MEASUREMENT) || defined(CONFIG_IWL3945_SPECTRUM_MEASUREMENT)
/* spectrum measurement report caching */
struct iwl_spectrum_notification measure_report;
u8 measurement_status;
@@ -916,18 +917,25 @@
* 4965's initialize alive response contains some calibration data. */
struct iwl_init_alive_resp card_alive_init;
struct iwl_alive_resp card_alive;
-#ifdef CONFIG_IWLWIFI_RFKILL
+#if defined(CONFIG_IWLWIFI_RFKILL) || defined(CONFIG_IWL3945_RFKILL)
struct rfkill *rfkill;
#endif
-#ifdef CONFIG_IWLWIFI_LEDS
- struct iwl_led led[IWL_LED_TRG_MAX];
+#if defined(CONFIG_IWLWIFI_LEDS) || defined(CONFIG_IWL3945_LEDS)
unsigned long last_blink_time;
u8 last_blink_rate;
u8 allow_blinking;
u64 led_tpt;
#endif
+#ifdef CONFIG_IWLWIFI_LEDS
+ struct iwl_led led[IWL_LED_TRG_MAX];
+#endif
+
+#ifdef CONFIG_IWL3945_LEDS
+ struct iwl3945_led led39[IWL_LED_TRG_MAX];
+ unsigned int rxtxpackets;
+#endif
u16 active_rate;
u16 active_rate_basic;
@@ -1048,12 +1056,16 @@
struct delayed_work init_alive_start;
struct delayed_work alive_start;
struct delayed_work scan_check;
+
+ /*For 3945 only*/
+ struct delayed_work thermal_periodic;
+
/* TX Power */
s8 tx_power_user_lmt;
s8 tx_power_channel_lmt;
-#ifdef CONFIG_IWLWIFI_DEBUG
+#if defined(CONFIG_IWLWIFI_DEBUG) || defined(CONFIG_IWL3945_DEBUG)
/* debugging info */
u32 debug_level;
u32 framecnt_to_us;
@@ -1070,6 +1082,35 @@
u32 disable_tx_power_cal;
struct work_struct run_time_calib_work;
struct timer_list statistics_periodic;
+
+ /*For 3945*/
+#define IWL_DEFAULT_TX_POWER 0x0F
+ s8 user_txpower_limit;
+ s8 max_channel_txpower_limit;
+
+ struct iwl3945_scan_cmd *scan39;
+
+ /* We declare this const so it can only be
+ * changed via explicit cast within the
+ * routines that actually update the physical
+ * hardware */
+ const struct iwl3945_rxon_cmd active39_rxon;
+ struct iwl3945_rxon_cmd staging39_rxon;
+ struct iwl3945_rxon_cmd recovery39_rxon;
+
+ struct iwl3945_tx_queue txq39[IWL39_MAX_NUM_QUEUES];
+
+ struct iwl3945_power_mgr power_data_39;
+ struct iwl3945_notif_statistics statistics_39;
+
+ struct iwl3945_station_entry stations_39[IWL_STATION_COUNT];
+
+ /* eeprom */
+ struct iwl3945_eeprom eeprom39;
+
+ u32 sta_supp_rates;
+ u8 call_post_assoc_from_beacon;
+
}; /*iwl_priv */
static inline void iwl_txq_ctx_activate(struct iwl_priv *priv, int txq_id)