Messages in this thread | | | Date | Wed, 29 Mar 2000 00:18:30 +0100 | From | "Stephen C. Tweedie" <> | Subject | Re: Slow pthread_create() under high load |
| |
Hi,
On Tue, Mar 28, 2000 at 10:04:58AM -0800, Jeremy Fitzhardinge wrote: > > Another way of dealing with this is to have local copies of the credentials in > each task, as well as the shared credentials, each with change counter.
Eeek. That still leaves the possibility that a setreuid() will leave other threads still processing data with the old uid, which probably violates posix. It's also an incredibly ugly solution. Just signal each task from in user space to force them to change local uid, and you don't need any kernel help whatsoever.
Remember, for things like file server tasks, you _want_ separate credentials for each thread, so that individual threads can serve data to different uids safely. Putting POSIX uid support into the kernel is insane if the functionality isn't performance-critical, since it will add complexity to many fast paths in the kernel.
--Stephen
- 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/
| |