android_kernel_xiaomi_sdm845/include
Nick Piggin 21cc199baa mm: introduce get_user_pages_fast
Introduce a new get_user_pages_fast mm API, which is basically a
get_user_pages with a less general API (but still tends to be suited to
the common case):

- task and mm are always current and current->mm
- force is always 0
- pages is always non-NULL
- don't pass back vmas

This restricted API can be implemented in a much more scalable way on many
architectures when the ptes are present, by walking the page tables
locklessly (no mmap_sem or page table locks).  When the ptes are not
populated, get_user_pages_fast() could be slower.

This is implemented locklessly on x86, and used in some key direct IO call
sites, in later patches, which provides nearly 10% performance improvement
on a threaded database workload.

Lots of other code could use this too, depending on use cases (eg.  grep
drivers/).  And it might inspire some new and clever ways to use it.

[akpm@linux-foundation.org: build fix]
[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Nick Piggin <npiggin@suse.de>
Cc: Dave Kleikamp <shaggy@austin.ibm.com>
Cc: Andy Whitcroft <apw@shadowen.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Dave Kleikamp <shaggy@austin.ibm.com>
Cc: Badari Pulavarty <pbadari@us.ibm.com>
Cc: Zach Brown <zach.brown@oracle.com>
Cc: Jens Axboe <jens.axboe@oracle.com>
Reviewed-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26 12:00:05 -07:00
..
acpi Merge branch 'linux-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6 2008-07-16 17:25:46 -07:00
asm-alpha dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-arm dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-avr32 dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-blackfin Merge git://git.infradead.org/~dwmw2/random-2.6 2008-07-25 12:01:37 -07:00
asm-cris dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-frv dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-generic Better interface for hooking early initcalls 2008-07-26 12:00:04 -07:00
asm-h8300 Merge git://git.infradead.org/~dwmw2/random-2.6 2008-07-25 12:01:37 -07:00
asm-ia64 dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-m32r Merge git://git.infradead.org/~dwmw2/random-2.6 2008-07-25 12:01:37 -07:00
asm-m68k dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-m68knommu Merge git://git.infradead.org/~dwmw2/random-2.6 2008-07-25 12:01:37 -07:00
asm-mips dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-mn10300 dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-parisc dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-powerpc dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-s390 Merge git://git.infradead.org/~dwmw2/random-2.6 2008-07-25 12:01:37 -07:00
asm-sh dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-sparc dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
asm-sparc64 remove dummy asm/kvm.h files 2008-07-25 14:35:50 -04:00
asm-um Merge git://git.infradead.org/~dwmw2/random-2.6 2008-07-25 12:01:37 -07:00
asm-v850 remove the v850 port 2008-07-24 10:47:24 -07:00
asm-x86 x86: implement pte_special 2008-07-26 12:00:05 -07:00
asm-xtensa dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
crypto crypto: hash - Move ahash functions into crypto/hash.h 2008-07-10 20:35:18 +08:00
drm drm/radeon: fixup issue with radeon and PAT support. 2008-07-15 15:48:05 +10:00
keys
linux mm: introduce get_user_pages_fast 2008-07-26 12:00:05 -07:00
math-emu
media V4L/DVB (8395): saa7134: Fix Kbuild dependency of ir-kbd-i2c 2008-07-20 07:29:03 -03:00
mtd UBI: fix checkpatch.pl errors and warnings 2008-07-24 13:36:09 +03:00
net Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6 2008-07-25 17:40:16 -07:00
pcmcia pcmcia: (re)move {pcmcia,pccard}_get_status 2008-06-24 15:33:44 +02:00
rdma dma-mapping: add the device argument to dma_mapping_error() 2008-07-26 12:00:03 -07:00
rxrpc
scsi driver core: remove KOBJ_NAME_LEN define 2008-07-21 21:54:52 -07:00
sound ALSA: Release v1.0.17 2008-07-14 09:54:43 +02:00
video include/video/atmel_lcdc.h must #include <linux/workqueue.h> 2008-07-26 12:00:01 -07:00
xen xen: implement Xen-specific spinlocks 2008-07-16 11:15:53 +02:00
Kbuild drm: reorganise drm tree to be more future proof. 2008-07-14 10:45:01 +10:00