Lines Matching refs:tlv

65 #include "iwl-dbg-tlv.h"
103 * @tlv: TLV attach to the timer node
109 struct iwl_ucode_tlv *tlv;
121 static int iwl_dbg_tlv_add(struct iwl_ucode_tlv *tlv, struct list_head *list)
123 u32 len = le32_to_cpu(tlv->length);
130 memcpy(&node->tlv, tlv, sizeof(node->tlv) + len);
136 static bool iwl_dbg_tlv_ver_support(struct iwl_ucode_tlv *tlv)
138 struct iwl_fw_ini_header *hdr = (void *)&tlv->data[0];
139 u32 type = le32_to_cpu(tlv->type);
151 struct iwl_ucode_tlv *tlv)
153 struct iwl_fw_ini_debug_info_tlv *debug_info = (void *)tlv->data;
155 if (le32_to_cpu(tlv->length) != sizeof(*debug_info))
161 return iwl_dbg_tlv_add(tlv, &trans->dbg.debug_info_tlv_list);
165 struct iwl_ucode_tlv *tlv)
167 struct iwl_fw_ini_allocation_tlv *alloc = (void *)tlv->data;
171 if (le32_to_cpu(tlv->length) != sizeof(*alloc))
211 struct iwl_ucode_tlv *tlv)
213 struct iwl_fw_ini_hcmd_tlv *hcmd = (void *)tlv->data;
216 if (le32_to_cpu(tlv->length) <= sizeof(*hcmd))
231 return iwl_dbg_tlv_add(tlv, &trans->dbg.time_point[tp].hcmd_list);
235 struct iwl_ucode_tlv *tlv)
237 struct iwl_fw_ini_region_tlv *reg = (void *)tlv->data;
241 u32 tlv_len = sizeof(*tlv) + le32_to_cpu(tlv->length);
243 if (le32_to_cpu(tlv->length) < sizeof(*reg))
270 *active_reg = kmemdup(tlv, tlv_len, GFP_KERNEL);
280 struct iwl_ucode_tlv *tlv)
282 struct iwl_fw_ini_trigger_tlv *trig = (void *)tlv->data;
287 if (le32_to_cpu(tlv->length) < sizeof(*trig))
299 dup = kmemdup(tlv, sizeof(*tlv) + le32_to_cpu(tlv->length),
305 tlv = dup;
308 ret = iwl_dbg_tlv_add(tlv, &trans->dbg.time_point[tp].trig_list);
315 struct iwl_ucode_tlv *tlv) = {
323 void iwl_dbg_tlv_alloc(struct iwl_trans *trans, struct iwl_ucode_tlv *tlv,
326 struct iwl_fw_ini_header *hdr = (void *)&tlv->data[0];
327 u32 type = le32_to_cpu(tlv->type);
347 if (!iwl_dbg_tlv_ver_support(tlv)) {
353 ret = dbg_tlv_alloc[tlv_idx](trans, tlv);
462 struct iwl_ucode_tlv *tlv;
465 while (len >= sizeof(*tlv)) {
466 len -= sizeof(*tlv);
467 tlv = (void *)data;
469 tlv_len = le32_to_cpu(tlv->length);
477 data += sizeof(*tlv) + ALIGN(tlv_len, 4);
479 iwl_dbg_tlv_alloc(trans, tlv, true);
713 struct iwl_fw_ini_hcmd_tlv *hcmd = (void *)node->tlv.data;
715 u16 hcmd_len = le32_to_cpu(node->tlv.length) - sizeof(*hcmd);
731 .trig = (void *)timer_node->tlv->data,
754 struct iwl_fw_ini_trigger_tlv *trig = (void *)node->tlv.data;
765 if (le32_to_cpu(node->tlv.length) <
789 timer_node->tlv = &node->tlv;
833 struct iwl_ucode_tlv *node_tlv = &node->tlv;
875 node_tlv = &tmp->tlv;
922 is_trig_data_contained(trig_tlv, &node->tlv)) {
946 struct iwl_ucode_tlv *tlv = &node->tlv;
948 iwl_dbg_tlv_add_active_trigger(fwrt, active_trig_list, tlv);
991 .trig = (void *)node->tlv.data,
993 u32 num_data = iwl_tlv_array_len(&node->tlv, dump_data.trig,