Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Unified Diff: sysdeps/nacl/irt.h

Issue 12382030: Provide mprotect syscall (Closed) Base URL: http://git.chromium.org/native_client/nacl-glibc.git@master
Patch Set: Remove addr const modifier from mprotect Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: sysdeps/nacl/irt.h
diff --git a/sysdeps/nacl/irt.h b/sysdeps/nacl/irt.h
index c363d032da8aafaf02b7466ee4e52ce466419dea..b4af11b988fd72ac54d8cb5ef4a0c119d2f7ca59 100644
--- a/sysdeps/nacl/irt.h
+++ b/sysdeps/nacl/irt.h
@@ -78,12 +78,20 @@ struct nacl_irt_filename {
};
#define NACL_IRT_MEMORY_v0_1 "nacl-irt-memory-0.1"
-struct nacl_irt_memory {
+struct nacl_irt_memory_v0_1 {
int (*sysbrk)(void **newbrk);
int (*mmap)(void **addr, size_t len, int prot, int flags, int fd, off_t off);
int (*munmap)(void *addr, size_t len);
};
+#define NACL_IRT_MEMORY_v0_2 "nacl-irt-memory-0.2"
+struct nacl_irt_memory_v0_2 {
+ int (*sysbrk)(void **newbrk);
+ int (*mmap)(void **addr, size_t len, int prot, int flags, int fd, off_t off);
+ int (*munmap)(void *addr, size_t len);
+ int (*mprotect)(void *addr, size_t len, int prot);
+};
+
#define NACL_IRT_DYNCODE_v0_1 "nacl-irt-dyncode-0.1"
struct nacl_irt_dyncode {
int (*dyncode_create)(void *dest, const void *src, size_t size);
@@ -154,6 +162,15 @@ struct nacl_irt_clock {
int (*gettime)(clockid_t clk_id, struct timespec *tp);
};
+/*
+ * NOTE: This is a 'dev' interface which is NOT stable.
+ * In the future, requests for this interface will fail.
+ */
+#define NACL_IRT_DEV_MPROTECT_v0_1 "nacl-irt-dev-mprotect-0.1"
Mark Seaborn 2013/03/29 15:48:07 You should remove this
Petr Hosek 2013/03/29 21:02:21 Removed.
+struct nacl_irt_dev_mprotect {
+ int (*mprotect)(void *addr, size_t len, int prot);
+};
+
#if __cplusplus
}
#endif
« no previous file with comments | « elf/Versions ('k') | sysdeps/nacl/irt_syscalls.h » ('j') | sysdeps/nacl/irt_syscalls.c » ('J')

Powered by Google App Engine
This is Rietveld 408576698