summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>2013-03-14 06:35:06 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-04-05 16:25:48 (GMT)
commit3d8e86bcaa87d05c3d7ffe428f54feacf24d11f8 (patch)
tree3e34961d078b6492767f8ee58b7da59a7ddc16dd
parent8937760b75606528a7b0837215eda91100e2b988 (diff)
downloadlinux-fsl-qoriq-3d8e86bcaa87d05c3d7ffe428f54feacf24d11f8.tar.xz
iwlwifi: fix length check in multi-TB HCMD
commit cc904c7188c29847817f35e6966fec3014c7479b upstream. As reported by Ben Hutchings, there was a harmless issue in the checks being done on the lengths of the TBs while building the TFD for a multi-TB host command. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/net/wireless/iwlwifi/pcie/tx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/iwlwifi/pcie/tx.c b/drivers/net/wireless/iwlwifi/pcie/tx.c
index c6cd922..d760da9 100644
--- a/drivers/net/wireless/iwlwifi/pcie/tx.c
+++ b/drivers/net/wireless/iwlwifi/pcie/tx.c
@@ -1242,7 +1242,7 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *trans,
for (i = 0; i < IWL_MAX_CMD_TFDS; i++) {
int copy = 0;
- if (!cmd->len)
+ if (!cmd->len[i])
continue;
/* need at least IWL_HCMD_MIN_COPY_SIZE copied */