Skip to content

Commit

Permalink
iwlwifi: fix unused variable warning
Browse files Browse the repository at this point in the history
In the case of disabled CONFIG_IWLWIFI_DEBUGFS option the compiler complains
about the unused variable 'img'. Fix this by moving the 'img' definition.

Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Acked-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Oliver Hartkopp authored and John W. Linville committed Apr 10, 2012
1 parent 227842d commit a855f7e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/net/wireless/iwlwifi/iwl-mac80211.c
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,6 @@ static int iwlagn_mac_resume(struct ieee80211_hw *hw)
unsigned long flags;
u32 base, status = 0xffffffff;
int ret = -EIO;
const struct fw_img *img;

IWL_DEBUG_MAC80211(priv, "enter\n");
mutex_lock(&priv->mutex);
Expand All @@ -459,6 +458,8 @@ static int iwlagn_mac_resume(struct ieee80211_hw *hw)

#ifdef CONFIG_IWLWIFI_DEBUGFS
if (ret == 0) {
const struct fw_img *img;

img = &(priv->fw->img[IWL_UCODE_WOWLAN]);
if (!priv->wowlan_sram) {
priv->wowlan_sram =
Expand Down

0 comments on commit a855f7e

Please sign in to comment.