diff options
author | Wey-Yi Guy <wey-yi.w.guy@intel.com> | 2009-07-17 12:30:27 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-07-24 15:05:26 -0400 |
commit | 30a12a8fbbd530b016277dd2ab65246b516540a8 (patch) | |
tree | d5178cdf45101a4418549ab568397eaa81c53949 /drivers/net/wireless/iwlwifi/iwl-helpers.h | |
parent | 4c423a2b0cc3c85137988962e6ba3f01baef0b4e (diff) |
iwlwifi: change iwl_enable/disable_interrupts to "inline"
iwl_enable_interrupts is being called inside the interrupt,
change from function call to inline
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@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/iwl-helpers.h')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-helpers.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-helpers.h b/drivers/net/wireless/iwlwifi/iwl-helpers.h index a1328c3c81ae..bd0b12efb5c7 100644 --- a/drivers/net/wireless/iwlwifi/iwl-helpers.h +++ b/drivers/net/wireless/iwlwifi/iwl-helpers.h | |||
@@ -145,4 +145,25 @@ static inline void iwl_stop_queue(struct iwl_priv *priv, u8 queue) | |||
145 | #define ieee80211_stop_queue DO_NOT_USE_ieee80211_stop_queue | 145 | #define ieee80211_stop_queue DO_NOT_USE_ieee80211_stop_queue |
146 | #define ieee80211_wake_queue DO_NOT_USE_ieee80211_wake_queue | 146 | #define ieee80211_wake_queue DO_NOT_USE_ieee80211_wake_queue |
147 | 147 | ||
148 | static inline void iwl_disable_interrupts(struct iwl_priv *priv) | ||
149 | { | ||
150 | clear_bit(STATUS_INT_ENABLED, &priv->status); | ||
151 | |||
152 | /* disable interrupts from uCode/NIC to host */ | ||
153 | iwl_write32(priv, CSR_INT_MASK, 0x00000000); | ||
154 | |||
155 | /* acknowledge/clear/reset any interrupts still pending | ||
156 | * from uCode or flow handler (Rx/Tx DMA) */ | ||
157 | iwl_write32(priv, CSR_INT, 0xffffffff); | ||
158 | iwl_write32(priv, CSR_FH_INT_STATUS, 0xffffffff); | ||
159 | IWL_DEBUG_ISR(priv, "Disabled interrupts\n"); | ||
160 | } | ||
161 | |||
162 | static inline void iwl_enable_interrupts(struct iwl_priv *priv) | ||
163 | { | ||
164 | IWL_DEBUG_ISR(priv, "Enabling interrupts\n"); | ||
165 | set_bit(STATUS_INT_ENABLED, &priv->status); | ||
166 | iwl_write32(priv, CSR_INT_MASK, priv->inta_mask); | ||
167 | } | ||
168 | |||
148 | #endif /* __iwl_helpers_h__ */ | 169 | #endif /* __iwl_helpers_h__ */ |