diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2013-03-14 08:35:06 +0200 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2013-03-20 12:07:07 +0100 |
commit | cc904c7188c29847817f35e6966fec3014c7479b (patch) | |
tree | fb3dffc0a22dfdd8b58164246f231f2d5e62f47e | |
parent | 2470b36e84a2e680d7a7e3809cbceae5bfae3606 (diff) | |
download | linux-cc904c7188c29847817f35e6966fec3014c7479b.tar.gz linux-cc904c7188c29847817f35e6966fec3014c7479b.tar.bz2 linux-cc904c7188c29847817f35e6966fec3014c7479b.zip |
iwlwifi: fix length check in multi-TB HCMD
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.
Cc: stable@vger@kernel.org
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r-- | drivers/net/wireless/iwlwifi/pcie/tx.c | 2 |
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 8595c16f74de..cb5c6792e3a8 100644 --- a/drivers/net/wireless/iwlwifi/pcie/tx.c +++ b/drivers/net/wireless/iwlwifi/pcie/tx.c @@ -1264,7 +1264,7 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *trans, for (i = 0; i < IWL_MAX_CMD_TBS_PER_TFD; i++) { int copy = 0; - if (!cmd->len) + if (!cmd->len[i]) continue; /* need at least IWL_HCMD_SCRATCHBUF_SIZE copied */ |