ath9k: Remove ath9k_hw_wow_event_to_string
authorSujith Manoharan <c_manoha@qca.qualcomm.com>
Fri, 30 Jan 2015 13:35:29 +0000 (19:05 +0530)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 3 Feb 2015 13:31:06 +0000 (15:31 +0200)
Printing the value of the wakeup status is sufficient.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/ath/ath9k/ar9003_wow.c
drivers/net/wireless/ath/ath9k/hw.h
drivers/net/wireless/ath/ath9k/wow.c

index 81c88dd606dcd960f43e740b9af8cffcdc25778a..3abc9073f4ac3b567a914ef4ef443f54f9e6b629 100644 (file)
 #include "reg.h"
 #include "hw-ops.h"
 
-const char *ath9k_hw_wow_event_to_string(u32 wow_event)
-{
-       if (wow_event & AH_WOW_MAGIC_PATTERN_EN)
-               return "Magic pattern";
-       if (wow_event & AH_WOW_USER_PATTERN_EN)
-               return "User pattern";
-       if (wow_event & AH_WOW_LINK_CHANGE)
-               return "Link change";
-       if (wow_event & AH_WOW_BEACON_MISS)
-               return "Beacon miss";
-
-       return  "unknown reason";
-}
-EXPORT_SYMBOL(ath9k_hw_wow_event_to_string);
-
 static void ath9k_hw_set_powermode_wow_sleep(struct ath_hw *ah)
 {
        struct ath_common *common = ath9k_hw_common(ah);
index dabc94e11805e483c1eebcd74df751af893ee780..22b04222a1bd1c76396baaf38a6e06134750da2c 100644 (file)
@@ -1146,17 +1146,12 @@ ath9k_hw_get_btcoex_scheme(struct ath_hw *ah)
 
 
 #ifdef CONFIG_ATH9K_WOW
-const char *ath9k_hw_wow_event_to_string(u32 wow_event);
 void ath9k_hw_wow_apply_pattern(struct ath_hw *ah, u8 *user_pattern,
                                u8 *user_mask, int pattern_count,
                                int pattern_len);
 u32 ath9k_hw_wow_wakeup(struct ath_hw *ah);
 void ath9k_hw_wow_enable(struct ath_hw *ah, u32 pattern_enable);
 #else
-static inline const char *ath9k_hw_wow_event_to_string(u32 wow_event)
-{
-       return NULL;
-}
 static inline void ath9k_hw_wow_apply_pattern(struct ath_hw *ah,
                                              u8 *user_pattern,
                                              u8 *user_mask,
index fa60dbb0bf14674613968805a2fec6ebaabcd206..d4cfbc363eb5743e47cae055a74db897c85bd51f 100644 (file)
@@ -281,7 +281,7 @@ int ath9k_resume(struct ieee80211_hw *hw)
        struct ath_softc *sc = hw->priv;
        struct ath_hw *ah = sc->sc_ah;
        struct ath_common *common = ath9k_hw_common(ah);
-       u32 wow_status;
+       ustatus;
 
        mutex_lock(&sc->mutex);
 
@@ -296,12 +296,8 @@ int ath9k_resume(struct ieee80211_hw *hw)
 
        spin_unlock_bh(&sc->sc_pcu_lock);
 
-       wow_status = ath9k_hw_wow_wakeup(ah);
-
-       if (wow_status) {
-               ath_dbg(common, ANY, "Waking up due to WoW triggers %s with WoW status = %x\n",
-                       ath9k_hw_wow_event_to_string(wow_status), wow_status);
-       }
+       status = ath9k_hw_wow_wakeup(ah);
+       ath_dbg(common, WOW, "Resume with WoW status: 0x%x\n", status);
 
        ath_restart_work(sc);
        ath9k_start_btcoex(sc);