Messages in this thread | | | Date | Wed, 8 Feb 2012 17:20:13 +0100 | From | Oleg Nesterov <> | Subject | Re: [PATCH 6/8] blackfin: Fix possible race on task->mm |
| |
On 02/07, Anton Vorontsov wrote: > > Even when in atomic context, grabbing irqsave variant of tasklist lock > is not enough to protect task->mm from disappearing on SMP machines. > Instead, we have to grab the task lock.
Yes, but afaics there is no reason for write_lock_irqsave(tasklist). read_lock() should be enough.
I know nothing about arch/blackfin/ but in fact this looks simply wrong.
For example. sysrq_showregs_othercpus() does smp_call_function(showacpu) and showacpu() show_stack()->decode_address(). Now suppose that IPI interrupts the task holding read_lock(tasklist).
Mike?
Oleg.
| |