Lines Matching refs:fwrt
91 static inline void iwl_fw_free_dump_desc(struct iwl_fw_runtime *fwrt) in iwl_fw_free_dump_desc() argument
93 if (fwrt->dump.desc != &iwl_dump_desc_assert) in iwl_fw_free_dump_desc()
94 kfree(fwrt->dump.desc); in iwl_fw_free_dump_desc()
95 fwrt->dump.desc = NULL; in iwl_fw_free_dump_desc()
96 fwrt->dump.trig = NULL; in iwl_fw_free_dump_desc()
99 void iwl_fw_error_dump(struct iwl_fw_runtime *fwrt);
100 int iwl_fw_dbg_collect_desc(struct iwl_fw_runtime *fwrt,
103 int iwl_fw_dbg_collect(struct iwl_fw_runtime *fwrt,
107 int iwl_fw_dbg_collect_trig(struct iwl_fw_runtime *fwrt,
110 int iwl_fw_start_dbg_conf(struct iwl_fw_runtime *fwrt, u8 id);
140 iwl_fw_dbg_trigger_stop_conf_match(struct iwl_fw_runtime *fwrt, in iwl_fw_dbg_trigger_stop_conf_match() argument
144 (fwrt->dump.conf == FW_DBG_INVALID || in iwl_fw_dbg_trigger_stop_conf_match()
145 (BIT(fwrt->dump.conf) & le32_to_cpu(trig->stop_conf_ids)))); in iwl_fw_dbg_trigger_stop_conf_match()
149 iwl_fw_dbg_no_trig_window(struct iwl_fw_runtime *fwrt, in iwl_fw_dbg_no_trig_window() argument
157 if (fwrt->dump.non_collect_ts_start[id] && in iwl_fw_dbg_no_trig_window()
158 (time_after(fwrt->dump.non_collect_ts_start[id] + wind_jiff, in iwl_fw_dbg_no_trig_window()
162 fwrt->dump.non_collect_ts_start[id] = jiffies; in iwl_fw_dbg_no_trig_window()
167 iwl_fw_dbg_trigger_check_stop(struct iwl_fw_runtime *fwrt, in iwl_fw_dbg_trigger_check_stop() argument
174 if (iwl_fw_dbg_no_trig_window(fwrt, trig)) { in iwl_fw_dbg_trigger_check_stop()
175 IWL_WARN(fwrt, "Trigger %d occurred while no-collect window.\n", in iwl_fw_dbg_trigger_check_stop()
180 return iwl_fw_dbg_trigger_stop_conf_match(fwrt, trig); in iwl_fw_dbg_trigger_check_stop()
184 _iwl_fw_dbg_trigger_simple_stop(struct iwl_fw_runtime *fwrt, in _iwl_fw_dbg_trigger_simple_stop() argument
191 if (!iwl_fw_dbg_trigger_check_stop(fwrt, wdev, trigger)) in _iwl_fw_dbg_trigger_simple_stop()
194 iwl_fw_dbg_collect_trig(fwrt, trigger, NULL); in _iwl_fw_dbg_trigger_simple_stop()
197 #define iwl_fw_dbg_trigger_simple_stop(fwrt, wdev, trig) \ argument
198 _iwl_fw_dbg_trigger_simple_stop((fwrt), (wdev), \
199 iwl_fw_dbg_get_trigger((fwrt)->fw,\
202 static inline void iwl_fw_dbg_stop_recording(struct iwl_fw_runtime *fwrt) in iwl_fw_dbg_stop_recording() argument
204 if (fwrt->trans->cfg->device_family == IWL_DEVICE_FAMILY_7000) { in iwl_fw_dbg_stop_recording()
205 iwl_set_bits_prph(fwrt->trans, MON_BUFF_SAMPLE_CTL, 0x100); in iwl_fw_dbg_stop_recording()
207 iwl_write_prph(fwrt->trans, DBGC_IN_SAMPLE, 0); in iwl_fw_dbg_stop_recording()
209 iwl_write_prph(fwrt->trans, DBGC_OUT_CTRL, 0); in iwl_fw_dbg_stop_recording()
213 static inline void iwl_fw_dump_conf_clear(struct iwl_fw_runtime *fwrt) in iwl_fw_dump_conf_clear() argument
215 fwrt->dump.conf = FW_DBG_INVALID; in iwl_fw_dump_conf_clear()
220 static inline void iwl_fw_flush_dump(struct iwl_fw_runtime *fwrt) in iwl_fw_flush_dump() argument
222 flush_delayed_work(&fwrt->dump.wk); in iwl_fw_flush_dump()
225 static inline void iwl_fw_cancel_dump(struct iwl_fw_runtime *fwrt) in iwl_fw_cancel_dump() argument
227 cancel_delayed_work_sync(&fwrt->dump.wk); in iwl_fw_cancel_dump()
231 static inline void iwl_fw_cancel_timestamp(struct iwl_fw_runtime *fwrt) in iwl_fw_cancel_timestamp() argument
233 fwrt->timestamp.delay = 0; in iwl_fw_cancel_timestamp()
234 cancel_delayed_work_sync(&fwrt->timestamp.wk); in iwl_fw_cancel_timestamp()
237 void iwl_fw_trigger_timestamp(struct iwl_fw_runtime *fwrt, u32 delay);
239 static inline void iwl_fw_suspend_timestamp(struct iwl_fw_runtime *fwrt) in iwl_fw_suspend_timestamp() argument
241 cancel_delayed_work_sync(&fwrt->timestamp.wk); in iwl_fw_suspend_timestamp()
244 static inline void iwl_fw_resume_timestamp(struct iwl_fw_runtime *fwrt) in iwl_fw_resume_timestamp() argument
246 if (!fwrt->timestamp.delay) in iwl_fw_resume_timestamp()
249 schedule_delayed_work(&fwrt->timestamp.wk, in iwl_fw_resume_timestamp()
250 round_jiffies_relative(fwrt->timestamp.delay)); in iwl_fw_resume_timestamp()
255 static inline void iwl_fw_cancel_timestamp(struct iwl_fw_runtime *fwrt) {} in iwl_fw_cancel_timestamp() argument
257 static inline void iwl_fw_trigger_timestamp(struct iwl_fw_runtime *fwrt, in iwl_fw_trigger_timestamp() argument
260 static inline void iwl_fw_suspend_timestamp(struct iwl_fw_runtime *fwrt) {} in iwl_fw_suspend_timestamp() argument
262 static inline void iwl_fw_resume_timestamp(struct iwl_fw_runtime *fwrt) {} in iwl_fw_resume_timestamp() argument