staging: rtl8192u: r8192U_dm: Replace MSECS with msecs_to_jiffies
authorAmitoj Kaur Chawla <amitoj1606@gmail.com>
Sat, 13 Feb 2016 04:34:16 +0000 (10:04 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 15 Feb 2016 00:38:11 +0000 (16:38 -0800)
Replace driver specific macro MSECS with msecs_to_jiffies().

This was found using the following Coccinelle semantic patch:

//<smpl>
@@
expression e;
@@

- MSECS(e)
+ msecs_to_jiffies(e)
//</smpl>

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8192u/r8192U_dm.c

index 9b58b1afc1d1e371e30b9b67a8849b01c5f177ab..d2e86b9d2c975293d78234162277ee874891c70d 100644 (file)
@@ -2769,12 +2769,14 @@ void dm_fsync_timer_callback(unsigned long data)
                if (bDoubleTimeInterval) {
                        if (timer_pending(&priv->fsync_timer))
                                del_timer_sync(&priv->fsync_timer);
-                       priv->fsync_timer.expires = jiffies + MSECS(priv->ieee80211->fsync_time_interval*priv->ieee80211->fsync_multiple_timeinterval);
+                       priv->fsync_timer.expires = jiffies +
+                               msecs_to_jiffies(priv->ieee80211->fsync_time_interval*priv->ieee80211->fsync_multiple_timeinterval);
                        add_timer(&priv->fsync_timer);
                } else {
                        if (timer_pending(&priv->fsync_timer))
                                del_timer_sync(&priv->fsync_timer);
-                       priv->fsync_timer.expires = jiffies + MSECS(priv->ieee80211->fsync_time_interval);
+                       priv->fsync_timer.expires = jiffies +
+                               msecs_to_jiffies(priv->ieee80211->fsync_time_interval);
                        add_timer(&priv->fsync_timer);
                }
        } else {
@@ -2847,7 +2849,8 @@ static void dm_StartSWFsync(struct net_device *dev)
        }
        if (timer_pending(&priv->fsync_timer))
                del_timer_sync(&priv->fsync_timer);
-       priv->fsync_timer.expires = jiffies + MSECS(priv->ieee80211->fsync_time_interval);
+       priv->fsync_timer.expires = jiffies +
+                       msecs_to_jiffies(priv->ieee80211->fsync_time_interval);
        add_timer(&priv->fsync_timer);
 
        write_nic_dword(dev, rOFDM0_RxDetector2, 0x465c12cd);