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

Unified Diff: src/include/minsfi.h

Issue 539683002: MinSFI: Add loader (Closed) Base URL: https://chromium.googlesource.com/native_client/src/native_client.git@master
Patch Set: Active sandbox interface Created 6 years, 3 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: src/include/minsfi.h
diff --git a/src/include/minsfi.h b/src/include/minsfi.h
new file mode 100644
index 0000000000000000000000000000000000000000..d44658f98ebd80599e2630a6d345dfdd2a250637
--- /dev/null
+++ b/src/include/minsfi.h
@@ -0,0 +1,32 @@
+/*
+ * Copyright (c) 2014 The Native Client Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+#ifndef SRC_INCLUDE_MINSFI_H_
jvoung (off chromium) 2014/09/08 23:18:47 I think the full NaCl header guards are: NATIVE_C
dbrazdil 2014/09/09 00:57:52 Done. (Lint said it was this but I see you're righ
+#define SRC_INCLUDE_MINSFI_H_
+
+#include <stdbool.h>
+#include <stdint.h>
+
+/*
+ * Allocates a memory region for the sandbox and initializes it. Returns TRUE
+ * if it was successful or if the sandbox has already been initialized.
+ */
+bool MinsfiInitializeSandbox(void);
+
+/*
+ * Invokes the entry function of the sandbox and returns the exit value
+ * returned by the sandbox. Returns EXIT_FAILURE if sandbox cannot be invoked,
+ * e.g. because it has not been initialized.
+ */
+int MinsfiInvokeSandbox(void);
+
+/*
+ * Destroys the MinSFI address subspace if there is one. Returns FALSE if
+ * a subspace exists but could not be destroyed.
+ */
+bool MinsfiDestroySandbox(void);
+
+#endif // SRC_INCLUDE_MINSFI_H_

Powered by Google App Engine
This is Rietveld 408576698