diff options
author | Kees Cook <keescook@chromium.org> | 2017-10-17 02:25:12 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-10-18 16:52:39 +0300 |
commit | f8af6a323368dd28fcea9742d582593c9adb2261 (patch) | |
tree | 9dc5a708a3fbda8ffb58c37e45a537269bc5e789 /drivers/staging/rtlwifi/phydm | |
parent | 682455befdc549bee146502d541a9a0c63f298de (diff) | |
download | linux-f8af6a323368dd28fcea9742d582593c9adb2261.tar.xz |
staging: rtlwifi: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to
all timer callbacks, switch to using the new timer_setup() and from_timer()
to pass the timer pointer explicitly. Also drops unused odm timer code.
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Kalle Valo <kvalo@codeaurora.org>
Cc: Ping-Ke Shih <pkshih@realtek.com>
Cc: shaofu <shaofu@realtek.com>
Cc: devel@driverdev.osuosl.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtlwifi/phydm')
-rw-r--r-- | drivers/staging/rtlwifi/phydm/phydm_interface.c | 23 | ||||
-rw-r--r-- | drivers/staging/rtlwifi/phydm/phydm_interface.h | 11 |
2 files changed, 0 insertions, 34 deletions
diff --git a/drivers/staging/rtlwifi/phydm/phydm_interface.c b/drivers/staging/rtlwifi/phydm/phydm_interface.c index 102576a46c04..2f9bf6708c54 100644 --- a/drivers/staging/rtlwifi/phydm/phydm_interface.c +++ b/drivers/staging/rtlwifi/phydm/phydm_interface.c @@ -179,29 +179,6 @@ void ODM_sleep_ms(u32 ms) { msleep(ms); } void ODM_sleep_us(u32 us) { usleep_range(us, us + 1); } -void odm_set_timer(struct phy_dm_struct *dm, struct timer_list *timer, - u32 ms_delay) -{ - mod_timer(timer, jiffies + msecs_to_jiffies(ms_delay)); -} - -void odm_initialize_timer(struct phy_dm_struct *dm, struct timer_list *timer, - void *call_back_func, void *context, - const char *sz_id) -{ - init_timer(timer); - timer->function = call_back_func; - timer->data = (unsigned long)dm; - /*mod_timer(timer, jiffies+RTL_MILISECONDS_TO_JIFFIES(10)); */ -} - -void odm_cancel_timer(struct phy_dm_struct *dm, struct timer_list *timer) -{ - del_timer(timer); -} - -void odm_release_timer(struct phy_dm_struct *dm, struct timer_list *timer) {} - static u8 phydm_trans_h2c_id(struct phy_dm_struct *dm, u8 phydm_h2c_id) { u8 platform_h2c_id = phydm_h2c_id; diff --git a/drivers/staging/rtlwifi/phydm/phydm_interface.h b/drivers/staging/rtlwifi/phydm/phydm_interface.h index d315c79c962a..53ba5585bf33 100644 --- a/drivers/staging/rtlwifi/phydm/phydm_interface.h +++ b/drivers/staging/rtlwifi/phydm/phydm_interface.h @@ -172,17 +172,6 @@ void ODM_sleep_ms(u32 ms); void ODM_sleep_us(u32 us); -void odm_set_timer(struct phy_dm_struct *dm, struct timer_list *timer, - u32 ms_delay); - -void odm_initialize_timer(struct phy_dm_struct *dm, struct timer_list *timer, - void *call_back_func, void *context, - const char *sz_id); - -void odm_cancel_timer(struct phy_dm_struct *dm, struct timer_list *timer); - -void odm_release_timer(struct phy_dm_struct *dm, struct timer_list *timer); - /* * ODM FW relative API. */ |