iwlwifi: fix problem when rf_killswitch change during suspend/resume
authorZhu Yi <yi.zhu@intel.com>
Thu, 24 Jan 2008 10:19:38 +0000 (02:19 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 28 Jan 2008 23:09:58 +0000 (15:09 -0800)
commite655b9f03f41c7a84fb74d6619abf844d7f2ab65
tree219be4a1e49e9d630874684b6996e9d0a73d166c
parent5a66926aa9230810704fd5a127966215fd58881e
iwlwifi: fix problem when rf_killswitch change during suspend/resume

After we delay device initialization until interface up, there are more
conditions for the hardware rf_kill switch states during suspend and
resume. For example, before suspend we can have interface up or down,
rf_kill enable or disable; before resume we can have rf_kill enable or
disable. So there are totally 2^3 = 8 conditions to handle. This patch
addressed this problem and makes sure every condition works correctly.

This patch also merges the device suspend and resume handlers with the
mac_start and mac_stop code since they are basically doing the same
thing.

Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/wireless/iwlwifi/iwl3945-base.c
drivers/net/wireless/iwlwifi/iwl4965-base.c