Re: Linux-2.5.16

Linus Torvalds (torvalds@transmeta.com)
Sun, 19 May 2002 18:25:47 -0700 (PDT)


On Mon, 20 May 2002, Paul Mackerras wrote:
>
> My only comment at this stage is that I would like to have the address
> passed to tlb_remove_page, as it used to be, so that I can find and
> clear the PTEs in the MMU hash table efficiently when the buffer in
> the mmu_gather_t fills up, before freeing the pages.

Sure enough, but you need to keep in mind that x86 (and others) want to
use the generic support even for pages that don't have virtual addresses,
ie the page directories etc. So that argues for splitting up the existing
"tlb_remove_page()" into something like

tlb_remove_tlb_entry(tlb_gather_t *tlb, struct page *page, unsigned long address)
{
tlb_flush_mapping(tlb, page, address);
tlb->freed++;
tlb_remove_page(tlb,page);
}

tlb_remove_page(tlb_gather_t *tlb, tlb)
{
.. add the page to the pages[] array ..
}

where PPC would have the "tlb_flush_mapping()" thing, and something like
x86 or a regular TLB would just define it to be a no-op.

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/