Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --- a/drivers/phone_svn/svnet/main.c
- +++ b/drivers/phone_svn/svnet/main.c
- @@ -118,6 +118,7 @@
- wake_lock_init(&sn->wlock, WAKE_LOCK_SUSPEND, "svnet");
- sn->wake_time = DEFAULT_RAW_WAKE_TIME;
- sn->wake_process_time = DEFAULT_FMT_WAKE_TIME;
- + sn->wlock.expires = jiffies;
- }
- static inline void _wake_lock_destroy(struct svnet *sn)
- @@ -127,7 +128,9 @@
- static inline void _wake_lock_timeout(struct svnet *sn)
- {
- - wake_lock_timeout(&sn->wlock, sn->wake_time);
- + long exp_cnt = sn->wlock.expires - jiffies;
- + if (exp_cnt < sn->wake_time)
- + wake_lock_timeout(&sn->wlock, sn->wake_time);
- }
- void _non_fmt_wakelock_timeout( void ) {
- @@ -137,7 +140,9 @@
- static inline void _wake_process_lock_timeout(struct svnet *sn)
- {
- - wake_lock_timeout(&sn->wlock, sn->wake_process_time);
- + long exp_cnt = sn->wlock.expires - jiffies;
- + if (exp_cnt < sn->wake_process_time)
- + wake_lock_timeout(&sn->wlock, sn->wake_process_time);
- }
- void _fmt_wakelock_timeout( void ) {
Advertisement
Add Comment
Please, Sign In to add comment