Re: [PATCH V2 1/1] tick: broadcast-hrtimer: Fix a race in bc_set_next

2019-09-26 Thread Thomas Gleixner
On Wed, 25 Sep 2019, Balasubramani Vivekanandan wrote: > > Since it is now allowed to start the hrtimer from the callback, there is Is now allowed? > no need for the try to cancel logic. All that is now removed. Sure I can see that it is removed from the patch, but why and why is it correct?

[PATCH V2 1/1] tick: broadcast-hrtimer: Fix a race in bc_set_next

2019-09-25 Thread Balasubramani Vivekanandan
When a cpu requests broadcasting, before starting the tick broadcast hrtimer, bc_set_next() checks if the timer callback (bc_handler) is active using hrtimer_try_to_cancel(). But hrtimer_try_to_cancel() does not provide the required synchronization when the callback is active on other core. The cal

[PATCH V2 1/1] tick: broadcast-hrtimer: Fix a race in bc_set_next

2019-09-25 Thread Balasubramani Vivekanandan
Sorry, I missed to fix few checkpatch warnings. Corrected it now

Re: [PATCH V2 1/1] tick: broadcast-hrtimer: Fix a race in bc_set_next

2019-09-25 Thread Balasubramani Vivekanandan
+ Peter Zijlstra, linux-renesas-soc

[PATCH V2 1/1] tick: broadcast-hrtimer: Fix a race in bc_set_next

2019-09-25 Thread Balasubramani Vivekanandan
When a cpu requests broadcasting, before starting the tick broadcast hrtimer, bc_set_next() checks if the timer callback (bc_handler) is active using hrtimer_try_to_cancel(). But hrtimer_try_to_cancel() does not provide the required synchronization when the callback is active on other core. The cal

[PATCH V2 1/1] tick: broadcast-hrtimer: Fix a race in bc_set_next

2019-09-25 Thread Balasubramani Vivekanandan
> Find a completely untested patch below Thanks for the patch. I tested your patch and it is working fine. I do not notice the rcu stall warnings anymore. I have just updated the formatting of brackets. Please check and apply