5
Line | |
---|
1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @brief Change Memory Protection |
---|
5 | * @ingroup POSIXAPI |
---|
6 | * |
---|
7 | * 12.2.3 Change Memory Protection, P1003.1b-1996, p. 277. |
---|
8 | * |
---|
9 | * This is not a functional version of mprotect() but the SPARC backend |
---|
10 | * for at least gcc 2.8.1 plus gnat 3.13p and gcc 3.0.1 require it to |
---|
11 | * be there and return 0. |
---|
12 | * |
---|
13 | * As of gcc 4.2.2, the gcc SPARC backend doesn't appear to have a |
---|
14 | * way to call this for RTEMS anymore but it doesn't hurt to leave it. |
---|
15 | */ |
---|
16 | |
---|
17 | /* |
---|
18 | * COPYRIGHT (c) 1989-2014. |
---|
19 | * On-Line Applications Research Corporation (OAR). |
---|
20 | * |
---|
21 | * The license and distribution terms for this file may be |
---|
22 | * found in the file LICENSE in this distribution or at |
---|
23 | * http://www.rtems.org/license/LICENSE. |
---|
24 | */ |
---|
25 | |
---|
26 | #if HAVE_CONFIG_H |
---|
27 | #include "config.h" |
---|
28 | #endif |
---|
29 | |
---|
30 | #include <unistd.h> |
---|
31 | #include <sys/mman.h> |
---|
32 | |
---|
33 | int mprotect( |
---|
34 | #ifdef HAVE_MPROTECT_CONST |
---|
35 | const void *addr, |
---|
36 | #else |
---|
37 | void *addr, |
---|
38 | #endif |
---|
39 | size_t len, |
---|
40 | int prot |
---|
41 | ) |
---|
42 | { |
---|
43 | (void) addr; |
---|
44 | (void) len; |
---|
45 | (void) prot; |
---|
46 | return 0; |
---|
47 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.