]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/net/wireless/intel/iwlwifi/iwl-trans.h
Merge remote-tracking branch 'block/for-next'
[karo-tx-linux.git] / drivers / net / wireless / intel / iwlwifi / iwl-trans.h
index 82fb3a97a46d3f6a165a5623d4a5be83883b092e..0ca0f13b69b0fa66e4d7ee13ed1f4c301bb2a1f6 100644 (file)
@@ -506,7 +506,7 @@ struct iwl_trans_config {
        bool sw_csum_tx;
        const struct iwl_hcmd_arr *command_groups;
        int command_groups_size;
+
        u32 sdio_adma_addr;
 };
 
@@ -618,9 +618,9 @@ struct iwl_trans_ops {
        void (*fw_alive)(struct iwl_trans *trans, u32 scd_addr);
        void (*stop_device)(struct iwl_trans *trans, bool low_power);
 
-       void (*d3_suspend)(struct iwl_trans *trans, bool test);
+       void (*d3_suspend)(struct iwl_trans *trans, bool test, bool reset);
        int (*d3_resume)(struct iwl_trans *trans, enum iwl_d3_status *status,
-                        bool test);
+                        bool test, bool reset);
 
        int (*send_cmd)(struct iwl_trans *trans, struct iwl_host_cmd *cmd);
 
@@ -736,6 +736,11 @@ enum iwl_plat_pm_mode {
        IWL_PLAT_PM_MODE_D0I3,
 };
 
+/* Max time to wait for trans to become idle/non-idle on d0i3
+ * enter/exit (in msecs).
+ */
+#define IWL_TRANS_IDLE_TIMEOUT 2000
+
 /**
  * struct iwl_trans - transport common data
  *
@@ -920,22 +925,23 @@ static inline void iwl_trans_stop_device(struct iwl_trans *trans)
        _iwl_trans_stop_device(trans, true);
 }
 
-static inline void iwl_trans_d3_suspend(struct iwl_trans *trans, bool test)
+static inline void iwl_trans_d3_suspend(struct iwl_trans *trans, bool test,
+                                       bool reset)
 {
        might_sleep();
        if (trans->ops->d3_suspend)
-               trans->ops->d3_suspend(trans, test);
+               trans->ops->d3_suspend(trans, test, reset);
 }
 
 static inline int iwl_trans_d3_resume(struct iwl_trans *trans,
                                      enum iwl_d3_status *status,
-                                     bool test)
+                                     bool test, bool reset)
 {
        might_sleep();
        if (!trans->ops->d3_resume)
                return 0;
 
-       return trans->ops->d3_resume(trans, status, test);
+       return trans->ops->d3_resume(trans, status, test, reset);
 }
 
 static inline void iwl_trans_ref(struct iwl_trans *trans)