ARM11MPcore: tlb_ops_need_broadcast causes deadlock

Peter Waechtler pwaechtler at mac.com
Sun Mar 25 14:22:05 EDT 2012


On 25.03.2012 15:09, Russell King - ARM Linux wrote:
> On Sun, Mar 25, 2012 at 12:08:47PM +0000, Peter Waechtler wrote:
>> But Will, is that tlb_flush necessary at all? The ARM has only 3 permission
>> bits in the page table (APX and AP0 and AP1). The young/accessed bit is done
>> via software.
> Yes it most definitely is, because setting a page to be young means we
> must receive a subsequent fault to make it 'old' again.  This means we
> must set the page to be inaccessible to get that fault, and flush the
> TLBs across all CPUs so that any CPU accessing that page receives a
> fault.
Ok I see, it's also not the "right or perfect" fix.

But the worst thing that can happen is:

young page: causes no page fault anymore and stays longer young than
kswapd wants in case a TLB has a stale entry but that access would have
marked it young again - no big deal?

old page: causes a page fault so that it can be made young, a stale TLB
would cause still a page fault - but in that path the tlb_flush still 
happens

 From my point of view: I definitively prefer to avoid the deadlock ;)

I'm afraid that I missed something? I hope not :)

     Peter




More information about the linux-arm-kernel mailing list