WSL2-Linux-Kernel/arch/m32r/mm
Russell King 4b3073e1c5 MM: Pass a PTE pointer to update_mmu_cache() rather than the PTE itself
On VIVT ARM, when we have multiple shared mappings of the same file
in the same MM, we need to ensure that we have coherency across all
copies.  We do this via make_coherent() by making the pages
uncacheable.

This used to work fine, until we allowed highmem with highpte - we
now have a page table which is mapped as required, and is not available
for modification via update_mmu_cache().

Ralf Beache suggested getting rid of the PTE value passed to
update_mmu_cache():

  On MIPS update_mmu_cache() calls __update_tlb() which walks pagetables
  to construct a pointer to the pte again.  Passing a pte_t * is much
  more elegant.  Maybe we might even replace the pte argument with the
  pte_t?

Ben Herrenschmidt would also like the pte pointer for PowerPC:

  Passing the ptep in there is exactly what I want.  I want that
  -instead- of the PTE value, because I have issue on some ppc cases,
  for I$/D$ coherency, where set_pte_at() may decide to mask out the
  _PAGE_EXEC.

So, pass in the mapped page table pointer into update_mmu_cache(), and
remove the PTE value, updating all implementations and call sites to
suit.

Includes a fix from Stephen Rothwell:

  sparc: fix fallout from update_mmu_cache API change

  Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>

Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-20 16:41:46 +00:00
..
Makefile Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cache.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
discontig.c m32r: Fix set_memory() for DISCONTIGMEM 2009-10-04 12:02:36 +09:00
extable.c [PATCH] m32r: Cleanup arch/m32r/mm/extable.c 2005-06-21 19:07:31 -07:00
fault-nommu.c MM: Pass a PTE pointer to update_mmu_cache() rather than the PTE itself 2010-02-20 16:41:46 +00:00
fault.c MM: Pass a PTE pointer to update_mmu_cache() rather than the PTE itself 2010-02-20 16:41:46 +00:00
init.c arches: drop superfluous casts in nr_free_pages() callers 2009-09-22 07:17:34 -07:00
ioremap-nommu.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ioremap.c [PATCH] Generic ioremap_page_range: m32r conversion 2006-10-01 00:39:31 -07:00
mmu.S m32r: fix tme_handler 2009-10-04 12:02:35 +09:00
page.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00