[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1247850069.6522.91.camel@laptop>
Date:	Fri, 17 Jul 2009 19:01:09 +0200
From:	Peter Zijlstra <a.p.zijlstra@...llo.nl>
To:	Catalin Marinas <catalin.marinas@....com>
Cc:	Ingo Molnar <mingo@...e.hu>,
	"Paul E. McKenney" <paulmck@...ibm.com>,
	linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH] kmemleak: Scan all thread stacks
On Fri, 2009-07-17 at 17:57 +0100, Catalin Marinas wrote:
> On Fri, 2009-07-17 at 18:43 +0200, Ingo Molnar wrote:
> > * Catalin Marinas <catalin.marinas@....com> wrote:
> > > 2. Is it safe to use rcu_read_lock() and task_lock() when scanning the
> > >    corresponding kernel stack (thread_info structure)? The loop doesn't
> > >    do any modification to the task list. The reason for this is to
> > >    allow kernel preemption when scanning the stacks.
> > 
> > you cannot generally preempt while holding the RCU read-lock.
> 
> This may work with rcupreempt enabled. But, with classic RCU is it safe
> to call schedule (or cond_resched) while holding the RCU read-lock?
No.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/
Powered by blists - more mailing lists
 
