lkml.org 
[lkml]   [2006]   [Sep]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] move put_task_struct() reaping into a thread [Re: 2.6.18-rt1]
From
On Thu, Sep 21, 2006 at 09:56:33AM +0200, Ingo Molnar wrote:
> * Bill Huey <billh@gnuppy.monkey.org> wrote:
>
> > [...] If the upstream kernel used RCU function in a task allocation or
> > task struct reading in the first place then call_rcu() would be a
> > clear choice. However, I didn't see it used in that way (I could be
> > wrong) [...]
>
> it was RCU-ified briefly but then it was further improved to direct
> freeing, because upstream _can_ free it directly.

Unfortunately, this is a problem with -rt patch and the lock ordering
in this system when you have to call a memory allocator within an atomic
critical section. I fully accept this as part of what goes into making a
kernel preemptive and I'm ok with it. Not many folks know about the
special case locking rules in the -rt kernel so this might be new to
various folks.

If you're looking for validation of this technique from me and an ego
stroking, then you have it from me. :)

Fortunately, it's in a non-critical place so this should *not* be too
much of a problem, but I've already encountered oddies trying to
allocate a pool of entities for populating a free list under an atomic
critical section of some sort for some code I've been writing. This is
a significant problem with kernel coding in -rt, but I can't say what
the general solution is other than making the memory allocators
non-preemptible by reverting the locks back to raw spinlocks, etc...
using lock-break, who knows. I'm ok with the current scenario, but this
could eventually be a larger problem.

bill

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

\
 
 \ /
  Last update: 2006-09-21 10:17    [W:0.156 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site