linux-stable/tools/testing/selftests/vm
David Rientjes 215ba78115 mm, selftests: test return value of munmap for MAP_HUGETLB memory
When MAP_HUGETLB memory is unmapped, the length must be hugepage aligned,
otherwise it fails with -EINVAL.

All tests currently behave correctly, but it's better to explcitly test
the return value for completeness and document the requirement, especially
if users copy map_hugetlb.c as a sample implementation.

Signed-off-by: David Rientjes <rientjes@google.com>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Davide Libenzi <davidel@xmailserver.org>
Cc: Luiz Capitulino <lcapitulino@redhat.com>
Cc: Shuah Khan <shuahkh@osg.samsung.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: Joern Engel <joern@logfs.org>
Cc: Jianguo Wu <wujianguo@huawei.com>
Cc: Eric B Munson <emunson@akamai.com>
Acked-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-04-15 16:35:19 -07:00
..
.gitignore selftests: add .gitignore for vm 2013-07-03 16:08:07 -07:00
hugepage-mmap.c mm: move hugepage test examples to tools/testing/selftests/vm 2012-03-28 17:14:37 -07:00
hugepage-shm.c mm: move hugepage test examples to tools/testing/selftests/vm 2012-03-28 17:14:37 -07:00
hugetlbfstest.c mm, selftests: test return value of munmap for MAP_HUGETLB memory 2015-04-15 16:35:19 -07:00
Makefile selftests: Set CC using CROSS_COMPILE once in lib.mk 2015-03-19 15:16:51 -06:00
map_hugetlb.c mm, selftests: test return value of munmap for MAP_HUGETLB memory 2015-04-15 16:35:19 -07:00
run_vmtests selftests: Introduce minimal shared logic for running tests 2015-03-13 15:13:40 -06:00
thuge-gen.c selftests: add a test program for variable huge page sizes in mmap/shmget 2012-12-11 17:22:25 -08:00
transhuge-stress.c selftests/vm/transhuge-stress: stress test for memory compaction 2014-10-09 22:26:01 -04:00