Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=53e490936a91940a153e231c3b8288e3ecfcc5aa
Commit:     53e490936a91940a153e231c3b8288e3ecfcc5aa
Parent:     1a8d122782bdabe4475f29d022c9a0c092ac9878
Author:     Zhu Yi <[EMAIL PROTECTED]>
AuthorDate: Thu Dec 6 16:08:44 2007 +0800
Committer:  John W. Linville <[EMAIL PROTECTED]>
CommitDate: Mon Dec 17 17:01:40 2007 -0500

    iwlwifi: fix rf_kill state inconsistent during suspend and resume
    
    The patch fixes the STATUS_RF_KILL_HW state is not cleared problem if the
    device goes to suspend when the rf_kill switch is enabled. The bug causes
    the driver always thinks the rf_kill switch is enabled (although it is
    disabled) after resume.
    
    Signed-off-by: Zhu Yi <[EMAIL PROTECTED]>
    Signed-off-by: John W. Linville <[EMAIL PROTECTED]>
---
 drivers/net/wireless/iwlwifi/iwl3945-base.c |    4 +++-
 drivers/net/wireless/iwlwifi/iwl4965-base.c |    4 +++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c 
b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index 1c3ca6e..3d1da07 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -4743,8 +4743,10 @@ static void iwl_irq_tasklet(struct iwl_priv *priv)
                 *   when we loaded driver, and is now set to "enable".
                 * After we're Alive, RF_KILL gets handled by
                 *   iwl_rx_card_state_notif() */
-               if (!hw_rf_kill && !test_bit(STATUS_ALIVE, &priv->status))
+               if (!hw_rf_kill && !test_bit(STATUS_ALIVE, &priv->status)) {
+                       clear_bit(STATUS_RF_KILL_HW, &priv->status);
                        queue_work(priv->workqueue, &priv->restart);
+               }
 
                handled |= CSR_INT_BIT_RF_KILL;
        }
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c 
b/drivers/net/wireless/iwlwifi/iwl4965-base.c
index 3b31607..b54fe5e 100644
--- a/drivers/net/wireless/iwlwifi/iwl4965-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c
@@ -5059,8 +5059,10 @@ static void iwl_irq_tasklet(struct iwl_priv *priv)
                 *   when we loaded driver, and is now set to "enable".
                 * After we're Alive, RF_KILL gets handled by
                 *   iwl_rx_card_state_notif() */
-               if (!hw_rf_kill && !test_bit(STATUS_ALIVE, &priv->status))
+               if (!hw_rf_kill && !test_bit(STATUS_ALIVE, &priv->status)) {
+                       clear_bit(STATUS_RF_KILL_HW, &priv->status);
                        queue_work(priv->workqueue, &priv->restart);
+               }
 
                handled |= CSR_INT_BIT_RF_KILL;
        }
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to