Re: [PATCH] 15/18 better pte invalidation

From: Paul Mackerras (paulus@samba.org)
Date: Sat Aug 10 2002 - 07:28:50 EST


Arnd Bergmann writes:

> 2) s/390 has an instruction called ipte (invalidate page table entry) that
> is used to get rid of virtual pages. It does two things, first it set
> the invalid bit in the pte and second it flushes the tlbs for this
> page on all cpus. Very handy but it requires that the pte it should
> flush is still valid. The introduction of establish_pte was a step
> into the right direction but it is defined in mm/memory.c. We need
> to be able to replace this function with a special s/390 variant.

It's now possible in 2.5 to go from a PTE pointer to the mm and
virtual address that it maps - see ptep_to_mm and ptep_to_address in
include/asm-generic/rmap.h. I'm planning to use this to do MMU
hashtable management on PPC in set_pte et al. and thus avoid the
second walk of the Linux page tables that we currently do in
flush_tlb_* on PPC. You could use those functions to let you use the
ipte instruction in set_pte et al. and then make the flush_tlb_*
functions be no-ops.

The ptep_to_mm and ptep_to_address functions came in with rmap, but
all they rely on is having the page->mapping and page->index fields
filled in for pagetable pages. It should only be a minor addition to
the 2.4 MM system to set those fields, and it would be useful on ppc,
ppc64, s390 and s390x.

Paul.
-
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/



This archive was generated by hypermail 2b29 : Thu Aug 15 2002 - 22:00:22 EST