diff options
| author | Dave Airlie <airlied@redhat.com> | 2018-03-28 14:30:41 +1000 |
|---|---|---|
| committer | Dave Airlie <airlied@redhat.com> | 2018-03-28 14:30:41 +1000 |
| commit | 2b4f44eec2be2688511c2b617d0e1b4f94c45ba4 (patch) | |
| tree | 533c03602f4ae6d6404db6fa56c88e6f83e1bebe /drivers/net/wireless/intel/iwlwifi/fw/debugfs.h | |
| parent | 33d009cd889490838c5db9b9339856c9e3d3facc (diff) | |
| parent | 3eb2ce825ea1ad89d20f7a3b5780df850e4be274 (diff) | |
Backmerge tag 'v4.16-rc7' into drm-next
Linux 4.16-rc7
This was requested by Daniel, and things were getting
a bit hard to reconcile, most of the conflicts were
trivial though.
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/fw/debugfs.h')
| -rw-r--r-- | drivers/net/wireless/intel/iwlwifi/fw/debugfs.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/fw/debugfs.h b/drivers/net/wireless/intel/iwlwifi/fw/debugfs.h index e57ff92a68ae..3da468d2cc92 100644 --- a/drivers/net/wireless/intel/iwlwifi/fw/debugfs.h +++ b/drivers/net/wireless/intel/iwlwifi/fw/debugfs.h @@ -75,6 +75,20 @@ static inline void iwl_fw_cancel_timestamp(struct iwl_fw_runtime *fwrt) cancel_delayed_work_sync(&fwrt->timestamp.wk); } +static inline void iwl_fw_suspend_timestamp(struct iwl_fw_runtime *fwrt) +{ + cancel_delayed_work_sync(&fwrt->timestamp.wk); +} + +static inline void iwl_fw_resume_timestamp(struct iwl_fw_runtime *fwrt) +{ + if (!fwrt->timestamp.delay) + return; + + schedule_delayed_work(&fwrt->timestamp.wk, + round_jiffies_relative(fwrt->timestamp.delay)); +} + #else static inline int iwl_fwrt_dbgfs_register(struct iwl_fw_runtime *fwrt, struct dentry *dbgfs_dir) @@ -84,4 +98,8 @@ static inline int iwl_fwrt_dbgfs_register(struct iwl_fw_runtime *fwrt, static inline void iwl_fw_cancel_timestamp(struct iwl_fw_runtime *fwrt) {} +static inline void iwl_fw_suspend_timestamp(struct iwl_fw_runtime *fwrt) {} + +static inline void iwl_fw_resume_timestamp(struct iwl_fw_runtime *fwrt) {} + #endif /* CONFIG_IWLWIFI_DEBUGFS */ |
