Re: Prevent race in single_thread_set()

2020-12-01 Thread Claudio Jeker
On Tue, Dec 01, 2020 at 10:27:15AM -0300, Martin Pieuchot wrote: > On 01/12/20(Tue) 10:21, Claudio Jeker wrote: > > On Mon, Nov 30, 2020 at 07:19:28PM -0300, Martin Pieuchot wrote: > > > On 04/11/20(Wed) 11:19, Martin Pieuchot wrote: > > > > Here's a 3rd approach to solve the TOCTOU race in

Re: Prevent race in single_thread_set()

2020-12-01 Thread Martin Pieuchot
On 01/12/20(Tue) 10:21, Claudio Jeker wrote: > On Mon, Nov 30, 2020 at 07:19:28PM -0300, Martin Pieuchot wrote: > > On 04/11/20(Wed) 11:19, Martin Pieuchot wrote: > > > Here's a 3rd approach to solve the TOCTOU race in single_thread_set(). > > > The issue being that the lock serializing access to

Re: Prevent race in single_thread_set()

2020-12-01 Thread Claudio Jeker
On Mon, Nov 30, 2020 at 07:19:28PM -0300, Martin Pieuchot wrote: > On 04/11/20(Wed) 11:19, Martin Pieuchot wrote: > > Here's a 3rd approach to solve the TOCTOU race in single_thread_set(). > > The issue being that the lock serializing access to `ps_single' is not > > held when calling

Re: Prevent race in single_thread_set()

2020-11-30 Thread Martin Pieuchot
On 04/11/20(Wed) 11:19, Martin Pieuchot wrote: > Here's a 3rd approach to solve the TOCTOU race in single_thread_set(). > The issue being that the lock serializing access to `ps_single' is not > held when calling single_thread_check(). > > The approach below is controversial because it extends

Prevent race in single_thread_set()

2020-11-04 Thread Martin Pieuchot
Here's a 3rd approach to solve the TOCTOU race in single_thread_set(). The issue being that the lock serializing access to `ps_single' is not held when calling single_thread_check(). The approach below is controversial because it extends the scope of the SCHED_LOCK(). On the other hand, the two