linux/drivers/infiniband/core
Christoph Lameter bc3e53f682 mm: distinguish between mlocked and pinned pages
Some kernel components pin user space memory (infiniband and perf) (by
increasing the page count) and account that memory as "mlocked".

The difference between mlocking and pinning is:

A. mlocked pages are marked with PG_mlocked and are exempt from
   swapping. Page migration may move them around though.
   They are kept on a special LRU list.

B. Pinned pages cannot be moved because something needs to
   directly access physical memory. They may not be on any
   LRU list.

I recently saw an mlockalled process where mm->locked_vm became
bigger than the virtual size of the process (!) because some
memory was accounted for twice:

Once when the page was mlocked and once when the Infiniband
layer increased the refcount because it needt to pin the RDMA
memory.

This patch introduces a separate counter for pinned pages and
accounts them seperately.

Signed-off-by: Christoph Lameter <cl@linux.com>
Cc: Mike Marciniszyn <infinipath@qlogic.com>
Cc: Roland Dreier <roland@kernel.org>
Cc: Sean Hefty <sean.hefty@intel.com>
Cc: Hugh Dickins <hughd@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-10-31 17:30:46 -07:00
..
addr.c net: Abstract dst->neighbour accesses behind helpers. 2011-07-17 23:11:35 -07:00
agent.c IB/mad: Improve an error message so error code is included 2011-03-18 09:42:20 -07:00
agent.h RDMA: Remove subversion $Id tags 2008-07-14 23:48:44 -07:00
cache.c IB/core: Add GID change event 2011-07-18 21:04:30 -07:00
cm_msgs.h IB: Remove __constant_{endian} uses 2009-01-17 17:11:57 -08:00
cm.c RDMA: Check for NULL mode in .devnode methods 2011-07-04 15:53:28 -07:00
cma.c RDMA/cma: Don't allow IPoIB port space for IBoE 2011-07-18 16:50:25 -07:00
core_priv.h IB/core: Allow device-specific per-port sysfs files 2010-05-21 10:34:44 -07:00
device.c RDMA: Allow for NULL .modify_device() and .modify_port() methods 2011-07-18 16:44:30 -07:00
fmr_pool.c RDMA: Remove subversion $Id tags 2008-07-14 23:48:44 -07:00
iwcm.c RDMA/iwcm: Get rid of enum iw_cm_event_status 2011-05-09 22:23:57 -07:00
iwcm.h
mad_priv.h IB/mad: Allow tuning of QP0 and QP1 sizes 2009-09-07 08:28:48 -07:00
mad_rmpp.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
mad_rmpp.h RDMA: Remove subversion $Id tags 2008-07-14 23:48:44 -07:00
mad.c IB/mad: Return EPROTONOSUPPORT when an RDMA device lacks the QP required 2011-05-23 11:15:48 -07:00
Makefile RDMA: Add netlink infrastructure 2011-05-20 11:46:11 -07:00
multicast.c IB/mad: IBoE supports only QP1 (no QP0) 2010-10-13 09:38:11 -07:00
netlink.c rtnetlink: Compute and store minimum ifinfo dump size 2011-06-09 20:38:07 -07:00
packer.c RDMA: Remove subversion $Id tags 2008-07-14 23:48:44 -07:00
sa_query.c RDMA: Update missed conversion of flush_scheduled_work() 2011-01-28 16:39:08 -08:00
sa.h
smi.c IB/mad: Check hop count field in directed route MAD to avoid array overflow 2009-09-05 20:24:10 -07:00
smi.h IB/mad: Enable loopback of DR SMP responses from userspace 2008-01-25 14:15:25 -08:00
sysfs.c IB/core: Add link layer type information to sysfs 2010-10-25 10:20:39 -07:00
ucm.c IB/ucm: Use memdup_user() 2010-05-25 21:10:57 -07:00
ucma.c Merge branches 'cma', 'cxgb3', 'cxgb4', 'misc', 'nes', 'netlink', 'srp' and 'uverbs' into for-next 2011-05-25 13:47:20 -07:00
ud_header.c IB/pack: Remove some unused code added by the IBoE patches 2010-12-01 16:30:18 -08:00
umem.c mm: distinguish between mlocked and pinned pages 2011-10-31 17:30:46 -07:00
user_mad.c IB: Add devnode methods to cm_class and umad_class 2011-05-23 11:24:28 -07:00
uverbs_cmd.c IB/uverbs: Handle large number of entries in poll CQ 2010-12-08 15:23:49 -08:00
uverbs_main.c RDMA: Check for NULL mode in .devnode methods 2011-07-04 15:53:28 -07:00
uverbs_marshall.c IB: Fix information leak in marshalling code 2010-12-01 16:33:18 -08:00
uverbs.h Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6 2010-03-04 08:15:33 -08:00
verbs.c IB/core: Add link layer property to ports 2010-09-27 17:51:10 -07:00