lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170710134130.GA19645@dhcp22.suse.cz>
Date:   Mon, 10 Jul 2017 15:41:30 +0200
From:   Michal Hocko <mhocko@...nel.org>
To:     Anshuman Khandual <khandual@...ux.vnet.ibm.com>
Cc:     linux-mm@...ck.org, linux-kernel@...r.kernel.org,
        akpm@...ux-foundation.org, mike.kravetz@...cle.com
Subject: Re: [PATCH] mm/mremap: Document MREMAP_FIXED dependency on
 MREMAP_MAYMOVE

On Mon 10-07-17 17:02:11, Anshuman Khandual wrote:
> In the header file, just specify the dependency of MREMAP_FIXED
> on MREMAP_MAYMOVE and make it explicit for the user space.

I really fail to see a point of this patch. The depency belongs to the
code and it seems that we already enforce it
	if (flags & MREMAP_FIXED && !(flags & MREMAP_MAYMOVE))
		return ret;

So what is the point here?

> Signed-off-by: Anshuman Khandual <khandual@...ux.vnet.ibm.com>
> ---
>  include/uapi/linux/mman.h | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/include/uapi/linux/mman.h b/include/uapi/linux/mman.h
> index ade4acd..8cae3f6 100644
> --- a/include/uapi/linux/mman.h
> +++ b/include/uapi/linux/mman.h
> @@ -3,8 +3,10 @@
>  
>  #include <asm/mman.h>
>  
> -#define MREMAP_MAYMOVE	1
> -#define MREMAP_FIXED	2
> +#define MREMAP_MAYMOVE	1 /* VMA can move after remap and resize */
> +#define MREMAP_FIXED	2 /* VMA can remap at particular address */
> +
> +/* NOTE: MREMAP_FIXED must be set with MREMAP_MAYMOVE, not alone */
>  
>  #define OVERCOMMIT_GUESS		0
>  #define OVERCOMMIT_ALWAYS		1
> -- 
> 1.8.5.2
> 
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@...ck.org.  For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@...ck.org"> email@...ck.org </a>

-- 
Michal Hocko
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ