lkml.org 
[lkml]   [2009]   [Nov]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: irq lock inversion
Hello, Ingo.

Ingo Molnar wrote:
> I havent looked deeply but at first sight i'm not 100% sure that even
> the lock dance hack is safe - doesnt vfree() do TLB flushes, which must
> be done with irqs enabled in general? If yes, then the whole notion of
> using the allocator from irqs-off sections is wrong and the flags
> save/restore is misguided (or at least incomplete).

The only place where any v*() call is nested under pcpu_lock is in the
alloc path, specifically pcpu_extend_area_map() ends up calling
vfree(). pcpu_free() path which can be called from irq context never
calls any vmalloc function directly. The reclaiming is deferred to a
work. Breaking the single nesting completely decouples the two locks
and nobody would be calling vfree() with irq disabled, so I don't
think there will be any problem.

Thanks.

--
tejun


\
 
 \ /
  Last update: 2009-11-06 09:27    [W:0.138 / U:0.204 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site