Skip to content

Fix COW D-cache aliasing on fork

Ralf Baechle linux-arch lkml 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4Fix COW D-cache aliasing on forkinclude/linux/highmem.h+4 -00 replies
2/4Pass vma argument to copy_user_highpage().include/linux/highmem.h mm/hugetlb.c mm/memory.c+10 -90 replies
3/4MIPS: Fix COW D-cache aliasing on forkarch/mips/mm/init.c include/asm-mips/page.h+31 -100 replies
4/4Optimize D-cache alias handling on forkDocumentation/cachetlb.txt include/asm-alpha/cacheflush.h include/asm-arm/cacheflush.h +24 more+54 -70 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] Fix COW D-cache aliasing on fork

This is a respin of the patch series I posted a while ago updated for today's kernel:

o patch 1/4 allows an architecture to override the generic copy_user_highpage with an architecture specific implementation. For details about the aliasing issue please see the log message of that patch.
o patch 2/4 passes a vma argument to copy_user_highpage. This allows an architecture to optimize its cache handling by looking at the vma's VM_EXEC flag. On architecture that do not make use of this gcc will be able to optimize the argument passing away, so no overhead.
o patch 3/4 uses the facilities of the first two patches to solve the alias issue for MIPS
o patch 4/4 is not a cache alias fix but allows optimizing away the cache flush operation in dup_mm(). On a MIPS 34K this accelerates fork by 12.5%.
Since this patch is logically separate from 1-3 it can be applied independantly.

Ralf