kernel-ark/include/asm-um
Paolo 'Blaisorblade' Giarrusso 1e40cd383c [PATCH] uml: fixes performance regression in activate_mm and thus exec()
Normally, activate_mm() is called from exec(), and thus it used to be a
no-op because we use a completely new "MM context" on the host (for
instance, a new process), and so we didn't need to flush any "TLB entries"
(which for us are the set of memory mappings for the host process from the
virtual "RAM" file).

Kernel threads, instead, are usually handled in a different way.  So, when
for AIO we call use_mm(), things used to break and so Benjamin implemented
activate_mm().  However, that is only needed for AIO, and could slow down
exec() inside UML, so be smart: detect being called for AIO (via
PF_BORROWED_MM) and do the full flush only in that situation.

Comment also the caller so that people won't go breaking UML without
noticing.  I also rely on the caller's locks for testing current->flags.

Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
CC: Benjamin LaHaise <bcrl@kvack.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-09-05 00:06:21 -07:00
..
a.out.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
apic.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
archparam-i386.h [PATCH] uml: s390 preparation, elf.h 2005-05-05 16:36:37 -07:00
archparam-ppc.h [PATCH] uml: s390 preparation, elf.h 2005-05-05 16:36:37 -07:00
archparam-x86_64.h [PATCH] uml: s390 preparation, elf.h 2005-05-05 16:36:37 -07:00
atomic.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
bitops.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
boot.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
bug.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
bugs.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
byteorder.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cache.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cacheflush.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
calling.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
checksum.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cobalt.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
common.lds.S [PATCH] uml: fix oops related to exception table 2005-05-01 08:58:53 -07:00
cpufeature.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cputime.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
current.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
delay.h [PATCH] uml: s390 preparation, delay moved to arch 2005-05-05 16:36:38 -07:00
desc.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
div64.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
dma-mapping.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
dma.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
dwarf2.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
elf-i386.h [PATCH] uml: small fixes left over from rc4 2005-05-20 15:48:17 -07:00
elf-ppc.h [PATCH] uml: s390 preparation, elf.h 2005-05-05 16:36:37 -07:00
elf-x86_64.h [PATCH] uml: small fixes left over from rc4 2005-05-20 15:48:17 -07:00
emergency-restart.h [PATCH] Add emergency_restart() 2005-07-26 14:35:41 -07:00
errno.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
fcntl.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
fixmap.h [PATCH] uml: s390 preparation, elf.h 2005-05-05 16:36:37 -07:00
floppy.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hardirq.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hdreg.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
highmem.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
hw_irq.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ide.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
io.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ioctl.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ioctls.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ipc.h [PATCH] uml: obvious compile fixes for x86-64 Subarch and x86 regression fixes 2005-05-05 16:36:32 -07:00
ipcbuf.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
irq_vectors.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
irq.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
keyboard.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kmap_types.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ldt.h [PATCH] uml: consolidate modify_ldt 2005-07-14 09:00:24 -07:00
linkage.h [PATCH] uml: s390 preparation, linkage.h inherited from host 2005-05-05 16:36:38 -07:00
local.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
locks.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mca_dma.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mman.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mmu_context.h [PATCH] uml: fixes performance regression in activate_mm and thus exec() 2005-09-05 00:06:21 -07:00
mmu.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
module-generic.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
module-i386.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
module-x86_64.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
msgbuf.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
mtrr.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
namei.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
page_offset.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
page.h [PATCH] mm: consolidate get_order 2005-09-05 00:05:39 -07:00
param.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
pci.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
pda.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
percpu.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
pgalloc.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
pgtable-2level.h [PATCH] freepgt: arch FIRST_USER_ADDRESS 0 2005-04-19 13:29:23 -07:00
pgtable-3level.h [PATCH] uml: obvious compile fixes for x86-64 Subarch and x86 regression fixes 2005-05-05 16:36:32 -07:00
pgtable.h [PATCH] mm: correct _PAGE_FILE comment 2005-09-05 00:05:45 -07:00
poll.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
posix_types.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
prctl.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
processor-generic.h [PATCH] uml: S390 preparation, abstract host page fault data 2005-05-05 16:36:36 -07:00
processor-i386.h [PATCH] uml: S390 preparation, abstract host page fault data 2005-05-05 16:36:36 -07:00
processor-ppc.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
processor-x86_64.h [PATCH] uml: S390 preparation, abstract host page fault data 2005-05-05 16:36:36 -07:00
ptrace-generic.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ptrace-i386.h [PATCH] uml: add profile_pc for i386 2005-06-25 16:24:36 -07:00
ptrace-x86_64.h [AUDIT] Update UML audit-syscall-{entry,exit} calls to new prototypes 2005-05-03 07:54:51 +01:00
resource.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
rwlock.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
rwsem.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
scatterlist.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sections.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
segment.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
semaphore.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sembuf.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
serial.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
setup.h [PATCH] uml: command line handling cleanup 2005-05-06 22:09:29 -07:00
shmbuf.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
shmparam.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sigcontext-generic.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sigcontext-i386.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sigcontext-ppc.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sigcontext-x86_64.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
siginfo.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
signal.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
smp.h [PATCH] smp_processor_id() cleanup 2005-06-21 18:46:13 -07:00
socket.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
sockios.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
spinlock.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
stat.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
statfs.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
string.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
suspend.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
system-generic.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
system-i386.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
system-ppc.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
system-x86_64.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
termbits.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
termios.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
thread_info.h [PATCH] streamline preempt_count type across archs 2005-06-23 09:45:19 -07:00
timex.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
tlb.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
tlbflush.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
topology.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
types.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
uaccess.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
ucontext.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
unaligned.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
unistd.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
user.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
vga.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
vm86.h [PATCH] uml: vm86 compile fix 2005-07-28 21:46:03 -07:00
vm-flags-i386.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
vm-flags-x86_64.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
xor.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00