]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
wifi: iwlwifi: convert to use secs_to_jiffies()
authorYuesong Li <liyuesong@vivo.com>
Thu, 12 Jun 2025 02:24:53 +0000 (10:24 +0800)
committerMiri Korenblit <miriam.rachel.korenblit@intel.com>
Wed, 25 Jun 2025 07:57:33 +0000 (10:57 +0300)
Since secs_to_jiffies()(commit:b35108a51cf7) has been introduced, we can
use it to avoid scaling the time to msec.

Signed-off-by: Yuesong Li <liyuesong@vivo.com>
Link: https://patch.msgid.link/20250612022501.3492345-1-liyuesong@vivo.com
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
drivers/net/wireless/intel/iwlwifi/dvm/rx.c
drivers/net/wireless/intel/iwlwifi/fw/debugfs.c

index 5f8b608240438af37547dc4ef0e3459f227d9d26..b34ee68f3dce0bbc343d8245927ab1c444b01bb3 100644 (file)
@@ -429,7 +429,7 @@ static void iwlagn_rx_statistics(struct iwl_priv *priv,
         * thermal update even if the uCode doesn't give
         * us one */
        mod_timer(&priv->statistics_periodic, jiffies +
-                 msecs_to_jiffies(reg_recalib_period * 1000));
+                 secs_to_jiffies(reg_recalib_period));
 
        if (unlikely(!test_bit(STATUS_SCANNING, &priv->status)) &&
            (pkt->hdr.cmd == STATISTICS_NOTIFICATION)) {
index c70f2a20f7d558877eadae00caba259d05daa102..803ba35e75018d29cd14babcb889b055e2b3d00d 100644 (file)
@@ -198,7 +198,7 @@ void iwl_fw_trigger_timestamp(struct iwl_fw_runtime *fwrt, u32 delay)
 
        iwl_fw_cancel_timestamp(fwrt);
 
-       fwrt->timestamp.delay = msecs_to_jiffies(delay * 1000);
+       fwrt->timestamp.delay = secs_to_jiffies(delay);
 
        schedule_delayed_work(&fwrt->timestamp.wk,
                              round_jiffies_relative(fwrt->timestamp.delay));