summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/intel/iwlwifi/iwl-fw.h
diff options
context:
space:
mode:
authorSharon Dvir <sharon.dvir@intel.com>2016-08-03 10:55:45 +0300
committerLuca Coelho <luciano.coelho@intel.com>2016-09-16 09:10:32 +0300
commit612da1efc07f28ea9e64402820dd25287ff5233b (patch)
tree65e0fdb2052615f5188de5638298f7336e7949cc /drivers/net/wireless/intel/iwlwifi/iwl-fw.h
parent9fb064df6d57bf09ed3f8f964c8b0789b55206e7 (diff)
downloadlinux-612da1efc07f28ea9e64402820dd25287ff5233b.tar.bz2
iwlwifi: unify iwl_get_ucode_image() implementations
Avoid multiple implementations. Signed-off-by: Sharon Dvir <sharon.dvir@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/iwl-fw.h')
-rw-r--r--drivers/net/wireless/intel/iwlwifi/iwl-fw.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/iwl-fw.h b/drivers/net/wireless/intel/iwlwifi/iwl-fw.h
index 74ea68d1063c..5f229556339a 100644
--- a/drivers/net/wireless/intel/iwlwifi/iwl-fw.h
+++ b/drivers/net/wireless/intel/iwlwifi/iwl-fw.h
@@ -329,4 +329,13 @@ iwl_fw_dbg_conf_usniffer(const struct iwl_fw *fw, u8 id)
return conf_tlv->usniffer;
}
+static inline const struct fw_img *
+iwl_get_ucode_image(const struct iwl_fw *fw, enum iwl_ucode_type ucode_type)
+{
+ if (ucode_type >= IWL_UCODE_TYPE_MAX)
+ return NULL;
+
+ return &fw->img[ucode_type];
+}
+
#endif /* __iwl_fw_h__ */