From: Rick Farrington Date: Tue, 18 Mar 2008 21:57:49 +0000 (-0700) Subject: iwlwifi: mac start synchronization issue X-Git-Tag: v2.6.25-rc8~77^2~1^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a9f46786ec5bb291c9b5e6cc6f83ebbd3fceea51;p=platform%2Fkernel%2Flinux-3.10.git iwlwifi: mac start synchronization issue This patch fixes a synchronization problem on the 4965 and 3945 with the mac start callback routine. The problem is that this function exits BEFORE the 'xxx_alive_start' has completed. This can lead to a problem if a subsequent MAC callback attempts to issue a firmware command. Signed-off-by: Rick Farrington Signed-off-by: Reinette Chatre Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index 40b71bc..39cc13f 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c @@ -6206,11 +6206,11 @@ static void iwl3945_alive_start(struct iwl3945_priv *priv) /* At this point, the NIC is initialized and operational */ priv->notif_missed_beacons = 0; - set_bit(STATUS_READY, &priv->status); iwl3945_reg_txpower_periodic(priv); IWL_DEBUG_INFO("ALIVE processing complete.\n"); + set_bit(STATUS_READY, &priv->status); wake_up_interruptible(&priv->wait_command_queue); if (priv->error_recovering) diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c index a23d479..7020822 100644 --- a/drivers/net/wireless/iwlwifi/iwl4965-base.c +++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c @@ -6628,11 +6628,11 @@ static void iwl4965_alive_start(struct iwl4965_priv *priv) /* At this point, the NIC is initialized and operational */ priv->notif_missed_beacons = 0; - set_bit(STATUS_READY, &priv->status); iwl4965_rf_kill_ct_config(priv); IWL_DEBUG_INFO("ALIVE processing complete.\n"); + set_bit(STATUS_READY, &priv->status); wake_up_interruptible(&priv->wait_command_queue); if (priv->error_recovering)