Re: [PATCH v2 1/4] selftest/vm: verify mmap addr in mremap_test

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 4/20/22 3:57 PM, Sidhartha Kumar wrote:
Avoid calling mmap with requested addresses that are less than the system's
mmap_min_addr. When run as root, mmap returns EACCES when trying to map
addresses < mmap_min_addr. This is not one of the error codes for the
condition to retry the mmap in the test. Rather than arbitrarily retrying
on EACCES, don't attempt an mmap until addr > vm.mmap_min_addr.

Add a munmap call after an alignment check as the mappings are retained
after the retry and can reach the vm.max_map_count sysctl.

Signed-off-by: Sidhartha Kumar <sidhartha.kumar@xxxxxxxxxx>
---
v2:
-change comment for description of get_mmap_min_addr()
-fix commit message formatting


Thank you.

Reviewed-by: Shuah Khan <skhan@xxxxxxxxxxxxxxxxxxx>

Andrew, please let me know if you would like me to take this
through kselftest tree.

thanks,
-- Shuah




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux