18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci * This program is free software; you can redistribute it and/or
48c2ecf20Sopenharmony_ci * modify it under the terms of the GNU General Public License
58c2ecf20Sopenharmony_ci * as published by the Free Software Foundation; either version
68c2ecf20Sopenharmony_ci * 2 of the License, or (at your option) any later version.
78c2ecf20Sopenharmony_ci */
88c2ecf20Sopenharmony_ci#ifndef _UAPI_ASM_POWERPC_MMAN_H
98c2ecf20Sopenharmony_ci#define _UAPI_ASM_POWERPC_MMAN_H
108c2ecf20Sopenharmony_ci
118c2ecf20Sopenharmony_ci#include <asm-generic/mman-common.h>
128c2ecf20Sopenharmony_ci
138c2ecf20Sopenharmony_ci
148c2ecf20Sopenharmony_ci#define PROT_SAO	0x10		/* Strong Access Ordering */
158c2ecf20Sopenharmony_ci
168c2ecf20Sopenharmony_ci#define MAP_RENAME      MAP_ANONYMOUS   /* In SunOS terminology */
178c2ecf20Sopenharmony_ci#define MAP_NORESERVE   0x40            /* don't reserve swap pages */
188c2ecf20Sopenharmony_ci#define MAP_LOCKED	0x80
198c2ecf20Sopenharmony_ci
208c2ecf20Sopenharmony_ci#define MAP_GROWSDOWN	0x0100		/* stack-like segment */
218c2ecf20Sopenharmony_ci#define MAP_DENYWRITE	0x0800		/* ETXTBSY */
228c2ecf20Sopenharmony_ci#define MAP_EXECUTABLE	0x1000		/* mark it as an executable */
238c2ecf20Sopenharmony_ci
248c2ecf20Sopenharmony_ci
258c2ecf20Sopenharmony_ci#define MCL_CURRENT     0x2000          /* lock all currently mapped pages */
268c2ecf20Sopenharmony_ci#define MCL_FUTURE      0x4000          /* lock all additions to address space */
278c2ecf20Sopenharmony_ci#define MCL_ONFAULT	0x8000		/* lock all pages that are faulted in */
288c2ecf20Sopenharmony_ci
298c2ecf20Sopenharmony_ci/* Override any generic PKEY permission defines */
308c2ecf20Sopenharmony_ci#define PKEY_DISABLE_EXECUTE   0x4
318c2ecf20Sopenharmony_ci#undef PKEY_ACCESS_MASK
328c2ecf20Sopenharmony_ci#define PKEY_ACCESS_MASK       (PKEY_DISABLE_ACCESS |\
338c2ecf20Sopenharmony_ci				PKEY_DISABLE_WRITE  |\
348c2ecf20Sopenharmony_ci				PKEY_DISABLE_EXECUTE)
358c2ecf20Sopenharmony_ci#endif /* _UAPI_ASM_POWERPC_MMAN_H */
36