diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2008-12-18 21:37:06 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-01-29 15:58:54 -0500 |
commit | 28afaf9139ce9f1c26452f34808e322e8e868850 (patch) | |
tree | 0688d63de5770ff0b227a192a2349fbee9c66836 /drivers/net/wireless/iwlwifi/iwl3945-base.c | |
parent | 4c897253cc9ae1c6a2798b27b5fe8e6d94ab6185 (diff) |
iwlwifi: 3945 drop usage of union tsf
This patch replaces union tsf with u64
This also allows to use iwl_error_res
and iwl_rxon_time_cmd instead of 3945 structures
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl3945-base.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl3945-base.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index 0be3e7d97149..621e0877ca28 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c | |||
@@ -2058,13 +2058,10 @@ static void iwl3945_setup_rxon_timing(struct iwl3945_priv *priv) | |||
2058 | conf = ieee80211_get_hw_conf(priv->hw); | 2058 | conf = ieee80211_get_hw_conf(priv->hw); |
2059 | 2059 | ||
2060 | spin_lock_irqsave(&priv->lock, flags); | 2060 | spin_lock_irqsave(&priv->lock, flags); |
2061 | priv->rxon_timing.timestamp.dw[1] = cpu_to_le32(priv->timestamp1); | 2061 | priv->rxon_timing.timestamp = cpu_to_le64(priv->timestamp); |
2062 | priv->rxon_timing.timestamp.dw[0] = cpu_to_le32(priv->timestamp0); | ||
2063 | |||
2064 | priv->rxon_timing.listen_interval = INTEL_CONN_LISTEN_INTERVAL; | 2062 | priv->rxon_timing.listen_interval = INTEL_CONN_LISTEN_INTERVAL; |
2065 | 2063 | ||
2066 | tsf = priv->timestamp1; | 2064 | tsf = priv->timestamp; |
2067 | tsf = ((tsf << 32) | priv->timestamp0); | ||
2068 | 2065 | ||
2069 | beacon_int = priv->beacon_int; | 2066 | beacon_int = priv->beacon_int; |
2070 | spin_unlock_irqrestore(&priv->lock, flags); | 2067 | spin_unlock_irqrestore(&priv->lock, flags); |
@@ -6306,7 +6303,7 @@ static void iwl3945_post_associate(struct iwl3945_priv *priv) | |||
6306 | priv->staging_rxon.filter_flags &= ~RXON_FILTER_ASSOC_MSK; | 6303 | priv->staging_rxon.filter_flags &= ~RXON_FILTER_ASSOC_MSK; |
6307 | iwl3945_commit_rxon(priv); | 6304 | iwl3945_commit_rxon(priv); |
6308 | 6305 | ||
6309 | memset(&priv->rxon_timing, 0, sizeof(struct iwl3945_rxon_time_cmd)); | 6306 | memset(&priv->rxon_timing, 0, sizeof(struct iwl_rxon_time_cmd)); |
6310 | iwl3945_setup_rxon_timing(priv); | 6307 | iwl3945_setup_rxon_timing(priv); |
6311 | rc = iwl3945_send_cmd_pdu(priv, REPLY_RXON_TIMING, | 6308 | rc = iwl3945_send_cmd_pdu(priv, REPLY_RXON_TIMING, |
6312 | sizeof(priv->rxon_timing), &priv->rxon_timing); | 6309 | sizeof(priv->rxon_timing), &priv->rxon_timing); |
@@ -6686,7 +6683,7 @@ static void iwl3945_config_ap(struct iwl3945_priv *priv) | |||
6686 | iwl3945_commit_rxon(priv); | 6683 | iwl3945_commit_rxon(priv); |
6687 | 6684 | ||
6688 | /* RXON Timing */ | 6685 | /* RXON Timing */ |
6689 | memset(&priv->rxon_timing, 0, sizeof(struct iwl3945_rxon_time_cmd)); | 6686 | memset(&priv->rxon_timing, 0, sizeof(struct iwl_rxon_time_cmd)); |
6690 | iwl3945_setup_rxon_timing(priv); | 6687 | iwl3945_setup_rxon_timing(priv); |
6691 | rc = iwl3945_send_cmd_pdu(priv, REPLY_RXON_TIMING, | 6688 | rc = iwl3945_send_cmd_pdu(priv, REPLY_RXON_TIMING, |
6692 | sizeof(priv->rxon_timing), &priv->rxon_timing); | 6689 | sizeof(priv->rxon_timing), &priv->rxon_timing); |
@@ -6934,9 +6931,7 @@ static void iwl3945_bss_info_changed(struct ieee80211_hw *hw, | |||
6934 | if (bss_conf->assoc) { | 6931 | if (bss_conf->assoc) { |
6935 | priv->assoc_id = bss_conf->aid; | 6932 | priv->assoc_id = bss_conf->aid; |
6936 | priv->beacon_int = bss_conf->beacon_int; | 6933 | priv->beacon_int = bss_conf->beacon_int; |
6937 | priv->timestamp0 = bss_conf->timestamp & 0xFFFFFFFF; | 6934 | priv->timestamp = bss_conf->timestamp; |
6938 | priv->timestamp1 = (bss_conf->timestamp >> 32) & | ||
6939 | 0xFFFFFFFF; | ||
6940 | priv->assoc_capability = bss_conf->assoc_capability; | 6935 | priv->assoc_capability = bss_conf->assoc_capability; |
6941 | priv->next_scan_jiffies = jiffies + | 6936 | priv->next_scan_jiffies = jiffies + |
6942 | IWL_DELAY_NEXT_SCAN_AFTER_ASSOC; | 6937 | IWL_DELAY_NEXT_SCAN_AFTER_ASSOC; |
@@ -7178,8 +7173,7 @@ static void iwl3945_mac_reset_tsf(struct ieee80211_hw *hw) | |||
7178 | priv->ibss_beacon = NULL; | 7173 | priv->ibss_beacon = NULL; |
7179 | 7174 | ||
7180 | priv->beacon_int = priv->hw->conf.beacon_int; | 7175 | priv->beacon_int = priv->hw->conf.beacon_int; |
7181 | priv->timestamp1 = 0; | 7176 | priv->timestamp = 0; |
7182 | priv->timestamp0 = 0; | ||
7183 | if ((priv->iw_mode == NL80211_IFTYPE_STATION)) | 7177 | if ((priv->iw_mode == NL80211_IFTYPE_STATION)) |
7184 | priv->beacon_int = 0; | 7178 | priv->beacon_int = 0; |
7185 | 7179 | ||