xref: /openbmc/linux/arch/x86/um/asm/vm-flags.h (revision 5c48b108)
15c48b108SAl Viro /*
25c48b108SAl Viro  * Copyright (C) 2004 Jeff Dike (jdike@addtoit.com)
35c48b108SAl Viro  * Copyright 2003 PathScale, Inc.
45c48b108SAl Viro  * Licensed under the GPL
55c48b108SAl Viro  */
65c48b108SAl Viro 
75c48b108SAl Viro #ifndef __VM_FLAGS_X86_H
85c48b108SAl Viro #define __VM_FLAGS_X86_H
95c48b108SAl Viro 
105c48b108SAl Viro #ifdef CONFIG_X86_32
115c48b108SAl Viro 
125c48b108SAl Viro #define VM_DATA_DEFAULT_FLAGS \
135c48b108SAl Viro 	(VM_READ | VM_WRITE | \
145c48b108SAl Viro 	((current->personality & READ_IMPLIES_EXEC) ? VM_EXEC : 0 ) | \
155c48b108SAl Viro 		 VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
165c48b108SAl Viro 
175c48b108SAl Viro #else
185c48b108SAl Viro 
195c48b108SAl Viro #define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \
205c48b108SAl Viro 	VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
215c48b108SAl Viro #define VM_STACK_DEFAULT_FLAGS (VM_GROWSDOWN | VM_READ | VM_WRITE | \
225c48b108SAl Viro 	VM_EXEC | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
235c48b108SAl Viro 
245c48b108SAl Viro #endif
255c48b108SAl Viro #endif
26