]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
iwlwifi: yoyo: remove unnecessary active triggers status flag
authorLuca Coelho <luciano.coelho@intel.com>
Mon, 28 Oct 2019 10:39:10 +0000 (12:39 +0200)
committerLuca Coelho <luciano.coelho@intel.com>
Sat, 4 Jan 2020 10:41:55 +0000 (12:41 +0200)
Now that we can't change the domain at runtime anymore, we don't have
to protect the active trigger status.  Remove it.  Additionally, we
don't need to flush the dumps at this point anymore, since this only
runs during initialization and there shouldn't be any dumps running.

Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/fw/dbg.c
drivers/net/wireless/intel/iwlwifi/fw/runtime.h
drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c

index c8bc6b9b53a4ac3ef9ee483ad85fc674e5cfd421..09daf0f1f6f877f52e109a997fedf1af334c926c 100644 (file)
@@ -2353,9 +2353,6 @@ int iwl_fw_dbg_ini_collect(struct iwl_fw_runtime *fwrt,
        u32 occur, delay;
        unsigned long idx;
 
-       if (test_bit(STATUS_GEN_ACTIVE_TRIGS, &fwrt->status))
-               return -EBUSY;
-
        if (!iwl_fw_ini_trigger_on(fwrt, trig)) {
                IWL_WARN(fwrt, "WRT: Trigger %d is not active, aborting dump\n",
                         tp_id);
index c24575ff0e54c41743f318bac8d9092043b1be71..1b4bca717e79f5b5a8a4f18ce7eef3177789465f 100644 (file)
@@ -129,14 +129,6 @@ struct iwl_txf_iter_data {
        u8 internal_txf;
 };
 
-/**
- * enum iwl_fw_runtime_status - fw runtime status flags
- * @STATUS_GEN_ACTIVE_TRIGS: generating active trigger list
- */
-enum iwl_fw_runtime_status {
-       STATUS_GEN_ACTIVE_TRIGS,
-};
-
 /**
  * struct iwl_fw_runtime - runtime data for firmware
  * @fw: firmware image
@@ -150,7 +142,6 @@ enum iwl_fw_runtime_status {
  * @smem_cfg: saved firmware SMEM configuration
  * @cur_fw_img: current firmware image, must be maintained by
  *     the driver by calling &iwl_fw_set_current_image()
- * @status: &enum iwl_fw_runtime_status
  * @dump: debug dump data
  */
 struct iwl_fw_runtime {
@@ -171,8 +162,6 @@ struct iwl_fw_runtime {
        /* memory configuration */
        struct iwl_fwrt_shared_mem_cfg smem_cfg;
 
-       unsigned long status;
-
        /* debug */
        struct {
                const struct iwl_fw_dump_desc *desc;
index 79c8c8057c2d6ce38fd0111e05aa8e02b580a462..4acb24f8fc11aac761105878ee867c9aa8776a68 100644 (file)
@@ -891,15 +891,10 @@ static void
 iwl_dbg_tlv_gen_active_trig_list(struct iwl_fw_runtime *fwrt,
                                 struct iwl_dbg_tlv_time_point_data *tp)
 {
-       struct iwl_dbg_tlv_node *node, *tmp;
+       struct iwl_dbg_tlv_node *node;
        struct list_head *trig_list = &tp->trig_list;
        struct list_head *active_trig_list = &tp->active_trig_list;
 
-       list_for_each_entry_safe(node, tmp, active_trig_list, list) {
-               list_del(&node->list);
-               kfree(node);
-       }
-
        list_for_each_entry(node, trig_list, list) {
                struct iwl_ucode_tlv *tlv = &node->tlv;
                struct iwl_fw_ini_trigger_tlv *trig = (void *)tlv->data;
@@ -918,11 +913,6 @@ static int iwl_dbg_tlv_gen_active_trigs(struct iwl_fw_runtime *fwrt,
 {
        int i;
 
-       if (test_and_set_bit(STATUS_GEN_ACTIVE_TRIGS, &fwrt->status))
-               return -EBUSY;
-
-       iwl_fw_flush_dumps(fwrt);
-
        fwrt->trans->dbg.domains_bitmap = new_domain;
 
        IWL_DEBUG_FW(fwrt,
@@ -936,8 +926,6 @@ static int iwl_dbg_tlv_gen_active_trigs(struct iwl_fw_runtime *fwrt,
                iwl_dbg_tlv_gen_active_trig_list(fwrt, tp);
        }
 
-       clear_bit(STATUS_GEN_ACTIVE_TRIGS, &fwrt->status);
-
        return 0;
 }