android_kernel_xiaomi_sm8350/arch/powerpc/mm
Benjamin Herrenschmidt c5cf0e30bf [PATCH] powerpc: Fix buglet with MMU hash management
Our MMU hash management code would not set the "C" bit (changed bit) in
the hardware PTE when updating a RO PTE into a RW PTE. That would cause
the hardware to possibly to a write back to the hash table to set it on
the first store access, which in addition to being a performance issue,
might also hit a bug when running with native hash management (non-HV)
as our code is specifically optimized for the case where no write back
happens.

Thus there is a very small therocial window were a hash PTE can become
corrupted if that HPTE has just been upgraded to read write, a store
access happens on it, and that races with another processor evicting
that same slot. Since eviction (caused by an almost full hash) is
extremely rare, the bug is very unlikely to happen fortunately.

This fixes by allowing the updating of the protection bits in the native
hash handling to also set (but not clear) the "C" bit, and, in order to
also improve performances in the general case, by always setting that
bit on newly inserted hash PTE so that writeback really never happens.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-06-09 21:20:59 +10:00
..
4xx_mmu.c [PATCH] mm: powerpc init_mm without ptlock 2005-11-23 16:08:38 -08:00
44x_mmu.c
fault.c [PATCH] powerpc: trivial spelling fixes in fault.c 2006-04-01 22:37:13 +11:00
fsl_booke_mmu.c
hash_low_32.S [PATCH] powerpc: trivial: modify comments to refer to new location of files 2006-02-10 16:53:51 +11:00
hash_low_64.S [PATCH] powerpc: Fix buglet with MMU hash management 2006-06-09 21:20:59 +10:00
hash_native_64.c [PATCH] powerpc: Fix buglet with MMU hash management 2006-06-09 21:20:59 +10:00
hash_utils_64.c [PATCH] powerpc: Quiet page order output 2006-04-22 18:45:09 +10:00
hugetlbpage.c [PATCH] powerpc: Fix pagetable bloat for hugepages 2006-04-28 15:02:51 +10:00
imalloc.c [PATCH] sem2mutex: misc static one-file mutexes 2006-03-26 08:56:55 -08:00
init_32.c [PATCH] remove set_page_count() outside mm/ 2006-03-22 07:54:02 -08:00
init_64.c [PATCH] powerpc: Fix pagetable bloat for hugepages 2006-04-28 15:02:51 +10:00
lmb.c [PATCH] powerpc: Unify mem= handling 2006-05-19 15:02:15 +10:00
Makefile
mem.c [PATCH] powerpc: Less verbose mem configuration output 2006-04-22 18:45:12 +10:00
mmap.c [PATCH] powerpc: trivial: modify comments to refer to new location of files 2006-02-10 16:53:51 +11:00
mmu_context_32.c
mmu_context_64.c
mmu_decl.h
numa.c Merge ../linux-2.6 2006-05-05 15:45:48 +10:00
pgtable_32.c [PATCH] lock PTE before updating it in 440/BookE page fault handler 2006-03-29 13:44:15 +11:00
pgtable_64.c [PATCH] powerpc: IOMMU: don't ioremap null addresses 2006-01-10 15:30:31 +11:00
ppc_mmu_32.c
slb_low.S [PATCH] powerpc: trivial: modify comments to refer to new location of files 2006-02-10 16:53:51 +11:00
slb.c [PATCH] powerpc: Replace VMALLOCBASE with VMALLOC_START 2006-01-09 15:05:47 +11:00
stab.c [PATCH] for_each_possible_cpu: powerpc 2006-03-29 13:44:15 +11:00
tlb_32.c
tlb_64.c [PATCH] powerpc: trivial: modify comments to refer to new location of files 2006-02-10 16:53:51 +11:00