diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2011-08-26 02:10:42 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-08-29 15:25:31 -0400 |
commit | 63013ae30159c90d2a873e20e680e7810fa533fa (patch) | |
tree | 7bb7dcaf655df21297cf75ddeb8d350a68386a38 /drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c | |
parent | 74e28e44095e30ffd2d0258e4fe91826a15247e7 (diff) |
iwlagn: priv->status moves to iwl_shared
Since it is used by all the layers, it needs to move to iwl_shared.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c b/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c index b751f52905c0..ab421529d12c 100644 --- a/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c +++ b/drivers/net/wireless/iwlwifi/iwl-trans-tx-pcie.c | |||
@@ -96,7 +96,7 @@ void iwl_txq_update_write_ptr(struct iwl_priv *priv, struct iwl_tx_queue *txq) | |||
96 | txq->q.write_ptr | (txq_id << 8)); | 96 | txq->q.write_ptr | (txq_id << 8)); |
97 | } else { | 97 | } else { |
98 | /* if we're trying to save power */ | 98 | /* if we're trying to save power */ |
99 | if (test_bit(STATUS_POWER_PMI, &priv->status)) { | 99 | if (test_bit(STATUS_POWER_PMI, &priv->shrd->status)) { |
100 | /* wake up nic if it's powered down ... | 100 | /* wake up nic if it's powered down ... |
101 | * uCode will wake up, and interrupt us again, so next | 101 | * uCode will wake up, and interrupt us again, so next |
102 | * time we'll skip this part. */ | 102 | * time we'll skip this part. */ |
@@ -544,7 +544,7 @@ static int iwl_enqueue_hcmd(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
544 | int trace_idx; | 544 | int trace_idx; |
545 | #endif | 545 | #endif |
546 | 546 | ||
547 | if (test_bit(STATUS_FW_ERROR, &priv->status)) { | 547 | if (test_bit(STATUS_FW_ERROR, &priv->shrd->status)) { |
548 | IWL_WARN(priv, "fw recovery, no hcmd send\n"); | 548 | IWL_WARN(priv, "fw recovery, no hcmd send\n"); |
549 | return -EIO; | 549 | return -EIO; |
550 | } | 550 | } |
@@ -786,7 +786,7 @@ void iwl_tx_cmd_complete(struct iwl_priv *priv, struct iwl_rx_mem_buffer *rxb) | |||
786 | iwl_hcmd_queue_reclaim(priv, txq_id, index); | 786 | iwl_hcmd_queue_reclaim(priv, txq_id, index); |
787 | 787 | ||
788 | if (!(meta->flags & CMD_ASYNC)) { | 788 | if (!(meta->flags & CMD_ASYNC)) { |
789 | clear_bit(STATUS_HCMD_ACTIVE, &priv->status); | 789 | clear_bit(STATUS_HCMD_ACTIVE, &priv->shrd->status); |
790 | IWL_DEBUG_INFO(priv, "Clearing HCMD_ACTIVE for command %s\n", | 790 | IWL_DEBUG_INFO(priv, "Clearing HCMD_ACTIVE for command %s\n", |
791 | get_cmd_string(cmd->hdr.cmd)); | 791 | get_cmd_string(cmd->hdr.cmd)); |
792 | wake_up_interruptible(&priv->wait_command_queue); | 792 | wake_up_interruptible(&priv->wait_command_queue); |
@@ -917,7 +917,7 @@ static int iwl_send_cmd_async(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
917 | if (!cmd->callback) | 917 | if (!cmd->callback) |
918 | cmd->callback = iwl_generic_cmd_callback; | 918 | cmd->callback = iwl_generic_cmd_callback; |
919 | 919 | ||
920 | if (test_bit(STATUS_EXIT_PENDING, &priv->status)) | 920 | if (test_bit(STATUS_EXIT_PENDING, &priv->shrd->status)) |
921 | return -EBUSY; | 921 | return -EBUSY; |
922 | 922 | ||
923 | ret = iwl_enqueue_hcmd(priv, cmd); | 923 | ret = iwl_enqueue_hcmd(priv, cmd); |
@@ -943,30 +943,30 @@ static int iwl_send_cmd_sync(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
943 | IWL_DEBUG_INFO(priv, "Attempting to send sync command %s\n", | 943 | IWL_DEBUG_INFO(priv, "Attempting to send sync command %s\n", |
944 | get_cmd_string(cmd->id)); | 944 | get_cmd_string(cmd->id)); |
945 | 945 | ||
946 | set_bit(STATUS_HCMD_ACTIVE, &priv->status); | 946 | set_bit(STATUS_HCMD_ACTIVE, &priv->shrd->status); |
947 | IWL_DEBUG_INFO(priv, "Setting HCMD_ACTIVE for command %s\n", | 947 | IWL_DEBUG_INFO(priv, "Setting HCMD_ACTIVE for command %s\n", |
948 | get_cmd_string(cmd->id)); | 948 | get_cmd_string(cmd->id)); |
949 | 949 | ||
950 | cmd_idx = iwl_enqueue_hcmd(priv, cmd); | 950 | cmd_idx = iwl_enqueue_hcmd(priv, cmd); |
951 | if (cmd_idx < 0) { | 951 | if (cmd_idx < 0) { |
952 | ret = cmd_idx; | 952 | ret = cmd_idx; |
953 | clear_bit(STATUS_HCMD_ACTIVE, &priv->status); | 953 | clear_bit(STATUS_HCMD_ACTIVE, &priv->shrd->status); |
954 | IWL_ERR(priv, "Error sending %s: enqueue_hcmd failed: %d\n", | 954 | IWL_ERR(priv, "Error sending %s: enqueue_hcmd failed: %d\n", |
955 | get_cmd_string(cmd->id), ret); | 955 | get_cmd_string(cmd->id), ret); |
956 | return ret; | 956 | return ret; |
957 | } | 957 | } |
958 | 958 | ||
959 | ret = wait_event_interruptible_timeout(priv->wait_command_queue, | 959 | ret = wait_event_interruptible_timeout(priv->wait_command_queue, |
960 | !test_bit(STATUS_HCMD_ACTIVE, &priv->status), | 960 | !test_bit(STATUS_HCMD_ACTIVE, &priv->shrd->status), |
961 | HOST_COMPLETE_TIMEOUT); | 961 | HOST_COMPLETE_TIMEOUT); |
962 | if (!ret) { | 962 | if (!ret) { |
963 | if (test_bit(STATUS_HCMD_ACTIVE, &priv->status)) { | 963 | if (test_bit(STATUS_HCMD_ACTIVE, &priv->shrd->status)) { |
964 | IWL_ERR(priv, | 964 | IWL_ERR(priv, |
965 | "Error sending %s: time out after %dms.\n", | 965 | "Error sending %s: time out after %dms.\n", |
966 | get_cmd_string(cmd->id), | 966 | get_cmd_string(cmd->id), |
967 | jiffies_to_msecs(HOST_COMPLETE_TIMEOUT)); | 967 | jiffies_to_msecs(HOST_COMPLETE_TIMEOUT)); |
968 | 968 | ||
969 | clear_bit(STATUS_HCMD_ACTIVE, &priv->status); | 969 | clear_bit(STATUS_HCMD_ACTIVE, &priv->shrd->status); |
970 | IWL_DEBUG_INFO(priv, "Clearing HCMD_ACTIVE for command" | 970 | IWL_DEBUG_INFO(priv, "Clearing HCMD_ACTIVE for command" |
971 | "%s\n", get_cmd_string(cmd->id)); | 971 | "%s\n", get_cmd_string(cmd->id)); |
972 | ret = -ETIMEDOUT; | 972 | ret = -ETIMEDOUT; |
@@ -974,13 +974,13 @@ static int iwl_send_cmd_sync(struct iwl_priv *priv, struct iwl_host_cmd *cmd) | |||
974 | } | 974 | } |
975 | } | 975 | } |
976 | 976 | ||
977 | if (test_bit(STATUS_RF_KILL_HW, &priv->status)) { | 977 | if (test_bit(STATUS_RF_KILL_HW, &priv->shrd->status)) { |
978 | IWL_ERR(priv, "Command %s aborted: RF KILL Switch\n", | 978 | IWL_ERR(priv, "Command %s aborted: RF KILL Switch\n", |
979 | get_cmd_string(cmd->id)); | 979 | get_cmd_string(cmd->id)); |
980 | ret = -ECANCELED; | 980 | ret = -ECANCELED; |
981 | goto fail; | 981 | goto fail; |
982 | } | 982 | } |
983 | if (test_bit(STATUS_FW_ERROR, &priv->status)) { | 983 | if (test_bit(STATUS_FW_ERROR, &priv->shrd->status)) { |
984 | IWL_ERR(priv, "Command %s failed: FW Error\n", | 984 | IWL_ERR(priv, "Command %s failed: FW Error\n", |
985 | get_cmd_string(cmd->id)); | 985 | get_cmd_string(cmd->id)); |
986 | ret = -EIO; | 986 | ret = -EIO; |