]> sourceware.org Git - lvm2.git/commit
mlockall() -> mlock()
authorZdenek Kabelac <zkabelac@redhat.com>
Fri, 5 Mar 2010 14:48:33 +0000 (14:48 +0000)
committerZdenek Kabelac <zkabelac@redhat.com>
Fri, 5 Mar 2010 14:48:33 +0000 (14:48 +0000)
commit18b82048e457d6ff426d9dd828475d4dd02b8204
tree3c265f7b4471c8a45cfd10d4b8765a77de45eb96
parentdb724a449b8a6325e81d04e835f7e24a35f9e78b
mlockall() -> mlock()

This patch adds a new implementation of locking function instead
of mlockall() that may lock way too much memory (>100MB).
New function instead uses mlock() system call and selectively locks
memory areas from /proc/self/maps trying to avoid locking areas
unused during lock-ed state.

Patch also adds struct cmd_context to all memlock() calls to have
access to configuration.

For backward compatibility functionality of mlockall()
is preserved with "activation/use_mlockall" flag.

As a simple check, locking and unlocking counts the amount of memory
and compares whether values are matching.
WHATS_NEW
doc/example.conf
lib/activate/activate.c
lib/config/defaults.h
lib/locking/locking.c
lib/mm/memlock.c
lib/mm/memlock.h
tools/lvmcmdlib.c
This page took 0.037988 seconds and 5 git commands to generate.