iwlwifi: move to wide ID for all commands
[cascardo/linux.git] / drivers / net / wireless / intel / iwlwifi / iwl-trans.c
index 6069a9f..b42152c 100644 (file)
@@ -65,6 +65,7 @@
 
 #include "iwl-trans.h"
 #include "iwl-drv.h"
+#include "iwl-fh.h"
 
 struct iwl_trans *iwl_trans_alloc(unsigned int priv_size,
                                  struct device *dev,
@@ -139,6 +140,9 @@ int iwl_trans_send_cmd(struct iwl_trans *trans, struct iwl_host_cmd *cmd)
        if (!(cmd->flags & CMD_ASYNC))
                lock_map_acquire_read(&trans->sync_cmd_lockdep_map);
 
+       if (trans->wide_cmd_header && !iwl_cmd_groupid(cmd->id))
+               cmd->id = DEF_ID(cmd->id);
+
        ret = trans->ops->send_cmd(trans, cmd);
 
        if (!(cmd->flags & CMD_ASYNC))