Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-21 Thread Chirag Jog
Hi Benjamin * Benjamin Herrenschmidt <[EMAIL PROTECTED]> [2008-07-19 08:05:30]: > > > With the original patch, the pending batch does get flushed > > in a non-preemptable region. > > I am resending the original with just adding the necesary comments. > > Your comment isn't what I meant. What

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-18 Thread Benjamin Herrenschmidt
> There's lots of semantics that are changed with -rt that should make > everything still work ;-) Some spinlocks remain real spinlocks, but we > shouldn't have a problem with most being mutexes. > > There's some cases that uses per CPU variables or other per cpu actions > that require a special

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-18 Thread Steven Rostedt
On Sat, 19 Jul 2008, Benjamin Herrenschmidt wrote: > > > With the original patch, the pending batch does get flushed > > in a non-preemptable region. > > I am resending the original with just adding the necesary comments. > > Your comment isn't what I meant. What I meant is that if the process > i

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-18 Thread Benjamin Herrenschmidt
> With the original patch, the pending batch does get flushed > in a non-preemptable region. > I am resending the original with just adding the necesary comments. Your comment isn't what I meant. What I meant is that if the process is context switched while walking the page tables, the low leve

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-18 Thread Chirag Jog
* Benjamin Herrenschmidt <[EMAIL PROTECTED]> [2008-07-18 06:14:31]: > > > All these operations are done assuming that tlb_gather_mmu disables > > preemption and tlb_finish_mmu enables preemption again. > > This is not true for -rt. > > For x86, none of the code paths between tlb_gather_mmu and >

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-17 Thread Benjamin Herrenschmidt
> All these operations are done assuming that tlb_gather_mmu disables > preemption and tlb_finish_mmu enables preemption again. > This is not true for -rt. > For x86, none of the code paths between tlb_gather_mmu and > tlb_finish_mmu access any per_cpu variables. > But this is not true for powerpc

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-17 Thread Chirag Jog
Hi Benjamin, Thanks for the review * Benjamin Herrenschmidt <[EMAIL PROTECTED]> [2008-07-15 11:32:01]: > On Wed, 2008-07-09 at 21:35 +0530, Chirag Jog wrote: > > Hi, > > This patch fixes various paths in the -rt kernel on powerpc64 where per_cpu > > variables are accessed in a preempt unsafe wa

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-14 Thread Benjamin Herrenschmidt
On Wed, 2008-07-09 at 21:35 +0530, Chirag Jog wrote: > Hi, > This patch fixes various paths in the -rt kernel on powerpc64 where per_cpu > variables are accessed in a preempt unsafe way. > When a power box with -rt kernel is booted, multiple BUG messages are > generated "BUG: init:1 task might have

Re: [PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-11 Thread Sebastien Dugue
Hi Chirag, On Wed, 9 Jul 2008 21:35:43 +0530 Chirag Jog <[EMAIL PROTECTED]> wrote: > > Hi, > This patch fixes various paths in the -rt kernel on powerpc64 where per_cpu > variables are accessed in a preempt unsafe way. > When a power box with -rt kernel is booted, multiple BUG messages are >

[PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-09 Thread Chirag Jog
Hi, This patch fixes various paths in the -rt kernel on powerpc64 where per_cpu variables are accessed in a preempt unsafe way. When a power box with -rt kernel is booted, multiple BUG messages are generated "BUG: init:1 task might have lost a preemption check!". After booting a kernel with these

[PATCH][RT][PPC64] Fix preempt unsafe paths accessing per_cpu variables

2008-07-09 Thread Chirag Jog
Hi, This patch fixes various paths in the -rt kernel on powerpc64 where per_cpu variables are accessed in a preempt unsafe way. When a power box with -rt kernel is booted, multiple BUG messages are generated "BUG: init:1 task might have lost a preemption check!". After booting a kernel with these