Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1695732
| From | Michal Hocko <mhocko@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH V2] selftests/vm: Add tests to validate mirror functionality with mremap |
| Date | 2017-07-25 15:40 +0200 |
| Message-ID | <u78e6-3nc-15@gated-at.bofh.it> (permalink) |
| References | <u71FE-7Lw-7@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue 25-07-17 12:06:57, Anshuman Khandual wrote:
[...]
> diff --git a/tools/testing/selftests/vm/mremap_mirror_private_anon.c b/tools/testing/selftests/vm/mremap_mirror_private_anon.c
[...]
> + ptr = mmap(NULL, alloc_size, PROT_READ | PROT_WRITE,
> + MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
> + if (ptr == MAP_FAILED) {
> + perror("map() failed");
> + return -1;
> + }
> + memset(ptr, PATTERN, alloc_size);
> +
> + mirror_ptr = (char *) mremap(ptr, 0, alloc_size, MREMAP_MAYMOVE);
> + if (mirror_ptr == MAP_FAILED) {
> + perror("mremap() failed");
> + return -1;
> + }
What is the point of this test? It will break with Mike's patch very
soon. Btw. it never worked.
--
Michal Hocko
SUSE Labs
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH V2] selftests/vm: Add tests to validate mirror functionality with mremap Anshuman Khandual <khandual@linux.vnet.ibm.com> - 2017-07-25 08:40 +0200
Re: [PATCH V2] selftests/vm: Add tests to validate mirror functionality with mremap Michal Hocko <mhocko@kernel.org> - 2017-07-25 15:40 +0200
Re: [PATCH V2] selftests/vm: Add tests to validate mirror functionality with mremap Anshuman Khandual <khandual@linux.vnet.ibm.com> - 2017-07-26 06:30 +0200
Re: [PATCH V2] selftests/vm: Add tests to validate mirror functionality with mremap Michal Hocko <mhocko@kernel.org> - 2017-07-26 07:50 +0200
csiph-web