]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
tools/testing/selftests: add forked (un)/faulted VMA merge tests
authorLorenzo Stoakes <lorenzo.stoakes@oracle.com>
Mon, 5 Jan 2026 20:11:50 +0000 (20:11 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Thu, 15 Jan 2026 06:16:25 +0000 (22:16 -0800)
commitfb39444732f02c32a8312c168d97e33d872c14d3
tree079188eb6da912487bb7d63c5de24b4fea3783c3
parent3b617fd3d317bf9dd7e2c233e56eafef05734c9d
tools/testing/selftests: add forked (un)/faulted VMA merge tests

Now we correctly handle forked faulted/unfaulted merge on mremap(),
exhaustively assert that we handle this correctly.

Do this in the less duplicative way by adding a new merge_with_fork
fixture and forked/unforked variants, and abstract the forking logic as
necessary to avoid code duplication with this also.

Link: https://lkml.kernel.org/r/1daf76d89fdb9d96f38a6a0152d8f3c2e9e30ac7.1767638272.git.lorenzo.stoakes@oracle.com
Fixes: 879bca0a2c4f ("mm/vma: fix incorrectly disallowed anonymous VMA merges")
Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
Cc: David Hildenbrand (Red Hat) <david@kernel.org>
Cc: Jann Horn <jannh@google.com>
Cc: Jeongjun Park <aha310510@gmail.com>
Cc: Liam Howlett <liam.howlett@oracle.com>
Cc: Pedro Falcato <pfalcato@suse.de>
Cc: Rik van Riel <riel@surriel.com>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Yeoreum Yun <yeoreum.yun@arm.com>
Cc: Harry Yoo <harry.yoo@oracle.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
tools/testing/selftests/mm/merge.c