lkml.org 
[lkml]   [1999]   [Nov]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [NEW PATCH] POSIX timers for 2.3.26
Date
From
> > > +		timers = current->posix_timers = itimer_struct_new();
> >
> > What if two threads sharing timers execute this at the same time. I suspect
> > you need to guard this with the tasklist lock perhaps ?
>
> If you have two threads sharing timers the current->posix_timers is
> already initialized in fork.c when the clone_flags has the CLONE_ITIMERS
> bit set.

Good point.

> > Also consider exec and a setuid program getting started with suprise signals
> > pending. I suspect execve needs to kill these timers ?
>
> The timers are not inherited/copied across a fork, so do pending
> signals.

exec not fork. Consider executing a setuid program. I think an exec should
clear the timers ?

> Signal queues cannot be shared between threads. I recall that this is one
> of the remaining incompatibilities of LinuxThreads with POSIX threads.

If you have ideas how to sort the queue sharing btw lots of people want this.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.040 / U:1.408 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site