summaryrefslogtreecommitdiffstats
path: root/ppapi/api
diff options
context:
space:
mode:
authorjvoung <jvoung@chromium.org>2014-10-02 21:39:17 -0700
committerCommit bot <commit-bot@chromium.org>2014-10-03 04:39:52 +0000
commit203dbe474745b94c447c0e1dfc18cfae409a2840 (patch)
treedbab4650751f131dd515e1ce275008ec3198391a /ppapi/api
parenta03ae49d253d7d1f517e2f92146a6ba201c78aa6 (diff)
downloadchromium_src-203dbe474745b94c447c0e1dfc18cfae409a2840.zip
chromium_src-203dbe474745b94c447c0e1dfc18cfae409a2840.tar.gz
chromium_src-203dbe474745b94c447c0e1dfc18cfae409a2840.tar.bz2
NaCl: Replace launch/start param flags with a NaClAppProcessType enum.
There was already an enum called NaClProcessType (for the broker, etc.), so I called this NaClAppProcessType instead. Renamed the original NaClProcessType to NaClTrustedProcessType. This type can then be used to decide on various things like crash throttling, nexe size limits, dyncode enablement, IRT usage rather than plumb separate flags through the various layers and IPCs. Then we can tweak the "uses_irt" to be "optional" for the PNaClTranslator as well. Misc: removed enable_dev_interfaces from service_runtime SelLdrStartParams struct, since it looked unused. BUG= https://code.google.com/p/nativeclient/issues/detail?id=3914 Review URL: https://codereview.chromium.org/614373004 Cr-Commit-Position: refs/heads/master@{#297987}
Diffstat (limited to 'ppapi/api')
-rw-r--r--ppapi/api/private/ppb_nacl_private.idl31
1 files changed, 13 insertions, 18 deletions
diff --git a/ppapi/api/private/ppb_nacl_private.idl b/ppapi/api/private/ppb_nacl_private.idl
index 3924ca2..ba2b693 100644
--- a/ppapi/api/private/ppb_nacl_private.idl
+++ b/ppapi/api/private/ppb_nacl_private.idl
@@ -133,6 +133,17 @@ enum PP_NaClReadyState {
PP_NACL_READY_STATE_DONE = 4
};
+/** Types of untrusted NaCl processes. Mirrors NaClAppProcessType from
+ * components/nacl/common/nacl_types.h.
+ */
+enum PP_NaClAppProcessType {
+ PP_UNKNOWN_NACL_PROCESS_TYPE,
+ PP_NATIVE_NACL_PROCESS_TYPE,
+ PP_PNACL_PROCESS_TYPE,
+ PP_PNACL_TRANSLATOR_PROCESS_TYPE,
+ PP_NUM_NACL_PROCESS_TYPES
+};
+
struct PP_PNaClOptions {
PP_Bool translate;
PP_Bool is_debug;
@@ -158,36 +169,20 @@ interface PPB_NaCl_Private {
/* Launches NaCl's sel_ldr process. Returns PP_EXTERNAL_PLUGIN_OK on success
* and writes a NaClHandle to imc_handle. Returns PP_EXTERNAL_PLUGIN_FAILED on
* failure. The |enable_ppapi_dev| parameter controls whether GetInterface
- * returns 'Dev' interfaces to the NaCl plugin. The |uses_ppapi| flag
- * indicates that the nexe run by sel_ldr will use the PPAPI APIs.
- * This implies that LaunchSelLdr is run from the main thread. If a nexe
- * does not need PPAPI, then it can run off the main thread.
+ * returns 'Dev' interfaces to the NaCl plugin.
* The |nexe_file_info| is currently used only in non-SFI mode. It is the
* file handle for the main nexe file, which should be initially loaded.
* LaunchSelLdr takes the ownership of the file handle.
- * The |uses_irt| flag indicates whether the IRT should be loaded in this
- * NaCl process. This is true for ABI stable nexes.
* The |uses_nonsfi_mode| flag indicates whether or not nonsfi-mode should
* be used with the binary pointed by the url.
- * The |enable_dyncode_syscalls| flag indicates whether or not the nexe
- * will be able to use dynamic code system calls (e.g., mmap with PROT_EXEC).
- * The |enable_exception_handling| flag indicates whether or not the nexe
- * will be able to use hardware exception handling.
- * The |enable_crash_throttling| flag indicates whether or not crashes of
- * the nexe contribute to crash throttling statisics and whether nexe starts
- * are throttled by crash throttling.
*/
void LaunchSelLdr([in] PP_Instance instance,
[in] PP_Bool main_service_runtime,
[in] str_t alleged_url,
[in] PP_NaClFileInfo nexe_file_info,
- [in] PP_Bool uses_irt,
- [in] PP_Bool uses_ppapi,
[in] PP_Bool uses_nonsfi_mode,
[in] PP_Bool enable_ppapi_dev,
- [in] PP_Bool enable_dyncode_syscalls,
- [in] PP_Bool enable_exception_handling,
- [in] PP_Bool enable_crash_throttling,
+ [in] PP_NaClAppProcessType process_type,
[out] mem_t imc_handle,
[in] PP_CompletionCallback callback);